DragonFlyBSD / DPorts

The dedicated application build system for DragonFly BSD
Other
89 stars 44 forks source link

dns/nss_mdns missing real libraries in PLIST_FILES #142

Closed tgyurci closed 9 years ago

tgyurci commented 9 years ago

The lib/nss_mdns.so and lib/nss_mdns_minimal.so are just symlinks to lib/nss_mdns.so.1 and lib/nss_mdns_minimal_so.1. The commit 7a37213cb2c0b163134cea5fc02d2680d7b9ad30 removes the real libraries from PLIST_FILES making the package totally unusable.

jrmarino commented 9 years ago

correction: commit 7a37213 documents what is actually installed. The *.so.1 files are never built. The problem is elsewhere.

jrmarino commented 9 years ago

The problem is with the port makefile, post install target

jrmarino commented 9 years ago

trying pulling dports and rebuilding from source. Tell me if it works now. fix: e981e15d74e3a14f891c6e9a32080a89ad00592d

tgyurci commented 9 years ago

Looking at the configure script I figured out, that there is a separate configuration for building nss_mdns for FreeBSD. This configuration is not applied to DragonFly. If you tell the configure script to handle DragonFly as FreeBSD, then it works, and the other tweaks are not needed because it builds the .so.1 files and .so symlinks that way.

--- configure.ac.orig   2015-03-09 13:40:19 UTC
+++ configure.ac
@@ -85,7 +85,7 @@ AC_CHECK_FUNCS([gethostbyaddr gethostbyn

 # FreeBSD has a slightly different NSS interface
 case ${host} in
-     *-freebsd*) freebsd="yes" ;;
+     *-freebsd* | *-dragonfly*) freebsd="yes" ;;
 esac

 AM_CONDITIONAL([FREEBSD_NSS], [test "x$freebsd" = "xyes"])
jrmarino commented 9 years ago

I acknowledge a patch to configure.ac (or should it be configure?) is cleaner than patching the port Makefile, but should we be matching the FreeBSD NSS interface?

The patch I just added should be equivalent.

It provides a lot more libraries than the FreeBSD version too, so I'm wondering if we really want to emulator FreeBSD in this case.

tgyurci commented 9 years ago

The port has USES=autoreconf so a patched configure would have been overridden. The NSS in DragonFly was imported from FreeBSD and both tries to load nss_mdns.so.1 not nss_mdns.so so the libnss_mdns.so.2 and the nss_mdns.so symlink to it are not used at all. And I'm not sure that if Glibc versions (libnss_mdns*) are compatible with DragonFly, but it worked for me with the FreeBSD-ish patch above.

jrmarino commented 9 years ago

okay, done: e0bcba2915ebe88cdbac12e93fc317819fdeacec thanks