]> git.ipfire.org Git - thirdparty/openldap.git/commitdiff
ITS#10098 fixup passwd module subdirs too
authorHoward Chu <hyc@openldap.org>
Fri, 1 Dec 2023 21:41:02 +0000 (21:41 +0000)
committerQuanah Gibson-Mount <quanah@openldap.org>
Mon, 4 Dec 2023 18:40:45 +0000 (18:40 +0000)
(Squash this)

contrib/slapd-modules/passwd/pbkdf2/Makefile
contrib/slapd-modules/passwd/sha2/Makefile
contrib/slapd-modules/passwd/totp/Makefile

index 6279f50c158668a68558a7bb7b16d17b7dc50507..0ed0962dd89e75ee9f929450dcf0a9c15c4a53b9 100644 (file)
@@ -6,6 +6,11 @@ LDAP_INC = -I$(LDAP_BUILD)/include -I$(LDAP_SRC)/include -I$(LDAP_SRC)/servers/s
 LDAP_LIB = $(LDAP_BUILD)/libraries/libldap/libldap.la \
        $(LDAP_BUILD)/libraries/liblber/liblber.la
 
+PLAT = UNIX
+NT_LIB = -L$(LDAP_BUILD)/servers/slapd -lslapd
+NT_LDFLAGS = -no-undefined -avoid-version
+UNIX_LDFLAGS = -version-info $(LTVER)
+
 LIBTOOL = $(LDAP_BUILD)/libtool
 INSTALL = /usr/bin/install
 CC = gcc
@@ -16,7 +21,8 @@ SSL_INC =
 SSL_LIB = -lcrypto
 
 INCS = $(LDAP_INC) $(SSL_INC)
-LIBS = $(LDAP_LIB) $(SSL_LIB)
+LIBS = $($(PLAT)_LIB) $(LDAP_LIB) $(SSL_LIB)
+LD_FLAGS= $(LDFLAGS) $($(PLAT)_LDFLAGS) -rpath $(moduledir) -module
 
 PROGRAMS = pw-pbkdf2.la
 MANPAGES = slapd-pw-pbkdf2.5
@@ -40,8 +46,7 @@ man5dir = $(mandir)/man5
 all:           $(PROGRAMS)
 
 pw-pbkdf2.la: pw-pbkdf2.lo
-       $(LIBTOOL) --mode=link $(CC) $(LDFLAGS) -version-info $(LTVER) \
-       -rpath $(moduledir) -module -o $@ $? $(LIBS)
+       $(LIBTOOL) --mode=link $(CC) $(LD_FLAGS) -o $@ $? $(LIBS)
 
 clean:
        rm -rf *.o *.lo *.la .libs
index 2d2075688387fbb7c33fe9f759b5d64934ca8bb8..123787ae04e22db98f2da4ea08818a0fb9b109f1 100644 (file)
@@ -6,6 +6,11 @@ LDAP_INC = -I$(LDAP_BUILD)/include -I$(LDAP_SRC)/include -I$(LDAP_SRC)/servers/s
 LDAP_LIB = $(LDAP_BUILD)/libraries/libldap/libldap.la \
        $(LDAP_BUILD)/libraries/liblber/liblber.la
 
+PLAT = UNIX
+NT_LIB = -L$(LDAP_BUILD)/servers/slapd -lslapd
+NT_LDFLAGS = -no-undefined -avoid-version
+UNIX_LDFLAGS = -version-info $(LTVER)
+
 LIBTOOL = $(LDAP_BUILD)/libtool
 INSTALL = /usr/bin/install
 CC = gcc
@@ -13,7 +18,8 @@ OPT = -g -O2
 DEFS = 
 #DEFS = -DSLAPD_SHA2_DEBUG
 INCS = $(LDAP_INC)
-LIBS = $(LDAP_LIB)
+LIBS = $($(PLAT)_LIB) $(LDAP_LIB)
+LD_FLAGS = $(LDFLAGS) $($(PLAT)_LDFLAGS) -rpath $(moduledir) -module
 
 PROGRAMS = pw-sha2.la
 MANPAGES = slapd-pw-sha2.5
@@ -37,8 +43,7 @@ man5dir = $(mandir)/man5
 all:           $(PROGRAMS)
 
 pw-sha2.la:    slapd-sha2.lo sha2.lo
-       $(LIBTOOL) --mode=link $(CC) $(LDFLAGS) -version-info $(LTVER) \
-       -rpath $(moduledir) -module -o $@ $? $(LIBS)
+       $(LIBTOOL) --mode=link $(CC) $(LD_FLAGS) -o $@ $? $(LIBS)
 
 clean:
        rm -rf *.o *.lo *.la .libs
index f7dff4bd7d7ba9dc7e7907087b56228ad4efbae5..199fa39fc1e070d7e48778c0938e676c62900908 100644 (file)
@@ -6,13 +6,19 @@ LDAP_INC = -I$(LDAP_BUILD)/include -I$(LDAP_SRC)/include -I$(LDAP_SRC)/servers/s
 LDAP_LIB = $(LDAP_BUILD)/libraries/libldap/libldap.la \
        $(LDAP_BUILD)/libraries/liblber/liblber.la
 
+PLAT = UNIX
+NT_LIB = -L$(LDAP_BUILD)/servers/slapd -lslapd
+NT_LDFLAGS = -no-undefined -avoid-version
+UNIX_LDFLAGS = -version-info $(LTVER)
+
 LIBTOOL = $(LDAP_BUILD)/libtool
 INSTALL = /usr/bin/install
 CC = gcc
 OPT = -g -O2
 DEFS = 
 INCS = $(LDAP_INC)
-LIBS = $(LDAP_LIB)
+LIBS = $($(PLAT)_LIB) $(LDAP_LIB)
+LD_FLAGS = $(LDFLAGS) $($(PLAT)_LDFLAGS) -rpath $(moduledir) -module
 
 PROGRAMS = pw-totp.la
 MANPAGES = slapo-totp.5
@@ -36,8 +42,7 @@ man5dir = $(mandir)/man5
 all:           $(PROGRAMS)
 
 pw-totp.la:    slapd-totp.lo
-       $(LIBTOOL) --mode=link $(CC) $(LDFLAGS) -version-info $(LTVER) \
-       -rpath $(moduledir) -module -o $@ $? $(LIBS)
+       $(LIBTOOL) --mode=link $(CC) $(LD_FLAGS) -o $@ $? $(LIBS)
 
 clean:
        rm -rf *.o *.lo *.la .libs