工具/软件:TI C/C++编译器
您好!
我使用 Utimaco 的 CryptoServer (LAN V5) HSM、后者使用 TI 的 C6000工具链进行编译。 我需要修改生成的.out 文件。 我正在寻找像 objcopy 这样的工具来修改其中一个段。 这是一个与我希望执行的操作等效的 GCC、
$ cat hello.c
#include
int moduleID __attribute__( section("ediman"))=0;
int main (int argc、char** argv){
printf ("moduleID 为%d\n"、moduleID);
返回0;
}
$ gcc hello.c
$./a.out
模数 ID 为0
$ objcopy --dump-section ediman=edithere.bin a.out
$ hexdump -C edithere.bin
00000000 00 00 00 00 |……|
$ printf "\x7f\x00\x00\x00"> edithere.bin
$ objcopy --update-section ediath=edithere.bin a.out
$./a.out
模数 ID 为127
我研究了雷达2、但令人惊讶的是、它似乎无法识别 TI COFF2格式。 您能告诉我如何使用 C6000工具执行相同的操作吗?
谢谢、
Krishnan