Maybe I don't understand something, but I think that dependency on net-nds/openldap is wrong. Reproducible: Always
Yes, it definitely does want to link the ldap module against liblber and libldap.
Created attachment 444390 [details, diff] Make ldap optional via USE="ldap" for ldb-1.1.27 It looks like the dependency on openldap can be made optional now. I tested the latest ldb version out (1.1.27), and the configure script seems to handle not finding the LDAP libs/headers just fine. Built and installed, then compiled and installed samba-4.2.14, and that runs just fine, even reading my old samba3 user database. Also tested an update to samba-4.4.5. Granted, this is a home server, so not the most comprehensive testcase. But it indicates that for anyone wanting to retain their existing Samba3 setup w/o LDAP can just migrate forward without issue. I've attached a patch to 1.1.27. It makes ldap the default, but now a user can override this if they don't want to have openldap installed. I'd suggest making the change with this version only, and let it progress through the stable process as usual.
*** Bug 579544 has been marked as a duplicate of this bug. ***
(In reply to Joshua Kinard from comment #2) > Created attachment 444390 [details, diff] [details, diff] > Make ldap optional via USE="ldap" for ldb-1.1.27 > > It looks like the dependency on openldap can be made optional now. I tested > the latest ldb version out (1.1.27), and the configure script seems to > handle not finding the LDAP libs/headers just fine. Built and installed, > then compiled and installed samba-4.2.14, and that runs just fine, even > reading my old samba3 user database. Also tested an update to samba-4.4.5. > Granted, this is a home server, so not the most comprehensive testcase. But > it indicates that for anyone wanting to retain their existing Samba3 setup > w/o LDAP can just migrate forward without issue. > > I've attached a patch to 1.1.27. It makes ldap the default, but now a user > can override this if they don't want to have openldap installed. I'd > suggest making the change with this version only, and let it progress > through the stable process as usual. Sorry, but this is not sufficient as your patch would turn ldap into an automagic dependency (stupid wscript crap). If openldap is installed, the package would still link to it. I've added a patched =sys-libs/ldb-1.1.27-r1 to the tree which whould make ldap support optional: commit 896306c12642c3343ef6f3f1375c15858246f2e9 Author: Lars Wendler <polynomial-c@gentoo.org> Date: Tue Sep 6 11:23:17 2016 sys-libs/ldb: Revbump to make ldap support optional (bug #506448). Package-Manager: portage-2.3.0 Signed-off-by: Lars Wendler <polynomial-c@gentoo.org>