]> git.ipfire.org Git - pbs.git/blob - Makefile.am
web: Drop more unused UI modules
[pbs.git] / Makefile.am
1 ###############################################################################
2 # #
3 # Pakfire - The IPFire package management system #
4 # Copyright (C) 2017 Pakfire development team #
5 # #
6 # This program is free software: you can redistribute it and/or modify #
7 # it under the terms of the GNU General Public License as published by #
8 # the Free Software Foundation, either version 3 of the License, or #
9 # (at your option) any later version. #
10 # #
11 # This program is distributed in the hope that it will be useful, #
12 # but WITHOUT ANY WARRANTY; without even the implied warranty of #
13 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the #
14 # GNU General Public License for more details. #
15 # #
16 # You should have received a copy of the GNU General Public License #
17 # along with this program. If not, see <http://www.gnu.org/licenses/>. #
18 # #
19 ###############################################################################
20
21 ACLOCAL_AMFLAGS = -I m4 ${ACLOCAL_FLAGS}
22 AM_MAKEFLAGS = --no-print-directory
23 AUTOMAKE_OPTIONS = color-tests
24
25 # remove target it the command fails
26 .DELETE_ON_ERROR:
27
28 # keep itermediate files
29 .SECONDARY:
30
31 SUBDIRS = . po
32
33 pythondir = $(pyexecdir)/pakfire
34
35 configsdir = $(sysconfdir)/pakfire
36 crondir = $(sysconfdir)/cron.d
37
38 BUILT_SOURCES =
39 CLEANFILES =
40 DISTCLEANFILES =
41 EXTRA_DIST =
42 INSTALL_DIRS =
43 noinst_DATA =
44
45 @INTLTOOL_POLICY_RULE@
46
47 .PHONY: update-po
48 update-po: po/POTFILES.in
49 $(MAKE) -C po update-po
50
51 po/POTFILES.in: Makefile
52 find $(abs_srcdir)/src -not -path "$(abs_srcdir)/src/third-party/*" | \
53 grep -E "\.(html|py|txt)(\.in)?$$" | \
54 sed -e "s@$(abs_srcdir)/@@g" | \
55 LC_COLLATE=C sort > $@
56
57 DISTCHECK_CONFIGURE_FLAGS = \
58 --with-systemdsystemunitdir=$$dc_install_base/$(systemdsystemunitdir)
59
60 # ------------------------------------------------------------------------------
61
62 AM_V_XSLT = $(AM_V_XSLT_$(V))
63 AM_V_XSLT_ = $(AM_V_XSLT_$(AM_DEFAULT_VERBOSITY))
64 AM_V_XSLT_0 = @echo " XSLT " $@;
65
66 # ------------------------------------------------------------------------------
67
68 dist_doc_DATA = \
69 COPYING \
70 README
71
72 # ------------------------------------------------------------------------------
73
74 dist_bin_SCRIPTS = \
75 src/scripts/pakfire-build-service \
76 src/scripts/pakfire-hub \
77 src/scripts/pakfire-web
78
79 dist_configs_DATA = \
80 pbs.conf.sample
81
82 buildservice_PYTHON = \
83 src/buildservice/__init__.py \
84 src/buildservice/__version__.py \
85 src/buildservice/aws.py \
86 src/buildservice/base.py \
87 src/buildservice/bugtracker.py \
88 src/buildservice/builders.py \
89 src/buildservice/builds.py \
90 src/buildservice/cache.py \
91 src/buildservice/config.py \
92 src/buildservice/constants.py \
93 src/buildservice/database.py \
94 src/buildservice/decorators.py \
95 src/buildservice/distribution.py \
96 src/buildservice/events.py \
97 src/buildservice/git.py \
98 src/buildservice/jobqueue.py \
99 src/buildservice/jobs.py \
100 src/buildservice/keys.py \
101 src/buildservice/ldap.py \
102 src/buildservice/messages.py \
103 src/buildservice/mirrors.py \
104 src/buildservice/misc.py \
105 src/buildservice/packages.py \
106 src/buildservice/repository.py \
107 src/buildservice/sessions.py \
108 src/buildservice/settings.py \
109 src/buildservice/sources.py \
110 src/buildservice/uploads.py \
111 src/buildservice/users.py
112
113 buildservicedir = $(pythondir)/buildservice
114
115 BUILT_SOURCES += \
116 src/buildservice/constants.py
117
118 EXTRA_DIST += \
119 src/buildservice/constants.py.in
120
121 CLEANFILES += \
122 src/buildservice/constants.py
123
124 hub_PYTHON = \
125 src/hub/__init__.py \
126 src/hub/builds.py \
127 src/hub/handlers.py \
128 src/hub/jobs.py \
129 src/hub/queue.py \
130 src/hub/uploads.py
131
132 hubdir = $(buildservicedir)/hub
133
134 web_PYTHON = \
135 src/web/__init__.py \
136 src/web/auth.py \
137 src/web/base.py \
138 src/web/bugs.py \
139 src/web/builders.py \
140 src/web/builds.py \
141 src/web/distributions.py \
142 src/web/errors.py \
143 src/web/events.py \
144 src/web/handlers.py \
145 src/web/jobs.py \
146 src/web/keys.py \
147 src/web/mirrors.py \
148 src/web/packages.py \
149 src/web/repos.py \
150 src/web/search.py \
151 src/web/ui_modules.py \
152 src/web/users.py
153
154 webdir = $(buildservicedir)/web
155
156 # ------------------------------------------------------------------------------
157
158 dist_templates_DATA = \
159 src/templates/base.html \
160 src/templates/build-delete.html \
161 src/templates/build-manage.html \
162 src/templates/build-schedule-test.html \
163 src/templates/build-state.html \
164 src/templates/builds-watchers-add.html \
165 src/templates/builds-watchers-list.html \
166 src/templates/distro-edit.html \
167 src/templates/distro-source-commit-detail.html \
168 src/templates/distro-source-commit-reset.html \
169 src/templates/distro-source-commits.html \
170 src/templates/distro-source-detail.html \
171 src/templates/distro-update-detail.html \
172 src/templates/distro-update-edit.html \
173 src/templates/file-detail.html \
174 src/templates/index.html \
175 src/templates/jobs-abort.html \
176 src/templates/jobs-buildroot.html \
177 src/templates/log.html \
178 src/templates/login.html \
179 src/templates/package-properties.html \
180 src/templates/queue.html \
181 src/templates/search.html \
182 src/templates/source-list.html
183
184 templatesdir = $(datadir)/templates
185
186 templates_bugsdir = $(templatesdir)/bugs
187
188 dist_templates_bugs_modules_DATA = \
189 src/templates/bugs/modules/list.html
190
191 templates_bugs_modulesdir = $(templates_bugsdir)/modules
192
193 dist_templates_builders_DATA = \
194 src/templates/builders/delete.html \
195 src/templates/builders/detail.html \
196 src/templates/builders/edit.html \
197 src/templates/builders/list.html \
198 src/templates/builders/new.html
199
200 templates_buildersdir = $(templatesdir)/builders
201
202 dist_templates_builds_DATA = \
203 src/templates/builds/index.html \
204 src/templates/builds/show.html
205
206 templates_buildsdir = $(templatesdir)/builds
207
208 dist_templates_builds_modules_DATA = \
209 src/templates/builds/modules/list.html
210
211 templates_builds_modulesdir = $(templates_buildsdir)/modules
212
213 dist_templates_distros_DATA = \
214 src/templates/distros/index.html \
215 src/templates/distros/show.html
216
217 templates_distrosdir = $(templatesdir)/distros
218
219 dist_templates_errors_DATA = \
220 src/templates/errors/error.html \
221 src/templates/errors/error-400.html \
222 src/templates/errors/error-403.html \
223 src/templates/errors/error-404.html
224
225 templates_errorsdir = $(templatesdir)/errors
226
227 templates_eventsdir = $(templatesdir)/events
228
229 dist_templates_events_modules_DATA = \
230 src/templates/events/modules/list.html \
231 src/templates/events/modules/build-comment.html \
232 src/templates/events/modules/system-message.html \
233 src/templates/events/modules/user-message.html
234
235 templates_events_modulesdir = $(templates_eventsdir)/modules
236
237 templates_messagesdir = $(templatesdir)/messages
238
239 dist_templates_messages_builds_DATA = \
240 src/templates/messages/builds/new-comment.markdown
241
242 templates_messages_buildsdir = $(templates_messagesdir)/builds
243
244 dist_templates_messages_jobs_DATA = \
245 src/templates/messages/jobs/failed.markdown \
246 src/templates/messages/jobs/finished.markdown
247
248 templates_messages_jobsdir = $(templates_messagesdir)/jobs
249
250 dist_templates_messages_users_DATA = \
251 src/templates/messages/users/email-activation.markdown
252
253 templates_messages_usersdir = $(templates_messagesdir)/users
254
255 dist_templates_mirrors_DATA = \
256 src/templates/mirrors/delete.html \
257 src/templates/mirrors/detail.html \
258 src/templates/mirrors/edit.html \
259 src/templates/mirrors/list.html \
260 src/templates/mirrors/new.html
261
262 templates_mirrorsdir = $(templatesdir)/mirrors
263
264 dist_templates_modules_DATA = \
265 src/templates/modules/build-headline.html \
266 src/templates/modules/build-offset.html \
267 src/templates/modules/build-state-warnings.html \
268 src/templates/modules/build-table.html \
269 src/templates/modules/commits-table.html \
270 src/templates/modules/commit-message.html \
271 src/templates/modules/files-table.html \
272 src/templates/modules/link-to-user.html \
273 src/templates/modules/log-files-table.html \
274 src/templates/modules/modal-base.html \
275 src/templates/modules/modal-build-comment.html \
276 src/templates/modules/modal-build-push.html \
277 src/templates/modules/modal-build-unpush.html \
278 src/templates/modules/packages-files-table.html \
279 src/templates/modules/source-table.html \
280 src/templates/modules/text.html
281
282 templates_modulesdir = $(templatesdir)/modules
283
284 dist_templates_modules_jobs_DATA = \
285 src/templates/modules/jobs/list.html \
286 src/templates/modules/jobs/status.html
287
288 templates_modules_jobsdir = $(templates_modulesdir)/jobs
289
290 dist_templates_modules_select_DATA = \
291 src/templates/modules/select/locale.html \
292 src/templates/modules/select/timezone.html
293
294 templates_modules_selectdir = $(templates_modulesdir)/select
295
296 dist_templates_repos_DATA = \
297 src/templates/repos/create-custom.html \
298 src/templates/repos/builds.html \
299 src/templates/repos/edit.html \
300 src/templates/repos/show.html
301
302 templates_reposdir = $(templatesdir)/repos
303
304 dist_templates_repos_modules_DATA = \
305 src/templates/repos/modules/list.html
306
307 templates_repos_modulesdir = $(templates_reposdir)/modules
308
309 dist_templates_packages_DATA = \
310 src/templates/packages/index.html \
311 src/templates/packages/name.html \
312 src/templates/packages/show.html \
313 src/templates/packages/view-file.html
314
315 templates_packagesdir = $(templatesdir)/packages
316
317 dist_templates_packages_modules_DATA = \
318 src/templates/packages/modules/dependencies.html \
319 src/templates/packages/modules/info.html
320
321 templates_packages_modulesdir = $(templates_packagesdir)/modules
322
323 dist_templates_users_DATA = \
324 src/templates/users/delete.html \
325 src/templates/users/edit.html \
326 src/templates/users/index.html \
327 src/templates/users/show.html
328
329 templates_usersdir = $(templatesdir)/users
330
331 dist_templates_users_modules_DATA = \
332 src/templates/users/modules/list.html
333
334 templates_users_modulesdir = $(templates_usersdir)/modules
335
336 # ------------------------------------------------------------------------------
337 #
338 dist_static_DATA = \
339 src/static/favicon.ico \
340 src/static/robots.txt
341
342 staticdir = $(datadir)/static
343
344 static_css_DATA = \
345 src/static/css/highlight.css \
346 src/static/css/site.css
347
348 static_cssdir = $(staticdir)/css
349
350 EXTRA_DIST += \
351 src/static/css/_fonts.scss \
352 src/static/css/_icons.scss \
353 src/static/css/site.scss
354
355 CLEANFILES += \
356 src/static/css/site.css
357
358 static_js_DATA = \
359 src/static/js/foundation.min.js \
360 src/static/js/jquery.min.js \
361 src/static/js/pbs.js \
362 src/static/js/prettify.js
363
364 static_jsdir = $(staticdir)/js
365
366 CLEANFILES += \
367 src/static/js/foundation.min.js \
368 src/static/js/jquery.min.js
369
370 dist_static_fonts_DATA = \
371 src/third-party/fonts/prompt/OFL.txt \
372 src/third-party/fonts/prompt/Prompt-Black.ttf \
373 src/third-party/fonts/prompt/Prompt-BlackItalic.ttf \
374 src/third-party/fonts/prompt/Prompt-Bold.ttf \
375 src/third-party/fonts/prompt/Prompt-BoldItalic.ttf \
376 src/third-party/fonts/prompt/Prompt-ExtraBold.ttf \
377 src/third-party/fonts/prompt/Prompt-ExtraBoldItalic.ttf \
378 src/third-party/fonts/prompt/Prompt-ExtraLight.ttf \
379 src/third-party/fonts/prompt/Prompt-ExtraLightItalic.ttf \
380 src/third-party/fonts/prompt/Prompt-Italic.ttf \
381 src/third-party/fonts/prompt/Prompt-Light.ttf \
382 src/third-party/fonts/prompt/Prompt-LightItalic.ttf \
383 src/third-party/fonts/prompt/Prompt-Medium.ttf \
384 src/third-party/fonts/prompt/Prompt-MediumItalic.ttf \
385 src/third-party/fonts/prompt/Prompt-Regular.ttf \
386 src/third-party/fonts/prompt/Prompt-SemiBold.ttf \
387 src/third-party/fonts/prompt/Prompt-SemiBoldItalic.ttf \
388 src/third-party/fonts/prompt/Prompt-Thin.ttf \
389 src/third-party/fonts/prompt/Prompt-ThinItalic.ttf \
390 src/third-party/Font-Awesome/webfonts/fa-brands-400.ttf \
391 src/third-party/Font-Awesome/webfonts/fa-brands-400.woff2 \
392 src/third-party/Font-Awesome/webfonts/fa-regular-400.ttf \
393 src/third-party/Font-Awesome/webfonts/fa-regular-400.woff2 \
394 src/third-party/Font-Awesome/webfonts/fa-solid-900.ttf \
395 src/third-party/Font-Awesome/webfonts/fa-solid-900.woff2
396
397 static_fontsdir = $(staticdir)/fonts
398
399 # ------------------------------------------------------------------------------
400
401 if HAVE_SYSTEMD
402 systemdsystemunit_DATA = \
403 src/systemd/pakfire-hub.service \
404 src/systemd/pakfire-web.service
405
406 CLEANFILES += \
407 $(systemdsystemunit_DATA)
408
409 INSTALL_DIRS += \
410 $(systemdsystemunitdir)
411 endif
412
413 EXTRA_DIST += \
414 src/systemd/pakfire-hub.service.in \
415 src/systemd/pakfire-web.service.in
416
417 dist_database_DATA = \
418 src/database.sql
419
420 databasedir = $(datadir)/database
421
422 dist_cron_DATA = \
423 src/crontab/pakfire-build-service
424
425 EXTRA_DIST += \
426 src/tools/dump-database-schema.sh
427
428 # ------------------------------------------------------------------------------
429
430 substitutions = \
431 '|PACKAGE_NAME=$(PACKAGE_NAME)|' \
432 '|PACKAGE_VERSION=$(PACKAGE_VERSION)|' \
433 '|configsdir=$(configsdir)|' \
434 '|bindir=$(bindir)|' \
435 '|datadir=$(datadir)|' \
436 '|localedir=$(localedir)|' \
437 '|templatesdir=$(templatesdir)|' \
438 '|staticdir=$(staticdir)|'
439
440 SED_PROCESS = \
441 $(AM_V_GEN)$(MKDIR_P) $(dir $@) && \
442 $(SED) $(subst '|,-e 's|@,$(subst =,\@|,$(subst |',|g',$(substitutions)))) \
443 < $< > $@
444
445 UGLIFYJS_PROCESS = \
446 $(AM_V_GEN)$(MKDIR_P) $(dir $@) && \
447 $(UGLIFYJS) --compress --mangle -- $< > $@
448
449 %: %.in Makefile
450 $(SED_PROCESS)
451
452 %.css: %.scss
453 $(AM_V_GEN)$(MKDIR_P) $(dir $@) && \
454 $(SASSC) --style compressed $< > $@
455
456 src/static/css/highlight.css: Makefile
457 $(AM_V_GEN)$(MKDIR_P) $(dir $@) && \
458 $(PYGMENTIZE) -S xcode -f html -a .highlight > $@
459
460 %.min.js: %.js
461 $(UGLIFYJS_PROCESS)
462
463 src/static/js/foundation.min.js: src/third-party/foundation-sites/dist/js/foundation.js
464 $(UGLIFYJS_PROCESS)
465
466 # ------------------------------------------------------------------------------
467
468 TESTS = \
469 $(dist_check_SCRIPTS)
470
471 TESTS_ENVIRONMENT = \
472 PYTHONPATH="$(abs_top_srcdir)/src" \
473 abs_top_srcdir="$(abs_top_srcdir)"
474
475 dist_check_SCRIPTS = \
476 tests/setup.py \
477 tests/build.py \
478 tests/builder.py \
479 tests/distro.py \
480 tests/package.py \
481 tests/repo.py \
482 tests/upload.py
483
484 EXTRA_DIST += \
485 tests/test.py
486
487 EXTRA_DIST += \
488 tests/data/beep-1.3-2.ip3.src.pfm \
489 tests/data/beep-1.3-2.ip3.x86_64.pfm