{"thread":{"id":"43208","subject":"Re: [PATCH 1/2] move Git.pm build instructions into perl/Makefile","startedAt":"2006-11-21T22:59:11Z","lastAt":"2006-12-04T13:52:15Z","messageCount":6,"participants":["Junio C Hamano","Alex Riesen"],"isPatch":true,"patchVersion":1,"patchTotal":2},"messages":[{"id":"294907","messageId":"20061121225911.GA24201@steel.home","threadId":"43208","inReplyTo":null,"subject":"[PATCH] move Git.pm build instructions into perl/Makefile","fromName":"Alex Riesen","fromEmail":"fork0@t-online.de","sentAt":"2006-11-21T22:59:11Z","receivedAt":"2006-11-21T22:59:11Z","isPatch":true,"sender":{"key":"raa.lkml@gmail.com","avatar":"https://avatars.githubusercontent.com/u/324101?v=4"},"body":"Signed-off-by: Alex Riesen <raa.lkml@gmail.com>\n---\n\n...so that I can disable MakeMaker stuff as soon as I get to work,\nwhich is the only windows+cygwin+activestate system available to me.\nAlas, it is also the system where I use git most.\nThe MakeMaker killing patch should follow.\n\n Makefile        |   19 +++++++++----------\n perl/.gitignore |    3 ++-\n perl/Makefile   |   23 +++++++++++++++++++++++\n 3 files changed, 34 insertions(+), 11 deletions(-)\n\ndiff --git a/Makefile b/Makefile\nindex 36ce8cd..c849227 100644\n--- a/Makefile\n+++ b/Makefile\n@@ -592,8 +592,8 @@ export prefix TAR INSTALL DESTDIR SHELL_\n \n all: $(ALL_PROGRAMS) $(BUILT_INS) git$X gitk gitweb/gitweb.cgi\n \n-all: perl/Makefile\n-\t$(MAKE) -C perl\n+all:\n+\t$(MAKE) -C perl PERL_PATH='$(PERL_PATH_SQ)' prefix='$(prefix_SQ)' all\n \t$(MAKE) -C templates\n \n strip: $(PROGRAMS) git$X\n@@ -627,7 +627,11 @@ $(patsubst %.sh,%,$(SCRIPT_SH)) : % : %.\n \tchmod +x $@+\n \tmv $@+ $@\n \n-$(patsubst %.perl,%,$(SCRIPT_PERL)): perl/Makefile\n+$(patsubst %.perl,%,$(SCRIPT_PERL)): perl/perl.mak\n+\n+perl/perl.mak: GIT-CFLAGS\n+\t$(MAKE) -C perl PERL_PATH='$(PERL_PATH_SQ)' prefix='$(prefix_SQ)' $(@F)\n+\n $(patsubst %.perl,%,$(SCRIPT_PERL)): % : %.perl\n \trm -f $@ $@+\n \tINSTLIBDIR=`$(MAKE) -C perl -s --no-print-directory instlibdir` && \\\n@@ -767,10 +771,6 @@ $(XDIFF_LIB): $(XDIFF_OBJS)\n \trm -f $@ && $(AR) rcs $@ $(XDIFF_OBJS)\n \n \n-perl/Makefile: perl/Git.pm perl/Makefile.PL GIT-CFLAGS\n-\t(cd perl && $(PERL_PATH) Makefile.PL \\\n-\t\tPREFIX='$(prefix_SQ)')\n-\n doc:\n \t$(MAKE) -C Documentation all\n \n@@ -833,7 +833,7 @@ install: all\n \t$(INSTALL) $(ALL_PROGRAMS) '$(DESTDIR_SQ)$(gitexecdir_SQ)'\n \t$(INSTALL) git$X gitk '$(DESTDIR_SQ)$(bindir_SQ)'\n \t$(MAKE) -C templates DESTDIR='$(DESTDIR_SQ)' install\n-\t$(MAKE) -C perl install\n+\t$(MAKE) -C perl prefix='$(prefix_SQ)' install\n \t$(INSTALL) -d -m755 '$(DESTDIR_SQ)$(GIT_PYTHON_DIR_SQ)'\n \t$(INSTALL) $(PYMODULES) '$(DESTDIR_SQ)$(GIT_PYTHON_DIR_SQ)'\n \tif test 'z$(bindir_SQ)' != 'z$(gitexecdir_SQ)'; \\\n@@ -905,8 +905,7 @@ clean:\n \trm -f $(htmldocs).tar.gz $(manpages).tar.gz\n \trm -f gitweb/gitweb.cgi\n \t$(MAKE) -C Documentation/ clean\n-\t[ ! -f perl/Makefile ] || $(MAKE) -C perl/ clean || $(MAKE) -C perl/ clean\n-\trm -f perl/ppport.h perl/Makefile.old\n+\t$(MAKE) -C perl clean\n \t$(MAKE) -C templates/ clean\n \t$(MAKE) -C t/ clean\n \trm -f GIT-VERSION-FILE GIT-CFLAGS\ndiff --git a/perl/.gitignore b/perl/.gitignore\nindex e990cae..98b2477 100644\n--- a/perl/.gitignore\n+++ b/perl/.gitignore\n@@ -1,4 +1,5 @@\n-Makefile\n+perl.mak\n+perl.mak.old\n blib\n blibdirs\n pm_to_blib\ndiff --git a/perl/Makefile b/perl/Makefile\nnew file mode 100644\nindex 0000000..cff24dd\n--- /dev/null\n+++ b/perl/Makefile\n@@ -0,0 +1,23 @@\n+#\n+# Makefile for perl support modules and routine\n+#\n+makfile:=perl.mak\n+\n+PERL_PATH_SQ = $(subst ','\\'',$(PERL_PATH))\n+prefix_SQ = $(subst ','\\'',$(prefix))\n+\n+all install instlibdir: $(makfile)\n+\t$(MAKE) -f $(makfile) $@\n+\n+clean:\n+\ttest -f $(makfile) && $(MAKE) -f $(makfile) $@ || exit 0\n+\t$(RM) ppport.h\n+\t$(RM) $(makfile)\n+\n+$(makfile): Makefile.PL ../GIT-CFLAGS\n+\t'$(PERL_PATH_SQ)' $< FIRST_MAKEFILE='$@' PREFIX='$(prefix_SQ)'\n+\n+# this is just added comfort for calling make directly in perl dir\n+# (even though GIT-CFLAGS aren't used yet. If ever)\n+../GIT-CFLAGS:\n+\t$(MAKE) -C .. GIT-CFLAGS\n-- \n"},{"id":"297689","messageId":"81b0412b0611300827h64722fa0i7e32808994a97a51@mail.gmail.com","threadId":"43208","inReplyTo":"20061121225911.GA24201@steel.home","subject":"[PATCH 1/2] move Git.pm build instructions into perl/Makefile","fromName":"Alex Riesen","fromEmail":"raa.lkml@gmail.com","sentAt":"2006-11-30T16:27:34Z","receivedAt":"2006-11-30T16:27:34Z","isPatch":true,"sender":{"key":"raa.lkml@gmail.com","avatar":"https://avatars.githubusercontent.com/u/324101?v=4"},"body":"Signed-off-by: Alex Riesen <raa.lkml@gmail.com>\n\n---\n\nThis is the first patch, just rebased upon current master.\nThe ActiveState-related parts follow\n\n\nFrom 95483f27aa0aede7d19b643f321994001ab1f065 Mon Sep 17 00:00:00 2001\nFrom: Alex Riesen <raa.lkml@gmail.com>\nDate: Tue, 21 Nov 2006 23:59:11 +0100\nSubject: [PATCH] move Git.pm build instructions into perl/Makefile\n\nSigned-off-by: Alex Riesen <raa.lkml@gmail.com>\n---\n Makefile        |   15 +++++++++------\n perl/.gitignore |    3 ++-\n perl/Makefile   |   23 +++++++++++++++++++++++\n 3 files changed, 34 insertions(+), 7 deletions(-)\n\ndiff --git a/Makefile b/Makefile\nindex de3e9f3..5903a6f 100644\n--- a/Makefile\n+++ b/Makefile\n@@ -568,8 +568,8 @@ export prefix TAR INSTALL DESTDIR SHELL_PATH template_dir\n \n all: $(ALL_PROGRAMS) $(BUILT_INS) git$X gitk gitweb/gitweb.cgi\n \n-all: perl/Makefile\n-\t$(MAKE) -C perl\n+all:\n+\t$(MAKE) -C perl PERL_PATH='$(PERL_PATH_SQ)' prefix='$(prefix_SQ)' all\n \t$(MAKE) -C templates\n \n strip: $(PROGRAMS) git$X\n@@ -602,7 +602,11 @@ $(patsubst %.sh,%,$(SCRIPT_SH)) : % : %.sh\n \tchmod +x $@+\n \tmv $@+ $@\n \n-$(patsubst %.perl,%,$(SCRIPT_PERL)): perl/Makefile\n+$(patsubst %.perl,%,$(SCRIPT_PERL)): perl/perl.mak\n+\n+perl/perl.mak: GIT-CFLAGS\n+\t$(MAKE) -C perl PERL_PATH='$(PERL_PATH_SQ)' prefix='$(prefix_SQ)' $(@F)\n+\n $(patsubst %.perl,%,$(SCRIPT_PERL)): % : %.perl\n \trm -f $@ $@+\n \tINSTLIBDIR=`$(MAKE) -C perl -s --no-print-directory instlibdir` && \\\n@@ -796,7 +800,7 @@ install: all\n \t$(INSTALL) $(ALL_PROGRAMS) '$(DESTDIR_SQ)$(gitexecdir_SQ)'\n \t$(INSTALL) git$X gitk '$(DESTDIR_SQ)$(bindir_SQ)'\n \t$(MAKE) -C templates DESTDIR='$(DESTDIR_SQ)' install\n-\t$(MAKE) -C perl install\n+\t$(MAKE) -C perl prefix='$(prefix_SQ)' install\n \tif test 'z$(bindir_SQ)' != 'z$(gitexecdir_SQ)'; \\\n \tthen \\\n \t\tln -f '$(DESTDIR_SQ)$(bindir_SQ)/git$X' \\\n@@ -866,8 +870,7 @@ clean:\n \trm -f $(htmldocs).tar.gz $(manpages).tar.gz\n \trm -f gitweb/gitweb.cgi\n \t$(MAKE) -C Documentation/ clean\n-\t[ ! -f perl/Makefile ] || $(MAKE) -C perl/ clean || $(MAKE) -C perl/ clean\n-\trm -f perl/ppport.h perl/Makefile.old\n+\t$(MAKE) -C perl clean\n \t$(MAKE) -C templates/ clean\n \t$(MAKE) -C t/ clean\n \trm -f GIT-VERSION-FILE GIT-CFLAGS\ndiff --git a/perl/.gitignore b/perl/.gitignore\nindex e990cae..98b2477 100644\n--- a/perl/.gitignore\n+++ b/perl/.gitignore\n@@ -1,4 +1,5 @@\n-Makefile\n+perl.mak\n+perl.mak.old\n blib\n blibdirs\n pm_to_blib\ndiff --git a/perl/Makefile b/perl/Makefile\nnew file mode 100644\nindex 0000000..cff24dd\n--- /dev/null\n+++ b/perl/Makefile\n@@ -0,0 +1,23 @@\n+#\n+# Makefile for perl support modules and routine\n+#\n+makfile:=perl.mak\n+\n+PERL_PATH_SQ = $(subst ','\\'',$(PERL_PATH))\n+prefix_SQ = $(subst ','\\'',$(prefix))\n+\n+all install instlibdir: $(makfile)\n+\t$(MAKE) -f $(makfile) $@\n+\n+clean:\n+\ttest -f $(makfile) && $(MAKE) -f $(makfile) $@ || exit 0\n+\t$(RM) ppport.h\n+\t$(RM) $(makfile)\n+\n+$(makfile): Makefile.PL ../GIT-CFLAGS\n+\t'$(PERL_PATH_SQ)' $< FIRST_MAKEFILE='$@' PREFIX='$(prefix_SQ)'\n+\n+# this is just added comfort for calling make directly in perl dir\n+# (even though GIT-CFLAGS aren't used yet. If ever)\n+../GIT-CFLAGS:\n+\t$(MAKE) -C .. GIT-CFLAGS\n-- \n1.4.4.1.g3924-dirty\n\n"},{"id":"294033","messageId":"7vvektyi7n.fsf@assigned-by-dhcp.cox.net","threadId":"43208","inReplyTo":"81b0412b0611300827h64722fa0i7e32808994a97a51@mail.gmail.com","subject":"Re: [PATCH 1/2] move Git.pm build instructions into perl/Makefile","fromName":"Junio C Hamano","fromEmail":"junkio@cox.net","sentAt":"2006-12-02T23:46:20Z","receivedAt":"2006-12-02T23:46:20Z","isPatch":true,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"\"Alex Riesen\" <raa.lkml@gmail.com> writes:\n\n> Signed-off-by: Alex Riesen <raa.lkml@gmail.com>\n>\n> ---\n>\n> This is the first patch, just rebased upon current master.\n> The ActiveState-related parts follow\n\nHuh?\n\nAh, attachment that is not inline.\n\ndiff --git a/perl/.gitignore b/perl/.gitignore\nindex e990cae..98b2477 100644\n--- a/perl/.gitignore\n+++ b/perl/.gitignore\n@@ -1,4 +1,5 @@\n-Makefile\n+perl.mak\n+perl.mak.old\n blib\n blibdirs\n pm_to_blib\n\nThis, and perl/Makefile not cleaning perl.mak.old, are wrong.\n\"make && make clean\" after a fresh checkout should leave the\nworking tree the same state is it were.\n"},{"id":"298054","messageId":"81b0412b0612040156w794a276cqaa37f1734ba7a1ca@mail.gmail.com","threadId":"43208","inReplyTo":"7vvektyi7n.fsf@assigned-by-dhcp.cox.net","subject":"Re: [PATCH 1/2] move Git.pm build instructions into perl/Makefile","fromName":"Alex Riesen","fromEmail":"raa.lkml@gmail.com","sentAt":"2006-12-04T09:56:49Z","receivedAt":"2006-12-04T09:56:49Z","isPatch":true,"sender":{"key":"raa.lkml@gmail.com","avatar":"https://avatars.githubusercontent.com/u/324101?v=4"},"body":"On 12/3/06, Junio C Hamano <junkio@cox.net> wrote:\n> > This is the first patch, just rebased upon current master.\n> > The ActiveState-related parts follow\n>\n> diff --git a/perl/.gitignore b/perl/.gitignore\n> index e990cae..98b2477 100644\n> --- a/perl/.gitignore\n> +++ b/perl/.gitignore\n> @@ -1,4 +1,5 @@\n> -Makefile\n> +perl.mak\n> +perl.mak.old\n>  blib\n>  blibdirs\n>  pm_to_blib\n>\n> This, and perl/Makefile not cleaning perl.mak.old, are wrong.\n\nHow is this wrong, and the previous (for when there weren't\nMakefile at all) Makefile-in-.gitignore is not?\nThese are generated files, what do you want to preserve them for?\n\n> \"make && make clean\" after a fresh checkout should leave the\n> working tree the same state is it were.\n\noh, right. Missed it (never seen it generated, BTW. Just took\nfrom Pasky's code that it happens).\n\nUpdated patch attached.\n\n\nAuthor: Alex Riesen <raa.lkml@gmail.com>\nDate: Mon Dec 4 10:50:04 2006 +0100\nSubject: Move Git.pm build instructions into perl/Makefile\n\nSigned-off-by: Alex Riesen <raa.lkml@gmail.com>\n\ndiff --git a/Makefile b/Makefile\nindex de3e9f3..3e6825b 100644\n--- a/Makefile\n+++ b/Makefile\n@@ -539,6 +539,9 @@ endif\n ifdef NO_ACCURATE_DIFF\n \tBASIC_CFLAGS += -DNO_ACCURATE_DIFF\n endif\n+ifdef NO_PERL_MAKEMAKER\n+\texport NO_PERL_MAKEMAKER\n+endif\n \n # Shell quote (do not use $(call) to accommodate ancient setups);\n \n@@ -568,8 +571,8 @@ export prefix TAR INSTALL DESTDIR SHELL_PATH template_dir\n \n all: $(ALL_PROGRAMS) $(BUILT_INS) git$X gitk gitweb/gitweb.cgi\n \n-all: perl/Makefile\n-\t$(MAKE) -C perl\n+all:\n+\t$(MAKE) -C perl PERL_PATH='$(PERL_PATH_SQ)' prefix='$(prefix_SQ)' all\n \t$(MAKE) -C templates\n \n strip: $(PROGRAMS) git$X\n@@ -602,7 +605,11 @@ $(patsubst %.sh,%,$(SCRIPT_SH)) : % : %.sh\n \tchmod +x $@+\n \tmv $@+ $@\n \n-$(patsubst %.perl,%,$(SCRIPT_PERL)): perl/Makefile\n+$(patsubst %.perl,%,$(SCRIPT_PERL)): perl/perl.mak\n+\n+perl/perl.mak: GIT-CFLAGS\n+\t$(MAKE) -C perl PERL_PATH='$(PERL_PATH_SQ)' prefix='$(prefix_SQ)' $(@F)\n+\n $(patsubst %.perl,%,$(SCRIPT_PERL)): % : %.perl\n \trm -f $@ $@+\n \tINSTLIBDIR=`$(MAKE) -C perl -s --no-print-directory instlibdir` && \\\n@@ -796,7 +803,7 @@ install: all\n \t$(INSTALL) $(ALL_PROGRAMS) '$(DESTDIR_SQ)$(gitexecdir_SQ)'\n \t$(INSTALL) git$X gitk '$(DESTDIR_SQ)$(bindir_SQ)'\n \t$(MAKE) -C templates DESTDIR='$(DESTDIR_SQ)' install\n-\t$(MAKE) -C perl install\n+\t$(MAKE) -C perl prefix='$(prefix_SQ)' install\n \tif test 'z$(bindir_SQ)' != 'z$(gitexecdir_SQ)'; \\\n \tthen \\\n \t\tln -f '$(DESTDIR_SQ)$(bindir_SQ)/git$X' \\\n@@ -866,8 +873,7 @@ clean:\n \trm -f $(htmldocs).tar.gz $(manpages).tar.gz\n \trm -f gitweb/gitweb.cgi\n \t$(MAKE) -C Documentation/ clean\n-\t[ ! -f perl/Makefile ] || $(MAKE) -C perl/ clean || $(MAKE) -C perl/ clean\n-\trm -f perl/ppport.h perl/Makefile.old\n+\t$(MAKE) -C perl clean\n \t$(MAKE) -C templates/ clean\n \t$(MAKE) -C t/ clean\n \trm -f GIT-VERSION-FILE GIT-CFLAGS\ndiff --git a/perl/.gitignore b/perl/.gitignore\nindex e990cae..98b2477 100644\n--- a/perl/.gitignore\n+++ b/perl/.gitignore\n@@ -1,4 +1,5 @@\n-Makefile\n+perl.mak\n+perl.mak.old\n blib\n blibdirs\n pm_to_blib\ndiff --git a/perl/Makefile b/perl/Makefile\nnew file mode 100644\nindex 0000000..bd483b0\n--- /dev/null\n+++ b/perl/Makefile\n@@ -0,0 +1,39 @@\n+#\n+# Makefile for perl support modules and routine\n+#\n+makfile:=perl.mak\n+\n+PERL_PATH_SQ = $(subst ','\\'',$(PERL_PATH))\n+prefix_SQ = $(subst ','\\'',$(prefix))\n+\n+all install instlibdir: $(makfile)\n+\t$(MAKE) -f $(makfile) $@\n+\n+clean:\n+\ttest -f $(makfile) && $(MAKE) -f $(makfile) $@ || exit 0\n+\t$(RM) ppport.h\n+\t$(RM) $(makfile)\n+\t$(RM) $(makfile).old\n+\n+ifdef NO_PERL_MAKEMAKER\n+instdir_SQ = $(subst ','\\'',$(prefix)/lib)\n+$(makfile): ../GIT-CFLAGS Makefile\n+\techo all: > $@\n+\techo '\t:' >> $@\n+\techo install: >> $@\n+\techo '\tmkdir -p $(instdir_SQ)' >> $@\n+\techo '\t$(RM) $(instdir_SQ)/Git.pm; cp Git.pm $(instdir_SQ)' >> $@\n+\techo '\t$(RM) $(instdir_SQ)/Error.pm; \\\n+\tcp private-Error.pm $(instdir_SQ)/Error.pm' >> $@\n+\techo instlibdir: >> $@\n+\techo '\techo $(instdir_SQ)' >> $@\n+else\n+$(makfile): Makefile.PL ../GIT-CFLAGS\n+\t'$(PERL_PATH_SQ)' $< FIRST_MAKEFILE='$@' PREFIX='$(prefix_SQ)'\n+endif\n+\n+# this is just added comfort for calling make directly in perl dir\n+# (even though GIT-CFLAGS aren't used yet. If ever)\n+../GIT-CFLAGS:\n+\t$(MAKE) -C .. GIT-CFLAGS\n+\n"},{"id":"294982","messageId":"7v64csq7e9.fsf@assigned-by-dhcp.cox.net","threadId":"43208","inReplyTo":"81b0412b0612040156w794a276cqaa37f1734ba7a1ca@mail.gmail.com","subject":"Re: [PATCH 1/2] move Git.pm build instructions into perl/Makefile","fromName":"Junio C Hamano","fromEmail":"junkio@cox.net","sentAt":"2006-12-04T10:31:42Z","receivedAt":"2006-12-04T10:31:42Z","isPatch":true,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"\"Alex Riesen\" <raa.lkml@gmail.com> writes:\n\n> Updated patch attached.\n\nWill apply, thanks, but with a few tweaks while I had to hand\nmunge your attachment anyway.\n"},{"id":"298762","messageId":"81b0412b0612040552w28755dd6uf168bb43bdc99bae@mail.gmail.com","threadId":"43208","inReplyTo":"7v64csq7e9.fsf@assigned-by-dhcp.cox.net","subject":"Re: [PATCH 1/2] move Git.pm build instructions into perl/Makefile","fromName":"Alex Riesen","fromEmail":"raa.lkml@gmail.com","sentAt":"2006-12-04T13:52:15Z","receivedAt":"2006-12-04T13:52:15Z","isPatch":true,"sender":{"key":"raa.lkml@gmail.com","avatar":"https://avatars.githubusercontent.com/u/324101?v=4"},"body":"On 12/4/06, Junio C Hamano <junkio@cox.net> wrote:\n> \"Alex Riesen\" <raa.lkml@gmail.com> writes:\n>\n> > Updated patch attached.\n>\n> Will apply, thanks, but with a few tweaks while I had to hand\n> munge your attachment anyway.\n\n"}]}