Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 549104 - =net-dns/knot-2.0.0_beta version bump
Summary: =net-dns/knot-2.0.0_beta version bump
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal enhancement (vote)
Assignee: Ondřej Surý
URL: https://www.knot-dns.cz/pages/downloa...
Whiteboard:
Keywords: EBUILD
Depends on:
Blocks:
 
Reported: 2015-05-10 19:41 UTC by Karl-Johan Karlsson
Modified: 2015-05-15 09:55 UTC (History)
2 users (show)

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


Attachments
knot-2.0.0_beta.ebuild v1 (knot-2.0.0_beta.ebuild,2.35 KB, text/plain)
2015-05-10 19:42 UTC, Karl-Johan Karlsson
Details
metadata.xml with USE flag descriptions (metadata.xml,878 bytes, text/xml)
2015-05-10 19:42 UTC, Karl-Johan Karlsson
Details
2.0.0_beta-dont-create-extra-directories.patch (2.0.0_beta-dont-create-extra-directories.patch,595 bytes, patch)
2015-05-10 19:44 UTC, Karl-Johan Karlsson
Details | Diff
2.0.0_beta-spell-enable-vars-correctly.patch (2.0.0_beta-spell-enable-vars-correctly.patch,303 bytes, patch)
2015-05-10 19:45 UTC, Karl-Johan Karlsson
Details | Diff
knot-2.0.0_beta.ebuild v2 (knot-2.0.0_beta.ebuild,2.25 KB, text/plain)
2015-05-15 08:04 UTC, Karl-Johan Karlsson
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Karl-Johan Karlsson 2015-05-10 19:41:41 UTC
I just wrote an ebuild for net-dns/knot-1.6.3 in bug 531448, so I thought I might as well write one for 2.0.0_beta while I'm on a roll.

Since it is a beta, I'd suggest adding it without any KEYWORDS. Or just leave it in Bugzilla and use it as a template once 2.0.0 is released.

Reproducible: Always
Comment 1 Karl-Johan Karlsson 2015-05-10 19:42:11 UTC
Created attachment 402994 [details]
knot-2.0.0_beta.ebuild v1
Comment 2 Karl-Johan Karlsson 2015-05-10 19:42:39 UTC
Created attachment 402996 [details]
metadata.xml with USE flag descriptions
Comment 3 Karl-Johan Karlsson 2015-05-10 19:44:24 UTC
Created attachment 402998 [details, diff]
2.0.0_beta-dont-create-extra-directories.patch

If bug 531448 results in this kind of patch being a bad way of doing things, this patch should also be redone.
Comment 4 Karl-Johan Karlsson 2015-05-10 19:45:13 UTC
Created attachment 403000 [details, diff]
2.0.0_beta-spell-enable-vars-correctly.patch

Submitted upstream, will hopefully be fixed for the 2.0.0 release.
Comment 5 Yixun Lan archtester gentoo-dev 2015-05-15 02:32:37 UTC
$(usex systemd --enable-systemd=yes --enable-systemd=no)

this would save complex "&& ||" logic ..

I'm sure Ondreg should merge 2.0.0_beta-spell-enable-vars-correctly.patch into upstream (a simple typo) ;-)
Comment 6 Yixun Lan archtester gentoo-dev 2015-05-15 02:49:44 UTC
hi all, one more thing, there is one additional USE=system-lmdb, so starting from knot-2.0.x, it will include bundled lmdb? what if this USE disabled? will it use internal lmdb, is it still configurable (since you dropped USE=lmdb)?

https://wiki.gentoo.org/wiki/Why_not_bundle_dependencies
Comment 7 Ondřej Surý 2015-05-15 05:36:55 UTC
(In reply to Yixun Lan from comment #5)
> I'm sure Ondrej should merge 2.0.0_beta-spell-enable-vars-correctly.patch
> into upstream (a simple typo) ;-)

Just to confirm, it has been already merged.  Karl-Johan sent us the fix right away.

(In reply to Yixun Lan from comment #6)
> hi all, one more thing, there is one additional USE=system-lmdb, so starting
> from knot-2.0.x, it will include bundled lmdb? what if this USE disabled?
> will it use internal lmdb, is it still configurable (since you dropped
> USE=lmdb)?

lmdb is mandatory now and we (as in upstream) are bundling it since it's just two C files and two headers and some platforms are still not carrying lmdb (I know it's a trade-off and that was a hard decision to make).  That said, I also think that USE=system-lmdb should be dropped and lmdb added as a hard dependency.  I guess gentoo is also using lmdb in OpenLDAP, so it should be it excellent shape anyway :).
Comment 8 Yixun Lan archtester gentoo-dev 2015-05-15 06:41:52 UTC
(In reply to Ondřej Surý from comment #7)
> lmdb is mandatory now and we (as in upstream) are bundling it since it's
> just two C files and two headers and some platforms are still not carrying
> lmdb (I know it's a trade-off and that was a hard decision to make).  That
> said, I also think that USE=system-lmdb should be dropped and lmdb added as
> a hard dependency.  I guess gentoo is also using lmdb in OpenLDAP, so it
> should be it excellent shape anyway :).

ok, the sytem-XX type of USE is introduced to control ebuild to use either internal bundled library or Gentoo system wide library (eg, dev-db/lmdb here)

what I'm not sure is that if knot at least provide a configurable option to use system lmdb (disable the internal one)? it's perfect to drop USE=system-lmdb and hard depend on system-wide..

try to look at openldap, it's quite brute to remove lmdb and depend on system library mandatory (I thought at least a choice has to be provided)

try to take a look at app-emulation/xen-tools USE=system-qemu as example
(sometimes internal bundled library/application are un-avoidable..)
Comment 9 Karl-Johan Karlsson 2015-05-15 08:04:53 UTC
Created attachment 403314 [details]
knot-2.0.0_beta.ebuild v2

Always build with shared LMDB. Remove system-lmdb USE flag.
Use $(usex) for use-flag conditional logic.
Comment 10 Karl-Johan Karlsson 2015-05-15 08:07:12 UTC
Comment on attachment 402996 [details]
metadata.xml with USE flag descriptions

2.0.0_beta can now use the same metadata.xml as 1.6.3. See bug 531448 for a correct file.
Comment 11 Ondřej Surý 2015-05-15 09:37:11 UTC
(In reply to Yixun Lan from comment #8)
> (In reply to Ondřej Surý from comment #7)
> > lmdb is mandatory now and we (as in upstream) are bundling it since it's
> > just two C files and two headers and some platforms are still not carrying
> > lmdb (I know it's a trade-off and that was a hard decision to make).  That
> > said, I also think that USE=system-lmdb should be dropped and lmdb added as
> > a hard dependency.  I guess gentoo is also using lmdb in OpenLDAP, so it
> > should be it excellent shape anyway :).
> 
> ok, the system-XX type of USE is introduced to control ebuild to use either
> internal bundled library or Gentoo system wide library (eg, dev-db/lmdb here)
> 
> what I'm not sure is that if knot at least provide a configurable option to
> use system lmdb (disable the internal one)? it's perfect to drop
> USE=system-lmdb and hard depend on system-wide..

Yes, of course, and it is default to use system-wide when system-wide LMDB is found.  We are well behaved upstream ;).

> try to look at openldap, it's quite brute to remove lmdb and depend on
> system library mandatory (I thought at least a choice has to be provided)

[off-topic]Did you add SOVERSION to Gentoo?  It might be a good idea to sync the SOVERSION across distros - the Debian (me) and Fedora maintainers have agreed to use .so.0
Comment 12 Yixun Lan archtester gentoo-dev 2015-05-15 09:55:12 UTC
(In reply to Ondřej Surý from comment #11)
> Yes, of course, and it is default to use system-wide when system-wide LMDB
> is found.  We are well behaved upstream ;).
great!

> [off-topic]Did you add SOVERSION to Gentoo?  It might be a good idea to sync
> the SOVERSION across distros - the Debian (me) and Fedora maintainers have
> agreed to use .so.0
checking dev-db/lmdb, sound already done
x86_64-pc-linux-gnu-gcc -Wl,-O1 -Wl,--as-needed -pthread -shared -Wl,-soname,liblmdb.so.0 -o liblmdb.so mdb.o midl.o

this ebuild already in tree, closed..