| # |
| # Top-level Makefile for APRUTIL |
| # |
| |
| TARGET_LIB = libaprutil.la |
| TARGET_EXPORTS = aprutil.exports |
| |
| TARGETS = delete-lib $(TARGET_LIB) delete-exports $(TARGET_EXPORTS) |
| |
| top_builddir = @top_builddir@ |
| include $(top_builddir)/build/rules.mk |
| |
| SUBDIRS = src . test build |
| |
| CLEAN_TARGETS = $(TARGET_EXPORTS) |
| DISTCLEAN_TARGETS = config.cache config.log config.status config.sub \ |
| include/private/apu_config.h include/private/apu_private.h |
| EXTRACLEAN_TARGETS = configure libtool aclocal.m4 \ |
| include/private/apu_config.h.in |
| |
| ### fix this up at some point (install location) |
| libdir = /usr/local/lib |
| |
| delete-lib: |
| @if test -f $(TARGET_LIB); then \ |
| objects="`find src -name '*.lo' -a -newer $(TARGET_LIB)`" ; \ |
| if test -n "$$objects"; then \ |
| echo Found newer objects. Will relink $(TARGET_LIB). ; \ |
| echo $(RM) -f $(TARGET_LIB) ; \ |
| $(RM) -f $(TARGET_LIB) ; \ |
| fi \ |
| fi |
| |
| $(TARGET_LIB): |
| @objects="`find src -name '*.lo'`" ; \ |
| echo $(LINK) $$objects ; \ |
| $(LINK) -rpath $(libdir) $$objects |
| |
| delete-exports: |
| @if test -f $(TARGET_EXPORTS); then \ |
| headers="`find include/*.h -newer $(TARGET_EXPORTS)`" ; \ |
| if test -n "$$headers"; then \ |
| echo Found newer headers. Will rebuild $(TARGET_EXPORTS). ; \ |
| echo $(RM) -f $(TARGET_EXPORTS) ; \ |
| $(RM) -f $(TARGET_EXPORTS) ; \ |
| fi \ |
| fi |
| |
| $(TARGET_EXPORTS): |
| perl @APR_SOURCE_DIR@/helpers/make_export.pl -o $@ include/*.h |
| |
| docs: |
| mkdir ./docs |
| perl @APR_SOURCE_DIR@/helpers/scandoc -i./build/default.pl -p./docs/ ./include/*.h |
| |
| |
| .PHONY: delete-lib delete-exports |