Liste des Groupes | Revenir à cl c |
On Fri, 31 May 2024 13:55:33 +0100
No, it does not work like that.I've now tried all sorts of combinations. While I can display the address of _binary_hello_c_size, it will crash if I try and deference it.
First, copy *exactly* what I said in my previous post.
Only after you reproduced, start to be smart.
_binary_hello_c_size is a link simbol rather than variable.
Declaration:
extern char _binary_hello_c_size[];
Usage:
printf("%zd\n", (size_t)_binary_hello_c_size);
There are two possibilities I'm interested in:One small matter is those ugly, long identifiers. A bigger one inThe tool is not made specifically for ASCII strings, it is more generic.
this case is that I really want that embedded text to be zero
terminated; here it's unlikely to be.
>
You said RTFM; I did. Nowhere did it say you have to use ELF object format /on Windows/.Unfortunately gcc/ld doesn't recognise the output of objcopy. EvenIt recognizes it if lye to objcopy about format.
though it accepts the output of mcc which is the same COFF format.
>
Specify elf64-x86-64 instead of pe-x86-64 and everything suddenly
works.
It's all was said in my posts from yesterday. It does not sound like you
had read them.
Les messages affichés proviennent d'usenet.