Bug 13576 - wscript:51: error: Building the AD DC requires GnuTLS which is already installed
Summary: wscript:51: error: Building the AD DC requires GnuTLS which is already installed
Status: NEW
Alias: None
Product: Samba 4.1 and newer
Classification: Unclassified
Component: Build (show other bugs)
Version: 4.8.4
Hardware: Other AIX
: P5 normal (vote)
Target Milestone: ---
Assignee: Samba QA Contact
QA Contact: Samba QA Contact
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2018-08-16 14:59 UTC by Chris Lee
Modified: 2020-01-04 00:02 UTC (History)
1 user (show)

See Also:


Attachments
Detailed samba configuration information (69.72 KB, text/rtf)
2018-08-16 14:59 UTC, Chris Lee
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Chris Lee 2018-08-16 14:59:03 UTC
Created attachment 14427 [details]
Detailed samba configuration information

Team,

I believe I discovered a couple of issues with my AIX systems & my attempts to compile the Samba source code. I have an AIX 7.1 & an AIX 7.2 system available.

While working on a new system project, I discovered a couple of odd issues with the recent Samba source. My previous Samba distribution was from pware, but that site appears to be idle. So, I downloaded a distribution version 4 from Group Bull & IBM AIX Linux toolbox. Perzl only offers version 3. IBM LINUX Toolbox appears to be compiled without ADS support. The Group Bull also failed [see below]. When all available distributions failed, I downloaded the source, 4.8.3 & 4.8.4. There are a couple of issues during the configure stage [below]. I checked various websites & forums & did not discover a solution. I followed the directions via web site; https://wiki.samba.org/index.php/Build_Samba_from_Source#Viewing_Built_Options_of_an_Existing_Installation

Recap;
Samba-tool fails with an error __glue.so. While this not a direct tie to the samba source, it is the reason that I attempted to compile samba with ADS support. I could not locate the samba-python source to recompile. The distribution was from Group Bull. I tested the current & previous release from that site which also failed [samba-tool].

First issue with samba source;
/samba-4.8.3/source4/lib/tls/wscript:51: error: Building the AD DC requires GnuTLS (eg libgnutls-dev, gnutls-devel) for ldaps:// support and for the BackupKey protocol

 # rpm -qa | grep tls
gnutls-3.5.14-1.ppc
gnutls-devel-3.5.14-1.ppc

if I comment the GnuTLS check in the wscript51 script, this is the next error.
/export/samba/samba-4.8.4/source3/wscript:684: error: LDAP support not found. Try installing libldap2-dev or openldap-devel. Otherwise, use --without-ldap to build without LDAP support. LDAP support is required for the LDAP passdb backend, LDAP idmap backends and ADS. ADS support improves communication with Active Directory domain controllers.

 # rpm -qa | grep lda
openldap-devel-2.4.45-3.ppc
openldap-2.4.45-3.ppc

I checked the previous bug reports against wscript. There are a couple of similar issues from a few years ago.

The third issue is that I receive many header errors [re: attached]. I am wondering if I have an configuration issue with the library paths or if they ca be ignored. 

FYI
LIBPATH=/opt/freeware/lib:/opt/freeware/lib64:/usr/lib64:/usr/lib:/opt/freeware/lib64/httpd/modules:/opt/freeware/64/lib:/opt/subversion/lib:/usr/linux/lib:

LD_LIBRARY_PATH=/opt/freeware/python2.7/lib:/opt/freeware/python2.7/lib:/python2.7/lib:::/opt/freeware/lib/python2.7/site-packages/samba/netcmd::/opt/freeware/lib/python2.7/site-packages/samba/netcmd:

Please see the attached document for any addition details. 

AIX 7.2
# rpm -qa | grep pyt
python-pycurl-7.43.0-1.ppc
python-2.7.15-1.ppc
python-devel-2.7.15-1.ppc
python-tools-2.7.15-1.ppc
python3-3.6.6-1.ppc
samba-python-4.6.14-1.ppc
python-iniparse-0.4-1.noarch
python-urlgrabber-3.10.1-1.noarch

I also needed package; dnspython-1.15.0, that was installed via g-zip file.

Lastly, which I feel is an issue with the Group Bull Distribution [or LIBPATH] is that I needed to link these modules for smbstatus & testparm to work. This also makes me wonder about other library calls too. Hence, the compile from samba source.

ln -s /opt/freeware/lib/libsamba-util.so.0  /usr/lib/libsamba-util.so
ln -s /opt/freeware/lib/libsmbconf.so.0  /usr/lib/libsmbconf.so
ln -s /opt/freeware/lib/libndr.so.0.0.8 /usr/lib/libndr.so
ln -s /opt/freeware/lib/libtevent-util.so.0 /usr/lib/libtevent-util.so
ln -s /opt/freeware/lib/libsamba-errors.so.1 /usr/lib/libsamba-errors.so
ln -s /opt/freeware/lib/libnetapi.so.0 /usr/lib/libnetapi.so
ln -s /opt/freeware/lib/libdcerpc-samr.so.0 /usr/lib/libdcerpc-samr.so
ln -s /opt/freeware/lib/libsamba-credentials.so.0 /usr/lib/libsamba-credentials.so
ln -s /opt/freeware/lib/libsamba-hostconfig.so.0 l/usr/lib/ibsamba-hostconfig.so
ln -s /opt/freeware/lib/libsamba-passdb.so.0 /usr/lib/libsamba-passdb.so
ln -s /opt/freeware/lib/libsamba-policy.so.0 /usr/lib/libsamba-policy.so
ln -s /opt/freeware/lib/libsamdb.so.0 /usr/lib/libsamdb.so
ln -s /opt/freeware/lib/libndr-krb5pac.so.0 /usr/lib/libndr-krb5pac.so
ln -s /opt/freeware/lib/libndr-nbt.so.0 /usr/lib/libndr-nbt.so
ln -s /opt/freeware/lib/libndr-standard.so.0 /usr/lib/libndr-standard.so
ln -s /opt/freeware/lib/libdcerpc-binding.so.0 /usr/lib/libdcerpc-binding.so
ln -s /opt/freeware/lib/libsmbldap.so.0 /usr/lib/libsmbldap.so
ln -s /opt/freeware/lib/libdcerpc.so.0 /usr/lib/libdcerpc.so
ln -s /opt/freeware/lib/libsamba-util.so.0.0.1  /usr/lib/libsamba-util.so

Example:
 smbstatus
exec(): 0509-036 Cannot load program smbstatus because of the following errors:
        0509-022 Cannot load module /opt/freeware/lib/libsamba-util.so.
        0509-150   Dependent module /usr/lib/libiconv.a(libiconv.so.2) could not be loaded.
        0509-152   Member libiconv.so.2 is not found in archive
        0509-022 Cannot load module smbstatus.
        0509-150   Dependent module /opt/freeware/lib/libsamba-util.so could not be loaded.

yum install libiconv
find / -name libiconv* -ls
3011979 Aug 15 16:04 /opt/freeware/lib/libiconv.a
781303 Nov 28 2017  /usr/lib/libiconv.a
/usr/linux/lib/libiconv.a -> ../../../opt/freeware/lib/libiconv.a

This path statement resolved the issue.

LIBPATH=/opt/freeware/lib:/opt/freeware/lib64:/usr/lib64:/usr/lib:/opt/freeware/lib64/httpd/modules:/opt/freeware/64/lib:/opt/subversion/lib:/usr/linux/lib:

Thank you for your time. 

Regards,
Chris