I tried a few ways, but none seemed working.
After unpack the perl 5.10.0
1) setarch i386 ./Configure
The perl was compiled successfully. But the executable is still 64
bit
2) Configure
When ptompted for the architecture, answered with "i386"
The perl was compiled successfully. But the executable is still
64 bit
3) Configure -des -Dcc="gcc -m32"
get the following error:
gcc -m32 -o try -O2 -fno-strict-aliasing -pipe -I/usr/local/
include -L/usr/local/lib try.c -lnsl -lgdbm -ldb -ldl -lm -lcrypt -
lutil -lc
./try
and I got the following output:
/usr/bin/ld: skipping incompatible /usr/lib64/libgdbm.so when
searching for -lgdbm
/usr/bin/ld: skipping incompatible /usr/lib64/libgdbm.a when searching
for -lgdbm
/usr/bin/ld: cannot find -lgdbm
collect2: ld returned 1 exit status
I can't compile the test program.
You have a BIG problem. Shall I abort Configure [y]
Ok. Stopping Configure.
Do I have install 32bit gcc to compile? Can 64bit gcc and 32bit gcc co-
exist in the box?
Thanks.
Actually the 3rd method would work . The error I got was the 32bit
librarie files /usr/lib/libgdbm.so and /usr/lib/libdb.so are needed
for the compilation. The 64 bit version will not work. After I
installed the gdbm-devel and db4-devel, the compilation was good the
generated perl executable is ELF-32, which is what we are looking for.
Thanks.