summaryrefslogtreecommitdiffstats
path: root/ipa-server/ipa-slapi-plugins/ipa-pwd-extop/Makefile
diff options
context:
space:
mode:
authorKarl MacMillan <kmacmillan@mentalrootkit.com>2007-08-10 07:09:16 -0400
committerKarl MacMillan <kmacmillan@mentalrootkit.com>2007-08-10 07:09:16 -0400
commit88a1ab65ce61bd94af0560980194d44affea45fb (patch)
treee3fb46756dca7959129b63eae62bdda5c8eee8a5 /ipa-server/ipa-slapi-plugins/ipa-pwd-extop/Makefile
parenta3e786e22ec9d4b0e7d2ef982ac045a29477433e (diff)
downloadfreeipa-88a1ab65ce61bd94af0560980194d44affea45fb.tar.gz
freeipa-88a1ab65ce61bd94af0560980194d44affea45fb.tar.xz
freeipa-88a1ab65ce61bd94af0560980194d44affea45fb.zip
Updates to build kpaswd and the slapi plugins.
Diffstat (limited to 'ipa-server/ipa-slapi-plugins/ipa-pwd-extop/Makefile')
-rw-r--r--ipa-server/ipa-slapi-plugins/ipa-pwd-extop/Makefile29
1 files changed, 26 insertions, 3 deletions
diff --git a/ipa-server/ipa-slapi-plugins/ipa-pwd-extop/Makefile b/ipa-server/ipa-slapi-plugins/ipa-pwd-extop/Makefile
index 2a5646432..e89ca27ad 100644
--- a/ipa-server/ipa-slapi-plugins/ipa-pwd-extop/Makefile
+++ b/ipa-server/ipa-slapi-plugins/ipa-pwd-extop/Makefile
@@ -1,5 +1,28 @@
-all:
- gcc ipa_pwd_extop.c -I/usr/include -I/usr/include/nss3 -I/usr/include/mozldap -I/usr/include/nspr4 -I/usr/include/fedora-ds -lkrb5 -lmhash -llber -lssl -shared -g -fPIC -DPIC -Wl,-soname -Wl,libipa_pwd_extop.so -o libipa_pwd_extop.so
+PREFIX ?= $(DESTDIR)/usr
+LIBDIR = $(PREFIX)/lib/fedora-ds/plugins
+SHAREDIR = $(DESTDIR)/usr/share/ipa
+
+SONAME = libipa_pwd_extop.so
+LDFLAGS += -lkrb5 -llber -lldap -lmhash -llber -lssl
+CFLAGS ?= -Wall -Wshadow -O2
+CFLAGS += -I/usr/include/fedora-ds -I/usr/include/nss3 -I/usr/include/mozldap -I/usr/include/nspr4 -fPIC -DPIC
+
+OBJS = $(patsubst %.c,%.o,$(wildcard *.c))
+
+all: $(OBJS)
+ $(CC) $(LDFLAGS) $(OBJS) -Wl,-soname -Wl,$(SONAME) -shared -o $(SONAME)
+
+%.o: %.c
+ $(CC) $(CFLAGS) -c -o $@ $<
install:
- cp -f libipa_pwd_extop.so /usr/lib/fedora-ds/plugins/
+ -mkdir -p $(LIBDIR)
+ install -m 644 libipa_pwd_extop.so $(LIBDIR)
+ install -m 644 *.ldif $(SHAREDIR)
+
+clean:
+ rm -f *.o
+ rm -f $(SONAME)
+ rm -f *~
+
+