Welcome to mirror list, hosted at ThFree Co, Russian Federation.

Makefile.am - github.com/freebsd/poudriere.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
blob: 23c3f3dc8788160c722ecb084fd357b826b7ec0f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
CLEANFILES=	$(dist_rc_SCRIPTS)
MOSTLYCLEANFILES=

ACLOCAL_AMFLAGS=	-I m4
AM_CFLAGS=	-Wall -pipe -O2 @AM_CFLAGS@
if MAINTAINER_MODE
AM_CFLAGS+=	-Wextra -Werror
endif

awkdir=	$(pkgdatadir)/awk
htmldir= $(pkgdatadir)/html
includedir= $(pkgdatadir)/include
assetsdir= $(htmldir)/assets
bootstrapdir= $(assetsdir)/bootstrap-3.1.1
btcssdir= $(bootstrapdir)/css
btjsdir= $(bootstrapdir)/js
btfontsdir= $(bootstrapdir)/fonts
datatablesdir= $(assetsdir)/DataTables-1.10.0
dtcssdir= $(datatablesdir)/css
dtimagesdir= $(datatablesdir)/images
dtjsdir= $(datatablesdir)/js
rcdir= $(sysconfdir)/rc.d
hookdir= $(sysconfdir)/poudriere.d/hooks
mandir= $(prefix)/man
examplesdir= $(datadir)/examples/$(PACKAGE_NAME)

EXTRA_DIST=	\
		src/bin/poudriere.in \
		test-ports/

dist_bin_SCRIPTS=	poudriere

dist_man_MANS=	src/man/poudriere.8 \
		src/man/poudriere-bulk.8 \
		src/man/poudriere-distclean.8 \
		src/man/poudriere-image.8 \
		src/man/poudriere-jail.8 \
		src/man/poudriere-logclean.8 \
		src/man/poudriere-options.8 \
		src/man/poudriere-pkgclean.8 \
		src/man/poudriere-ports.8 \
		src/man/poudriere-queue.8 \
		src/man/poudriere-status.8 \
		src/man/poudriere-testport.8 \
		src/man/poudriere-version.8

dist_sysconf_DATA=	\
		src/etc/poudriere.conf.sample \
		src/etc/poudriered.conf.sample
dist_examples_DATA=	\
		src/share/examples/poudriere/nginx.conf.sample \
		src/share/examples/poudriere/httpd.conf.sample

dist_hook_DATA=	src/etc/poudriere.d/hooks/bulk.sh.sample \
		src/etc/poudriere.d/hooks/pkgbuild.sh.sample

dist_pkgdata_DATA=	\
			src/share/poudriere/api.sh \
			src/share/poudriere/bulk.sh \
			src/share/poudriere/common.sh \
			src/share/poudriere/daemon.sh \
			src/share/poudriere/distclean.sh \
			src/share/poudriere/foreachport.sh \
			src/share/poudriere/image.sh \
			src/share/poudriere/image_dump.sh \
			src/share/poudriere/image_firmware.sh \
			src/share/poudriere/image_hybridiso.sh \
			src/share/poudriere/image_iso.sh \
			src/share/poudriere/image_mfs.sh \
			src/share/poudriere/image_rawdisk.sh \
			src/share/poudriere/image_tar.sh \
			src/share/poudriere/image_usb.sh \
			src/share/poudriere/image_zfs.sh \
			src/share/poudriere/image_zsnapshot.sh \
			src/share/poudriere/jail.sh \
			src/share/poudriere/logclean.sh \
			src/share/poudriere/options.sh \
			src/share/poudriere/pkgclean.sh \
			src/share/poudriere/ports.sh \
			src/share/poudriere/processonelog.sh \
			src/share/poudriere/queue.sh \
			src/share/poudriere/status.sh \
			src/share/poudriere/testport.sh

dist_include_HEADERS= \
			src/share/poudriere/include/cache.sh \
			src/share/poudriere/include/colors.sh \
			src/share/poudriere/include/colors.pre.sh \
			src/share/poudriere/include/common.sh.dragonfly \
			src/share/poudriere/include/common.sh.freebsd \
			src/share/poudriere/include/display.sh \
			src/share/poudriere/include/html.sh \
			src/share/poudriere/include/hash.sh \
			src/share/poudriere/include/fs.sh \
			src/share/poudriere/include/parallel.sh \
			src/share/poudriere/include/pkg.sh \
			src/share/poudriere/include/pkgqueue.sh \
			src/share/poudriere/include/shared_hash.sh \
			src/share/poudriere/include/util.sh

dist_awk_DATA= src/share/poudriere/awk/dependency_loop.awk \
		src/share/poudriere/awk/humanize.awk \
		src/share/poudriere/awk/json.awk \
		src/share/poudriere/awk/json_jail.awk \
		src/share/poudriere/awk/json_top.awk \
		src/share/poudriere/awk/parse_MOVED.awk \
		src/share/poudriere/awk/processonelog2.awk \
		src/share/poudriere/awk/siginfo_buildtime.awk \
		src/share/poudriere/awk/unique_pkgnames_from_flavored_origins.awk

dist_html_DATA= 	src/share/poudriere/html/build.html \
			src/share/poudriere/html/index.html \
			src/share/poudriere/html/jail.html \
			src/share/poudriere/html/robots.txt
dist_assets_DATA=	src/share/poudriere/html/assets/poudriere.js \
			src/share/poudriere/html/assets/logo.svg \
			src/share/poudriere/html/assets/favicon.ico \
			src/share/poudriere/html/assets/poudriere.css \
			src/share/poudriere/html/assets/jquery-1.11.1.js \
			src/share/poudriere/html/assets/jquery-1.11.1.min.js \
			src/share/poudriere/html/assets/jquery-1.11.1.min.map \
			src/share/poudriere/html/assets/jquery.dataTables.rowGrouping-1.2.9.js
dist_btjs_DATA=		src/share/poudriere/html/assets/bootstrap-3.1.1/js/bootstrap.min.js
dist_btfonts_DATA=	src/share/poudriere/html/assets/bootstrap-3.1.1/fonts/glyphicons-halflings-regular.eot \
			src/share/poudriere/html/assets/bootstrap-3.1.1/fonts/glyphicons-halflings-regular.svg \
			src/share/poudriere/html/assets/bootstrap-3.1.1/fonts/glyphicons-halflings-regular.ttf \
			src/share/poudriere/html/assets/bootstrap-3.1.1/fonts/glyphicons-halflings-regular.woff
dist_btcss_DATA=	src/share/poudriere/html/assets/bootstrap-3.1.1/css/bootstrap-theme.min.css \
			src/share/poudriere/html/assets/bootstrap-3.1.1/css/bootstrap.min.css
dist_dtcss_DATA=	src/share/poudriere/html/assets/DataTables-1.10.0/css/jquery.dataTables.min.css \
			src/share/poudriere/html/assets/DataTables-1.10.0/css/jquery.dataTables_themeroller.min.css
dist_dtjs_DATA=		src/share/poudriere/html/assets/DataTables-1.10.0/js/jquery.dataTables.min.js
dist_dtimages_DATA=	src/share/poudriere/html/assets/DataTables-1.10.0/images/back_disabled.png \
			src/share/poudriere/html/assets/DataTables-1.10.0/images/back_enabled.png \
			src/share/poudriere/html/assets/DataTables-1.10.0/images/back_enabled_hover.png \
			src/share/poudriere/html/assets/DataTables-1.10.0/images/forward_disabled.png \
			src/share/poudriere/html/assets/DataTables-1.10.0/images/forward_enabled.png \
			src/share/poudriere/html/assets/DataTables-1.10.0/images/forward_enabled_hover.png \
			src/share/poudriere/html/assets/DataTables-1.10.0/images/sort_asc.png \
			src/share/poudriere/html/assets/DataTables-1.10.0/images/sort_asc_disabled.png \
			src/share/poudriere/html/assets/DataTables-1.10.0/images/sort_both.png \
			src/share/poudriere/html/assets/DataTables-1.10.0/images/sort_desc.png \
			src/share/poudriere/html/assets/DataTables-1.10.0/images/sort_desc_disabled.png

dist_rc_SCRIPTS=	src/etc/rc.d/poudriered

pkglibexec_PROGRAMS= \
		     cachec \
		     cached \
		     clock \
		     cpdup \
		     dirempty \
		     dirwatch \
		     jexecd \
		     locked_mkdir \
		     nc \
		     poudriered \
		     ptsort \
		     pwait \
		     rename \
		     rexec \
		     @USE_RM@ \
		     setsid \
		     timeout \
		     timestamp \
		     @SH@
EXTRA_PROGRAMS= \
		rm \
		sh

noinst_LTLIBRARIES=	libucl.la libnv.la libptsort.la
CLEANFILES+=		libucl.a libnv.a libptsort.a

AUTOMAKE_OPTIONS=	subdir-objects

clock_SOURCES=	src/libexec/poudriere/clock/clock.c
cpdup_SOURCES=	src/libexec/poudriere/cpdup/src/cpdup.c \
		src/libexec/poudriere/cpdup/src/cpdup.h \
		src/libexec/poudriere/cpdup/src/hclink.c \
		src/libexec/poudriere/cpdup/src/hclink.h \
		src/libexec/poudriere/cpdup/src/hcproto.c \
		src/libexec/poudriere/cpdup/src/hcproto.h \
		src/libexec/poudriere/cpdup/src/md5.c \
		src/libexec/poudriere/cpdup/src/misc.c
cpdup_LDADD=	-lcrypto
cpdup_CFLAGS=	$(AM_CFLAGS) -D_ST_FLAGS_PRESENT_=1
dirempty_SOURCES=	src/libexec/poudriere/dirempty/dirempty.c
dirwatch_SOURCES=	src/libexec/poudriere/dirwatch/dirwatch.c
locked_mkdir_SOURCES=	src/libexec/poudriere/locked_mkdir/locked_mkdir.c
nc_SOURCES=		src/libexec/poudriere/nc/nc.c
pwait_SOURCES=		src/libexec/poudriere/pwait/pwait.c
rename_SOURCES=		src/libexec/poudriere/rename/rename.c
rm_SOURCES=		src/libexec/poudriere/rm/rm.c
setsid_SOURCES=		src/libexec/poudriere/setsid/setsid.c \
			src/libexec/poudriere/setsid/c.h
setsid_CFLAGS=		-DHAVE_ERR_H -DHAVE_NANOSLEEP
timeout_SOURCES=	src/libexec/poudriere/timeout/timeout.c
timestamp_SOURCES=	src/libexec/poudriere/timestamp/timestamp.c
timestamp_LDADD=	-lpthread

sh_CFLAGS=		$(AM_CFLAGS) -Wno-extra \
			-DSHELL -std=gnu99 -DVTABSIZE=1000 ${sh_hist_CFLAGS} \
			-Wno-unused-const-variable \
			-include $(top_srcdir)/external/sh_compat/compat.h \
			-I$(top_srcdir)/src \
			-I$(top_srcdir)/external/sh
sh_LDADD=		${sh_hist_LDADD} -lsbuf
if MAINTAINER_MODE
sh_hist_LDADD=		-ledit
else
sh_hist_CFLAGS=		-DNO_HISTORY
endif
include $(top_srcdir)/external/sh/Makefile.sources
# Extra builtins
CLEANFILES+=		\
			src/poudriere-sh/builtins.c \
			src/poudriere-sh/builtins.def \
			src/poudriere-sh/builtins.h \
			src/poudriere-sh/shell.h
sh_SOURCES+=		\
			src/libexec/poudriere/clock/clock.c \
			src/libexec/poudriere/dirempty/dirempty.c \
			src/libexec/poudriere/locked_mkdir/locked_mkdir.c \
			src/libexec/poudriere/pwait/pwait.c \
			src/libexec/poudriere/rename/rename.c \
			src/libexec/poudriere/rm/rm.c \
			src/poudriere-sh/builtins-poudriere.def \
			src/poudriere-sh/helpers.c \
			src/poudriere-sh/helpers.h \
			src/poudriere-sh/mapfile.c \
			src/poudriere-sh/mkdir.c \
			src/poudriere-sh/mkfifo.c \
			src/poudriere-sh/mktemp.c \
			src/poudriere-sh/realpath.c \
			src/poudriere-sh/rmdir.c \
			src/poudriere-sh/setproctitle.c \
			src/poudriere-sh/sleep.c \
			src/poudriere-sh/stat.c \
			src/poudriere-sh/touch.c \
			src/poudriere-sh/traps.c \
			src/poudriere-sh/unlink.c

sh_CFLAGS+=		-I$(top_srcdir)/src/poudriere-sh \
			-I$(top_builddir)/src/poudriere-sh
# cachec
#sh_SOURCES+=		src/libexec/poudriere/cachec/cachec.c
#sh_LDADD+=		-lrt
src/poudriere-sh/builtins.def: external/sh/builtins.def \
    src/poudriere-sh/builtins-poudriere.def
	cat $^${.ALLSRC} > $@
src/poudriere-sh/shell.h:
	@ln -fs $(abs_top_srcdir)/external/sh/shell.h $@
src/poudriere-sh/builtins.h: src/poudriere-sh/builtins.def \
      src/poudriere-sh/shell.h external/sh/mkbuiltins
	cd src/poudriere-sh && \
	    sh $(abs_top_srcdir)/external/sh/mkbuiltins .
src/poudriere-sh/builtins.c: src/poudriere-sh/builtins.h
sh_SOURCES+=		src/poudriere-sh/builtins.c
${sh_OBJECTS}:		src/poudriere-sh/builtins.h

libucl_la_SOURCES=	\
			external/libucl/include/lua_ucl.h \
			external/libucl/include/ucl.h \
			external/libucl/klib/khash.h \
			external/libucl/klib/kvec.h \
			external/libucl/src/tree.h \
			external/libucl/src/ucl_chartable.h \
			external/libucl/src/ucl_emitter.c \
			external/libucl/src/ucl_emitter_streamline.c \
			external/libucl/src/ucl_emitter_utils.c \
			external/libucl/src/ucl_hash.c \
			external/libucl/src/ucl_hash.h \
			external/libucl/src/ucl_internal.h \
			external/libucl/src/ucl_parser.c \
			external/libucl/src/ucl_util.c \
			external/libucl/src/xxhash.c \
			external/libucl/src/xxhash.h \
			external/libucl/uthash/uthash.h \
			external/libucl/uthash/utlist.h \
			external/libucl/uthash/utstring.h

libucl_la_CFLAGS=	$(AM_CFLAGS) -Wno-extra \
			-I$(top_srcdir)/external/libucl/uthash \
			-I$(top_srcdir)/external/libucl/klib  \
			-I$(top_srcdir)/external/libucl/include  \
			-I$(top_srcdir)/external/libucl/src \
			-Wno-unused-parameter -Wno-pointer-sign \
			-Wno-unused-variable

libptsort_la_SOURCES=	external/ptsort/lib/aa_tree.c \
			external/ptsort/lib/aa_tree.h \
			external/ptsort/lib/fline.c \
			external/ptsort/lib/fline.h

libptsort_la_CPPFLAGS=	-I$(top_srcdir)/external/ptsort/lib
ptsort_SOURCES=		external/ptsort/bin/ptsort.c
ptsort_LDADD=		libptsort.la
ptsort_CPPFLAGS=	-I$(top_srcdir)/external/ptsort/lib

libnv_la_CFLAGS=	$(AM_CFLAGS) \
			-isystem $(top_srcdir)/external/libnv/ -std=gnu99
libnv_la_SOURCES=	\
			external/libnv/common_impl.h \
			external/libnv/msgio.c \
			external/libnv/msgio.h \
			external/libnv/sys/dnv.h \
			external/libnv/sys/dnvlist.c \
			external/libnv/sys/nv.h \
			external/libnv/sys/nv_impl.h \
			external/libnv/sys/nvlist.c \
			external/libnv/sys/nvlist_impl.h \
			external/libnv/sys/nvpair.c \
			external/libnv/sys/nvpair_impl.h

poudriered_SOURCES=	src/poudriered/poudriered.c
poudriered_CFLAGS=	$(AM_CFLAGS) \
			-DPREFIX=\"$(prefix)\" \
			-I$(top_srcdir)/external/libucl/include
poudriered_LDADD=	libucl.la \
			-lsbuf \
			-lutil

jexecd_SOURCES=	src/libexec/poudriere/jexecd/jexecd.c
jexecd_CFLAGS=	$(AM_CFLAGS) -I$(top_srcdir)/external/libnv/sys
jexecd_LDADD=	libnv.la \
		-lsbuf \
		-lutil \
		-ljail

rexec_SOURCES=	src/libexec/poudriere/rexec/rexec.c
rexec_CFLAGS=	$(AM_CFLAGS) -I$(top_srcdir)/external/libnv/sys
rexec_LDADD=	libnv.la

cached_SOURCES=	src/libexec/poudriere/cached/cached.c \
		external/klib/khash.h
cached_CFLAGS=	$(AM_CFLAGS) -I$(top_srcdir)/external/klib
cached_LDADD=	-lutil -lrt

cachec_SOURCES=	src/libexec/poudriere/cachec/cachec.c
cachec_LDADD=	-lrt

DEVEL_SFX=	-devel

.PHONY:	gen-make-wiki
gen-man-wiki:
	@if [ ! -e wiki/poudriere.8.md ]; then \
	  echo "You must clone https://github.com/freebsd/poudriere.wiki.git to wiki/"; \
	  exit 1; \
	fi
	@if ! which mandoc 2>&1 >/dev/null; then \
	  echo "Mandoc required, install textproc/mdocml"; \
	  exit 1; \
	fi
	@for man in $(dist_man_MANS); do \
	  echo "MANDOC wiki/$${man##*/}${DEVEL_SFX}.md"; \
	  ( \
	    echo "### This page is auto-generated from $${man}"; \
	    (mandoc -Thtml -O man=%N.%S${DEVEL_SFX} $${man} | awk \
	    '$$1 == "<body>" { seenbody=1; next; }; \
	     $$1 == "</body>" { seenbody=0; }; \
	     seenbody == 1 { print };'\
	    ); \
	  ) > wiki/$${man##*/}${DEVEL_SFX}.md; \
	done

MOSTLYCLEANFILES+=	poudriere
.PHONY: poudriere
poudriere: src/bin/poudriere.in
	$(AM_V_GEN)if test -e $(top_srcdir)/.git && \
	    which git >/dev/null 2>&1 && \
	    [ -d "$$(git -C "$(top_srcdir)" rev-parse --git-dir)" ]; then \
	    gitver=$$(git -C "$(top_srcdir)" describe --tags HEAD); \
	    sed -e "s,^\(POUDRIERE_VERSION\)=.*,\1='$${gitver}'," \
	      $^${.ALLSRC} > $@; \
	else \
	    cp -f $^${.ALLSRC} $@; \
	fi; \
	chmod +x $@

SUBDIRS= . test

installcheck-local:
	$(MAKE) $(AM_MAKEFLAGS) check am_installcheck=1