Makefile.am 3.21 KB
Newer Older
1 2 3 4 5 6 7
#
# Makefile.am for sofia-sip/libsofia-sip-ua
#
# Copyright (C) 2005,2006 Nokia Corporation
# Contact: Pekka Pessi <pekka.pessi@nokia.com>
# Licensed under LGPL. See file COPYING.
#
Pekka Pessi's avatar
Pekka Pessi committed
8 9 10 11 12
# ref: http://www.gnu.org/software/automake/manual/automake.html

AUTOMAKE_OPTIONS = foreign

# note: order does matter in the subdir list
13 14
SUBDIRS = su features bnf sresolv sdp url msg sip stun ipt soa \
	  tport http nta nea iptsec nth nua
15
DIST_SUBDIRS = $(SUBDIRS) docs
16

Pekka Pessi's avatar
Pekka Pessi committed
17
EXTRA_DIST = sofia.am
Pekka Pessi's avatar
Pekka Pessi committed
18
DOXYGEN = doxygen
Pekka Pessi's avatar
Pekka Pessi committed
19 20 21 22

lib_LTLIBRARIES = libsofia-sip-ua.la

libsofia_sip_ua_la_SOURCES = 
23
libsofia_sip_ua_la_LIBADD = 	bnf/libbnf.la \
Pekka Pessi's avatar
Pekka Pessi committed
24
				features/libfeatures.la \
25 26 27 28 29 30 31 32 33 34 35 36 37
				ipt/libipt.la \
				iptsec/libiptsec.la \
				msg/libmsg.la \
				nea/libnea.la \
				nta/libnta.la \
				nth/libnth.la \
				nua/libnua.la \
				http/libhttp.la \
				sdp/libsdp.la \
				sip/libsip.la \
				soa/libsoa.la \
				sresolv/libsresolv.la \
				su/libsu.la \
38
				stun/libstun.la \
39
				tport/libtport.la \
40
				url/liburl.la
41 42 43
# set the libtool version info version:revision:age for libsofia-sip-ua
# - soname to 'libsofia-sip-ua.so.(CUR-AGE)'
libsofia_sip_ua_la_LDFLAGS = \
44
	-version-info $(LIBVER_SOFIA_SIP_UA_CUR):$(LIBVER_SOFIA_SIP_UA_REV):$(LIBVER_SOFIA_SIP_UA_AGE)
45

46 47
if ENABLE_COVERAGE
COVERAGE_RECURSIVE = coverage-recursive
48
coverage: $(COVERAGE_RECURSIVE)
49 50
endif

51
all-recursive: built-sources-recursive
52
built-sources: built-sources-recursive 
53 54 55
clean-built-sources: clean-built-sources-recursive

built-sources-recursive clean-built-sources-recursive $(COVERAGE_RECURSIVE):
56
	target=`echo $@ | sed s/-recursive//`; \
57
	list='$(DIST_SUBDIRS)'; for subdir in $$list; do \
58 59
	  echo "Making $@ in $$subdir"; \
	  (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) $$target) \
60
	done;
Pekka Pessi's avatar
Pekka Pessi committed
61

62
doxygen: built-sources
63
	@echo Generating empty doxytags
Pekka Pessi's avatar
Pekka Pessi committed
64
	cd ${srcdir}; \
65
	mkdir -p docs/html ; \
Pekka Pessi's avatar
Pekka Pessi committed
66 67
	for d in $(DIST_SUBDIRS); do \
	  test -r $$d/Doxyfile || continue ; \
68 69
	  if ! test -r docs/$$d.doxytags ; then \
	    echo '<?xml version="1.0"?><tagfile/>' > docs/$$d.doxytags ; \
70 71 72 73
	  else \
	    sed '2,10s!<name>index</name>!<name>'$$d'_index</name>!' \
	    docs/$$d.doxytags > docs/$$d.doxytags.tmp && \
	    mv -f docs/$$d.doxytags.tmp docs/$$d.doxytags ; \
74
          fi ; \
Pekka Pessi's avatar
Pekka Pessi committed
75 76
	done
	@cd ${srcdir} ;\
77
	for d in $(DIST_SUBDIRS); do \
78
	  test -r $$d/Doxyfile \
Pekka Pessi's avatar
Pekka Pessi committed
79
	  && pushd $$d > /dev/null \
Pekka Pessi's avatar
Pekka Pessi committed
80
	  && echo running ${DOXYGEN} first time in $$d \
81 82 83 84 85 86 87
          && ${DOXYGEN} | fgrep -v -e resolve \
	  | fgrep -v -e 'Warning: Unsupported xml/html tag' \
          ; popd > /dev/null ; \
	  test -r docs/$$d.doxytags && \
	  sed '2,10s!<name>index</name>!<name>'$$d'_index</name>!' \
	    docs/$$d.doxytags > docs/$$d.doxytags.tmp && \
	  mv -f docs/$$d.doxytags.tmp docs/$$d.doxytags ; \
88 89 90 91 92
	done 
	@cd ${srcdir} ;\
	for d in $(DIST_SUBDIRS); do \
	  test -r $$d/Doxyfile \
	  && pushd $$d > /dev/null \
Pekka Pessi's avatar
Pekka Pessi committed
93
	  && echo running ${DOXYGEN} in second time in $$d \
94 95 96 97 98 99
          && ${DOXYGEN} | fgrep -v -e 'Warning: Unsupported xml/html tag' \
          ; popd > /dev/null ; \
	  test -r docs/$$d.doxytags && \
	  sed '2,10s!<name>index</name>!<name>'$$d'_index</name>!' \
	    docs/$$d.doxytags > docs/$$d.doxytags.tmp && \
	  mv -f docs/$$d.doxytags.tmp docs/$$d.doxytags ; \
100
	done 
Pekka Pessi's avatar
Pekka Pessi committed
101 102 103
	cd ${srcdir}/docs/html && ../hide_emails.sh

.PHONY: built-sources built-sources-am empty-doxytags doxygen