Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 436406 - mail-mta/exim please install headers files (aka please add "dlfunc" use flag)
Summary: mail-mta/exim please install headers files (aka please add "dlfunc" use flag)
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Server (show other bugs)
Hardware: All Linux
: Low enhancement (vote)
Assignee: Fabian Groffen
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: 436484 436486
  Show dependency tree
 
Reported: 2012-09-27 12:52 UTC by Marcin Mirosław
Modified: 2013-07-24 08:10 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
Patch for ebuild (ebuild.patch,1.15 KB, patch)
2012-09-28 08:36 UTC, Marcin Mirosław
Details | Diff
Patch for ebuild (ebuild.patch,1.20 KB, patch)
2012-09-28 09:43 UTC, Marcin Mirosław
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Marcin Mirosław 2012-09-27 12:52:31 UTC
... or at least local_scan.h:)
I'd like to write ebuilds for two libraries[1] and both needs local_scan.h to be available. 

[1] - http://dist.epipe.com/exim/

Reproducible: Always
Comment 1 Fabian Groffen gentoo-dev 2012-09-27 17:15:53 UTC
Hmmm, that shouldn't be too hard.  Got a patch ready?
Comment 2 Marcin Mirosław 2012-09-28 08:36:00 UTC
Created attachment 325172 [details, diff]
Patch for ebuild

I don't know how to install headers files using exim's build system so I did static list of headers files (dirty).
My proposal for change in metadata.xml is:
<flag name='dlfunc'>Adds support for using locally written C function</flag>

With proposed changes in ebuild I was able to build exim-geoipv6-dlfunc-0.1 and successfully use in expansion (tested via exim -be).
Comment 3 Marcin Mirosław 2012-09-28 09:43:42 UTC
Created attachment 325176 [details, diff]
Patch for ebuild
Comment 4 Fabian Groffen gentoo-dev 2012-09-28 10:37:12 UTC
I'm not so happy with the patch, because it includes config.h as shipped header.  I presume the other headers include it as first-thing?
Comment 5 Marcin Mirosław 2012-09-28 10:40:14 UTC
I used file list used by exim-dev on debian. And yes, local_scan.h needs config.h:
$ grep  '#include' /usr/include/exim/*
/usr/include/exim/local_scan.h:#include <stdarg.h>
/usr/include/exim/local_scan.h:#include <sys/types.h>
/usr/include/exim/local_scan.h:#include "config.h"
/usr/include/exim/local_scan.h:#include "mytypes.h"
/usr/include/exim/local_scan.h:#include "store.h"
Comment 6 Fabian Groffen gentoo-dev 2012-11-04 19:36:24 UTC
I almost feel like it's saner to just add your two libraries to the main exim ebuild with two USE-flags.
Comment 7 Marcin Mirosław 2012-11-05 14:19:33 UTC
For me it should be ok but enabling dlfunc is more general.
Comment 8 Marcin Mirosław 2013-02-04 09:35:04 UTC
Hi Fabian, is any progress with this bug? Is something I can do to help resolving bug(s)?
Comment 9 Fabian Groffen gentoo-dev 2013-02-26 21:34:47 UTC
I was thinking maybe it's best to add apply_user_patches or something to the exim ebuild, such that you can use this, as I'm not too happy adding this, since it exposes stuff that normally shouldn't be.  Or the USE-flag idea, of course.
Comment 10 Marcin Mirosław 2013-02-28 14:58:42 UTC
I'm admirer of system wide user_epatch. For me you can add it independent of this bug;)
I'm not programmer so it's not clear for me what is wrong with putting additional headers file to system? And I'm not sure it is good place for such discussion;)
Messems once main disadvantage of USE-flag is that the two dlfunc libraries are independent of upstream. Something like kernel and external modules like zfs;) or it can be treated as a kind of plugin. Hmm but nginx and NGINX_MODULES allows external modules to be compiled and installed together wit nginx.
Comment 11 Marcin Mirosław 2013-07-10 13:27:56 UTC
I'm still thinking about using geoip and p0f inside exim;)
Comment 12 Fabian Groffen gentoo-dev 2013-07-22 19:01:49 UTC
This is implemented now in 4.80.1-r1
Comment 13 Marcin Mirosław 2013-07-23 08:49:01 UTC
Thanks Fabian for spending time on it! I emerged exim and I can see problem with installed headers:

ls -l /usr/include/exim/
razem 15
-rw-r--r-- 1 root root 5695 07-22 23:17 config.h
-rw-r--r-- 1 root root 8201 07-22 23:17 local_scan.h
lrwxrwxrwx 1 root root   16 07-22 23:17 mytypes.h -> ../src/mytypes.h
lrwxrwxrwx 1 root root   14 07-22 23:17 store.h -> ../src/store.h

Last two are broken symlinks (while emerging I have QA Notices:
QA: preinst
QA Notice: Symbolic link /usr/include/exim/mytypes.h points to /usr/include/src/mytypes.h which does not exist.
QA Notice: Symbolic link /usr/include/exim/store.h points to /usr/include/src/store.h which does not exist.
Comment 14 Fabian Groffen gentoo-dev 2013-07-23 09:25:52 UTC
Thanks, I just fixed that (before I saw this bug).  Yesterday, I didn't check too well what I did, I guess.  The fix should propagate to the mirrors.  I didn't bump because you're basically the only consumer now, so you'll have to re-emerge exim.  Hope that's ok with you.
Comment 15 Marcin Mirosław 2013-07-23 12:52:46 UTC
Now exim-p0f and exim-geoip builds fine. Thanks.
Now I'm going to use it on production MTA (about 1000-8000 emails per day). Would it be possible to add those ebuilds to tree after some time?
Comment 16 Fabian Groffen gentoo-dev 2013-07-23 13:09:08 UTC
certainly yes, I hoped for you to test/check them first ;)
Comment 17 Marcin Mirosław 2013-07-24 08:10:23 UTC
Thanks for commiting exim p0f and exim-geoip. Yes, I'm using both of them and (as for know) works without problem.