summaryrefslogtreecommitdiffstats
path: root/ipa-server/ipa-slapi-plugins
diff options
context:
space:
mode:
authorKarl MacMillan <kmacmillan@mentalrootkit.com>2007-08-15 15:56:45 -0400
committerKarl MacMillan <kmacmillan@mentalrootkit.com>2007-08-15 15:56:45 -0400
commite27ab98fd27fbfef7634900a4f136b2d5cba9c21 (patch)
treee4f946aeeeb948fa0e2e67326d92a0f0d20ed3a4 /ipa-server/ipa-slapi-plugins
parentd3415f85b00ee993679afad6f6a2f64c881ed0ec (diff)
downloadfreeipa-e27ab98fd27fbfef7634900a4f136b2d5cba9c21.tar.gz
freeipa-e27ab98fd27fbfef7634900a4f136b2d5cba9c21.tar.xz
freeipa-e27ab98fd27fbfef7634900a4f136b2d5cba9c21.zip
Integrate memberof plugin into build.
Diffstat (limited to 'ipa-server/ipa-slapi-plugins')
-rw-r--r--ipa-server/ipa-slapi-plugins/Makefile2
-rw-r--r--ipa-server/ipa-slapi-plugins/ipa-memberof/Makefile29
2 files changed, 27 insertions, 4 deletions
diff --git a/ipa-server/ipa-slapi-plugins/Makefile b/ipa-server/ipa-slapi-plugins/Makefile
index 95ed26c6..a5d1c191 100644
--- a/ipa-server/ipa-slapi-plugins/Makefile
+++ b/ipa-server/ipa-slapi-plugins/Makefile
@@ -1,4 +1,4 @@
-SUBDIRS=ipa-pwd-extop
+SUBDIRS=ipa-pwd-extop ipa-memberof
all:
@for subdir in $(SUBDIRS); do \
diff --git a/ipa-server/ipa-slapi-plugins/ipa-memberof/Makefile b/ipa-server/ipa-slapi-plugins/ipa-memberof/Makefile
index 013d6273..62176265 100644
--- a/ipa-server/ipa-slapi-plugins/ipa-memberof/Makefile
+++ b/ipa-server/ipa-slapi-plugins/ipa-memberof/Makefile
@@ -1,5 +1,28 @@
-all:
- gcc ipa-memberof.c -I/usr/include/nss3 -I/usr/include/mozldap -I/usr/include/nspr4 -I/usr/include/fedora-ds -I/usr/include -llber -shared -fPIC -DPIC -g -Wl,-soname -Wl,libipa-memberof-plugin.so -o libipa-memberof-plugin.so
+PREFIX ?= $(DESTDIR)/usr
+LIBDIR = $(PREFIX)/lib/fedora-ds/plugins
+SHAREDIR = $(DESTDIR)/usr/share/ipa
+
+SONAME = libipa-memberof-plugin.so
+LDFLAGS += -llber
+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-memberof-plugin.so /usr/lib/fedora-ds/plugins/
+ -mkdir -p $(LIBDIR)
+ install -m 644 $(SONAME) $(LIBDIR)
+ install -m 644 *.ldif $(SHAREDIR)
+
+clean:
+ rm -f *.o
+ rm -f $(SONAME)
+ rm -f *~
+
+