openldap-2.3.24-contrib-smbk5pwd.patch 1.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354
  1. --- contrib/slapd-modules/smbk5pwd/Makefile.ORIG 2006-05-17 13:11:57.194660019 +0300
  2. +++ contrib/slapd-modules/smbk5pwd/Makefile 2006-05-17 13:11:14.503082288 +0300
  3. @@ -9,29 +9,39 @@
  4. # top-level directory of the distribution or, alternatively, at
  5. # <http://www.OpenLDAP.org/license.html>.
  6. +#libexecdir=/usr/lib/openldap
  7. +moduledir=$(libexecdir)/openldap
  8. LIBTOOL=../../../libtool
  9. -OPT=-g -O2
  10. +#OPT=
  11. CC=gcc
  12. # Omit DO_KRB5 or DO_SAMBA if you don't want to support it.
  13. -DEFS=-DDO_KRB5 -DDO_SAMBA
  14. +#DEFS=
  15. -HEIMDAL_INC=-I/usr/heimdal/include
  16. +#KRB5_INC=
  17. SSL_INC=
  18. LDAP_INC=-I../../../include -I../../../servers/slapd
  19. -INCS=$(LDAP_INC) $(HEIMDAL_INC) $(SSL_INC)
  20. +INCS=$(LDAP_INC) $(SSL_INC) $(KRB5_INC)
  21. -HEIMDAL_LIB=-L/usr/heimdal/lib -lkrb5 -lkadm5srv
  22. +KRB5_LIB=-lkrb5 -lkadm5srv
  23. SSL_LIB=-lcrypto
  24. -LDAP_LIB=-lldap_r -llber
  25. -LIBS=$(LDAP_LIB) $(HEIMDAL_LIB) $(SSL_LIB)
  26. -
  27. +LDAP_LIB=-L../../../libraries/libldap_r -lldap_r -llber
  28. +ifneq (DDO_KRB5,$(findstring DDO_KRB5,$(DEFS)))
  29. + LIBS=$(LDAP_LIB) $(SSL_LIB)
  30. +else
  31. + LIBS=$(LDAP_LIB) $(KRB5_LIB) $(SSL_LIB)
  32. +endif
  33. +
  34. all: smbk5pwd.la
  35. smbk5pwd.lo: smbk5pwd.c
  36. - $(LIBTOOL) --mode=compile $(CC) $(OPT) $(DEFS) $(INCS) -c $?
  37. + $(LIBTOOL) --mode=compile $(CC) $(CFLAGS) $(DEFS) $(INCS) -c $?
  38. smbk5pwd.la: smbk5pwd.lo
  39. - $(LIBTOOL) --mode=link $(CC) $(OPT) -version-info 0:0:0 \
  40. - -rpath /usr/local/libexec/openldap -module -o $@ $? $(LIBS)
  41. + $(LIBTOOL) --mode=link $(CC) $(CFLAGS) -version-info 0:0:0 \
  42. + -rpath $(moduledir) -module -o $@ $? $(LIBS)
  43. +
  44. +install-mod:
  45. + $(LIBTOOL) --mode=install ../../../build/shtool install -c \
  46. + -m 755 smbk5pwd.la $(DESTDIR)$(moduledir)