diff options
author | Kelvin M. Klann <kmk3.code@protonmail.com> | 2022-06-23 02:51:52 -0300 |
---|---|---|
committer | Kelvin M. Klann <kmk3.code@protonmail.com> | 2022-06-30 05:32:07 -0300 |
commit | 83ae0ed8379e2e00815cbe60e2e512665e48c1ed (patch) | |
tree | 2f7abf48abad397bffcfe6add4d949b3557df95b | |
parent | build: reduce autoconf input files from 32 to 2 (diff) | |
download | firejail-83ae0ed8379e2e00815cbe60e2e512665e48c1ed.tar.gz firejail-83ae0ed8379e2e00815cbe60e2e512665e48c1ed.tar.zst firejail-83ae0ed8379e2e00815cbe60e2e512665e48c1ed.zip |
makefiles: stop failing when config.mk does not exist
This allows running `make clean` and `make distclean` (and possibly
others) without having to run ./configure beforehand.
Note that some packaging-related targets still depend on the existence
of generated files. For example:
* dist: config.mk
* deb: config.sh
Commands used to search and replace:
$ git grep -Elz 'include *([^ ]*/)?config.mk' | xargs -0 -I '{}' \
sh -c "printf '%s\n' \
\"\$(sed -E 's|^include *(([^ ]*/)?config.mk)|-include \1|' '{}')\" >'{}'"
Relates to #5140.
-rw-r--r-- | Makefile | 2 | ||||
-rw-r--r-- | src/bash_completion/Makefile | 2 | ||||
-rw-r--r-- | src/common.mk | 2 | ||||
-rw-r--r-- | src/libpostexecseccomp/Makefile | 2 | ||||
-rw-r--r-- | src/libtrace/Makefile | 2 | ||||
-rw-r--r-- | src/libtracelog/Makefile | 2 | ||||
-rw-r--r-- | src/man/Makefile | 2 | ||||
-rw-r--r-- | src/zsh_completion/Makefile | 2 |
8 files changed, 8 insertions, 8 deletions
@@ -1,4 +1,4 @@ | |||
1 | include config.mk | 1 | -include config.mk |
2 | 2 | ||
3 | ifneq ($(HAVE_MAN),no) | 3 | ifneq ($(HAVE_MAN),no) |
4 | MAN_TARGET = man | 4 | MAN_TARGET = man |
diff --git a/src/bash_completion/Makefile b/src/bash_completion/Makefile index 9157c9225..16c4a31ee 100644 --- a/src/bash_completion/Makefile +++ b/src/bash_completion/Makefile | |||
@@ -2,7 +2,7 @@ | |||
2 | all: firejail.bash_completion | 2 | all: firejail.bash_completion |
3 | 3 | ||
4 | ROOT = ../.. | 4 | ROOT = ../.. |
5 | include $(ROOT)/config.mk | 5 | -include $(ROOT)/config.mk |
6 | 6 | ||
7 | firejail.bash_completion: firejail.bash_completion.in | 7 | firejail.bash_completion: firejail.bash_completion.in |
8 | gawk -f ../man/preproc.awk -- $(MANFLAGS) < $< > $@.tmp | 8 | gawk -f ../man/preproc.awk -- $(MANFLAGS) < $< > $@.tmp |
diff --git a/src/common.mk b/src/common.mk index 2b87c33f0..07b5e373d 100644 --- a/src/common.mk +++ b/src/common.mk | |||
@@ -2,7 +2,7 @@ | |||
2 | # | 2 | # |
3 | # Note: "ROOT" must be defined before including this file. | 3 | # Note: "ROOT" must be defined before including this file. |
4 | 4 | ||
5 | include $(ROOT)/config.mk | 5 | -include $(ROOT)/config.mk |
6 | 6 | ||
7 | H_FILE_LIST = $(sort $(wildcard *.h)) | 7 | H_FILE_LIST = $(sort $(wildcard *.h)) |
8 | C_FILE_LIST = $(sort $(wildcard *.c)) | 8 | C_FILE_LIST = $(sort $(wildcard *.c)) |
diff --git a/src/libpostexecseccomp/Makefile b/src/libpostexecseccomp/Makefile index 2f108d8b9..14e0cdb1d 100644 --- a/src/libpostexecseccomp/Makefile +++ b/src/libpostexecseccomp/Makefile | |||
@@ -1,5 +1,5 @@ | |||
1 | ROOT = ../.. | 1 | ROOT = ../.. |
2 | include $(ROOT)/config.mk | 2 | -include $(ROOT)/config.mk |
3 | 3 | ||
4 | H_FILE_LIST = $(sort $(wildcard *.h)) | 4 | H_FILE_LIST = $(sort $(wildcard *.h)) |
5 | C_FILE_LIST = $(sort $(wildcard *.c)) | 5 | C_FILE_LIST = $(sort $(wildcard *.c)) |
diff --git a/src/libtrace/Makefile b/src/libtrace/Makefile index 11c75136d..46a8f97c2 100644 --- a/src/libtrace/Makefile +++ b/src/libtrace/Makefile | |||
@@ -1,5 +1,5 @@ | |||
1 | ROOT = ../.. | 1 | ROOT = ../.. |
2 | include $(ROOT)/config.mk | 2 | -include $(ROOT)/config.mk |
3 | 3 | ||
4 | H_FILE_LIST = $(sort $(wildcard *.h)) | 4 | H_FILE_LIST = $(sort $(wildcard *.h)) |
5 | C_FILE_LIST = $(sort $(wildcard *.c)) | 5 | C_FILE_LIST = $(sort $(wildcard *.c)) |
diff --git a/src/libtracelog/Makefile b/src/libtracelog/Makefile index d09a8aa1c..1a3ab1ba5 100644 --- a/src/libtracelog/Makefile +++ b/src/libtracelog/Makefile | |||
@@ -1,5 +1,5 @@ | |||
1 | ROOT = ../.. | 1 | ROOT = ../.. |
2 | include $(ROOT)/config.mk | 2 | -include $(ROOT)/config.mk |
3 | 3 | ||
4 | H_FILE_LIST = $(sort $(wildcard *.h)) | 4 | H_FILE_LIST = $(sort $(wildcard *.h)) |
5 | C_FILE_LIST = $(sort $(wildcard *.c)) | 5 | C_FILE_LIST = $(sort $(wildcard *.c)) |
diff --git a/src/man/Makefile b/src/man/Makefile index c83a4b7eb..b786e1ca9 100644 --- a/src/man/Makefile +++ b/src/man/Makefile | |||
@@ -2,7 +2,7 @@ | |||
2 | all: firecfg.man firejail.man firejail-login.man firejail-users.man firejail-profile.man firemon.man jailcheck.man | 2 | all: firecfg.man firejail.man firejail-login.man firejail-users.man firejail-profile.man firemon.man jailcheck.man |
3 | 3 | ||
4 | ROOT = ../.. | 4 | ROOT = ../.. |
5 | include $(ROOT)/config.mk | 5 | -include $(ROOT)/config.mk |
6 | 6 | ||
7 | %.man: %.txt | 7 | %.man: %.txt |
8 | gawk -f ./preproc.awk -- $(MANFLAGS) < $< > $@ | 8 | gawk -f ./preproc.awk -- $(MANFLAGS) < $< > $@ |
diff --git a/src/zsh_completion/Makefile b/src/zsh_completion/Makefile index 303057b0b..bec015049 100644 --- a/src/zsh_completion/Makefile +++ b/src/zsh_completion/Makefile | |||
@@ -2,7 +2,7 @@ | |||
2 | all: _firejail | 2 | all: _firejail |
3 | 3 | ||
4 | ROOT = ../.. | 4 | ROOT = ../.. |
5 | include $(ROOT)/config.mk | 5 | -include $(ROOT)/config.mk |
6 | 6 | ||
7 | _firejail: _firejail.in | 7 | _firejail: _firejail.in |
8 | gawk -f ../man/preproc.awk -- $(MANFLAGS) < $< > $@.tmp | 8 | gawk -f ../man/preproc.awk -- $(MANFLAGS) < $< > $@.tmp |