s3-waf: let winbind depend on SRV_NDR_WBINT and RPCCLI_NDR_WBINT.
[samba.git] / nsswitch / wscript_build
index e13b4dc40223e1fa682e3cba515eae9758cd4768..eb3beb3cd70d964e042754ad6bede3de2fe0239e 100644 (file)
@@ -3,7 +3,7 @@
 bld.SAMBA_SUBSYSTEM('LIBWINBIND-CLIENT',
                     source='wb_common.c',
                     deps='replace',
-                    cflags='-DSOCKET_WRAPPER_DISABLE=1'
+                    cflags='-DSOCKET_WRAPPER_DISABLE=1 -DWINBINDD_SOCKET_DIR=\"%s\"' % bld.env.WINBINDD_SOCKET_DIR
                     )
 
 
@@ -15,6 +15,19 @@ bld.SAMBA_BINARY('nsstest',
 
 bld.SAMBA_BINARY('wbinfo',
        source='wbinfo.c',
-       deps='LIBSAMBA-UTIL LIBCLI_AUTH popt POPT_SAMBA LIBWINBIND-CLIENT LIBWBCLIENT tevent UTIL_TEVENT LIBASYNC_REQ UID_WRAPPER'
+       deps='LIBSAMBA-UTIL LIBCLI_AUTH popt POPT_SAMBA LIBWINBIND-CLIENT LIBWBCLIENT tevent UTIL_TEVENT LIBASYNC_REQ UID_WRAPPER LIBSECURITY_COMMON LIBNDR NDR_SECURITY'
        )
 
+bld.SAMBA_LIBRARY('nss_winbind',
+    source='../nsswitch/winbind_nss_linux.c',
+    deps='LIBWINBIND-CLIENT',
+    realname='libnss_winbind.so.2',
+    vnum='2')
+
+if bld.CONFIG_SET('HAVE_PAM_START'):
+    bld.SAMBA_LIBRARY('pamwinbind',
+        source='../nsswitch/pam_winbind.c',
+        deps='talloc LIBWBCLIENT LIBWINBIND-CLIENT LIBINIPARSER pam',
+        cflags='-DLOCALEDIR=\"%s/locale\"' % bld.env.DATADIR,
+        realname='pam_winbind.so',
+        )