1MAINTAINERCLEANFILES = Makefile.in
2
3includesdir = $(includedir)/openjpeg-$(MAJOR_NR).$(MINOR_NR)
4includes_HEADERS =
5
6lib_LTLIBRARIES =
7
8if WANT_JPIP
9lib_LTLIBRARIES += libopenjpip_local.la
10endif
11
12if WANT_JPIP_SERVER
13lib_LTLIBRARIES += libopenjpip_server.la
14endif
15
16JPIP_SRC = \
17openjpip.c \
18query_parser.c \
19channel_manager.c \
20session_manager.c \
21jpip_parser.c \
22boxheader_manager.c \
23codestream_manager.c \
24imgreg_manager.c \
25marker_manager.c \
26msgqueue_manager.c \
27box_manager.c \
28faixbox_manager.c \
29index_manager.c \
30metadata_manager.c \
31placeholder_manager.c \
32byte_manager.c \
33ihdrbox_manager.c \
34manfbox_manager.c \
35mhixbox_manager.c \
36target_manager.c \
37cachemodel_manager.c \
38j2kheader_manager.c \
39jp2k_encoder.c \
40sock_manager.c \
41openjpip.h \
42bool.h \
43boxheader_manager.h \
44box_manager.h \
45byte_manager.h \
46codestream_manager.h \
47faixbox_manager.h \
48ihdrbox_manager.h \
49imgreg_manager.h \
50index_manager.h \
51manfbox_manager.h \
52marker_manager.h \
53metadata_manager.h \
54mhixbox_manager.h \
55msgqueue_manager.h \
56placeholder_manager.h \
57target_manager.h \
58cachemodel_manager.h \
59j2kheader_manager.h \
60jp2k_encoder.h \
61query_parser.h \
62channel_manager.h \
63session_manager.h \
64jpip_parser.h \
65jp2k_decoder.h \
66sock_manager.h
67
68SERVER_SRC = auxtrans_manager.c \
69auxtrans_manager.h
70
71LOCAL_SRC = jp2k_decoder.c \
72imgsock_manager.c \
73jpipstream_manager.c \
74cache_manager.c \
75dec_clientmsg_handler.c \
76imgsock_manager.h \
77jpipstream_manager.h \
78cache_manager.h \
79dec_clientmsg_handler.h
80
81libopenjpip_server_la_CPPFLAGS = \
82-I. \
83-I$(top_srcdir)/applications/jpip/libopenjpip \
84-I$(top_builddir)/applications/jpip/libopenjpip \
85@FCGI_CFLAGS@ \
86@LIBCURL_CFLAGS@ \
87-DSERVER
88libopenjpip_server_la_CFLAGS = @THREAD_CFLAGS@
89libopenjpip_server_la_LIBADD = @FCGI_LIBS@ @LIBCURL_LIBS@ @THREAD_LIBS@ -lm
90libopenjpip_server_la_LDFLAGS = -no-undefined -version-info @lt_version@
91libopenjpip_server_la_SOURCES = $(JPIP_SRC) $(SERVER_SRC)
92
93libopenjpip_local_la_CPPFLAGS = \
94-I. \
95-I$(top_srcdir)/libopenjpeg \
96-I$(top_builddir)/libopenjpeg \
97-I$(top_srcdir)/applications/jpip/libopenjpip \
98-I$(top_builddir)/applications/jpip/libopenjpip \
99@LIBCURL_CFLAGS@
100libopenjpip_local_la_CFLAGS =
101libopenjpip_local_la_LIBADD = $(top_builddir)/libopenjpeg/libopenjpeg.la -lm
102libopenjpip_local_la_LDFLAGS = -no-undefined -version-info @lt_version@
103libopenjpip_local_la_SOURCES = $(JPIP_SRC) $(LOCAL_SRC)
104
105install-data-hook:
106if WANT_JPIP_SERVER
107	@echo -e " (LA)\t$(libdir)/libopenjpip_server.la" >> $(top_builddir)/report.txt
108if BUILD_SHARED
109	@( $(call solist_s) ) >> $(top_builddir)/report.txt
110endif
111if BUILD_STATIC
112	@echo -e " (A)\t$(base_s)/$(a_s)" >> $(top_builddir)/report.txt
113endif
114endif
115if WANT_JPIP
116	@echo -e " (LA)\t$(libdir)/libopenjpip_local.la" >> $(top_builddir)/report.txt
117if BUILD_SHARED
118	@( $(call solist_c) ) >> $(top_builddir)/report.txt
119endif
120if BUILD_STATIC
121	@echo -e " (A)\t$(base_c)/$(a_c)" >> $(top_builddir)/report.txt
122endif
123endif
124
125solist_s    = $(foreach f, $(dll_s) $(so_s), echo -e ' $(SO_PREFIX)\t$(base_s)/$(f)' ;)
126get_tok_s   = $(shell grep -E "^$(1)=" libopenjpip_server.la | cut -d "'" -f 2)
127base_s      = $(call get_tok_s,libdir)
128so_s        = $(call get_tok_s,library_names)
129a_s         = $(call get_tok_s,old_library)
130
131solist_c    = $(foreach f, $(dll_c) $(so_c), echo -e ' $(SO_PREFIX)\t$(base_c)/$(f)' ;)
132get_tok_c   = $(shell grep -E "^$(1)=" libopenjpip_local.la | cut -d "'" -f 2)
133base_c      = $(call get_tok_c,libdir)
134so_c        = $(call get_tok_c,library_names)
135a_c         = $(call get_tok_c,old_library)
136
137if HAVE_WIN32
138SO_PREFIX = (DLL)
139dll_s     = $(call get_tok_s,dlname)
140dll_c     = $(call get_tok_c,dlname)
141else
142if HAVE_DARWIN
143SO_PREFIX = (DY)
144dll_s     =
145dll_c     =
146else
147SO_PREFIX = (SO)
148dll_s     =
149dll_c     =
150endif
151endif
152