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