Hello, I am trying to compile mod_perl-2.0.4 for Apache httpd-2.2.17 on Solaris10 SunOS 5.10 Generic_141414-10 sun4v sparc SUNW,SPARC-Enterprise-T5120
I am facing ld: wrong ELF class: ELFCLASS64 problem. Everyting was compiled in m -64 mode, generated .so 64bit, with export CC="gcc -m64" When compiling mod_perl it looks its trying to compile in 32bit mode, dont understand why. How to forse it to compile in 64bit mode? Till now gcc -m64 was good to use, with exported LD_LIBRARY_PATH and PATH for sparcv9 CFLAGS="-L/usr/sfw/lib/sparcv9 -R/usr/sfw/lib/sparcv9" Perl Version: perl-5.12.2 Can you advise, please? No error log under t/logs/error_log ld: fatal: file /pkg/products/httpd_test/httpd/httpd-2.2.17a/apr-util//lib/libaprutil-1.so: wrong ELF class: ELFCLASS64 ld: fatal: file /pkg/products/httpd_test/httpd/httpd-2.2.17a/apr-util//lib/libexpat.so: wrong ELF class: ELFCLASS64 ld: fatal: file /pkg/products/httpd_test/httpd/httpd-2.2.17a/apr/lib/libapr-1.so: wrong ELF class: ELFCLASS64 ld: fatal: File processing errors. No output written to ../../../blib/arch/auto/APR/APR.so collect2: ld returned 1 exit status *** Error code 1 make: Fatal error: Command failed for target `../../../blib/arch/auto/APR/APR.so' Current working directory /home/admin/kstas/httpd/modules/mod_perl/mod_perl-2.0.4/xs/APR/APR *** Error code 1 The following command caused the error: cd APR && make -f Makefile all LIBPERL_A="libperl.a" LINKTYPE="dynamic" OPTIMIZE="-fPIC" PREFIX="/pkg/products/perl/perl-5.12.2" PASTHRU_INC="" make: Fatal error: Command failed for target `subdirs' Current working directory /home/admin/kstas/httpd/modules/mod_perl/mod_perl-2.0.4/xs/APR *** Error code 1 The following command caused the error: cd APR && make -f Makefile all LIBPERL_A="libperl.a" LINKTYPE="dynamic" OPTIMIZE="-fPIC" PREFIX="/pkg/products/perl/perl-5.12.2" PASTHRU_INC="" make: Fatal error: Command failed for target `subdirs' Current working directory /home/admin/kstas/httpd/modules/mod_perl/mod_perl-2.0.4/xs *** Error code 1 The following command caused the error: cd xs && make -f Makefile all LIBPERL_A="libperl.a" LINKTYPE="dynamic" OPTIMIZE="-fPIC" PREFIX="/pkg/products/perl/perl-5.12.2" PASTHRU_DEFINE="" PASTHRU_INC="" PERL="/pkg/products/perl/perl-5.12.2/bin/perl" DEFINE="-DMP_HAVE_APR_LIBS" make: Fatal error: Command failed for target `subdirs'