茨城県つくばみらい市から来ました

プログラマーになるために生きています

つづき。

昨日の。libmondaiは警告無視してやった。
キャストの警告だから宣言のとこさえ見直せばクリーンなビルドができるかもしれんけど今はそんな時間がないんだぜ。(でもハマってる)

# cd panda-1.2.8
# ./configure --cache-file=/dev/null --with-ruby=`which ruby` --with-postgres --with-shell --with-ssl --with-eruby=`which eruby`
(snip)

                                                                                                          • -

panda Configuration:

VERSION: 1.2.8
GNOME support: yes
client support: yes
PostgreSQL support: yes
shell driver support: yes
Oseki/Search support: no
dotCOBOL support: no
OpenCOBOL support: no
Ruby support: yes
pty message support: no
IP v6 support: no
SSL support: no
OKI support: no
msgd support: no
syslog support: no
IE5 support: no
MCE support: no
ERUBY support: yes

最初のうちはイントラだけだろうし、SSLはあーとーでー。

# make
(snip)
blob_v1.c:294: error: conflicting types for ‘OpenBLOB_V1’
blob_v1.h:80: error: previous declaration of ‘OpenBLOB_V1’ was here
make[2]: *** [blob_v1.o] エラー 1

うえっ。定義で関数の型が違うぢゃん。これなら厨の僕にもわかる!
ヘッダの型の方が正しいんだろ、たぶん。違ったらどうしよう。

# make
(snip)
/bin/sh ../libtool --mode=link gcc -g -O2 -o System.la -rpath /usr/local/lib -module -export-dynamic dbgroup.lo redirect.lo System.lo ../libs/libpandas.a -lcrypt -lpthread -ldl

Warning: Linking the shared library System.la against the
static library ../libs/libpandas.a is not portable!

rm -fr .libs/System.la .libs/System.* .libs/System.*
gcc -shared dbgroup.lo redirect.lo System.lo ../libs/libpandas.a -lcrypt -lpthread -ldl -Wl,-soname -Wl,System.so.0 -o .libs/System.so.0.0.0
/usr/bin/ld: ../libs/libpandas.a(term.o): relocation R_X86_64_32 against `a local symbol' can not be used when making a shared object; recompile with -fPIC
../libs/libpandas.a: could not read symbols: Bad value
collect2: ld returned 1 exit status
make[2]: *** [System.la] エラー 1

今日はモチベーションがあんまり高くないので全てのオプションに-fPICを追加
configureからリトライするけど再発。CFLAGSが使われてないヨカーン。(ちゃんと読みましょう)
ゴニョゴニョっと。

# ./configure --cache-file=/dev/null --with-ruby=`which ruby` --with-postgres --with-shell --with-ssl --with-eruby=`which eruby`
# make clean
# make
(snip)
gcc -DHAVE_CONFIG_H -I. -I. -I.. -I.. -I../include -I../libs -I/usr/include/glib-1.2 -I/usr/lib64/glib/include -I/usr/include/glib-1.2 -I/usr/lib64/glib/include -I/usr/include/libxml2 -I/usr/local/include/libmondai -g -O2 -fPIC -c glserver.c
glserver.c: In function ‘main’:
glserver.c:125: error: ‘fSsl’ undeclared (first use in this function)
glserver.c:125: error: (Each undeclared identifier is reported only once
glserver.c:125: error: for each function it appears in.)
make[2]: *** [glserver.o] エラー 1

いやぁん。定義されてないのぉぉぉぉぉっ
該当箇所を適当にゴニョる。イフ!デフ!エルス!エンドイフ!

# make clean
# make

( ^ω^)トオッター