diff options
author | Greg Norris <adric@debian.org> | 2003-12-22 19:39:46 -0600 |
---|---|---|
committer | Timo Weingärtner <timo@tiwe.de> | 2012-11-08 08:21:18 +0100 |
commit | a5e39be83fdda78550b960b6099e48f60ac6305c (patch) | |
tree | 10a35c220d6f6969b9adba5840fbf1dd384339fd /Makefile.Debian | |
parent | 39cc0d22f5c8950f98ecbce84f42e158619db561 (diff) | |
download | libpam-pwdfile-a5e39be83fdda78550b960b6099e48f60ac6305c.tar.gz |
Imported Debian patch 0.99-2debian/0.99-2
Diffstat (limited to 'Makefile.Debian')
-rw-r--r-- | Makefile.Debian | 56 |
1 files changed, 56 insertions, 0 deletions
diff --git a/Makefile.Debian b/Makefile.Debian new file mode 100644 index 0000000..2b9e302 --- /dev/null +++ b/Makefile.Debian @@ -0,0 +1,56 @@ +# Modified Makefile to allow for building of the standalone module + +TITLE=pam_pwdfile + +CC = gcc +LD = ld +CFLAGS = -fPIC -c -g -Wall -Wformat-security +LDFLAGS = -x --shared +LDLIBS = -lcrypt -lpam -lpam_misc +LIBSRC = $(TITLE).c +LIBOBJ = $(TITLE).o md5_good.o md5_broken.o md5_crypt_good.o md5_crypt_broken.o bigcrypt.o +LIBSHARED = $(TITLE).so +PAM_LIB_DIR = $(DESTDIR)/lib/security +INSTALL = /usr/bin/install + +ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS))) + CFLAGS += -O0 +else + CFLAGS += -O2 +endif + + +all: $(LIBSHARED) + +md5_good.o: md5.c + $(CC) $(CFLAGS) $(CPPFLAGS) -DHIGHFIRST -D'MD5Name(x)=Good##x' \ + $(TARGET_ARCH) $< -o $@ + +md5_broken.o: md5.c + $(CC) $(CFLAGS) $(CPPFLAGS) -D'MD5Name(x)=Broken##x' \ + $(TARGET_ARCH) $< -o $@ + +md5_crypt_good.o: md5_crypt.c + $(CC) $(CFLAGS) $(CPPFLAGS) -D'MD5Name(x)=Good##x' \ + $(TARGET_ARCH) $< -o $@ + +md5_crypt_broken.o: md5_crypt.c + $(CC) $(CFLAGS) $(CPPFLAGS) -D'MD5Name(x)=Broken##x' \ + $(TARGET_ARCH) $< -o $@ + +$(LIBSHARED): $(LIBOBJ) + $(LD) $(LDFLAGS) -o $@ $(LIBOBJ) $(LDLIBS) + +install: $(LIBSHARED) + $(INSTALL) -m 0755 -d $(PAM_LIB_DIR) + $(INSTALL) -m 0644 pam_pwdfile.so $(PAM_LIB_DIR) + +clean: + rm -f $(LIBOBJS) $(LIBSHARED) core *~ + +extraclean: clean + rm -f *.a *.o *.so *.bak + +.c.o: + $(CC) $(CFLAGS) $< -o $@ + |