summaryrefslogtreecommitdiff
path: root/libgssdp/Makefile.am
blob: 63283a4636f6c7e7301f147d6bb2dfd11bb4bc29 (plain)
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
# Version format current:revision:age
# If the library source code has changed at all since the last update, then
# increment revision (‘c:r:a’ becomes ‘c:r+1:a’).
# If any interfaces have been added, removed, or changed since the last update,
# increment current, and set revision to 0.
# If any interfaces have been added since the last public release, then
# increment age.
# If any interfaces have been removed since the last public release, then set
# age to 0.

LTVERSION = 3:0:0

AM_CFLAGS = $(LIBGSSDP_CFLAGS) -I$(top_srcdir)

libgssdpincdir = $(includedir)/gssdp-1.0/libgssdp

lib_LTLIBRARIES = libgssdp-1.0.la

libgssdpinc_HEADERS = 	gssdp-client.h		 \
			gssdp-error.h		 \
			gssdp-resource-browser.h \
			gssdp-resource-group.h	 \
			gssdp.h

gssdp-marshal.c: gssdp-marshal.list
	$(AM_V_GEN) \
	$(GLIB_GENMARSHAL) --prefix=gssdp_marshal $(srcdir)/gssdp-marshal.list --header --body > gssdp-marshal.c

gssdp-marshal.h: gssdp-marshal.list
	$(AM_V_GEN) \
	$(GLIB_GENMARSHAL) --prefix=gssdp_marshal $(srcdir)/gssdp-marshal.list --header > gssdp-marshal.h

BUILT_SOURCES = gssdp-marshal.c gssdp-marshal.h

introspection_sources = $(libgssdpinc_HEADERS)	\
			gssdp-client.c		\
			gssdp-error.c		\
			gssdp-resource-browser.c\
			gssdp-resource-group.c

libgssdp_1_0_la_LDFLAGS = -version-info $(LTVERSION)
libgssdp_1_0_la_SOURCES = $(introspection_sources)	\
			  gssdp-client-private.h	\
			  gssdp-protocol.h		\
			  gssdp-socket-source.c		\
			  gssdp-socket-source.h		\
			  gssdp-socket-functions.c	\
			  gssdp-socket-functions.h	\
			  $(BUILT_SOURCES)

if HAVE_PKTINFO
libgssdp_1_0_la_SOURCES += gssdp-pktinfo-message.c \
						   gssdp-pktinfo-message.h
endif

libgssdp_1_0_la_LIBADD = $(LIBGSSDP_LIBS)

if OS_WIN32

libgssdp_1_0_la_LIBADD += -lws2_32 -liphlpapi
libgssdp_1_0_la_LDFLAGS += -no-undefined
endif

if TARGET_ANDROID
libgssdp_1_0_la_LIBADD += -llog
endif

EXTRA_DIST = gssdp-marshal.list

CLEANFILES = $(BUILT_SOURCES)

-include $(INTROSPECTION_MAKEFILE)
INTROSPECTION_GIRS =
INTROSPECTION_SCANNER_ARGS = --warn-all				\
			     --symbol-prefix=gssdp		\
			     --identifier-prefix=GSSDP		\
			     --add-include-path=$(top_srcdir) \
			     --pkg-export=gssdp-1.0
INTROSPECTION_COMPILER_ARGS = --includedir=$(top_srcdir)


if HAVE_INTROSPECTION
GSSDP-1.0.gir: libgssdp-1.0.la
GSSDP_1_0_gir_INCLUDES = GObject-2.0 Gio-2.0 Soup-2.4
GSSDP_1_0_gir_CFLAGS = $(INCLUDES)
GSSDP_1_0_gir_LIBS = libgssdp-1.0.la
GSSDP_1_0_gir_FILES = $(introspection_sources)
GSSDP_1_0_gir_NAMESPACE = GSSDP
GSSDP_1_0_gir_VERSION = 1.0
INTROSPECTION_GIRS += GSSDP-1.0.gir

girdir = $(datadir)/gir-1.0
gir_DATA = GSSDP-1.0.gir

typelibdir = $(libdir)/girepository-1.0
typelib_DATA = $(gir_DATA:.gir=.typelib)

CLEANFILES += $(gir_DATA) $(typelib_DATA)
endif

DISTCLEANFILES = $(BUILT_SOURCES)
MAINTAINERCLEANFILES = Makefile.in $(BUILT_SOURCES)