upload http
[bottlenecks.git] / rubbos / app / httpd-2.0.64 / srclib / apr-util / Makefile
1 #
2 # Top-level Makefile for APRUTIL
3 #
4 CPP = gcc -E
5
6 # gets substituted into some targets
7 APRUTIL_MAJOR_VERSION=0
8 APRUTIL_DOTTED_VERSION=0.9.19
9
10 srcdir = .
11
12
13 INCLUDES = -I/bottlenecks/rubbos/app/httpd-2.0.64/srclib/apr-util/include -I/bottlenecks/rubbos/app/httpd-2.0.64/srclib/apr-util/include/private  -I/bottlenecks/rubbos/app/httpd-2.0.64/srclib/apr/include  -I/bottlenecks/rubbos/app/httpd-2.0.64/srclib/apr-util/xml/expat/lib
14 APRUTIL_LDFLAGS = -L/bottlenecks/rubbos/app/httpd-2.0.64/srclib/apr-util/xml/expat/lib
15 APRUTIL_LIBS = /bottlenecks/rubbos/app/httpd-2.0.64/srclib/apr-util/xml/expat/libexpat.la /bottlenecks/rubbos/app/httpd-2.0.64/srclib/apr/libapr-0.la -lrt -lm -lcrypt -lnsl -lpthread -ldl
16
17 TARGET_LIB = libaprutil-${APRUTIL_MAJOR_VERSION}.la
18 INSTALL_SUBDIRS = xml/expat
19
20 TARGETS = delete-lib $(TARGET_LIB) delete-exports aprutil.exp export_vars.h
21
22 # bring in rules.mk for standard functionality
23 include /bottlenecks/rubbos/app/httpd-2.0.64/srclib/apr-util/build/rules.mk
24
25 SUBDIRS = buckets crypto dbm encoding hooks ldap uri xml misc strmatch xlate
26 CLEAN_SUBDIRS = test
27
28 CLEAN_TARGETS = exports.c export_vars.h aprutil.exp apu-config.out
29 DISTCLEAN_TARGETS = config.cache config.log config.status libtool \
30         include/private/apu_config.h include/private/apu_private.h \
31         include/private/apu_select_dbm.h include/apr_ldap.h include/apu.h \
32         export_vars.sh apu-config build/rules.mk include/apu_want.h
33 EXTRACLEAN_TARGETS = configure aclocal.m4 include/private/apu_config.h.in
34
35 prefix=/bottlenecks/rubbos/app/apache2
36 exec_prefix=/bottlenecks/rubbos/app/apache2
37 bindir=${prefix}/bin
38 libdir=${prefix}/lib
39 includedir=/bottlenecks/rubbos/app/apache2/include
40 top_srcdir=/bottlenecks/rubbos/app/httpd-2.0.64/srclib/apr-util
41 top_blddir=/bottlenecks/rubbos/app/httpd-2.0.64/srclib/apr-util
42
43 EXPORT_FILES = $(top_srcdir)/include/*.h
44
45 delete-lib:
46         @if test -f $(TARGET_LIB); then \
47             objects="`find $(SUBDIRS) -name expat -prune -o -name '*.lo' -a -newer $(TARGET_LIB) -print`" ; \
48             if test -n "$$objects"; then \
49                 echo Found newer objects. Will relink $(TARGET_LIB). ; \
50                 echo $(RM) -f $(TARGET_LIB) ; \
51                 $(RM) -f $(TARGET_LIB) ; \
52             fi; \
53         fi
54
55 apu-config.out: apu-config
56         sed 's,^\(location=\).*$$,\1installed,' < apu-config > $@
57
58 install: $(TARGET_LIB) apu-config.out
59 install: $(TARGET_LIB)
60         if [ ! -d $(DESTDIR)$(includedir) ]; then \
61             $(APR_MKDIR) $(DESTDIR)$(includedir); \
62         fi;
63         cp -p $(top_srcdir)/include/*.h $(DESTDIR)$(includedir)
64
65         if [ -n "$(top_blddir)" ]; then \
66                 cp -p $(top_blddir)/include/*.h $(DESTDIR)$(includedir); \
67         fi;
68         if [ ! -d $(DESTDIR)$(libdir) ]; then \
69             $(APR_MKDIR) $(DESTDIR)$(libdir); \
70         fi;
71         list='$(INSTALL_SUBDIRS)'; for i in $$list; do \
72                 ( cd $$i ; $(MAKE) DESTDIR=$(DESTDIR) install ); \
73         done
74         $(LIBTOOL) --mode=install cp $(TARGET_LIB) $(DESTDIR)$(libdir)
75         $(LIBTOOL) --mode=install cp aprutil.exp $(DESTDIR)$(libdir)
76         if [ ! -d $(DESTDIR)$(bindir) ]; then \
77                 $(APR_MKDIR) $(DESTDIR)$(bindir); \
78         fi;
79         $(LIBTOOL) --mode=install cp apu-config.out $(DESTDIR)$(bindir)/apu-config
80         chmod 755 $(DESTDIR)$(bindir)/apu-config
81
82 $(TARGET_LIB):
83         @objects="`find $(SUBDIRS) -name expat -prune -o -name 'gen_uri_delims.lo' -prune -o -name '*.lo' -print`"; \
84             tmpcmd="$(LINK) -rpath $(libdir) $$objects "; \
85             echo $$tmpcmd; \
86             $$tmpcmd && touch $@
87
88 delete-exports:
89         @if test -f aprutil.exp; then \
90             headers="`find include/*.h -newer aprutil.exp -print`" ; \
91             if test -n "$$headers"; then \
92                 echo Found newer headers. Will rebuild aprutil.exp. ; \
93                 echo $(RM) -f aprutil.exp ; \
94                 $(RM) -f aprutil.exp ; \
95             fi \
96         fi
97
98 exports.c:
99         $(APR_MKEXPORT) $(EXPORT_FILES) > $@
100
101 export_vars.h:
102         $(APR_MKVAREXPORT) $(EXPORT_FILES) > $@
103
104 aprutil.exp: exports.c export_vars.h
105         @echo "#! libaprutil-${APRUTIL_MAJOR_VERSION}.so" > $@
106         @echo "* This file was AUTOGENERATED at build time." >> $@
107         @echo "* Please do not edit by hand." >> $@
108         $(CPP) $(ALL_CPPFLAGS) $(ALL_INCLUDES) exports.c | grep "ap_hack_" | sed -e 's/^.*[)]\(.*\);$$/\1/' >> $@
109         $(CPP) $(ALL_CPPFLAGS) $(ALL_INCLUDES) export_vars.h | sed -e 's/^\#[^!]*//' | sed -e '/^$$/d' >> $@
110
111 dox:
112         doxygen $(top_srcdir)/docs/doxygen.conf
113
114 check: $(TARGET_LIB)
115         (cd test && $(MAKE) check)
116
117
118 .PHONY: delete-lib delete-exports
119 .NOTPARALLEL: delete-lib delete-exports