Help Compiling 64bit Python
John Abel
john.abel at pa.press.net
Sat Sep 20 08:28:53 EDT 2003
Martin v. Löwis wrote:
>John Abel <john.abel at pa.press.net> writes:
>
>
>
>>c++ -o python \
>> Modules/python.o \
>> libpython2.3.a -lresolv -lsocket -lnsl -lrt -ldl
>>-lpthread -lm
>>ld: fatal: file Modules/python.o: wrong ELF class: ELFCLASS64
>>ld: fatal: File processing errors. No output written to python
>>collect2: ld returned 1 exit status
>>make: *** [python] Error 1
>>
>>I'd be very grateful for any pointers.
>>
>>
>
>You need to arrange to use the -m options in the linker line as well.
>
>Looking at the generated Makefile will tell you where to best insert
>these options.
>
>Regards,
>Martin
>
>
I seem to be missing something really obvious here. I've modified the
Makefile so it looks like this:
CONFIG_ARGS= 'CC=gcc -mcpu=v9 -m64 -D_LARGEFILE64_SOURCE=1'
'LDFLAGS=-mcpu=v9 -m64'
ran the make, and it still comes up with the same error. I've even
tried running it with LDFLAGS=-64, with the same result.
Regards
John
More information about the Python-list
mailing list