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