8 iconslayoutsdir = $(pkgdatadir)/icons/layouts
9 dist_iconslayouts_DATA =
13 LAYOUTS += layouts/tile.c
14 LAYOUTS += layouts/tile.h
16 LAYOUTS += layouts/floating.c
17 LAYOUTS += layouts/floating.h
19 LAYOUTS += layouts/max.c
20 LAYOUTS += layouts/max.h
22 LAYOUTS += layouts/fibonacci.c
23 LAYOUTS += layouts/fibonacci.h
27 WIDGETS += widgets/taglist.c
28 WIDGETS += widgets/layoutinfo.c
29 WIDGETS += widgets/textbox.c
30 WIDGETS += widgets/iconbox.c
31 WIDGETS += widgets/focusicon.c
32 WIDGETS += widgets/progressbar.c
33 WIDGETS += widgets/tasklist.c
34 WIDGETS += widgets/graph.c
49 EXTRA_DIST += awesomerc.in
50 CLEANFILES += awesomerc
51 BUILT_SOURCES += awesomerc
53 awesomerc: $(srcdir)/awesomerc.in
54 $(SED) -e "s|[@]iconslayoutsdir@|$(iconslayoutsdir)|" \
55 < $(srcdir)/awesomerc.in > awesomerc
58 CLEANFILES += defconfig.h
59 BUILT_SOURCES += defconfig.h
60 defconfig.h: awesomerc
61 @echo "generating defconfig.h from awesomerc"
62 @echo "static const char *AWESOME_DEFAULT_CONFIG = " > defconfig.h
63 @echo -n "\"" >> defconfig.h
64 @$(SED) 's,\\,\\\\,g;s/$$/\\n\\/;s/"/\\"/g' "awesomerc" >> defconfig.h
65 @echo "\";" >> defconfig.h
67 CLEANFILES += uicbgen.h
68 BUILT_SOURCES += uicbgen.h
69 EXTRA_DIST += build-utils/uicbgen.sh
70 uicbgen.h: $(awesome_SOURCES)
71 @echo "generating uicbgen.h from headers file"
72 $(top_srcdir)/build-utils/uicbgen.sh "$(top_srcdir)" > uicbgen.h
74 CLEANFILES += layoutgen.h
75 BUILT_SOURCES += layoutgen.h
76 EXTRA_DIST += build-utils/layoutgen.sh
77 layoutgen.h: $(awesome_SOURCES)
78 @echo "generating layoutgen.h from layouts headers file"
79 $(top_srcdir)/build-utils/layoutgen.sh "$(top_srcdir)" > layoutgen.h
81 CLEANFILES += widgetgen.h
82 BUILT_SOURCES += widgetgen.h
83 EXTRA_DIST += build-utils/widgetgen.sh
85 @echo "generating widgetgen.h from widget.h"
86 $(top_srcdir)/build-utils/widgetgen.sh "$(top_srcdir)" > widgetgen.h
88 A_V = awesome-version-internal
89 CLEANFILES += $(A_V).h
90 BUILT_SOURCES += $(A_V).h.stamp
92 @current_ver=`$(SHELL) $(top_srcdir)/build-utils/package-version $(top_srcdir) version-stamp`; \
93 { echo '#ifndef AWESOME_VERSION_INTERNAL'; \
94 echo "#define AWESOME_VERSION_INTERNAL \"$${current_ver}\""; \
95 echo "#endif"; } > "$(A_V).h.new"
96 @if test -f "$(A_V).h" \
97 && cmp "$(A_V).h.new" "$(A_V).h"; then :; \
98 else cat "$(A_V).h.new" > "$(A_V).h"; fi; \
102 # If you are using gcc, and want to deactivate this default set of
103 # compile flags, run make with AWESOME_CFLAGS="".
104 AWESOME_CFLAGS = -std=gnu99 -pipe \
106 -Wundef -Wshadow -Wcast-align -Wwrite-strings -Wsign-compare \
107 -Wunused -Winit-self -Wpointer-arith -Wredundant-decls \
108 -Wmissing-prototypes -Wmissing-format-attribute -Wmissing-noreturn
110 AM_CPPFLAGS = $(XFT_CFLAGS) $(X_CFLAGS) $(CAIRO_CFLAGS) $(CONFUSE_CFLAGS) $(XRANDR_CFLAGS) $(XINERAMA_CFLAGS) $(AWESOME_CFLAGS)
112 bin_PROGRAMS += awesome
114 common/socket.c common/socket.h \
115 common/swindow.c common/swindow.h \
116 common/version.c common/version.h \
117 common/util.c common/util.h \
118 common/xutil.c common/xutil.h \
119 common/configopts.h common/configopts.c \
120 common/xscreen.h common/xscreen.c \
124 placement.c placement.h \
126 common/draw.c common/draw.h \
129 awesome.c awesome.h \
133 statusbar.c statusbar.h \
140 awesome_SOURCES += $(LAYOUTS)
141 awesome_SOURCES += $(WIDGETS)
142 awesome_LDADD = $(XFT_LIBS) $(X_LIBS) $(CAIRO_LIBS) $(CONFUSE_LIBS) $(XRANDR_LIBS) $(XINERAMA_LIBS)
144 bin_PROGRAMS += awesome-client
145 awesome_client_SOURCES = \
147 common/socket.c common/socket.h \
148 common/version.c common/version.h \
149 common/util.c common/util.h
151 bin_PROGRAMS += awesome-message
152 awesome_message_SOURCES = \
153 common/swindow.c common/swindow.h \
154 common/draw.c common/draw.h \
155 common/util.h common/util.c \
156 common/version.h common/version.c \
157 common/configopts.h common/configopts.c \
158 common/xscreen.h common/xscreen.c \
161 awesome_message_LDADD = $(XFT_LIBS) $(X_LIBS) $(CAIRO_LIBS) $(CONFUSE_LIBS) $(XINERAMA_LIBS)
163 bin_PROGRAMS += awesome-menu
164 awesome_menu_SOURCES = \
165 common/swindow.c common/swindow.h \
166 common/draw.c common/draw.h \
167 common/util.h common/util.c \
168 common/version.h common/version.c \
169 common/configopts.h common/configopts.c \
170 common/xutil.h common/xutil.c \
173 awesome_menu_LDADD = $(XFT_LIBS) $(X_LIBS) $(CAIRO_LIBS) $(CONFUSE_LIBS) $(XINERAMA_LIBS)
178 man_MANS += awesome.1
179 man_MANS += awesome-client.1
180 man_MANS += awesome-message.1
181 man_MANS += awesomerc.5
186 EXTRA_DIST += awesome.1.txt
187 EXTRA_DIST += awesome-client.1.txt
188 EXTRA_DIST += awesome-message.1.txt
189 EXTRA_DIST += awesomerc.5.txt
191 dist_iconslayouts_DATA += icons/layouts/dwindle.png
192 dist_iconslayouts_DATA += icons/layouts/dwindlew.png
193 dist_iconslayouts_DATA += icons/layouts/floating.png
194 dist_iconslayouts_DATA += icons/layouts/floatingw.png
195 dist_iconslayouts_DATA += icons/layouts/max.png
196 dist_iconslayouts_DATA += icons/layouts/maxw.png
197 dist_iconslayouts_DATA += icons/layouts/spiral.png
198 dist_iconslayouts_DATA += icons/layouts/spiralw.png
199 dist_iconslayouts_DATA += icons/layouts/tile.png
200 dist_iconslayouts_DATA += icons/layouts/tilebottom.png
201 dist_iconslayouts_DATA += icons/layouts/tilebottomw.png
202 dist_iconslayouts_DATA += icons/layouts/tileleft.png
203 dist_iconslayouts_DATA += icons/layouts/tileleftw.png
204 dist_iconslayouts_DATA += icons/layouts/tiletop.png
205 dist_iconslayouts_DATA += icons/layouts/tiletopw.png
206 dist_iconslayouts_DATA += icons/layouts/tilew.png
209 rm -f awesome*.1 awesome*.1.xml awesome*.5 awesome*.5.xml
211 SUFFIXES += .1.xml .1
212 SUFFIXES += .5.xml .5
220 SUFFIXES += .1.txt .1.xml
221 SUFFIXES += .5.txt .5.xml
224 $(ASCIIDOC) -d manpage -b docbook -o $@ $<
226 $(ASCIIDOC) -d manpage -b docbook -o $@ $<
230 # Check that package version matches git version before creating dist tarballs
231 dist-hook: git-version-check
232 distcheck-hook: git-version-check
234 # Note: We cannot run autogen.sh from here, because we would need some way to
235 # restart the whole dist process from the start and there is none.
236 EXTRA_DIST += build-utils/package-version
238 @git_ver=`$(top_srcdir)/build-utils/package-version $(top_srcdir) version-stamp`; \
239 if test "x$${git_ver}" = "x$(PACKAGE_VERSION)"; then :; else \
240 echo "ERROR: PACKAGE_VERSION and 'git describe' version do not match:"; \
241 echo " current 'git describe' version: $${git_ver}"; \
242 echo " current PACKAGE_VERSION: $(PACKAGE_VERSION)"; \
243 echo "Update PACKAGE_VERSION by running $(top_srcdir)/autogen.sh."; \
247 # Version stamp files can only exist in tarball source trees.
249 # So there is no need to generate them anywhere else or to clean them
252 echo "$(PACKAGE_VERSION)" > "$(distdir)/version-stamp"
254 EXTRA_DIST += awesome.doxygen.in
256 # Workaround for buggy pre-1.5.3 doxygen.
258 # Some pre-1.5.3 versions of doxygen segfault on reading these lines.
259 # Call make with DOXYGEN_SEGFAULT=-segfault as a workaround.
260 CLEANFILES += awesome.doxygen-segfault
261 awesome.doxygen-segfault: awesome.doxygen
262 $(SED) '/^QT_AUTOBRIEF/d; /^EXTRACT_ANON_NSPACES/d; /^HTML_DYNAMIC_SECTIONS/d' \
263 < awesome.doxygen > awesome.doxygen-segfault
266 doc: doc/html/index.html
268 doc/html/index.html: awesome.doxygen$(DOXYGEN_SEGFAULT) $(awesome_SOURCES) $(awesome_client_SOURCES)
269 $(DOXYGEN) awesome.doxygen$(DOXYGEN_SEGFAULT)
273 # Presuming we are running awesome on this screen, and this is screen 0, ...
274 # ...we replace the running awesome instance by a freshly compiled one.
275 restart-uninstalled: awesome awesome-client
276 screen=`echo "$${DISPLAY}" | sed 's/.*:[0-9]\.\([0-9]*\)$$/\1/; s/.*:\([0-9]*\)$$/0/'`; \
277 echo "$${screen}" exec "$${PWD}/awesome" | "$${PWD}/awesome-client"
279 # ...we replace the running awesome instance by the last installed one.
281 screen=`echo "$${DISPLAY}" | sed 's/.*:[0-9]\.\([0-9]*\)$$/\1/; s/.*:\([0-9]*\)$$/0/'`; \
282 echo "$${screen}" exec "$(DESTDIR)$(bindir)/awesome" | "$(DESTDIR)$(bindir)/awesome-client"