[PHP-users 25630] Re: php+mysqlサーバ構築

tamura masuhisa wander1275 @ hotmail.co.jp
2005年 5月 18日 (水) 20:30:04 JST


こんにちは、muです。

色々報告があり、長くなってます^^;

中村さん、三村さん、ぢょ〜@よくきたなさんお返事ありがとうございます。

>中村さん
>'--disable-all' が問題の原因では?
>これでは、mysql.soもできないと思いますが。

なるほど。それを取り消さなければいけませんね。

>三村さん
>FreeBSDを利用しているのなら、
>/usr/ports/lang/php4
>/usr/ports/lang/php4-extensions
>このportsからインストールするのが一番簡単だと思います。
>ただこの場合、apacheもportsから入れておかないといけないですね。

$portversion
portversion: Command not found. 
でした。

find / -name portsを実行しましたが、portsでHITしませんでした。
portsではやってないように思えました・・。

安い専用サーバーには罠があります><

>ぢょ〜@よくきたなさん
>http://wiki.poyo.jp/read/PHP/tips/mod_add_later
   ようは
>$ cd php-<version>/ext/mysql
>$ phpize   (コマンドなかったら困るな)
>$ ./configure --with-mysql
>$ make
>$ su -c "make install"
>    とかでしょうか?

おお!こんなやり方があったのですか!
で、さっそくやってみました。

ちょっと長くなります^^;

PHP 4.3.10のtarballを取得し、展開。

phpizeは/usr/local/bin内にあったので、実行。

$/usr/local/src/php-4.3.10/ext/mysql> /usr/local/bin/phpize

aclocal14 not found.と表示

phpizeのソースを読むとaclocal14,autoconf253,autoheader253が必要と書いてい
る。

それぞれはfreebsdをインストールしているなら/usr/local/binに入っているようだ
けど、
なぜかこの専用サーバーにはない。

したがって、それぞれのtarballを取得し、展開することに。

「aclocal」はautomake-1.4-p6.tar.gzをDLし、展開した。

$tar zxvf automake-1.4-p6.tar.gz
$cd automake-1.4-p6
$./configure
$make
$make check
$make install

「autoconf」,「autoheader」はautoconf-2.53.tar.gzをDLし、展開した。

$tar zxvf autoconf-2.53.tar.gz
$cd autoconf-2.53
$./configure
$make
$make check
$make install

ここで、phpizeを実行すると、m4が足りないと言われる。
m4-1.4.tar.gzをDLし、展開した。

$tar zxvf m4-1.4.tar.gz
$cd m4-1.4
$./configure
$make
$make check
$make install

そうして、phpizeを実行
$/usr/local/src/php-4.3.10/ext/mysql> /usr/local/bin/phpize
autoheader: `config.h.in' is unchanged
Configuring for:
  PHP Api Version:   20020918
  Zend Module Api No:   20020429
  Zend Extension Api No:   20021010

なんとか成功。

次に./configure


www /usr/local/src/php-4.3.10/ext/mysql> ./configure --with-mysql
creating cache ./config.cache
checking host system type... i386-unknown-freebsd4.11
checking for gcc... gcc
checking whether the C compiler (gcc  ) works... yes
checking whether the C compiler (gcc  ) is a cross-compiler... no
checking whether we are using GNU C... yes
checking whether gcc accepts -g... yes
checking whether gcc and cc understand -c and -o together... yes
checking how to run the C preprocessor... gcc -E

・・・・・・・・・・
(中略)
・・・・・・・・・・

appending configuration tag "CXX" to libtool
checking for ld used by g++... /usr/libexec/elf/ld
checking if the linker (/usr/libexec/elf/ld) is GNU ld... yes
checking whether the g++ linker (/usr/libexec/elf/ld) supports shared 
libraries... yes
checking for g++ option to produce PIC... -fPIC
checking if g++ PIC flag -fPIC works... yes
checking if g++ supports -c -o file.o... yes
checking whether the g++ linker (/usr/libexec/elf/ld) supports shared 
libraries... yes
checking dynamic linker characteristics... freebsd4.11 ld.so
checking how to hardcode library paths into programs... immediate
checking whether stripping libraries is possible... yes
appending configuration tag "F77" to libtool
checking if libtool supports shared libraries... yes
checking whether to build shared libraries... yes
checking whether to build static libraries... no
checking for f77 option to produce PIC... -fPIC
checking if f77 PIC flag -fPIC works... yes
checking if f77 supports -c -o file.o... yes
checking whether the f77 linker (/usr/libexec/elf/ld) supports shared 
libraries... yes
checking dynamic linker characteristics... freebsd4.11 ld.so
checking how to hardcode library paths into programs... immediate
checking whether stripping libraries is possible... yes
configure: error: tag name "CXX" already exists


"CXX"は既に存在しているとエラーで止まりました。
ここから先に進めなくなりました><

ちなみに
$ext/mbstring>./configure --enable-mbstring --enable-mbregex
mbstringで行っても同じところで止まりました。

configure: error: tag name "CXX" already exists
の原因が分かる方いらっしゃいますでしょうか?

ここまで来たからには最後までやってみたいと思います!

よろしくおねがいします!

_________________________________________________________________
無料250MBメールボックスのMSN Hotmail 
https://registernet.passport.net/reg.srf?id=2&lc=1041 



PHP-users メーリングリストの案内