1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146
|
##
## $Id: Makefile,v 1.26 1996/09/05 06:55:22 morgan Exp morgan $
##
## $Log: Makefile,v $
##
srcdir = .
# this should be the name of this directory
RELNAME = libpwdb-0.54preD
# this is the name of the archive file
DISTFILE = $(RELNAME).tar.gz
# Here we include the defines for the preferred operating system
# these include things like CC, CFLAGS and destination directories
# etc.. By default, this is a symbolic link to one of the .defs files
# the .../defs/ directory. Please take a moment to check that you are
# using the correct one.
include default.defs
# For extra debugging information
# EXTRAS += -DDEBUG
# ////////////////////////////////////////////////////
# // You should not modify anything below this line //
# ////////////////////////////////////////////////////
# the sub-directories to make things in
DIRS = libpwdb conf examples
#
# Conditional defines..
#
#
# basic defines
#
CRTDIR = $(shell pwd)
WARNINGS += -Wall -Wwrite-strings \
-Wpointer-arith -Wcast-qual -Wcast-align \
-Wtraditional -Wstrict-prototypes -Wmissing-prototypes \
-Wnested-externs -Winline -Wshadow #-ansi -pedantic -D_POSIX_SOURCE
INCLUDEDIR=-I$(srcdir)/include
#
# build composite defines
#
LOADLIBES = -L$(shell pwd)/libpwdb -lpwdb $(ULIBS) $(NSLLIB)
CFLAGS += $(EXTRAS) $(WARNINGS) $(INCLUDEDIR) -fPIC -D_REENTRANT
#
# generic exports
#
export CC # the C compiler
export INSTALL # to do instalations with
export MKDIR # to ensure directories exist
export CFLAGS # CC flags used to compile everything
export LD_D # build a shared object file (module)
export LD # build a generic library
export LDCONFIG # rebuild the shared libraries
export AR # build a static library
export RANLIB # reorder a static library
export LOADLIBES # libraries needed for application linking
#
# where to install things
#
export PREFIX # the basic prefix for all other directories
export INCLUDED # where to store pam---.h files
export SUPLEMENTED # where to store module helper binaries
export CONFIGED # where pam.conf file goes
export LIBDIR # where libpam and libpam_misc go
export SECUREDIR # where the modules will be placed
#
# Conditional exporting ( ... these go on for a while... )
#
##
## the rules
##
all:
@for i in $(DIRS) ; do \
test -d $$i || mkdir $$i ; \
make -C $$i -f $(srcdir)/../$$i/Makefile all srcdir=$(srcdir)/../$$i ; \
if [ $$? -ne 0 ]; then break ; fi ; \
done
install:
for i in $(DIRS) ; do \
test -d $$i || mkdir $$i ; \
make -C $$i -f $(srcdir)/../$$i/Makefile install srcdir=$(srcdir)/../$$i ; \
if [ $$? -ne 0 ]; then break ; fi ; \
done
sterile:
@make remove
@make extraclean
remove:
for i in $(DIRS) ; do \
test -d $$i || mkdir $$i ; \
make -C $$i -f $(srcdir)/../$$i/Makefile remove srcdir=$(srcdir)/../$$i ; \
done
clean:
rm -f *~ core
for i in $(DIRS) ; do \
test -d $$i || mkdir $$i ; \
make -C $$i -f $(srcdir)/../$$i/Makefile clean srcdir=$(srcdir)/../$$i ; \
done
test -d doc || mkdir doc
make -C doc -f $(srcdir)/../doc/Makefile clean srcdir=$(srcdir)/../doc
extraclean: clean
check:
make -C conf check
RCScheck:
make -C conf RCScheck
# this can be used to see what hasn't been check'd into RCS
open:
find . \( -type f -a -perm 644 \) -print
release:
@make extraclean
rm -f .filelist .RCSlist .freezemake
cd .. ; find $(RELNAME) \! -type d -print | grep -v RCS | grep -v 'conf/.md5sum' > $(RELNAME)/.filelist
chmod 444 .filelist
@make check
(cat .filelist ; echo $(RELNAME)/conf/.md5sum) | (cd .. ; tar -cz -f$(DISTFILE) -T-)
# cd .. ; find $(RELNAME) -type f -print | grep RCS | fgrep -v 'conf/.RCSsum' > $(RELNAME)/.RCSlist
# chmod 444 .RCSlist
# @make RCScheck
# (cat .RCSlist ; echo $(RELNAME)/conf/.RCSsum) | (cd .. ; tar -cz -fRCS+$(DISTFILE) -T-)
|