From: Daniel Pfeiffer <occitan@t-online.de>
To: git@vger.kernel.org
Subject: Compiling git with makepp patch
Date: Mon, 23 Aug 2010 00:31:27 +0200 [thread overview]
Message-ID: <4C71A53F.2020108@t-online.de> (raw)
In-Reply-To: <84FD9808A65CDF4C959FDB41FC3D134CBCF306D6@MSSRVS4.atlas.de>
[-- Attachment #1: Type: text/plain, Size: 2089 bytes --]
Hi,
getting ready for the release of makepp version 2.0, I'm testing it for
building various popular open source software.
Git has been giving our promise of Gnu make compatibility a hard time. I have
just checked in a series of small fixes, many which were needed to compile
Git. This includes things like:
* accepting an action-prefix of +
* implementing the cosmetic --no-print-directory directory option, which
in your usage is essential
* smarter MAKEFLAGS handling, because you unset it several times, but we
have more options, some must reach the submake
* allow special variables like $@ outside of rules — this used to be an error
There are however two things which I can hardly hope to fix:
GIT-VERSION-FILE: FORCE
@$(SHELL_PATH) ./GIT-VERSION-GEN
-include GIT-VERSION-FILE
.PHONY: FORCE
I don't know why you depend on a phony that has no rule — I also had to make
that possible. The file needs to be built immediately so that it can be
included, before reading the rest of the makefile. But the dependency is only
known to be phony after running the rule. Here you have a hen-egg problem,
where I have no clue how Gnu make can cope (this is the one case where it
requires .PHONY). Anyway, makepp needs the phony declaration before.
The other thing caused me quite a headache before I understood:
PERL_PATH_SQ = $(subst ','\'',$(PERL_PATH))#'
I suppose you added the comment for Emacs' syntax highlighting, to have an
even number of unescaped quotes. The problem is makepp parses this line just
like Emacs, so it doesn't find the comment, adding in the #' at the point of
use, which completely screws the sed command. (You might want to apply my fix
to a few other makefiles, which have SQ variables, albeit without the syntax
highlighting workaround, so they are only visually defect.)
coralament / best Grötens / liebe Grüße / best regards / elkorajn salutojn
Daniel Pfeiffer
--
lerne / learn / apprends / lär dig / ucz się Esperanto:
http://lernu.net /http://ikurso.net
[-- Attachment #2: git-makepp.patch --]
[-- Type: text/x-diff, Size: 2254 bytes --]
diff -wrup git-2010-08-21/git-gui/Makefile git-2010-08-21a/git-gui/Makefile
--- git-2010-08-21/git-gui/Makefile 2010-08-20 21:55:41.000000000 +0200
+++ git-2010-08-21a/git-gui/Makefile 2010-08-21 20:59:10.272785510 +0200
@@ -7,6 +7,7 @@ all::
# TCL_PATH must be vaild for this to work.
#
+.PHONY: FORCE
GIT-VERSION-FILE: FORCE
@$(SHELL_PATH) ./GIT-VERSION-GEN
-include GIT-VERSION-FILE
@@ -340,4 +341,3 @@ ifdef GITGUI_WINDOWS_WRAPPER
endif
.PHONY: all install uninstall dist-version clean
-.PHONY: FORCE
diff -wrup git-2010-08-21/gitweb/Makefile git-2010-08-21a/gitweb/Makefile
--- git-2010-08-21/gitweb/Makefile 2010-08-20 21:55:41.000000000 +0200
+++ git-2010-08-21a/gitweb/Makefile 2010-08-21 21:09:47.499919056 +0200
@@ -52,12 +52,15 @@ SHELL_PATH ?= $(SHELL)
PERL_PATH ?= /usr/bin/perl
# Shell quote;
-bindir_SQ = $(subst ','\'',$(bindir))#'
-gitwebdir_SQ = $(subst ','\'',$(gitwebdir))#'
-gitwebstaticdir_SQ = $(subst ','\'',$(gitwebdir)/static)#'
-SHELL_PATH_SQ = $(subst ','\'',$(SHELL_PATH))#'
-PERL_PATH_SQ = $(subst ','\'',$(PERL_PATH))#'
-DESTDIR_SQ = $(subst ','\'',$(DESTDIR))#'
+Q='
+# ' This comment is only to appease IDEs like Emacs.
+# The comment is on a new line, else makepp would see it as a quoted hash.
+bindir_SQ = $(subst $Q,'\'',$(bindir))
+gitwebdir_SQ = $(subst $Q,'\'',$(gitwebdir))
+gitwebstaticdir_SQ = $(subst $Q,'\'',$(gitwebdir)/static)
+SHELL_PATH_SQ = $(subst $Q,'\'',$(SHELL_PATH))
+PERL_PATH_SQ = $(subst $Q,'\'',$(PERL_PATH))
+DESTDIR_SQ = $(subst $Q,'\'',$(DESTDIR))
# Quiet generation (unless V=1)
QUIET_SUBDIR0 = +$(MAKE) -C # space to separate -C and subdir
diff -wrup git-2010-08-21/Makefile git-2010-08-21a/Makefile
--- git-2010-08-21/Makefile 2010-08-20 21:55:41.000000000 +0200
+++ git-2010-08-21a/Makefile 2010-08-21 21:02:07.676932693 +0200
@@ -236,6 +236,7 @@ all::
#
# Define NATIVE_CRLF if your platform uses CRLF for line endings.
+.PHONY: FORCE
GIT-VERSION-FILE: FORCE
@$(SHELL_PATH) ./GIT-VERSION-GEN
-include GIT-VERSION-FILE
@@ -2217,7 +2218,7 @@ endif
.PHONY: all install clean strip
.PHONY: shell_compatibility_test please_set_SHELL_PATH_to_a_more_modern_shell
-.PHONY: FORCE TAGS tags cscope
+.PHONY: TAGS tags cscope
### Check documentation
#
next parent reply other threads:[~2010-08-22 22:31 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <84FD9808A65CDF4C959FDB41FC3D134CBCF306D6@MSSRVS4.atlas.de>
2010-08-22 22:31 ` Daniel Pfeiffer [this message]
2010-08-23 7:47 ` Compiling git with makepp patch Thomas Rast
2010-08-23 9:00 ` Jakub Narebski
2010-08-25 21:08 ` Daniel Pfeiffer
2010-08-23 20:27 ` Ævar Arnfjörð Bjarmason
2010-08-25 20:58 ` Daniel Pfeiffer
2010-08-24 4:32 ` Jonathan Nieder
2010-08-25 20:41 ` Daniel Pfeiffer
2010-08-25 21:56 ` Andreas Schwab
2010-08-25 22:53 ` Junio C Hamano
2010-08-26 0:20 ` Jonathan Nieder
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=4C71A53F.2020108@t-online.de \
--to=occitan@t-online.de \
--cc=git@vger.kernel.org \
--cc=occitan@esperanto.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.