<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "http://bugs.gentoo.org/bugzilla.dtd">

<bugzilla version="2.22.7"
          urlbase="http://bugs.gentoo.org/"
          maintainer="bugzilla@gentoo.org"
>

    <bug>
          <bug_id>172437</bug_id>
          
          <creation_ts>2007-03-27 17:03 0000</creation_ts>
          <short_desc>mail-filter/amavisd-new-2.4.5-r1 compile fails w/ USE=milter</short_desc>
          <delta_ts>2007-03-27 17:47:34 0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>Gentoo Linux</product>
          <component>Ebuilds</component>
          <version>unspecified</version>
          <rep_platform>All</rep_platform>
          <op_sys>Linux</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          
          
          <priority>P2</priority>
          <bug_severity>major</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          
          <everconfirmed>1</everconfirmed>
          <reporter>steeeeeveee@gmx.net</reporter>
          <assigned_to>antivirus@gentoo.org</assigned_to>
          <cc>net-mail@gentoo.org</cc>

      

      
          <long_desc isprivate="0">
            <who>steeeeeveee@gmx.net</who>
            <bug_when>2007-03-27 17:03:37 0000</bug_when>
            <thetext>When having &quot;milter&quot; USE flag enabled then the installation of amavisd-new-2.4.5-r1 breaks:
&gt;&gt;&gt; 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 ]
&gt;&gt;&gt; Unpacking source...
&gt;&gt;&gt; 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 ]
&gt;&gt;&gt; Source unpacked.
&gt;&gt;&gt; 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&apos;:
amavis-milter.c:201: warning: unused variable `count&apos;
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: &apos;amavis_gid&apos; defined but not used
amavis-milter.c:251: warning: &apos;group_member&apos; 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
&gt;&gt;&gt; Source compiled.
&gt;&gt;&gt; Test phase [not enabled]: mail-filter/amavisd-new-2.4.5-r1

&gt;&gt;&gt; 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 &amp;&amp; install -o root -m 755 amavis-milter /var/tmp/portage/mail-filter/amavisd-new-2.4.5-r1/image//usr/sbin
test -f amavis &amp;&amp; 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&apos;: 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 &apos;src_install&apos;
  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 &apos;/var/tmp/portage/mail-filter/amavisd-new-2.4.5-r1/temp/build.log&apos;.




The problem is the following code:
        if use milter ; then
                cd &quot;${S}/helper-progs&quot;
                einstall
        fi


It should be:
        if use milter ; then
                cd &quot;${S}/helper-progs&quot;
                einstall
                cd &quot;${S}&quot;
        fi


See the extra &apos;cd &quot;${S}&quot;&apos; at the end of einstall? Without it, the ebuild will stay in &quot;${S}/helper-progs&quot; and will have problems to find the other files.

Reproducible: Always</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>ticho@gentoo.org</who>
            <bug_when>2007-03-27 17:47:34 0000</bug_when>
            <thetext>You&apos;re right. Fixed in 2.4.5-r1</thetext>
          </long_desc>
      
    </bug>

</bugzilla>