[PHP-users 15055]Re: libphp4.soが生成されません

habuchi @ koin.or.jp habuchi @ koin.or.jp
2003年 5月 6日 (火) 20:55:05 JST


羽渕です。
原因不明ですが解決しました。
以下あまり役に立たないと思いますが、報告まで。


> 中満です.
> 
> ログは添付ファイルではなく多少長くとも本文に記述してください.
> でないと過去ログ検索出来ない場合があります.
> 
> (っていうかmakeログのlibphp.soが関連する部分だけで良いのに・・・)

そうですね、以後気をつけます。


> makeの最後の部分でlibphp.soではなく静的なlibphp.laが作成されてい
> ますね.
> そもそもapacheはDSOモジュール可能な状態でインストールされています
> か?

ApacheのDSO moduleを有効にしていないとmakeの段階でその旨メッセージが出てmake自体を失敗します。と言っても、

> あと今回の問題には関係無いと思いますが,質問の前にもうちょっと
> 自分の操作を疑ってみてはどうですか?
> 
> (都合により改行あり)
> ./configure --with-imap=/usr/local --with-gettext=/usr/local \
> --with-apxs=/usr/local/apache/bin/apxs --enable-zend-multibyte \
> enable-mbstring --enable-mbstr-euc-trans --without-mysql \
> ^^^^^^^^^^^^^^^
> --without-pgsql --with-config-file-path=/usr/local/apache/conf
> (略)
> checking host system type... Invalid configuration `enable-
> mbstring': machine `enable' not recognized
>                              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
> ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

初歩的なミスをしているのででかい顔できません。
オプションの記述がめんどくさかったのでエディタで編集しながらコピペで何回かしているうちに間違えたみたいです申し訳なし。
ちなみに、オプションの記述ミスを修正しても結果は同じでした。


清水さんの指摘を参考に、
(今までlogあまり見てませんでした。これも反省します。非常に有用ですね)


> checking build system type... Invalid configuration `enable-
> mbstring':
> machine `enable' not recognized
> これはミス
はい。

> 羽渕さんの環境
> checking if gcc supports -fno-rtti -fno-exceptions... yes
> checking whether the linker (/usr/ccs/bin/ld) supports shared 
> libraries...
> nochecking how to hardcode library paths into programs... 
> unsupported
> checking whether stripping libraries is possible... no
> checking dynamic linker characteristics... no
> checking if libtool supports shared libraries... no
> checking whether to build shared libraries... no
> checking whether to build static libraries... yes
> creating libtool
> 
> 私のてもと(i386-gnu-linux(2.4))
> checking if gcc supports -fno-rtti -fno-exceptions... yes
> checking whether the linker (/usr/bin/ld) supports shared 
> libraries... yes
> checking how to hardcode library paths into programs... immediate
> checking whether stripping libraries is possible... yes
> checking dynamic linker characteristics... GNU/Linux ld.so
> checking if libtool supports shared libraries... yes
> checking whether to build shared libraries... yes
> checking whether to build static libraries... no
> checking whether -lc should be explicitly linked in... no
> creating libtool 

・gccのバージョンをpackageで3.2.3に。
・.cshrcでpathを変更。
・ldがOS標準であったのでphpのconfigureでgnu-ldをオプションに追加。
・標準ldはrename


checking if gcc supports -fno-rtti -fno-exceptions... yes
checking whether the linker (/opt/sfw/bin/ld) supports shared libraries... yes
checking how to hardcode library paths into programs... immediate
checking whether stripping libraries is possible... no
checking dynamic linker characteristics... solaris2.9 ld.so
checking if libtool supports shared libraries... yes
checking whether to build shared libraries... yes
checking whether to build static libraries... no
creating libtool

で上記の結果。
しかし、makeで大量のwarningが発生。
行ったれ!とばかりにやけの、make installで同じエラー発生。
清水さんの指摘では環境的なものとの事だったので、

> > 来週バージョンを上げて試してみます。

これも無駄だろうと思いながらも、php-4.3.1を同じオプションでmakeのみ。
同様に大量のwaning発生。libs フォルダは空。
findで libphp4.soを探すと
.libsフォルダが生成され、そのなかに

libphp4.la   libphp4.lai  libphp4.so

を発見。

再度、php4.2.3-multibyteでmake。
configureでこける。
gcc-3.2.3で大量のwaningがでるので元のgcc-2.95.3を使用(.cshrcでpathの編集)オプションのgnu-ldを消し、renameしたldを元に。(OS標準を使用)
make後、libs ディレクトリは空。.libsディレクトリに

libphp4.la   libphp4.lai  libphp4.s

を確認。

make installですんなり入ました。
タイムスタンプ、<? phpinfo() ?>で確認しましたが、ちゃんと入っています。

訳がわかりません。
原因は?ですが、一応連絡まで。お騒がせしました。


--------------------------------
甲南インターネット(株)
羽渕 祥宏
mail habuchi @ koin.or.jp


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