Clean up the source tree a little more:
[OpenSRF.git] / Makefile.am
1 # Copyright (C) 2008 Equinox Software, Inc.
2 # Kevin Beswick <kevinbeswick00@gmail.com>
3 #
4 # This program is free software; you can redistribute it and/or
5 # modify it under the terms of the GNU General Public License
6 # as published by the Free Software Foundation; either version 2
7 # of the License, or (at your option) any later version.
8 #
9 # This program is distributed in the hope that it will be useful,
10 # but WITHOUT ANY WARRANTY; without even the implied warranty of
11 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
12 # GNU General Public License for more details.
13
14
15 if !DEBUG
16 MAYBE_DEBUG = -DNDEBUG
17 endif
18
19 export PREFIX                   = @prefix@
20 export TMP                      = @TMP@
21 export LIBXML2_HEADERS          = @LIBXML2_HEADERS@
22 export APR_HEADERS              = @APR_HEADERS@
23 export ETCDIR                   = @sysconfdir@
24 export APXS2                    = @APXS2@
25 export APACHE2_HEADERS          = @APACHE2_HEADERS@
26 export DEF_CFLAGS               = -D_LARGEFILE64_SOURCE $(MAYBE_DEBUG) -pipe -g -Wall -O2 -fPIC -I@abs_top_srcdir@/include/ -I$(LIBXML2_HEADERS) -I$(APACHE2_HEADERS) -I$(APR_HEADERS) @INCLUDES@
27 export DEF_LDLIBS               = -lopensrf
28 export VAR                      = @localstatedir@
29 export PID                      = @localstatedir@/run/opensrf
30 export SOCK                     = @localstatedir@/lock/opensrf
31 export LOG                      = @localstatedir@/log/opensrf
32 export srcdir                   = @srcdir@
33
34 AM_CFLAGS = $(DEF_CFLAGS)
35
36 DOC_FILES = @srcdir@/doc/Application-HOWTO.txt \
37             @srcdir@/doc/dokuwiki-doc-stubber.pl \
38             @srcdir@/doc/OpenSRF-Messaging-Protocol.html \
39             @srcdir@/doc/Persist-API.html \
40             @srcdir@/doc/Roadmap.txt \
41                 @srcdir@/AUTHORS \
42                 @srcdir@/ChangeLog \
43                 @srcdir@/INSTALL \
44                 @srcdir@/README
45
46 EXAMPLES_FILES = @srcdir@/examples/fieldmapper2cdbi.xsl \
47                  @srcdir@/examples/fieldmapper2javascript.xsl \
48                  @srcdir@/examples/fieldmapper2perl.xsl \
49                  @srcdir@/examples/gen-fieldmapper.xml \
50                  @srcdir@/examples/math_bench.pl \
51                  @srcdir@/examples/math_client.py \
52                  @srcdir@/examples/multisession-test.pl \
53                  @srcdir@/examples/register.pl \
54                  @srcdir@/examples/srfsh_config.xsd \
55                  @srcdir@/examples/math_xul_client/math \
56                  @srcdir@/examples/math_xul_client/install.js
57
58 strn_compat_FILES = @srcdir@/src/ports/strn_compat/strndup.c \
59                     @srcdir@/src/ports/strn_compat/strndup.h \
60                     @srcdir@/src/ports/strn_compat/strnlen.c \
61                     @srcdir@/src/ports/strn_compat/strnlen.h
62
63 python_FILES = @srcdir@/src/python/opensrf.py \
64                @srcdir@/src/python/setup.py \
65                @srcdir@/src/python/srfsh.py \
66                @srcdir@/src/python/osrf
67
68 java_FILES = @srcdir@/src/java/deps.inc \
69              @srcdir@/src/java/deps.sh \
70              @srcdir@/src/java/org
71
72 libosrf_FILES = @srcdir@/src/libopensrf/basic_client.c \
73                 @srcdir@/src/libopensrf/osrf_big_hash.c \
74                 @srcdir@/src/libopensrf/osrf_big_list.c \
75                 @srcdir@/src/libopensrf/osrfConfig.c
76
77
78 EXTRA_DIST = $(DOC_FILES) $(EXAMPLES_FILES) $(libosrf_FILES) $(strn_compat_FILES) $(python_FILES) $(java_FILES) @srcdir@/autogen.sh @srcdir@/src/extras @srcdir@/COPYING @srcdir@/DCO-1.1.txt @srcdir@/LICENSE.txt @srcdir@/src/perl @srcdir@/src/javascript
79
80 opensrfincludedir = @includedir@/opensrf
81
82 OSRFINC=@srcdir@/include/opensrf
83
84 opensrfinclude_HEADERS = $(OSRFINC)/log.h \
85                                 $(OSRFINC)/md5.h \
86                                 $(OSRFINC)/osrf_application.h \
87                                 $(OSRFINC)/osrf_app_session.h \
88                                 $(OSRFINC)/osrf_big_hash.h \
89                                 $(OSRFINC)/osrf_big_list.h \
90                                 $(OSRFINC)/osrf_cache.h \
91                                 $(OSRFINC)/osrfConfig.h \
92                                 $(OSRFINC)/osrf_hash.h \
93                                 $(OSRFINC)/osrf_json.h \
94                                 $(OSRFINC)/osrf_json_utils.h \
95                                 $(OSRFINC)/osrf_json_xml.h \
96                                 $(OSRFINC)/osrf_legacy_json.h \
97                                 $(OSRFINC)/osrf_list.h \
98                                 $(OSRFINC)/osrf_message.h \
99                                 $(OSRFINC)/osrf_prefork.h \
100                                 $(OSRFINC)/osrf_settings.h \
101                                 $(OSRFINC)/osrf_stack.h \
102                                 $(OSRFINC)/osrf_system.h \
103                                 $(OSRFINC)/osrf_transgroup.h \
104                                 $(OSRFINC)/sha.h \
105                                 $(OSRFINC)/socket_bundle.h \
106                                 $(OSRFINC)/string_array.h \
107                                 $(OSRFINC)/transport_client.h \
108                                 $(OSRFINC)/transport_message.h \
109                                 $(OSRFINC)/transport_session.h \
110                                 $(OSRFINC)/utils.h \
111                                 $(OSRFINC)/xml_utils.h
112
113
114
115 SUBDIRS = src
116
117 jserver:
118         make -s -C src jserver
119
120 jserver-install:
121         make -s -C src jserver-install
122
123 javascript-install:
124         make -s -C src javascript-install
125
126 install-data-hook:
127         cp @srcdir@/src/gateway/apachetools.h @includedir@/opensrf/apachetools.h
128