]> andersk Git - test.git/blob - Makefile.am
For Debian packages, added a missing build dependency on zlib.
[test.git] / Makefile.am
1 AM_CPPFLAGS          =
2 AM_CFLAGS            = -g -std=gnu99 -Wall
3 AM_LDFLAGS           = -g
4
5 noinst_LTLIBRARIES   = libhttp.la                                             \
6                        liblogging.la
7 noinst_DATA          = $(top_srcdir)/demo/demo.js
8 bin_PROGRAMS         = shellinaboxd
9 man_MANS             = shellinaboxd.1
10 noinst_HEADERS       = libhttp/http.h
11 dist_doc_DATA        = AUTHORS                                                \
12                        COPYING                                                \
13                        GPL-2                                                  \
14                        ChangeLog                                              \
15                        INSTALL                                                \
16                        NEWS                                                   \
17                        README                                                 \
18                        TODO
19 EXTRA_DIST           = demo/beep.wav                                          \
20                        demo/favicon.ico                                       \
21                        demo/demo.html                                         \
22                        demo/demo.js                                           \
23                        demo/demo.jspp                                         \
24                        demo/demo.xml                                          \
25                        demo/styles.css                                        \
26                        demo/vt100.js                                          \
27                        shellinabox/shellinaboxd.man.in                        \
28                        shellinabox/shell_in_a_box.js                          \
29                        shellinabox/vt100.js                                   \
30                        debian/README                                          \
31                        debian/changelog                                       \
32                        debian/compat                                          \
33                        debian/control                                         \
34                        debian/copyright                                       \
35                        debian/docs                                            \
36                        debian/rules                                           \
37                        debian/shellinabox.default                             \
38                        debian/shellinabox.dirs                                \
39                        debian/shellinabox.init                                \
40                        debian/shellinabox.install                             \
41                        debian/shellinabox.postinst                            \
42                        debian/shellinabox.postrm
43 LIBLOGGING_INCLUDES  = logging/logging.h                                      \
44                        config.h
45 liblogging_la_SOURCES= logging/logging.c                                      \
46                        $(LIBLOGGING_INCLUDES)
47 liblogging_la_LDFLAGS= -version 1:0:0
48
49 LIBHTTP_INCLUDES     = libhttp/hashmap.h                                      \
50                        libhttp/trie.h                                         \
51                        libhttp/httpconnection.h                               \
52                        libhttp/server.h                                       \
53                        libhttp/ssl.h                                          \
54                        libhttp/url.h                                          \
55                        config.h
56 libhttp_la_SOURCES   = libhttp/hashmap.c                                      \
57                        libhttp/trie.c                                         \
58                        libhttp/httpconnection.c                               \
59                        libhttp/server.c                                       \
60                        libhttp/ssl.c                                          \
61                        libhttp/url.c                                          \
62                        $(LIBHTTP_INCLUDES)                                    \
63                        libhttp/libhttp.sym
64 libhttp_la_LDFLAGS   = -export-symbols  $(top_srcdir)/libhttp/libhttp.sym     \
65                        -version 1:0:0
66
67 shellinaboxd_SOURCES = shellinabox/shellinaboxd.c                             \
68                        shellinabox/externalfile.c                             \
69                        shellinabox/externalfile.h                             \
70                        shellinabox/launcher.c                                 \
71                        shellinabox/launcher.h                                 \
72                        shellinabox/privileges.c                               \
73                        shellinabox/privileges.h                               \
74                        shellinabox/service.c                                  \
75                        shellinabox/service.h                                  \
76                        shellinabox/session.c                                  \
77                        shellinabox/session.h                                  \
78                        shellinabox/cgi_root.html                              \
79                        shellinabox/root_page.html                             \
80                        shellinabox/vt100.jspp                                 \
81                        shellinabox/shell_in_a_box.jspp                        \
82                        shellinabox/styles.css                                 \
83                        shellinabox/favicon.ico                                \
84                        shellinabox/beep.wav                                   \
85                        config.h
86 shellinaboxd_LDADD   = liblogging.la                                          \
87                        libhttp.la
88 shellinaboxd_LDFLAGS = -static
89
90 objcopyflags         = case "$(host_cpu)" in                                  \
91                          i[0-9]86) echo '-O elf32-i386 -B i386';;             \
92                          x86_64)   echo '-O elf64-x86-64 -B i386:x86-64';;    \
93                          arm*)     echo '-O elf32-littlearm -B arm';;         \
94                        esac
95
96 renamesymbols        =                                                        \
97   sed -e 's/\(.*\/\)\([^.]*\)\([.].*\)/\1\2\3=\2 /'                           \
98       -e 't0'                                                                 \
99       -e 's/\([^.]*\)\([.].*\)/\1\2=\1 /'                                     \
100       -e 't0'                                                                 \
101       -e 's/.*/&=& /'                                                         \
102       -e ':0'                                                                 \
103       -e 's/$$/aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ/'         \
104       -e ':1'                                                                 \
105       -e 's/\(=[^_]*\)_\([a-z]\)\([^ ]* .*\2\)\(.\)/\1\4\3\4/'                \
106       -e 't1'                                                                 \
107       -e 's/.\{53\}$$//'                                                      \
108       -e 's/[/.]/_/g'                                                         \
109       -e 's/^/--redefine-sym _binary_/'                                       \
110       -e 's/\([^=]*\)\(=[^ ]*\)/& \1_end\2End/'                               \
111       -e 's/\([^=]*\)\(=[^ ]*\)/& \1_start\2Start/'                           \
112       -e 's/[^ ]*\([^=]*\)=[^ ]*/-N\1_size/'
113
114 libtool: $(LIBTOOL_DEPS)
115         $(SHELL) ./config.status --recheck
116
117
118 ${top_srcdir}/demo/demo.js: ${top_srcdir}/demo/beep.wav                       \
119                             ${top_srcdir}/demo/demo.jspp                      \
120                             ${top_srcdir}/demo/favicon.ico                    \
121                             ${top_srcdir}/demo/styles.css                     \
122                             ${top_srcdir}/demo/vt100.js
123
124 ${top_srcdir}/demo/beep.wav: ${top_srcdir}/shellinabox/beep.wav
125         @rm -f "$@"
126         ln "$<" "$@"
127
128 ${top_srcdir}/demo/favicon.ico: ${top_srcdir}/shellinabox/favicon.ico
129         @rm -f "$@"
130         ln "$<" "$@"
131
132 ${top_srcdir}/demo/styles.css: ${top_srcdir}/shellinabox/styles.css
133         @rm -f "$@"
134         ln "$<" "$@"
135
136 ${top_srcdir}/demo/vt100.js: ${top_srcdir}/shellinabox/vt100.js
137         @rm -f "$@"
138         ln "$<" "$@"
139
140 shellinaboxd.1: shellinabox/shellinaboxd.man.in config.h
141         @src="${top_srcdir}/shellinabox/shellinaboxd.man.in";                 \
142         echo preprocess  "$$src" '>'"$@";                                     \
143         if [ `sed -e 's/^#define \([^ ]*\).*/\1/' -e t -e d config.h |        \
144              egrep 'HAVE_OPENSSL_BIO_H|HAVE_OPENSSL_ERR_H|HAVE_OPENSSL_SSL_H'|\
145              wc -l` -eq 3 ]; then                                             \
146           sed -e '/^#ifdef  *HAVE_OPENSSL$$/d'                                \
147               -e '/^#endif$$/d' "$$src" >"$@";                                \
148         else                                                                  \
149           sed -e '/^#ifdef  *HAVE_OPENSSL$$/,/^#endif$$/d' "$$src" >"$@";     \
150         fi;                                                                   \
151         if sed -e 's/^#define \([^ ]*\).*/\1/' -e t -e d config.h |           \
152              grep 'HAVE_SECURITY_PAM_APPL_H' >/dev/null 2>&1; then            \
153           sed -e '/^#ifdef  *HAVE_PAM$$/d'                                    \
154               -e '/^#endif$$/d' "$$src" >"$@";                                \
155         else                                                                  \
156           sed -e '/^#ifdef  *HAVE_PAM$$/,/^#endif$$/d' "$$src" >"$@";         \
157         fi
158         @out=`echo "$@" 2>/dev/null|sed -e 's/\.[^.]*$$/.ps/'`;               \
159         man -Tps "./$@" >"$${out}" 2>/dev/null || rm -f "$${out}"
160
161 clean-local:
162         -rm -rf shellinaboxd.1                                                \
163                 shellinaboxd.ps
164         -rm -rf debian/shellinabox                                            \
165                 debian/shellinabox*.debhelper*                                \
166                 debian/shellinabox.substvars                                  \
167                 debian/tmp
168
169 .css.o:
170         @echo objcopy "$<" "$@"
171         @objcopy -I binary `$(objcopyflags)` `echo "$<" | $(renamesymbols)`   \
172           "$<" "$@"
173
174 .html.o:
175         @echo objcopy "$<" "$@"
176         @objcopy -I binary `$(objcopyflags)` `echo "$<" | $(renamesymbols)`   \
177           "$<" "$@"
178
179 .ico.o:
180         @echo objcopy "$<" "$@"
181         @objcopy -I binary `$(objcopyflags)` `echo "$<" | $(renamesymbols)`   \
182           "$<" "$@"
183
184 shellinabox/shell_in_a_box.o: shellinabox/shell_in_a_box.js config.h
185
186 .jspp.js:
187         @echo preprocess "$<" "$@"
188         @sed -e "`sed -e 's/^#define *\([^ ]*\) *\(.*\)/\/^[^#]\/s\/\1\/\2 \\\\\/* \1 *\\\\\/\/g/' \
189                      -e t                                                     \
190                      -e d "$<"`"                                              \
191              -e "s/^#/\/\/ #/"                                                \
192              -e "s/VERSION/\"@VERSION@ (revision @VCS_REVISION@)\"/g"         \
193              "$<" >"$@"
194
195 .js.o:
196         @echo objcopy "$<" "$@"
197         @objcopy -I binary `$(objcopyflags)` `echo "$<" | $(renamesymbols)`   \
198           "$<" "$@"
199
200 .wav.o:
201         @echo objcopy "$<" "$@"
202         @objcopy -I binary `$(objcopyflags)` `echo "$<" | $(renamesymbols)`   \
203           "$<" "$@"
204
This page took 0.06854 seconds and 5 git commands to generate.