According to the GCC documentation, when compiling with -m64, sizeof(long) should be 8, but in MinGW-W64, it's 4.
I don't need long to be 8-byte, but I'd like to know what's right (i.e. how it will be in the future).
version (filename):
mingw-w64-bin_i686-mingw_20080613.zip
Logged In: YES
user_id=1598680
Originator: NO
This is an abi difference between x86_64 and w64. For linux64 (and most other 64-bit unixes) the sizeof(long) is a scalar of 8 bytes. These platforms use the lp64 convention. For some strange reasons (IIUC for backward compatiblity with old windows sources) MS deceided to let the sizeof(long) having a scalar width of 4 bytes. This target uses the llp64 convention.
I hope I could help you by this anwser.
Cheers,
Kai
Logged In: YES
user_id=1956577
Originator: YES
Yes, you've helped me. Thanks, Jenda