2 from waflib
import Utils
6 bld
.SAMBA_LIBRARY('winbind-client',
9 cflags
='-DWINBINDD_SOCKET_DIR=\"%s\"' % bld
.env
.WINBINDD_SOCKET_DIR
,
14 bld
.SAMBA_BINARY('nsstest',
20 # The nss_wrapper code relies strictly on the linux implementation and
21 # name, so compile but do not install a copy under this name.
22 bld
.SAMBA_LIBRARY('nss_wrapper_winbind',
23 source
='winbind_nss_linux.c',
24 deps
='winbind-client',
25 realname
='libnss_wrapper_winbind.so.2',
29 # FIXME: original was *linux* | gnu* | k*bsd*-gnu | kopensolaris*-gnu)
30 # the search for .rfind('gnu') covers gnu* and *-gnu is that too broad?
32 if (Utils
.unversioned_sys_platform() == 'linux' or (host_os
.rfind('gnu') > -1)):
33 bld
.SAMBA_LIBRARY('nss_winbind',
35 source
='winbind_nss_linux.c',
36 deps
='winbind-client',
38 public_headers_install
=False,
42 bld
.SAMBA3_LIBRARY('nss_wins',
45 deps
='wbclient replace',
47 public_headers_install
=False,
50 elif (host_os
.rfind('freebsd') > -1):
51 # FreeBSD winbind client is implemented as a wrapper around
53 bld
.SAMBA_LIBRARY('nss_winbind',
54 source
='winbind_nss_linux.c winbind_nss_freebsd.c',
55 deps
='winbind-client',
56 realname
='nss_winbind.so.1',
59 bld
.SAMBA3_LIBRARY('nss_wins',
60 source
='wins.c wins_freebsd.c',
62 realname
='nss_wins.so.1',
65 elif (host_os
.rfind('netbsd') > -1):
66 # NetBSD winbind client is implemented as a wrapper
67 # around the Linux version. It needs getpwent_r() to
68 # indicate libc's use of the correct nsdispatch API.
70 if bld
.CONFIG_SET("HAVE_GETPWENT_R"):
71 bld
.SAMBA_LIBRARY('nss_winbind',
72 source
='winbind_nss_linux.c winbind_nss_netbsd.c',
73 deps
='winbind-client',
74 realname
='libnss_winbind.so')
75 elif Utils
.unversioned_sys_platform() == 'sunos':
76 bld
.SAMBA_LIBRARY('nss_winbind',
77 source
='winbind_nss_solaris.c winbind_nss_linux.c',
78 deps
='winbind-client',
79 realname
='nss_winbind.so.1',
81 elif (host_os
.rfind('hpux') > -1):
82 bld
.SAMBA_LIBRARY('nss_winbind',
83 source
='winbind_nss_linux.c',
84 deps
='winbind-client',
85 realname
='libnss_winbind.so')
86 elif (host_os
.rfind('aix') > -1):
87 bld
.SAMBA_LIBRARY('nss_winbind',
88 source
='winbind_nss_aix.c',
89 deps
='winbind-client',
92 if bld
.CONFIG_SET('WITH_PAM_MODULES') and bld
.CONFIG_SET('HAVE_PAM_START'):
93 bld
.SAMBA_LIBRARY('pamwinbind',
94 source
='pam_winbind.c',
95 deps
='talloc wbclient winbind-client tiniparser pam samba_intl',
96 cflags
='-DLOCALEDIR=\"%s/locale\"' % bld
.env
.DATADIR
,
97 realname
='pam_winbind.so',
98 install_path
='${PAMMODULESDIR}'
101 if bld
.CONFIG_SET('HAVE_KRB5_LOCATE_PLUGIN_H'):
102 bld
.SAMBA_LIBRARY('winbind_krb5_locator',
103 source
='krb5_plugin/winbind_krb5_locator.c',
104 deps
='wbclient krb5 com_err',
105 realname
='winbind_krb5_locator.so',
106 install_path
='${MODULESDIR}/krb5')
108 if bld
.CONFIG_SET('HAVE_KRB5_LOCALAUTH_PLUGIN_H'):
109 bld
.SAMBA_LIBRARY('winbind_krb5_localauth',
110 source
='krb5_plugin/winbind_krb5_localauth.c',
111 deps
='wbclient krb5 com_err',
112 realname
='winbind_krb5_localauth.so',
113 install_path
='${MODULESDIR}/krb5')
115 bld
.SAMBA_SUBSYSTEM('WB_REQTRANS',
116 source
='wb_reqtrans.c',
117 deps
='talloc tevent LIBASYNC_REQ'
120 bld
.SAMBA_BINARY('wbinfo',
122 deps
='samba-util LIBCLI_AUTH popt POPT_SAMBA wbclient LIBAFS_SETTOKEN'