mirror of
https://git.openldap.org/openldap/openldap.git
synced 2024-12-15 03:01:09 +08:00
334768c1bb
make depend, make tests, and make install all work when build directory is not the $srcdir. Also modified library handling such that -lpthread more likely to be last. WARNING: new orderring requires use of LDFLAGS to set global loader options such as -L/usr/local/lib. If you put this in LIBS, some libraries may not be found a link time. Likely broke Kerberos/LDAPD support. Don't have those in my testbed.
44 lines
1.3 KiB
Makefile
44 lines
1.3 KiB
Makefile
PROGRAMS= rp500 fax500
|
|
|
|
SRCS= main.c faxtotpc.c rp500.c
|
|
XSRCS=fax5version.c rpversion.c
|
|
|
|
FAX5OBJS = main.o faxtotpc.o
|
|
RPOBJS = rp500.o faxtotpc.o
|
|
|
|
LDAP_INCDIR= ../../include
|
|
LDAP_LIBDIR= ../../libraries
|
|
|
|
XLIBS = $(LDAP_LIBS)
|
|
XXLIBS = $(KRB_LIBS)
|
|
|
|
rp500 : rpversion.o
|
|
$(LTLINK) -o $@ $(RPOBJS) rpversion.o $(LIBS)
|
|
|
|
fax500 : fax5version.o
|
|
$(LTLINK) -o $@ $(RPOBJS) fax5version.o $(LIBS)
|
|
|
|
rpversion.c: ${RPOBJS} $(LDAP_LIBDEPEND)
|
|
$(RM) $@
|
|
(u=$${USER-root} v=`$(CAT) $(VERSIONFILE)` d=`$(PWD)` h=`$(HOSTNAME)` \
|
|
t=`$(DATE)`; $(SED) -e "s|%WHEN%|$${t}|" \
|
|
-e "s|%WHOANDWHERE%|$${u}@$${h}:$${d}|" \
|
|
-e "s|%VERSION%|$${v}|" \
|
|
< $(srcdir)/Versionrp.c > $@)
|
|
|
|
fax5version.c: ${FAX5OBJS} $(LDAP_LIBDEPEND)
|
|
$(RM) $@
|
|
(u=$${USER-root} v=`$(CAT) $(VERSIONFILE)` d=`$(PWD)` h=`$(HOSTNAME)` \
|
|
t=`$(DATE)`; $(SED) -e "s|%WHEN%|$${t}|" \
|
|
-e "s|%WHOANDWHERE%|$${u}@$${h}:$${d}|" \
|
|
-e "s|%VERSION%|$${v}|" \
|
|
< $(srcdir)/Version.c > $@)
|
|
|
|
install-local: $(PROGRAMS) xrpcomp FORCE
|
|
-$(MKDIR) $(libexecdir)
|
|
$(LTINSTALL) $(INSTALLFLAGS) -m 755 rp500 $(libexecdir)
|
|
$(LTINSTALL) $(INSTALLFLAGS) -m 755 fax500 $(libexecdir)
|
|
$(SED) -e 's%LIBEXECDIR%$(libexecdir)%' $(srcdir)/xrpcomp > /tmp/xrpcomp.tmp
|
|
$(INSTALL) $(INSTALLFLAGS) -m 755 /tmp/xrpcomp.tmp $(libexecdir)/xrpcomp
|
|
$(RM) /tmp/xrpcomp.tmp
|