Thursday, March 09, 2006

php di x86_64 (1)

Seharian aku mash oprek-oprek Server SunFore x4100, yahh.. memang sech ini kali pertama saya berhadapan dengan Mesin x86_64 tapi denagn demikian aku bisa belajar lebih banyak, Server ini sudah saya install RHEL4 U2 ES dan Oracle 10g, sampai disini semua Running Well.

Tetapi gliran mau meng-compile PHP, fiuhhh... banyak banget trouble-nya, mulai dari saat configure karena processornya 64 bit, jadi gcc-nya mungkin juga ngikutin 64 bit, akibatnya baru configure aja udah error :

configure: error: can not run test program while cross compiling

Kemudian saya coba configure lagi dengan tambahan CC="gcc -m32", dan kompilasi berhasil, saya lihat di direktori /etc/httpd/modules ada file libphp4.so tetapi waktu saya start Apache "/etc/init.d/httpd start" muncul error :

Starting httpd: Syntax error on line 6 of /etc/httpd/conf.d/php.conf:
Cannot load /etc/httpd/modules/libphp4.so into server:
/etc/httpd/modules/libphp4.so: cannot open shared object file: No such
file or directory
[FAILED]

padahal file libphp4.so itu ada, pusing ga sich, selidik punya selidik memang file
/etc/httpd/modules/libphp4.so adalah 32 Bit sedangkan /usr/sbih/httpd 64 bit, mungkin ga cocok ya sehingga si Apache bilang "cannot open shared object file: No such file or directory"

[hani@sunfire ~]$ file /etc/httpd/modules/libphp4.so
/etc/httpd/modules/libphp4.so: ELF 32-bit LSB shared object, Intel 80386, version 1 (SYSV), not stripped

[hani@sunfire ~]$ file /usr/sbin/httpd
/usr/sbin/httpd: ELF 64-bit LSB shared object, AMD x86-64, version 1 (SYSV), stripped

Saya sudah agak pusing nech, mungkin lebih baik diterusin aja besok pagi.

No comments: