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