]> git.ipfire.org Git - ipfire.org.git/blob - Makefile.am
292291aa6fca9f2dcb68a0c01d30aa136b4e14d5
[ipfire.org.git] / Makefile.am
1 #!/usr/bin/make
2
3 AM_MAKEFLAGS = --no-print-directory
4 AUTOMAKE_OPTIONS = color-tests
5
6 # remove target it the command fails
7 .DELETE_ON_ERROR:
8
9 # keep itermediate files
10 .SECONDARY:
11
12 pythondir = $(pyexecdir)
13
14 configsdir = $(sysconfdir)/ipfire.org
15 crondir = $(sysconfdir)/cron.d
16
17 CLEANFILES =
18 DISTCLEANFILES =
19 EXTRA_DIST =
20 INSTALL_DIRS =
21 noinst_DATA =
22
23 DISTCHECK_CONFIGURE_FLAGS = \
24 --with-systemdsystemunitdir=$$dc_install_base/$(systemdsystemunitdir)
25
26 # ------------------------------------------------------------------------------
27
28 bin_SCRIPTS = \
29 src/scripts/ipfire.org \
30 src/scripts/ipfire.org-webapp
31
32 EXTRA_DIST += \
33 src/scripts/ipfire.org.in \
34 src/scripts/ipfire.org-webapp.in
35
36 CLEANFILES += \
37 src/scripts/ipfire.org \
38 src/scripts/ipfire.org-webapp
39
40 configs_DATA = \
41 ipfire.org.conf.sample
42
43 EXTRA_DIST += \
44 ipfire.org.conf.sample.in
45
46 CLEANFILES += \
47 ipfire.org.conf.sample
48
49 backend_PYTHON = \
50 src/backend/__init__.py \
51 src/backend/accounts.py \
52 src/backend/ads.py \
53 src/backend/base.py \
54 src/backend/countries.py \
55 src/backend/database.py \
56 src/backend/fireinfo.py \
57 src/backend/geoip.py \
58 src/backend/iuse.py \
59 src/backend/memcached.py \
60 src/backend/mirrors.py \
61 src/backend/misc.py \
62 src/backend/netboot.py \
63 src/backend/news.py \
64 src/backend/nopaste.py \
65 src/backend/planet.py \
66 src/backend/releases.py \
67 src/backend/settings.py \
68 src/backend/talk.py \
69 src/backend/tracker.py \
70 src/backend/util.py \
71 src/backend/zeiterfassung.py
72
73 backenddir = $(pythondir)/ipfire
74
75 # ------------------------------------------------------------------------------
76
77 web_PYTHON = \
78 src/web/__init__.py \
79 src/web/handlers.py \
80 src/web/handlers_accounts.py \
81 src/web/handlers_admin.py \
82 src/web/handlers_base.py \
83 src/web/handlers_boot.py \
84 src/web/handlers_download.py \
85 src/web/handlers_fireinfo.py \
86 src/web/handlers_iuse.py \
87 src/web/handlers_mirrors.py \
88 src/web/handlers_news.py \
89 src/web/handlers_nopaste.py \
90 src/web/handlers_planet.py \
91 src/web/handlers_rss.py \
92 src/web/handlers_talk.py \
93 src/web/ui_modules.py
94
95 webdir = $(backenddir)/web
96
97 # ------------------------------------------------------------------------------
98
99 # TODO install the base for now and add all other templates later
100
101 templates_DATA = \
102 src/templates/base.html \
103 src/templates/base-1.html \
104 src/templates/error.html \
105 src/templates/error-404.html \
106 src/templates/error-500.html \
107 src/templates/index.html
108
109 templatesdir = $(datadir)/templates
110
111 templates_modules_DATA = \
112 src/templates/modules/menu.html
113
114 templates_modulesdir = $(templatesdir)/modules
115
116 templates_static_DATA = \
117 src/templates/static/artwork.html \
118 src/templates/static/chat.html \
119 src/templates/static/features.html \
120 src/templates/static/get-involved.html \
121 src/templates/static/get-started.html \
122 src/templates/static/get-support.html \
123 src/templates/static/hardware.html \
124 src/templates/static/legal.html
125
126 templates_staticdir = $(templatesdir)/static
127
128 # ------------------------------------------------------------------------------
129
130 SCSS_FILES = \
131 src/scss/style.scss \
132 src/scss/_donation.scss \
133 src/scss/_icons.scss \
134 src/scss/_variables.scss
135
136 EXTRA_DIST += \
137 src/templates/messages/main.scss
138
139 CLEANFILES += \
140 src/templates/messages/main.css
141
142 static_DATA = \
143 src/scss/main.css
144
145 CLEANFILES += \
146 src/scss/main.css
147
148 EXTRA_DIST += \
149 $(SCSS_FILES)
150
151 staticdir = $(datadir)/static
152
153 static_fonts_DATA = \
154 # TODO
155
156 static_fontsdir = $(staticdir)/fonts
157
158 static_images_DATA = \
159 src/static/img/appliance-pro.png \
160 src/static/img/header-background.jpg \
161 src/static/img/ipfire-tux.png
162
163 static_imagesdir = $(staticdir)/img
164
165 static_images_screenshots_DATA = \
166 src/static/img/screenshots/firewall-connections.png \
167 src/static/img/screenshots/firewall-host-groups.png \
168 src/static/img/screenshots/firewall-new-rule.png \
169 src/static/img/screenshots/firewall-rules.png \
170 src/static/img/screenshots/firewall-service-groups.png \
171 src/static/img/screenshots/pakfire-addon-services-1.png \
172 src/static/img/screenshots/pakfire-overview-1.png
173
174 static_images_screenshotsdir = $(static_imagesdir)/screenshots
175
176 static_js_DATA = \
177 src/bootstrap/dist/js/bootstrap.min.js \
178 src/bootstrap/dist/js/bootstrap.min.js.map \
179 \
180 src/static/js/jquery-3.3.1.min.js \
181 src/static/js/popper.min.js \
182 src/static/js/site.js
183
184 static_jsdir = $(staticdir)/js
185
186 # ------------------------------------------------------------------------------
187
188 dist_cron_DATA = \
189 src/crontab/ipfire.org
190
191 # ------------------------------------------------------------------------------
192
193 if HAVE_SYSTEMD
194 systemdsystemunit_DATA = \
195 src/systemd/ipfire.org-webapp-1.service \
196 src/systemd/ipfire.org-webapp-2.service \
197 src/systemd/ipfire.org-webapp-3.service \
198 src/systemd/ipfire.org-webapp-4.service
199
200 CLEANFILES += \
201 $(systemdsystemunit_DATA)
202
203 INSTALL_DIRS += \
204 $(systemdsystemunitdir)
205 endif
206
207 EXTRA_DIST += \
208 src/systemd/ipfire.org-webapp-1.service.in \
209 src/systemd/ipfire.org-webapp-3.service.in \
210 src/systemd/ipfire.org-webapp-3.service.in \
211 src/systemd/ipfire.org-webapp-4.service.in
212
213 # ------------------------------------------------------------------------------
214
215 substitutions = \
216 '|PACKAGE_NAME=$(PACKAGE_NAME)|' \
217 '|PACKAGE_VERSION=$(PACKAGE_VERSION)|' \
218 '|configsdir=$(configsdir)|' \
219 '|bindir=$(bindir)|' \
220 '|datadir=$(datadir)|'
221
222 SED_PROCESS = \
223 $(AM_V_GEN)$(MKDIR_P) $(dir $@) && \
224 $(SED) $(subst '|,-e 's|@,$(subst =,\@|,$(subst |',|g',$(substitutions)))) \
225 < $< > $@
226
227 %: %.in Makefile
228 $(SED_PROCESS)
229
230 %.css: %.scss Makefile
231 $(AM_V_GEN)$(MKDIR_P) $(dir $@) && \
232 $(SASSC) --style compressed $< > $@
233
234 src/scss/main.css: $(SCSS_FILES) Makefile
235 $(AM_V_GEN)$(MKDIR_P) $(dir $@) && \
236 $(SASSC) --style compressed $< > $@