Makefile.am 3.14 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
# ref: http://www.gnu.org/software/automake/manual/automake.html

AUTOMAKE_OPTIONS = foreign

12
# select which optional sofia-sip modules have been enabled
13 14 15 16 17 18 19 20 21 22 23 24 25
# in the build
OPT_LIBADD =
OPT_SUBDIRS_STUN =
OPT_SUBDIRS_NTH =
if HAVE_STUN
OPT_LIBADD += stun/libstun.la 
OPT_SUBDIRS_STUN += stun
endif
if HAVE_NTH
OPT_LIBADD += nth/libnth.la http/libhttp.la
OPT_SUBDIRS_NTH += nth http
endif

Pekka Pessi's avatar
Pekka Pessi committed
26
# note: order does matter in the subdir list
27 28
SUBDIRS = su features bnf sresolv sdp url msg sip $(OPT_SUBDIRS_STUN) ipt soa \
	  tport nta nea iptsec $(OPT_SUBDIRS_NTH) nua
29 30
DIST_SUBDIRS = su features bnf sresolv sdp url msg sip stun ipt soa \
	  tport nta nea iptsec nth http nua docs
31

Pekka Pessi's avatar
Pekka Pessi committed
32
DOXYGEN = doxygen
Pekka Pessi's avatar
Pekka Pessi committed
33 34 35 36

lib_LTLIBRARIES = libsofia-sip-ua.la

libsofia_sip_ua_la_SOURCES = 
37
libsofia_sip_ua_la_LIBADD = 	bnf/libbnf.la \
Pekka Pessi's avatar
Pekka Pessi committed
38
				features/libfeatures.la \
39 40 41 42 43 44 45 46 47 48 49 50
				ipt/libipt.la \
				iptsec/libiptsec.la \
				msg/libmsg.la \
				nea/libnea.la \
				nta/libnta.la \
				nua/libnua.la \
				sdp/libsdp.la \
				sip/libsip.la \
				soa/libsoa.la \
				sresolv/libsresolv.la \
				su/libsu.la \
				tport/libtport.la \
51 52
				url/liburl.la \
				$(OPT_LIBADD)
53

54 55 56
# 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 = \
57
	-version-info $(LIBVER_SOFIA_SIP_UA_CUR):$(LIBVER_SOFIA_SIP_UA_REV):$(LIBVER_SOFIA_SIP_UA_AGE)
58

Pekka Pessi's avatar
Pekka Pessi committed
59
PHONY = doxygen built-sources
60

61
include $(top_srcdir)/rules/recursive.am
Pekka Pessi's avatar
Pekka Pessi committed
62

63
doxygen: built-sources
64 65
	@echo Generating empty doxytags
	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
	done
76
	for d in $(DIST_SUBDIRS); do \
77
	  test -r $$d/Doxyfile \
Pekka Pessi's avatar
Pekka Pessi committed
78
	  && pushd $$d > /dev/null \
Pekka Pessi's avatar
Pekka Pessi committed
79
	  && echo running ${DOXYGEN} first time in $$d \
80
          && ${DOXYGEN} 2>&1 \
81
	  | egrep -v -i -e 'Warning: (unsupported (xml/)?html tag|unable to resolve reference|explicit link.*could not be resolved)' \
82 83 84 85 86
          ; 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 ; \
87 88 89 90
	done 
	for d in $(DIST_SUBDIRS); do \
	  test -r $$d/Doxyfile \
	  && pushd $$d > /dev/null \
91
	  && echo running ${DOXYGEN} second time in $$d \
92 93
          && ${DOXYGEN} 2>&1 \
	   | egrep -v -i -e 'Warning: Unsupported (xml/)?html tag' \
94 95 96 97 98
          ; 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 ; \
99
	done 
100
	${srcdir}/docs/hide_emails.sh docs/html
Pekka Pessi's avatar
Pekka Pessi committed
101

102
if HAVE_LCOV
Pekka Pessi's avatar
Pekka Pessi committed
103
include $(top_srcdir)/rules/lcov.am
104 105 106
endif

.PHONY: $(PHONY)