[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[debian-users:29704] Making a package wu-imapd++
柴田(あ)です。
現在、プログラミングについてわからないながらも、
初めてパッケージの作成に取り組んでいます。
しかしながら進めなくなってしまったので先達の教えを
乞いたく投稿いたします。
■目的
・拡張アドレスを使いたい ( user-hoge user-fuga のように )
・拡張アドレスを pop で受け取りたい
・すでに qmail が動いているので、 qmail といっしょに使いたい
・いきなり make と make install より .deb パッケージにしたい
■状況
●ソースは http://www.gentei.org/~yuuji/software/imapext/ から
もらって作成しようとしています。
ファイルは imap-2000c-qmav20010711.tar.gz
●上記ファイルを展開した後、 Make file の指定を見て、
dh_make してできた debian/rules には先頭のほうにある
#$(MAKE) を sl5 をつけ、コメント扱いでないように
改変してみました。
− 前略 −
# This is the debhelper compatability version to use.
export DH_COMPAT=1
build: build-stamp
build-stamp:
dh_testdir
# Add here commands to compile the package.
$(MAKE) sl5 ← sl5 をつけ、コメント扱いでないようにした
touch build-stamp
clean:
dh_testdir
dh_testroot
− 後略 −
●その後 debuild コマンドすると下記のようなエラーで停止します。
~/tmp/imap-2000c-qmav/debian$ debuild
dpkg-buildpackage: source package is imap
dpkg-buildpackage: source version is 2000c-qmav-1
dpkg-buildpackage: source maintainer is SHIBATA Akira <shibata@xxxxxxxxxxxxxx>
fakeroot debian/rules clean DEB_BUILD_ARCH=i386 DEB_BUILD_GNU_CPU=i386 DEB_BUILD_GNU_SYSTEM=linux DEB_BUILD_GNU_TYPE=i386-linux DEB_HOST_ARCH=i386 DEB_HOST_GNU_CPU
=i386 DEB_HOST_GNU_SYSTEM=linux DEB_HOST_GNU_TYPE=i386-linux
dh_testdir
dh_testroot
rm -f build-stamp
# Add here commands to clean up after the build process.
make clean
make[1]: Entering directory `/home/shibata/tmp/imap-2000c-qmav'
Removing old processed sources and binaries...
sh -c 'rm -rf an ua OSTYPE c-client mtest imapd ipopd || true'
cd tools;make clean
make[2]: Entering directory `/home/shibata/tmp/imap-2000c-qmav/tools'
sh -c 'rm -f *.o uahelper || true'
make[2]: Leaving directory `/home/shibata/tmp/imap-2000c-qmav/tools'
make[1]: Leaving directory `/home/shibata/tmp/imap-2000c-qmav'
dh_clean
dpkg-source -b imap-2000c-qmav
dpkg-source: building imap using existing imap_2000c-qmav.orig.tar.gz
dpkg-source: building imap in imap_2000c-qmav-1.diff.gz
dpkg-source: building imap in imap_2000c-qmav-1.dsc
debian/rules build DEB_BUILD_ARCH=i386 DEB_BUILD_GNU_CPU=i386 DEB_BUILD_GNU_SYSTEM=linux DEB_BUILD_GNU_TYPE=i386-linux DEB_HOST_ARCH=i386 DEB_HOST_GNU_CPU=i386 DEB
_HOST_GNU_SYSTEM=linux DEB_HOST_GNU_TYPE=i386-linux
dh_testdir
# Add here commands to compile the package.
make sl5
make[1]: Entering directory `/home/shibata/tmp/imap-2000c-qmav'
Applying an process to sources...
tools/an "ln -s" src/c-client c-client
tools/an "ln -s" src/ansilib c-client
tools/an "ln -s" src/charset c-client
sh -c '(test -d src/kerberos) && (ln -s `pwd`/src/kerberos/* c-client) || true'
tools/an "ln -s" src/osdep/unix c-client
tools/an "ln -s" src/mtest mtest
tools/an "ln -s" src/ipopd ipopd
tools/an "ln -s" src/imapd imapd
ln -s tools/an .
make build EXTRACFLAGS='-DQMAIL -DRESTRICT_POP' EXTRALDFLAGS='' EXTRADRIVERS='mbox' EXTRAAUTHENTICATORS='' SPECIALAUTHENTICATORS='' PASSWDTYPE=std EXTRASPECIALS=''
OS=sl5
make[2]: Entering directory `/home/shibata/tmp/imap-2000c-qmav'
Building c-client for sl5...
echo GSSDIR=/usr/local > c-client/SPECIALS
cd c-client;make sl5 EXTRACFLAGS='-DQMAIL -DRESTRICT_POP'\
EXTRALDFLAGS=''\
EXTRADRIVERS='mbox'\
EXTRAAUTHENTICATORS=''\
SPECIALAUTHENTICATORS=''\
PASSWDTYPE=std\
GSSDIR=/usr/local
make[3]: Entering directory `/home/shibata/tmp/imap-2000c-qmav/c-client'
You are building for libc5 versions of Secure Linux
If you want libc6/glibc versions you must use slx instead!
If you want libc4 versions you must use sl4 instead!
make build EXTRACFLAGS='-DQMAIL -DRESTRICT_POP' EXTRALDFLAGS='' EXTRADRIVERS='mbox' EXTRAAUTHENTICATORS='' PASSWDTYPE=std SPECIALAUTHENTICATORS='' `cat SPECIALS` OS
=slx \
SIGTYPE=psx CHECKPW=psx CRXTYPE=nfs \
SPOOLDIR=/var/spool \
ACTIVEFILE=/var/lib/news/active \
RSHPATH=/usr/bin/rsh \
BASECFLAGS="-g -fno-omit-frame-pointer -O6"
make[4]: Entering directory `/home/shibata/tmp/imap-2000c-qmav/c-client'
sh -c 'rm -rf auths.c crexcl.c flockbsd.c linkage.[ch] siglocal.c osdep*.[ch] *.o ARCHIVE *FLAGS *TYPE c-client.a || true'
Once-only environment setup...
echo cc > CCTYPE
echo -g -fno-omit-frame-pointer -O6 '-DQMAIL -DRESTRICT_POP' > CFLAGS
echo -DCREATEPROTO=unixproto -DEMPTYPROTO=unixproto \
-DMAILSPOOL=\"/var/spool/mail\" \
-DANONYMOUSHOME=\"/var/spool/mail/anonymous\" \
-DACTIVEFILE=\"/var/lib/news/active\" -DNEWSSPOOL=\"/var/spool/news\" \
-DRSHPATH=\"/usr/bin/rsh\" -DLOCKPGM=\"/etc/mlock\" > OSCFLAGS
echo > LDFLAGS
echo "ar rc c-client.a mail.o misc.o newsrc.o smanager.o osdep.o utf8.o siglocal.o dummy.o pseudo.o netmsg.o flstring.o fdstring.o rfc822.o nntp.o smtp.o imap4r1.o
pop3.o unix.o mbox.o mbx.o mmdf.o tenex.o mtx.o news.o phile.o mh.o mx.o maildir.o;ranlib c-client.a" > ARCHIVE
./drivers mbox maildir imap nntp pop3 mh mx mbx tenex mtx mmdf unix news phile dummy
./mkauths md5 log
make[5]: Entering directory `/home/shibata/tmp/imap-2000c-qmav/c-client'
echo -DMD5ENABLE=\"/etc/cram-md5.pwd\" -DAPOPOPEN=\"/usr/local/sbin/deapop\" -DUSERAPOPFILE=\".apop\" -DPOPBEFORESMTP -DPOP3RECORDER=\"/usr/local/etc/pop3-record\"
>> OSCFLAGS
make[5]: Leaving directory `/home/shibata/tmp/imap-2000c-qmav/c-client'
ln -s os_slx.h osdep.h
ln -s os_slx.c osdepbas.c
ln -s log_std.c osdeplog.c
ln -s sig_psx.c siglocal.c
ln -s crx_nfs.c crexcl.c
sh -c '(test -f /usr/include/sys/statvfs.h -a slx != sc5 -a slx != sco) && ln -s flocksun.c flockbsd.c || ln -s flocksv4.c flockbsd.c'
ln -s ckp_psx.c osdepckp.c
cat osdepbas.c osdepckp.c osdeplog.c > osdep.c
`cat CCTYPE` -c `cat CFLAGS` mail.c
`cat CCTYPE` -c `cat CFLAGS` misc.c
`cat CCTYPE` -c `cat CFLAGS` newsrc.c
`cat CCTYPE` -c `cat CFLAGS` smanager.c
`cat CCTYPE` -c `cat CFLAGS` `cat OSCFLAGS` -c osdep.c
`cat CCTYPE` -c `cat CFLAGS` utf8.c
`cat CCTYPE` -c `cat CFLAGS` siglocal.c
`cat CCTYPE` -c `cat CFLAGS` dummy.c
`cat CCTYPE` -c `cat CFLAGS` pseudo.c
`cat CCTYPE` -c `cat CFLAGS` netmsg.c
`cat CCTYPE` -c `cat CFLAGS` flstring.c
`cat CCTYPE` -c `cat CFLAGS` fdstring.c
`cat CCTYPE` -c `cat CFLAGS` rfc822.c
`cat CCTYPE` -c `cat CFLAGS` nntp.c
`cat CCTYPE` -c `cat CFLAGS` smtp.c
`cat CCTYPE` -c `cat CFLAGS` imap4r1.c
`cat CCTYPE` -c `cat CFLAGS` pop3.c
`cat CCTYPE` -c `cat CFLAGS` unix.c
`cat CCTYPE` -c `cat CFLAGS` mbox.c
`cat CCTYPE` -c `cat CFLAGS` mbx.c
`cat CCTYPE` -c `cat CFLAGS` mmdf.c
`cat CCTYPE` -c `cat CFLAGS` tenex.c
`cat CCTYPE` -c `cat CFLAGS` mtx.c
`cat CCTYPE` -c `cat CFLAGS` news.c
news.c: In function `news_open':
news.c:330: warning: passing arg 3 of `scandir' from incompatible pointer type
`cat CCTYPE` -c `cat CFLAGS` phile.c
`cat CCTYPE` -c `cat CFLAGS` mh.c
mh.c: In function `mh_ping':
mh.c:637: warning: passing arg 3 of `scandir' from incompatible pointer type
mh.c: In function `mh_append':
mh.c:894: warning: passing arg 3 of `scandir' from incompatible pointer type
`cat CCTYPE` -c `cat CFLAGS` mx.c
mx.c: In function `mx_ping':
mx.c:575: warning: passing arg 3 of `scandir' from incompatible pointer type
cc -g -DQMAIL -DRESTRICT_POP -DQMAILCONTROL=\"/var/qmail/control\" -c maildir.c
maildir.c:139: warning: initialization from incompatible pointer type
maildir.c: In function `maildir_ping_core':
maildir.c:490: warning: passing arg 3 of `scandir' from incompatible pointer type
maildir.c:553: warning: assignment makes pointer from integer without a cast
maildir.c: In function `maildir_flagmsg':
maildir.c:1026: warning: assignment makes pointer from integer without a cast
sh -c 'rm -rf c-client.a || true'
ar rc c-client.a mail.o misc.o newsrc.o smanager.o osdep.o utf8.o siglocal.o dummy.o pseudo.o netmsg.o flstring.o fdstring.o rfc822.o nntp.o smtp.o imap4r1.o pop3.o
unix.o mbox.o mbx.o mmdf.o tenex.o mtx.o news.o phile.o mh.o mx.o maildir.o;ranlib c-client.a
make[4]: Leaving directory `/home/shibata/tmp/imap-2000c-qmav/c-client'
make[3]: Leaving directory `/home/shibata/tmp/imap-2000c-qmav/c-client'
echo sl5 > OSTYPE
touch rebuild
sh -c 'rm -rf rebuild || true'
Building bundled tools...
cd mtest;make
make[3]: Entering directory `/home/shibata/tmp/imap-2000c-qmav/mtest'
`cat ../c-client/CCTYPE` -I../c-client `cat ../c-client/CFLAGS` -c -o mtest.o mtest.c
`cat ../c-client/CCTYPE` -I../c-client `cat ../c-client/CFLAGS` -o mtest mtest.o ../c-client/c-client.a `cat ../c-client/LDFLAGS`
mtest.o: In function `mm_login':
/home/shibata/tmp/imap-2000c-qmav/mtest/mtest.c:515: the `gets' function is dangerous and should not be used.
../c-client/c-client.a(osdep.o): In function `checkpw':
/home/shibata/tmp/imap-2000c-qmav/c-client/osdep.c:100: undefined reference to `crypt'
/home/shibata/tmp/imap-2000c-qmav/c-client/osdep.c:117: undefined reference to `crypt'
collect2: ld returned 1 exit status
make[3]: *** [mtest] Error 1
make[3]: Leaving directory `/home/shibata/tmp/imap-2000c-qmav/mtest'
make[2]: *** [bundled] Error 2
make[2]: Leaving directory `/home/shibata/tmp/imap-2000c-qmav'
make[1]: *** [sl5] Error 2
make[1]: Leaving directory `/home/shibata/tmp/imap-2000c-qmav'
make: *** [build-stamp] Error 2
debuild: fatal error at line 293:
dpkg-buildpackage failed: Illegal seek
shibata@dns00001:~/tmp/imap-2000c-qmav/debian$
● osdep.c には crypt という文字列はあるようです。
~/tmp/imap-2000c-qmav/c-client$ grep crypt * | grep osdep.c
osdep.c: strcmp (pw->pw_passwd,(char *) crypt (pass,pw->pw_passwd))) {
osdep.c: !strcmp (sp->sp_pwdp,(char *) crypt (pass,sp->sp_pwdp))) {
● checkpw について書いてあるファイル
(../c-client/c-client.a(osdep.o): In function `checkpw': )は
バイナリファイルのようです。
~/tmp/imap-2000c-qmav/c-client$ grep checkpw c-client.a
Binary file c-client.a matches
~/tmp/imap-2000c-qmav/c-client$ grep checkpw osdep.o
Binary file osdep.o matches
● mtest.c には gets という文字列はあるようです。
~/tmp/imap-2000c-qmav/mtest$ grep gets mtest.c
gets (txt);
while (gets (line)) {
当方ではこれくらいしか調べられないのですが、どうしたものでしょう?
お知恵を拝借できませんでしょうか?
--
SHIBATA Akira 既往は咎めず
shibata@xxxxxxxxxxxxxx Let bygones be bygones