アプリ版:「スタンプのみでお礼する」機能のリリースについて

Red Hat ES 3にPHP5.2.5をインストールしようとしています。
configure時に(オプションは後述)、

configure: error: GD build test failed. Please check the config.log for details.
と出てしまい、config.logを見てもよくわかりません。
(config.log 頭省略)
configure:43450: gcc -o conftest -g -O2 -Wl,-rpath,/usr/local//lib -L/usr/local//lib -Wl,-rpath,/usr/local/lib -L/usr/local/lib -Wl,-rpath,/usr/local//lib -L/usr/local//lib conftest.c -lgd -lgd -lfreetype -lpng -lz -ljpeg -lz -lresolv -lm -ldl -lnsl -lxml2 -lz -lm -lxml2 -lz -lm 1>&5
/usr/local//lib/libgd.so: undefined reference to `libiconv_open'
/usr/local//lib/libgd.so: undefined reference to `libiconv_close'
/usr/local//lib/libgd.so: undefined reference to `libiconv'
collect2: ld returned 1 exit status
configure: failed program was:
#line 43439 "configure"
#include "confdefs.h"
/* Override any gcc2 internal prototype to avoid an error. */
/* We use char because int might match the return type of a gcc2
builtin and then its argument prototype would still apply. */
char gdImageCreate();

int main() {
gdImageCreate()
; return 0; }
---------------------------

undefined reference to `libiconv_open'
かなと予想していますが、どこをどうしていいのやら?
ちなみに
# ls -l /usr/local/lib/libgd.so
/usr/local/lib/libgd.so -> libgd.so.2.0.0
でちゃんとシンボリックリンクは設定されているようです。

どなたか対処方法・調査方法がご存知の方、ぜひぜひご教授ください。m(_._)m

※ configureオプション
./configure --with-apxs2=/usr/local/apache2/bin/apxs --enable-mbstring --enable-mbsrt-enc-trans --enable-mbregex --enable-trans-sid --with-mysql=/usr/local/mysql --with-zlib-dir=/usr/local/lib --with-png-dir=/usr/local/lib --with-jpeg-dir=/usr/local/lib --with-freetype-dir=/usr/local/lib --with-gd=/usr/local/ --enable-gd-native-ttf --enable-gd-jis-conv

A 回答 (1件)

libiconvをインストールしていないからでは?


GDが入っていても、ライブラリがないからエラーになっています。

この回答への補足

ありがとうございます。
http://www.gnu.org/software/libiconv/#TOCdownloa …
からダウンロード(libiconv-1.12.tar.tar)してlibiconvをインストールしましたが同じ状態でした。
う~ん、困った…。取り急ぎお礼まで

補足日時:2008/05/01 10:04
    • good
    • 0
この回答へのお礼

自己レスになりますが、
http://d.hatena.ne.jp/rougeref/20061211
に回答があり、試したところうまくいきました。

configureの前に
$ export LDFLAGS=-liconv
にてLDFLAGS環境変数を定義してあげます。

ありがとうございます。

お礼日時:2008/05/01 11:17

お探しのQ&Aが見つからない時は、教えて!gooで質問しましょう!