]> andersk Git - test.git/blob - Makefile.am
Enable switching between 80 and 132 column mode, if the browser supports
[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                        shellinabox/white-on-black.css                         \
20                        shellinabox/black-on-white.css                         \
21                        shellinabox/monochrome.css                             \
22                        shellinabox/color.css
23 EXTRA_DIST           = INSTALL.Debian                                         \
24                        README.Fedora                                          \
25                        demo/beep.wav                                          \
26                        demo/favicon.ico                                       \
27                        demo/demo.html                                         \
28                        demo/demo.js                                           \
29                        demo/demo.jspp                                         \
30                        demo/demo.xml                                          \
31                        demo/enabled.gif                                       \
32                        demo/styles.css                                        \
33                        demo/print-styles.css                                  \
34                        demo/vt100.js                                          \
35                        demo/usercss-0.css                                     \
36                        demo/usercss-1.css                                     \
37                        demo/usercss-2.css                                     \
38                        demo/usercss-3.css                                     \
39                        etc-pam.d-shellinabox-example                          \
40                        shellinabox/shellinaboxd.man.in                        \
41                        shellinabox/shell_in_a_box.js                          \
42                        shellinabox/vt100.js                                   \
43                        shellinabox/cgi-mode-example.sh                        \
44                        debian/README                                          \
45                        debian/README.available                                \
46                        debian/README.enabled                                  \
47                        debian/changelog                                       \
48                        debian/compat                                          \
49                        debian/control                                         \
50                        debian/copyright                                       \
51                        debian/docs                                            \
52                        debian/rules                                           \
53                        debian/shellinabox.default                             \
54                        debian/shellinabox.dirs                                \
55                        debian/shellinabox.init                                \
56                        debian/shellinabox.install                             \
57                        debian/shellinabox.postinst                            \
58                        debian/shellinabox.postrm
59 LIBLOGGING_INCLUDES  = logging/logging.h                                      \
60                        config.h
61 liblogging_la_SOURCES= logging/logging.c                                      \
62                        $(LIBLOGGING_INCLUDES)
63 liblogging_la_LDFLAGS= -version 1:0:0
64
65 LIBHTTP_INCLUDES     = libhttp/hashmap.h                                      \
66                        libhttp/trie.h                                         \
67                        libhttp/httpconnection.h                               \
68                        libhttp/server.h                                       \
69                        libhttp/ssl.h                                          \
70                        libhttp/url.h                                          \
71                        config.h
72 libhttp_la_SOURCES   = libhttp/hashmap.c                                      \
73                        libhttp/trie.c                                         \
74                        libhttp/httpconnection.c                               \
75                        libhttp/server.c                                       \
76                        libhttp/ssl.c                                          \
77                        libhttp/url.c                                          \
78                        $(LIBHTTP_INCLUDES)                                    \
79                        libhttp/libhttp.sym
80 libhttp_la_LDFLAGS   = -export-symbols  $(top_srcdir)/libhttp/libhttp.sym     \
81                        -version 1:0:0
82
83 shellinaboxd_SOURCES = shellinabox/shellinaboxd.c                             \
84                        shellinabox/externalfile.c                             \
85                        shellinabox/externalfile.h                             \
86                        shellinabox/launcher.c                                 \
87                        shellinabox/launcher.h                                 \
88                        shellinabox/privileges.c                               \
89                        shellinabox/privileges.h                               \
90                        shellinabox/service.c                                  \
91                        shellinabox/service.h                                  \
92                        shellinabox/session.c                                  \
93                        shellinabox/session.h                                  \
94                        shellinabox/usercss.c                                  \
95                        shellinabox/usercss.h                                  \
96                        shellinabox/cgi_root.html                              \
97                        shellinabox/root_page.html                             \
98                        shellinabox/vt100.jspp                                 \
99                        shellinabox/shell_in_a_box.jspp                        \
100                        shellinabox/styles.css                                 \
101                        shellinabox/print-styles.css                           \
102                        shellinabox/enabled.gif                                \
103                        shellinabox/favicon.ico                                \
104                        shellinabox/beep.wav                                   \
105                        config.h
106 shellinaboxd_LDADD   = liblogging.la                                          \
107                        libhttp.la
108 shellinaboxd_LDFLAGS = -static
109
110 objcopyflags         = case "$(host_cpu)" in                                  \
111                          i[0-9]86) echo '-O elf32-i386 -B i386';;             \
112                          x86_64)   echo '-O elf64-x86-64 -B i386:x86-64';;    \
113                          arm*)     echo '-O elf32-littlearm -B arm';;         \
114                          powerpc*) echo '-O elf32-powerpc -B powerpc';;       \
115                        esac
116
117 renamesymbols        =                                                        \
118   sed -e 's/\(.*\/\)\([^.]*\)\([.].*\)/\1\2\3=\2 /'                           \
119       -e 't0'                                                                 \
120       -e 's/\([^.]*\)\([.].*\)/\1\2=\1 /'                                     \
121       -e 't0'                                                                 \
122       -e 's/.*/&=& /'                                                         \
123       -e ':0'                                                                 \
124       -e 's/$$/aAbBcCdDeEfFgGhHiIjJkKlLmMnNoOpPqQrRsStTuUvVwWxXyYzZ/'         \
125       -e ':1'                                                                 \
126       -e 's/\(=[^-_]*\)[-_]\([a-z]\)\([^ ]* .*\2\)\(.\)/\1\4\3\4/'            \
127       -e 't1'                                                                 \
128       -e 's/.\{53\}$$//'                                                      \
129       -e 's/[-/.]/_/g'                                                        \
130       -e 's/^/--redefine-sym _binary_/'                                       \
131       -e 's/\([^=]*\)\(=[^ ]*\)/& \1_end\2End/'                               \
132       -e 's/\([^=]*\)\(=[^ ]*\)/& \1_start\2Start/'                           \
133       -e 's/[^ ]*\([^=]*\)=[^ ]*/-N\1_size/'
134
135 libtool: $(LIBTOOL_DEPS)
136         $(SHELL) ./config.status --recheck
137
138
139 ${top_srcdir}/demo/demo.js: ${top_srcdir}/demo/beep.wav                       \
140                             ${top_srcdir}/demo/demo.jspp                      \
141                             ${top_srcdir}/demo/favicon.ico                    \
142                             ${top_srcdir}/demo/styles.css                     \
143                             ${top_srcdir}/demo/print-styles.css               \
144                             ${top_srcdir}/demo/vt100.js                       \
145                             ${top_srcdir}/demo/usercss-0.css                  \
146                             ${top_srcdir}/demo/usercss-1.css                  \
147                             ${top_srcdir}/demo/usercss-2.css                  \
148                             ${top_srcdir}/demo/usercss-3.css
149
150 ${top_srcdir}/demo/beep.wav: ${top_srcdir}/shellinabox/beep.wav
151         @rm -f "$@"
152         ln "$<" "$@"
153
154 ${top_srcdir}/demo/enabled.gif: ${top_srcdir}/shellinabox/enabled.gif
155         @rm -f "$@"
156         ln "$<" "$@"
157
158 ${top_srcdir}/demo/favicon.ico: ${top_srcdir}/shellinabox/favicon.ico
159         @rm -f "$@"
160         ln "$<" "$@"
161
162 ${top_srcdir}/demo/styles.css: ${top_srcdir}/shellinabox/styles.css
163         @rm -f "$@"
164         sed -e '/\[if DEFINES_COLORS\]/,/\[endif DEFINES_COLORS\]/d' "$<" >"$@"
165
166 ${top_srcdir}/demo/print-styles.css: ${top_srcdir}/shellinabox/print-styles.css
167         @rm -f "$@"
168         ln "$<" "$@"
169
170 ${top_srcdir}/demo/usercss-0.css: ${top_srcdir}/shellinabox/white-on-black.css
171         @rm -f "$@"
172         ln "$<" "$@"
173
174 ${top_srcdir}/demo/usercss-1.css: ${top_srcdir}/shellinabox/black-on-white.css
175         @rm -f "$@"
176         ln "$<" "$@"
177
178 ${top_srcdir}/demo/usercss-2.css: ${top_srcdir}/shellinabox/monochrome.css
179         @rm -f "$@"
180         ln "$<" "$@"
181
182 ${top_srcdir}/demo/usercss-3.css: ${top_srcdir}/shellinabox/color.css
183         @rm -f "$@"
184         ln "$<" "$@"
185
186 ${top_srcdir}/demo/vt100.js: ${top_srcdir}/shellinabox/vt100.js
187         @rm -f "$@"
188         ln "$<" "$@"
189
190 shellinaboxd.1: shellinabox/shellinaboxd.man.in config.h
191         @src="${top_srcdir}/shellinabox/shellinaboxd.man.in";                 \
192         echo preprocess  "$$src" '>'"$@";                                     \
193         if [ `sed -e 's/^#define \([^ ]*\).*/\1/' -e t -e d config.h |        \
194              egrep 'HAVE_OPENSSL_BIO_H|HAVE_OPENSSL_ERR_H|HAVE_OPENSSL_SSL_H'|\
195              wc -l` -eq 3 ]; then                                             \
196           sed -e '/^#ifndef  *HAVE_OPENSSL$$/,/^#endif$$/d' "$$src";          \
197         else                                                                  \
198           sed -e '/^#ifdef  *HAVE_OPENSSL$$/,/^#endif$$/d' "$$src";           \
199         fi |                                                                  \
200         if sed -e 's/^#define \([^ ]*\).*/\1/' -e t -e d config.h |           \
201              grep 'HAVE_SECURITY_PAM_APPL_H' >/dev/null 2>&1; then            \
202           sed -e '/^#ifndef  *HAVE_PAM$$/,/^#endif$$/d';                      \
203         else                                                                  \
204           sed -e '/^#ifdef  *HAVE_PAM$$/,/^#endif$$/d';                       \
205         fi |                                                                  \
206         if [ -n "${DPKGBUILD}" ]; then                                        \
207           sed -e '/^#ifndef  *DPKGBUILD$$/,/^#endif$$/d';                     \
208         else                                                                  \
209           sed -e '/^#ifdef  *DPKGBUILD$$/,/^#endif$$/d';                      \
210         fi |                                                                  \
211         sed -e '/^#/d' >"$@"
212         @out=`echo "$@" 2>/dev/null|sed -e 's/\.[^.]*$$/.ps/'`;               \
213         man -Tps "./$@" >"$${out}" 2>/dev/null || rm -f "$${out}"
214
215 clean-local:
216         -rm -rf shellinaboxd.1                                                \
217                 shellinaboxd.ps
218         -rm -rf debian/shellinabox                                            \
219                 debian/shellinabox*.debhelper*                                \
220                 debian/shellinabox.substvars                                  \
221                 debian/tmp
222
223 .css.o:
224         @echo objcopy "$<" "$@"
225         @objcopy -I binary `$(objcopyflags)` `echo "$<" | $(renamesymbols)`   \
226           "$<" "$@"
227
228 .gif.o:
229         @echo objcopy "$<" "$@"
230         @objcopy -I binary `$(objcopyflags)` `echo "$<" | $(renamesymbols)`   \
231           "$<" "$@"
232
233 .html.o:
234         @echo objcopy "$<" "$@"
235         @objcopy -I binary `$(objcopyflags)` `echo "$<" | $(renamesymbols)`   \
236           "$<" "$@"
237
238 .ico.o:
239         @echo objcopy "$<" "$@"
240         @objcopy -I binary `$(objcopyflags)` `echo "$<" | $(renamesymbols)`   \
241           "$<" "$@"
242
243 shellinabox/shell_in_a_box.o: shellinabox/shell_in_a_box.js config.h
244
245 .jspp.js:
246         @echo preprocess "$<" "$@"
247         @sed -e "`sed -e 's/^#define *\([^ ]*\) *\(.*\)/\/^[^#]\/s\/\1\/\2 \\\\\/* \1 *\\\\\/\/g/' \
248                      -e t                                                     \
249                      -e d "$<"`"                                              \
250              -e "s/^#/\/\/ #/"                                                \
251              -e "s/VERSION/\"@VERSION@ (revision @VCS_REVISION@)\"/g"         \
252              "$<" >"$@"
253
254 .js.o:
255         @echo objcopy "$<" "$@"
256         @objcopy -I binary `$(objcopyflags)` `echo "$<" | $(renamesymbols)`   \
257           "$<" "$@"
258
259 .wav.o:
260         @echo objcopy "$<" "$@"
261         @objcopy -I binary `$(objcopyflags)` `echo "$<" | $(renamesymbols)`   \
262           "$<" "$@"
263
This page took 0.080973 seconds and 5 git commands to generate.