When having "milter" USE flag enabled then the installation of
amavisd-new-2.4.5-r1 breaks:
>>> Emerging (1 of 1) mail-filter/amavisd-new-2.4.5-r1 to /
* amavisd-new-2.4.5.tar.gz RMD160 ;-) ...
[ ok ]
* amavisd-new-2.4.5.tar.gz SHA1 ;-) ...
[ ok ]
* amavisd-new-2.4.5.tar.gz SHA256 ;-) ...
[ ok ]
* amavisd-new-2.4.5.tar.gz size ;-) ...
[ ok ]
* checking ebuild checksums ;-) ...
[ ok ]
* checking auxfile checksums ;-) ...
[ ok ]
* checking miscfile checksums ;-) ...
[ ok ]
* checking amavisd-new-2.4.5.tar.gz ;-) ...
[ ok ]
>>> Unpacking source...
>>> Unpacking amavisd-new-2.4.5.tar.gz to /var/tmp/portage/mail-filter/amavisd-new-2.4.5-r1/work
* Patching with courier support.
* Applying amavisd-new-courier.patch ...
[ ok ]
* Applying amavisd-new-2.4.4-amavisd.conf-gentoo.patch ...
[ ok ]
>>> Source unpacked.
>>> Compiling source in /var/tmp/portage/mail-filter/amavisd-new-2.4.5-r1/work/amavisd-new-2.4.5 ...
./configure --prefix=/usr --host=i686-pc-linux-gnu --mandir=/usr/share/man
--infodir=/usr/share/info --datadir=/usr/share --sysconfdir=/etc
--localstatedir=/var/lib --with-runtime-dir=/var/amavis
--with-sockname=/var/amavis/amavisd.sock --with-user=amavis
--build=i686-pc-linux-gnu
checking for i686-pc-linux-gnu-gcc... i686-pc-linux-gnu-gcc
checking for C compiler default output... a.out
checking whether the C compiler works... yes
checking whether we are cross compiling... no
checking for suffix of executables...
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether i686-pc-linux-gnu-gcc accepts -g... yes
checking for i686-pc-linux-gnu-gcc option to accept ANSI C... none needed
checking for ar... ar
checking for awk... awk
checking for id... /usr/bin/id
checking for a BSD-compatible install... /usr/bin/install -c
checking for nm... /usr/bin/nm
checking for runtime directory... /var/amavis
checking socket name... /var/amavis/amavisd.sock
checking for header_tag... X-Virus-Scanned
checking for header_value... by amavisd-new
checking whether i686-pc-linux-gnu-gcc accepts -pthread... yes
checking for res_init in -lresolv... no
checking for htons in -lsocket... no
checking for gethostbyname in -lnsl... yes
checking for pthread_once in -lpthread... yes
checking for snprintf... yes
checking for mkdtemp... yes
checking for mktemp... yes
checking for libmilter/mfapi.h... /usr/include/libmilter/mfapi.h
checking for libmilter.a... /usr/lib/libmilter.a
checking for libsm.a... no
checking for libsmutil.a... no
checking for sendmail... /usr/sbin/sendmail
checking for rm... /bin/rm
checking whether libmilter must be linked with libsm... no
configure: creating ./config.status
config.status: creating Makefile
config.status: creating config.h
sendmail: invalid option -- d
sendmail: invalid option -- 0
sendmail: invalid option -- .
sendmail: invalid option -- 1
sendmail: invalid option -- d
sendmail: fatal: usage: sendmail [options]
Info: sendmail version detected
i686-pc-linux-gnu-gcc -march=athlon-tbird -O2 -pipe -mmmx -m3dnow -fforce-addr
-fomit-frame-pointer -falign-functions=4 -Wall -pthread
-D_POSIX_PTHREAD_SEMANTICS -c -o amavis-milter.o amavis-milter.c
i686-pc-linux-gnu-gcc -march=athlon-tbird -O2 -pipe -mmmx -m3dnow -fforce-addr
-fomit-frame-pointer -falign-functions=4 -Wall -D_POSIX_PTHREAD_SEMANTICS -c
-o amavis.o amavis.c
amavis-milter.c: In function `amavis_mkdtemp':
amavis-milter.c:201: warning: unused variable `count'
i686-pc-linux-gnu-gcc -march=athlon-tbird -O2 -pipe -mmmx -m3dnow -fforce-addr
-fomit-frame-pointer -falign-functions=4 -Wall -o amavis amavis.o -lpthread
-lnsl
amavis-milter.c: At top level:
amavis-milter.c:126: warning: 'amavis_gid' defined but not used
amavis-milter.c:251: warning: 'group_member' defined but not used
i686-pc-linux-gnu-gcc -march=athlon-tbird -O2 -pipe -mmmx -m3dnow -fforce-addr
-fomit-frame-pointer -falign-functions=4 -Wall -pthread -o amavis-milter
amavis-milter.o /usr/lib/libmilter.a -lpthread -lnsl
>>> Source compiled.
>>> Test phase [not enabled]: mail-filter/amavisd-new-2.4.5-r1
>>> Install amavisd-new-2.4.5-r1 into /var/tmp/portage/mail-filter/amavisd-new-2.4.5-r1/image/ category mail-filter
test -f amavis-milter && install -o root -m 755 amavis-milter
/var/tmp/portage/mail-filter/amavisd-new-2.4.5-r1/image//usr/sbin
test -f amavis && install -o root -m 755 amavis
/var/tmp/portage/mail-filter/amavisd-new-2.4.5-r1/image//usr/sbin
* Adding amavisd-new-2.4.5 schema to openldap schema dir.
cp: cannot stat `LDAP.schema': No such file or directory
!!! ERROR: mail-filter/amavisd-new-2.4.5-r1 failed.
Call stack:
ebuild.sh, line 1614: Called dyn_install
ebuild.sh, line 1060: Called qa_call 'src_install'
environment, line 3126: Called src_install
amavisd-new-2.4.5-r1.ebuild, line 129: Called die
!!! (no error message)
!!! If you need support, post the topmost build error, and the call stack if
relevant.
!!! A complete build log is located at
'/var/tmp/portage/mail-filter/amavisd-new-2.4.5-r1/temp/build.log'.
The problem is the following code:
if use milter ; then
cd "${S}/helper-progs"
einstall
fi
It should be:
if use milter ; then
cd "${S}/helper-progs"
einstall
cd "${S}"
fi
See the extra 'cd "${S}"' at the end of einstall? Without it, the ebuild will
stay in "${S}/helper-progs" and will have problems to find the other files.
Reproducible: Always