From: Mike Frysinger <vapier@gentoo.org>
To: qemu-devel@nongnu.org
Subject: [Qemu-devel] [PATCH v2] allow make {dist, }clean work w/out configure
Date: Sun, 16 Sep 2012 16:07:13 -0400 [thread overview]
Message-ID: <1347826033-4330-1-git-send-email-vapier@gentoo.org> (raw)
In-Reply-To: <5055A16F.4040303@redhat.com>
There's no reason to require configure to run before running a clean
target, so check MAKECMDGOALS before.
Signed-off-by: Mike Frysinger <vapier@gentoo.org>
---
v2
- handle edge cases
Makefile | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/Makefile b/Makefile
index 1cd5bc8..0a37369 100644
--- a/Makefile
+++ b/Makefile
@@ -14,9 +14,11 @@ config-host.mak: $(SRC_PATH)/configure
@sed -n "/.*Configured with/s/[^:]*: //p" $@ | sh
else
config-host.mak:
+ifneq ($(filter-out %clean,$(MAKECMDGOALS)),$(if $(MAKECMDGOALS),,fail))
@echo "Please call configure before running make!"
@exit 1
endif
+endif
GENERATED_HEADERS = config-host.h trace.h qemu-options.def
ifeq ($(TRACE_BACKEND),dtrace)
@@ -398,7 +400,9 @@ qemu-doc.dvi qemu-doc.html qemu-doc.info qemu-doc.pdf: \
# Add a dependency on the generated files, so that they are always
# rebuilt before other object files
+ifneq ($(filter-out %clean,$(MAKECMDGOALS)),$(if $(MAKECMDGOALS),,fail))
Makefile: $(GENERATED_HEADERS)
+endif
# Include automatically generated dependency files
# Dependencies in Makefile.objs files come from our recursive subdir rules
--
1.7.9.7
next prev parent reply other threads:[~2012-09-16 20:07 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-09-16 0:30 [Qemu-devel] [PATCH] allow make {dist,}clean work w/out configure Mike Frysinger
2012-09-16 9:52 ` [Qemu-devel] [PATCH] allow make {dist, }clean " Paolo Bonzini
2012-09-16 20:03 ` Mike Frysinger
2012-09-17 7:55 ` Paolo Bonzini
2012-09-16 20:07 ` Mike Frysinger [this message]
2012-09-17 8:46 ` [Qemu-devel] [PATCH v2] " Paolo Bonzini
2012-10-19 19:32 ` Aurelien Jarno
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1347826033-4330-1-git-send-email-vapier@gentoo.org \
--to=vapier@gentoo.org \
--cc=qemu-devel@nongnu.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).