to keep gentoo a little more maintainable the attached patch allowed libmilter to generate a shared library. I'm also keen to add py-milter at some stage which requires a shared libmilter library. This was largely copied of the way freebsd solved the same problem. Is this acceptable?
Created attachment 170978 [details, diff] patch to overlay
Created attachment 170980 [details] files/sharedlibrary.m4 hard added the -lc due to stat being used in the library. Otherwise same as freebsd version.
For consistency reasons, sendmail will have to be modified as well. Also, run-time dependencies of packages that depend on it will have to include a libmilter atom. Is net-mail team happy with it?
Sorry, but it seems we don't have a mail-mta/sendmail maintainer atm. Closed as REMIND.
*** Bug 281985 has been marked as a duplicate of this bug. ***
Since no one seems interested in fixing sendmail, I will fix this for both packages.
I've fixed this issue in mail-filter/libmilter-1.0.1 (all other libmilter versions were removed) and mail-mta/sendmail-8.14.3-r1. The solution which I've adopted is derived from the one implemented in FreeBSD, but with a twist: both static and shared library variants are installed and I did it without duplicating libmilter tree (compiling the same thing twice horrifies me). Furthermore, in order to force depending programs to be linked with the shared libmilter library, I've rev (or ver) bumped following packages: mail-filter/dk-milter mail-filter/dkim-milter mail-filter/sid-filter mail-filter/milter-regex mail-filter/mimedefang mail-filter/spamass-milter Closed as FIXED.
I guess few people use libmilter. confCCOPTS_SO needs defined in sendmail-8.14.3/devtools/OS/Linux with -fPIC elsewise, the above shared overlay patch puts the literal "confCCOPTS_SO" in the middle of the libmilter gcc line
--- sendmail-8.14.3.orig/devtools/OS/Linux 2002-03-21 18:59:25.000000000 -0500 +++ sendmail-8.14.3/devtools/OS/Linux 2009-11-09 15:31:51.000000000 -0500 @@ -13,6 +13,7 @@ define(`confLD', `ld') define(`confMTCCOPTS', `-D_REENTRANT') define(`confMTLDOPTS', `-lpthread') +define(`confCCOPTS_SO', `-fPIC') define(`confLDOPTS_SO', `-shared') define(`confSONAME',`-soname')
(In reply to comment #8) > I guess few people use libmilter. Not true. > confCCOPTS_SO needs defined in sendmail-8.14.3/devtools/OS/Linux with -fPIC > > elsewise, the above shared overlay patch puts the literal "confCCOPTS_SO" in > the middle of the libmilter gcc line ${FILESDIR}/gentoo-config.m4 is used as template for ${S}/devtools/Site/site.config.m4 and this is the last line in the template file: define(`confCCOPTS_SO', `-fPIC') In addition, I did a quick test and there was no "confCCOPTS_SO" string literal in the build.log resulted after an ebuild install.