{"thread":{"id":"39715","subject":"[PATCH 15/17] vcbuild/readme: Improve layout and reference msvc-build script","startedAt":"2015-06-25T00:03:36Z","lastAt":"2015-07-14T22:42:13Z","messageCount":34,"participants":["Philip Oakley","Junio C Hamano","Eric Sunshine","Sebastian Schuberth"],"isPatch":true,"patchVersion":1,"patchTotal":17},"messages":[{"id":"264795","messageId":"1435190633-2208-1-git-send-email-philipoakley@iee.org","threadId":"39715","inReplyTo":null,"subject":"[PATCH 00/17] Make the msvc-build scripts work again","fromName":"Philip Oakley","fromEmail":"philipoakley@iee.org","sentAt":"2015-06-25T00:03:36Z","receivedAt":"2015-06-25T00:03:36Z","isPatch":true,"sender":{"key":"philipoakley@iee.email","avatar":"https://avatars.githubusercontent.com/u/914343?v=4"},"body":"This series fixes the scripts which generated Visual Studio project\nfiles. The scripts had bit rotted over the years as other commits\nchanged the git makefile which it post processed.\n\nThe series doesn't attempt to install the Visual Studio compiled product\nbut allows Windows developers familiar with VS to support the Windows SDK\nport of Git.\n\nThe fixes are presented in a fine grained manner.\n\nA previous patch series were at $gmane/21132 (2014-11-20), $gmane/21207\n(2014-12-26), and on Msysgit list (2015-02-23)\n https://groups.google.com/forum/?hl=en_US?hl%3Den#!topic/msysgit/aiEVBKjRshY\n https://github.com/msysgit/git/pull/318/files\n\nHopefully it's not too late in the cycle for a review of this contrib/compat\nitem.\n\nPhilip Oakley (17):\n  .gitignore: improve MSVC ignore patterns\n  .gitignore: ignore library directories created by MSVC VS2008\n    buildsystem\n  (msvc-build) Vcproj.pm: remove duplicate GUID\n  Makefile: a dry-run can error out if no perl. Document the issue\n  engine.pl: fix error message (lib->link)\n  engine.pl: Avoid complications with perl support\n  engine.pl: Properly accept quoted spaces in filenames\n  engine.pl: Fix i18n -o option in msvc buildsystem generator\n  engine.pl: ignore invalidcontinue.obj which is known to MSVC\n  engine.pl: name the msvc buildsystem's makedry error file\n  engine.pl: delete the captured stderr file if empty\n  engine.pl: add debug line to capture the dry-run\n  engine.pl: provide more debug print statements\n  Vcproj.pm: list git.exe first to be startup project\n  vcbuild/readme: Improve layout and reference msvc-build script\n  msvc-build: add complete Microsoft Visual C compilation script\n  config.mak.uname: add MSVC No_SafeExeceptionHandler option\n\n .gitignore                                |  8 ++-\n Makefile                                  |  3 ++\n compat/vcbuild/README                     | 27 +++++++---\n compat/vcbuild/scripts/msvc-build         | 89 +++++++++++++++++++++++++++++++\n config.mak.uname                          |  9 ++++\n contrib/buildsystems/Generators/Vcproj.pm | 34 ++++++------\n contrib/buildsystems/engine.pl            | 37 ++++++++++---\n 7 files changed, 174 insertions(+), 33 deletions(-)\n create mode 100644 compat/vcbuild/scripts/msvc-build\n mode change 100755 => 100644 contrib/buildsystems/engine.pl\n\n-- \n2.3.1\n\n-- \n-- \n*** Please reply-to-all at all times ***\n*** (do not pretend to know who is subscribed and who is not) ***\n*** Please avoid top-posting. ***\nThe msysGit Wiki is here: https://github.com/msysgit/msysgit/wiki - Github accounts are free.\n\nYou received this message because you are subscribed to the Google\nGroups \"msysGit\" group.\nTo post to this group, send email to msysgit@googlegroups.com\nTo unsubscribe from this group, send email to\nmsysgit+unsubscribe@googlegroups.com\nFor more options, and view previous threads, visit this group at\nhttp://groups.google.com/group/msysgit?hl=en_US?hl=en\n\n--- \nYou received this message because you are subscribed to the Google Groups \"Git for Windows\" group.\nTo unsubscribe from this group and stop receiving emails from it, send an email to msysgit+unsubscribe@googlegroups.com.\nFor more options, visit https://groups.google.com/d/optout.\n"},{"id":"264791","messageId":"1435190633-2208-2-git-send-email-philipoakley@iee.org","threadId":"39715","inReplyTo":"1435190633-2208-1-git-send-email-philipoakley@iee.org","subject":"[PATCH 01/17] .gitignore: improve MSVC ignore patterns","fromName":"Philip Oakley","fromEmail":"philipoakley@iee.org","sentAt":"2015-06-25T00:03:37Z","receivedAt":"2015-06-25T00:03:37Z","isPatch":true,"sender":{"key":"philipoakley@iee.email","avatar":"https://avatars.githubusercontent.com/u/914343?v=4"},"body":"Add the Microsoft .manifest pattern, and correct the generic 'Debug'\nand 'Release' directory patterns which were mechanically adjusted way\nback in c591d5f (gitignore: root most patterns at the top-level directory,\n2009-10-26) to allow multi-level projects within the Git suite.\n\nSigned-off-by: Philip Oakley <philipoakley@iee.org>\n---\n .gitignore | 5 +++--\n 1 file changed, 3 insertions(+), 2 deletions(-)\n\ndiff --git a/.gitignore b/.gitignore\nindex 422c538..55498c1 100644\n--- a/.gitignore\n+++ b/.gitignore\n@@ -246,5 +246,6 @@\n *.user\n *.idb\n *.pdb\n-/Debug/\n-/Release/\n+*.manifest\n+**/Debug/\n+**/Release/\n-- \n2.3.1\n\n-- \n-- \n*** Please reply-to-all at all times ***\n*** (do not pretend to know who is subscribed and who is not) ***\n*** Please avoid top-posting. ***\nThe msysGit Wiki is here: https://github.com/msysgit/msysgit/wiki - Github accounts are free.\n\nYou received this message because you are subscribed to the Google\nGroups \"msysGit\" group.\nTo post to this group, send email to msysgit@googlegroups.com\nTo unsubscribe from this group, send email to\nmsysgit+unsubscribe@googlegroups.com\nFor more options, and view previous threads, visit this group at\nhttp://groups.google.com/group/msysgit?hl=en_US?hl=en\n\n--- \nYou received this message because you are subscribed to the Google Groups \"Git for Windows\" group.\nTo unsubscribe from this group and stop receiving emails from it, send an email to msysgit+unsubscribe@googlegroups.com.\nFor more options, visit https://groups.google.com/d/optout.\n"},{"id":"264788","messageId":"1435190633-2208-3-git-send-email-philipoakley@iee.org","threadId":"39715","inReplyTo":"1435190633-2208-1-git-send-email-philipoakley@iee.org","subject":"[PATCH 02/17] .gitignore: ignore library directories created by MSVC VS2008 buildsystem","fromName":"Philip Oakley","fromEmail":"philipoakley@iee.org","sentAt":"2015-06-25T00:03:38Z","receivedAt":"2015-06-25T00:03:38Z","isPatch":true,"sender":{"key":"philipoakley@iee.email","avatar":"https://avatars.githubusercontent.com/u/914343?v=4"},"body":"Signed-off-by: Philip Oakley <philipoakley@iee.org>\n---\n .gitignore | 3 +++\n 1 file changed, 3 insertions(+)\n\ndiff --git a/.gitignore b/.gitignore\nindex 55498c1..706d0d9 100644\n--- a/.gitignore\n+++ b/.gitignore\n@@ -177,6 +177,7 @@\n /gitweb/gitweb.cgi\n /gitweb/static/gitweb.js\n /gitweb/static/gitweb.min.*\n+/libgit\n /test-chmtime\n /test-ctype\n /test-config\n@@ -209,6 +210,8 @@\n /test-urlmatch-normalization\n /test-wildmatch\n /common-cmds.h\n+/vcs-svn_lib\n+/xdiff_lib\n *.tar.gz\n *.dsc\n *.deb\n-- \n2.3.1\n\n-- \n-- \n*** Please reply-to-all at all times ***\n*** (do not pretend to know who is subscribed and who is not) ***\n*** Please avoid top-posting. ***\nThe msysGit Wiki is here: https://github.com/msysgit/msysgit/wiki - Github accounts are free.\n\nYou received this message because you are subscribed to the Google\nGroups \"msysGit\" group.\nTo post to this group, send email to msysgit@googlegroups.com\nTo unsubscribe from this group, send email to\nmsysgit+unsubscribe@googlegroups.com\nFor more options, and view previous threads, visit this group at\nhttp://groups.google.com/group/msysgit?hl=en_US?hl=en\n\n--- \nYou received this message because you are subscribed to the Google Groups \"Git for Windows\" group.\nTo unsubscribe from this group and stop receiving emails from it, send an email to msysgit+unsubscribe@googlegroups.com.\nFor more options, visit https://groups.google.com/d/optout.\n"},{"id":"264798","messageId":"1435190633-2208-4-git-send-email-philipoakley@iee.org","threadId":"39715","inReplyTo":"1435190633-2208-1-git-send-email-philipoakley@iee.org","subject":"[PATCH 03/17] (msvc-build) Vcproj.pm: remove duplicate GUID","fromName":"Philip Oakley","fromEmail":"philipoakley@iee.org","sentAt":"2015-06-25T00:03:39Z","receivedAt":"2015-06-25T00:03:39Z","isPatch":true,"sender":{"key":"philipoakley@iee.email","avatar":"https://avatars.githubusercontent.com/u/914343?v=4"},"body":"Delete the duplicated GUID from the generation code for the Visual Studio\n.sln project file.\n\nThe duplicate GUID tended to be allocated to test-svn-fe, which was then\nignored by Visual Studio / MSVC, and it's omission from the build never\nnoticed.\n\nSigned-off-by: Philip Oakley <philipoakley@iee.org>\n---\n contrib/buildsystems/Generators/Vcproj.pm | 1 -\n 1 file changed, 1 deletion(-)\n\ndiff --git a/contrib/buildsystems/Generators/Vcproj.pm b/contrib/buildsystems/Generators/Vcproj.pm\nindex cfa74ad..1b01d58 100644\n--- a/contrib/buildsystems/Generators/Vcproj.pm\n+++ b/contrib/buildsystems/Generators/Vcproj.pm\n@@ -52,7 +52,6 @@ my @GUIDS = (\n     \"{00785268-A9CC-4E40-AC29-BAC0019159CE}\",\n     \"{4C06F56A-DCDB-46A6-B67C-02339935CF12}\",\n     \"{3A62D3FD-519E-4EC9-8171-D2C1BFEA022F}\",\n-    \"{3A62D3FD-519E-4EC9-8171-D2C1BFEA022F}\",\n     \"{9392EB58-D7BA-410B-B1F0-B2FAA6BC89A7}\",\n     \"{2ACAB2D5-E0CE-4027-BCA0-D78B2D7A6C66}\",\n     \"{86E216C3-43CE-481A-BCB2-BE5E62850635}\",\n-- \n2.3.1\n\n-- \n-- \n*** Please reply-to-all at all times ***\n*** (do not pretend to know who is subscribed and who is not) ***\n*** Please avoid top-posting. ***\nThe msysGit Wiki is here: https://github.com/msysgit/msysgit/wiki - Github accounts are free.\n\nYou received this message because you are subscribed to the Google\nGroups \"msysGit\" group.\nTo post to this group, send email to msysgit@googlegroups.com\nTo unsubscribe from this group, send email to\nmsysgit+unsubscribe@googlegroups.com\nFor more options, and view previous threads, visit this group at\nhttp://groups.google.com/group/msysgit?hl=en_US?hl=en\n\n--- \nYou received this message because you are subscribed to the Google Groups \"Git for Windows\" group.\nTo unsubscribe from this group and stop receiving emails from it, send an email to msysgit+unsubscribe@googlegroups.com.\nFor more options, visit https://groups.google.com/d/optout.\n"},{"id":"264789","messageId":"1435190633-2208-5-git-send-email-philipoakley@iee.org","threadId":"39715","inReplyTo":"1435190633-2208-1-git-send-email-philipoakley@iee.org","subject":"[PATCH 04/17] Makefile: a dry-run can error out if no perl. Document the issue","fromName":"Philip Oakley","fromEmail":"philipoakley@iee.org","sentAt":"2015-06-25T00:03:40Z","receivedAt":"2015-06-25T00:03:40Z","isPatch":true,"sender":{"key":"philipoakley@iee.email","avatar":"https://avatars.githubusercontent.com/u/914343?v=4"},"body":"A 'make -n' dry-run is used as part of the /compat/vcbuild and\n/contrib/buildsystems code. The commit ee9be06 (perl: detect new files\nin MakeMaker builds, 2012-07-27) was not aware of that dry-run usage\nand thus would not execute the target.\n\nAdd a comment to the make file stating the issue and the available\nsolutions of either NO_PERL or a '+recipe'.\n\nSigned-off-by: Philip Oakley <philipoakley@iee.org>\n---\n Makefile | 3 +++\n 1 file changed, 3 insertions(+)\n\ndiff --git a/Makefile b/Makefile\nindex 149f1c7..22108bb 100644\n--- a/Makefile\n+++ b/Makefile\n@@ -1746,6 +1746,9 @@ $(SCRIPT_PERL_GEN): perl/perl.mak\n \n perl/perl.mak: perl/PM.stamp\n \n+# 'make -n' (dry-run) will not execute this target which creates/updates the PM.stamp file.\n+# To avoid the error of failing to find the target PM.stamp, either use NO_PERL=1 (YesPlease),\n+# or add a leading '+' to the recipe '+$(QUIET_GEN)$(FIND) perl ...' so that it is executed.\n perl/PM.stamp: FORCE\n \t@$(FIND) perl -type f -name '*.pm' | sort >$@+ && \\\n \t{ cmp $@+ $@ >/dev/null 2>/dev/null || mv $@+ $@; } && \\\n-- \n2.3.1\n\n-- \n-- \n*** Please reply-to-all at all times ***\n*** (do not pretend to know who is subscribed and who is not) ***\n*** Please avoid top-posting. ***\nThe msysGit Wiki is here: https://github.com/msysgit/msysgit/wiki - Github accounts are free.\n\nYou received this message because you are subscribed to the Google\nGroups \"msysGit\" group.\nTo post to this group, send email to msysgit@googlegroups.com\nTo unsubscribe from this group, send email to\nmsysgit+unsubscribe@googlegroups.com\nFor more options, and view previous threads, visit this group at\nhttp://groups.google.com/group/msysgit?hl=en_US?hl=en\n\n--- \nYou received this message because you are subscribed to the Google Groups \"Git for Windows\" group.\nTo unsubscribe from this group and stop receiving emails from it, send an email to msysgit+unsubscribe@googlegroups.com.\nFor more options, visit https://groups.google.com/d/optout.\n"},{"id":"264786","messageId":"1435190633-2208-6-git-send-email-philipoakley@iee.org","threadId":"39715","inReplyTo":"1435190633-2208-1-git-send-email-philipoakley@iee.org","subject":"[PATCH 05/17] engine.pl: fix error message (lib->link)","fromName":"Philip Oakley","fromEmail":"philipoakley@iee.org","sentAt":"2015-06-25T00:03:41Z","receivedAt":"2015-06-25T00:03:41Z","isPatch":true,"sender":{"key":"philipoakley@iee.email","avatar":"https://avatars.githubusercontent.com/u/914343?v=4"},"body":"Signed-off-by: Philip Oakley <philipoakley@iee.org>\n---\n contrib/buildsystems/engine.pl | 2 +-\n 1 file changed, 1 insertion(+), 1 deletion(-)\n\ndiff --git a/contrib/buildsystems/engine.pl b/contrib/buildsystems/engine.pl\nindex 23da787..5398315 100755\n--- a/contrib/buildsystems/engine.pl\n+++ b/contrib/buildsystems/engine.pl\n@@ -329,7 +329,7 @@ sub handleLinkLine\n         } elsif ($part =~ /\\.(o|obj)$/) {\n             push(@objfiles, $part);\n         } else {\n-            die \"Unhandled lib option @ line $lineno: $part\";\n+            die \"Unhandled link option @ line $lineno: *$part*\";\n         }\n     }\n #    print \"AppOut: '$appout'\\nLFlags: @lflags\\nLibs  : @libs\\nOfiles: @objfiles\\n\";\n-- \n2.3.1\n\n-- \n-- \n*** Please reply-to-all at all times ***\n*** (do not pretend to know who is subscribed and who is not) ***\n*** Please avoid top-posting. ***\nThe msysGit Wiki is here: https://github.com/msysgit/msysgit/wiki - Github accounts are free.\n\nYou received this message because you are subscribed to the Google\nGroups \"msysGit\" group.\nTo post to this group, send email to msysgit@googlegroups.com\nTo unsubscribe from this group, send email to\nmsysgit+unsubscribe@googlegroups.com\nFor more options, and view previous threads, visit this group at\nhttp://groups.google.com/group/msysgit?hl=en_US?hl=en\n\n--- \nYou received this message because you are subscribed to the Google Groups \"Git for Windows\" group.\nTo unsubscribe from this group and stop receiving emails from it, send an email to msysgit+unsubscribe@googlegroups.com.\nFor more options, visit https://groups.google.com/d/optout.\n"},{"id":"264784","messageId":"1435190633-2208-7-git-send-email-philipoakley@iee.org","threadId":"39715","inReplyTo":"1435190633-2208-1-git-send-email-philipoakley@iee.org","subject":"[PATCH 06/17] engine.pl: Avoid complications with perl support","fromName":"Philip Oakley","fromEmail":"philipoakley@iee.org","sentAt":"2015-06-25T00:03:42Z","receivedAt":"2015-06-25T00:03:42Z","isPatch":true,"sender":{"key":"philipoakley@iee.email","avatar":"https://avatars.githubusercontent.com/u/914343?v=4"},"body":"ee9be06 (perl: detect new files in MakeMaker builds, 2012-07-27)\ndid not include dry-run support for the generation of the PM.stamp\nfile, though the dry-run output is used by the build engine.\n\nDisable the perl processing during the dry-run to avoid the issue.\n\nSigned-off-by: Philip Oakley <philipoakley@iee.org>\n---\n contrib/buildsystems/engine.pl | 2 +-\n 1 file changed, 1 insertion(+), 1 deletion(-)\n\ndiff --git a/contrib/buildsystems/engine.pl b/contrib/buildsystems/engine.pl\nindex 5398315..4d0a616 100755\n--- a/contrib/buildsystems/engine.pl\n+++ b/contrib/buildsystems/engine.pl\n@@ -72,7 +72,7 @@ Running GNU Make to figure out build structure...\n EOM\n \n # Pipe a make --dry-run into a variable, if not already loaded from file\n-@makedry = `cd $git_dir && make -n MSVC=1 V=1 2>/dev/null` if !@makedry;\n+@makedry = `cd $git_dir && make -n MSVC=1 NO_PERL=1 V=1 2>/dev/null` if !@makedry;\n \n # Parse the make output into usable info\n parseMakeOutput();\n-- \n2.3.1\n\n-- \n-- \n*** Please reply-to-all at all times ***\n*** (do not pretend to know who is subscribed and who is not) ***\n*** Please avoid top-posting. ***\nThe msysGit Wiki is here: https://github.com/msysgit/msysgit/wiki - Github accounts are free.\n\nYou received this message because you are subscribed to the Google\nGroups \"msysGit\" group.\nTo post to this group, send email to msysgit@googlegroups.com\nTo unsubscribe from this group, send email to\nmsysgit+unsubscribe@googlegroups.com\nFor more options, and view previous threads, visit this group at\nhttp://groups.google.com/group/msysgit?hl=en_US?hl=en\n\n--- \nYou received this message because you are subscribed to the Google Groups \"Git for Windows\" group.\nTo unsubscribe from this group and stop receiving emails from it, send an email to msysgit+unsubscribe@googlegroups.com.\nFor more options, visit https://groups.google.com/d/optout.\n"},{"id":"264787","messageId":"1435190633-2208-8-git-send-email-philipoakley@iee.org","threadId":"39715","inReplyTo":"1435190633-2208-1-git-send-email-philipoakley@iee.org","subject":"[PATCH 07/17] engine.pl: Properly accept quoted spaces in filenames","fromName":"Philip Oakley","fromEmail":"philipoakley@iee.org","sentAt":"2015-06-25T00:03:43Z","receivedAt":"2015-06-25T00:03:43Z","isPatch":true,"sender":{"key":"philipoakley@iee.email","avatar":"https://avatars.githubusercontent.com/u/914343?v=4"},"body":"The engine.pl script barfs on the properly quoted spaces in\nfilename options prevalent on Windows. Use shellwords() rather\nthan split() to separate such options.\n\nHelped-by: Junio C Hamano <gitster@pobox.com>\nSigned-off-by: Philip Oakley <philipoakley@iee.org>\n---\n$gamane/21145 & $gmane/21147\n---\n contrib/buildsystems/engine.pl | 7 ++++---\n 1 file changed, 4 insertions(+), 3 deletions(-)\n\ndiff --git a/contrib/buildsystems/engine.pl b/contrib/buildsystems/engine.pl\nindex 4d0a616..ccb59fd 100755\n--- a/contrib/buildsystems/engine.pl\n+++ b/contrib/buildsystems/engine.pl\n@@ -12,6 +12,7 @@ use File::Basename;\n use File::Spec;\n use Cwd;\n use Generators;\n+use Text::ParseWords;\n \n my (%build_structure, %compile_options, @makedry);\n my $out_dir = getcwd();\n@@ -231,7 +232,7 @@ sub removeDuplicates\n sub handleCompileLine\n {\n     my ($line, $lineno) = @_;\n-    my @parts = split(' ', $line);\n+    my @parts = shellwords($line);\n     my $sourcefile;\n     shift(@parts); # ignore cmd\n     while (my $part = shift @parts) {\n@@ -265,7 +266,7 @@ sub handleLibLine\n     my (@objfiles, @lflags, $libout, $part);\n     # kill cmd and rm 'prefix'\n     $line =~ s/^rm -f .* && .* rcs //;\n-    my @parts = split(' ', $line);\n+    my @parts = shellwords($line);\n     while ($part = shift @parts) {\n         if ($part =~ /^-/) {\n             push(@lflags, $part);\n@@ -306,7 +307,7 @@ sub handleLinkLine\n {\n     my ($line, $lineno) = @_;\n     my (@objfiles, @lflags, @libs, $appout, $part);\n-    my @parts = split(' ', $line);\n+    my @parts = shellwords($line);\n     shift(@parts); # ignore cmd\n     while ($part = shift @parts) {\n         if ($part =~ /^-IGNORE/) {\n-- \n2.3.1\n\n-- \n-- \n*** Please reply-to-all at all times ***\n*** (do not pretend to know who is subscribed and who is not) ***\n*** Please avoid top-posting. ***\nThe msysGit Wiki is here: https://github.com/msysgit/msysgit/wiki - Github accounts are free.\n\nYou received this message because you are subscribed to the Google\nGroups \"msysGit\" group.\nTo post to this group, send email to msysgit@googlegroups.com\nTo unsubscribe from this group, send email to\nmsysgit+unsubscribe@googlegroups.com\nFor more options, and view previous threads, visit this group at\nhttp://groups.google.com/group/msysgit?hl=en_US?hl=en\n\n--- \nYou received this message because you are subscribed to the Google Groups \"Git for Windows\" group.\nTo unsubscribe from this group and stop receiving emails from it, send an email to msysgit+unsubscribe@googlegroups.com.\nFor more options, visit https://groups.google.com/d/optout.\n"},{"id":"264796","messageId":"1435190633-2208-9-git-send-email-philipoakley@iee.org","threadId":"39715","inReplyTo":"1435190633-2208-1-git-send-email-philipoakley@iee.org","subject":"[PATCH 08/17] engine.pl: Fix i18n -o option in msvc buildsystem generator","fromName":"Philip Oakley","fromEmail":"philipoakley@iee.org","sentAt":"2015-06-25T00:03:44Z","receivedAt":"2015-06-25T00:03:44Z","isPatch":true,"sender":{"key":"philipoakley@iee.email","avatar":"https://avatars.githubusercontent.com/u/914343?v=4"},"body":"The i18n 5e9637c (i18n: add infrastructure for translating\nGit with gettext, 2011-11-18) introduced an extra '-o' option\ninto the make file.\n\nIf the msvc buildsystem is run without NO_GETTEXT being set\nthen this broke the engine.pl code for extracting the git.sln\nfor msvc gui-IDE. The setting of NO_GETTEXT was not fixed until\nlater, relative to the Msysgit project where this issue was being\ninvestigated.\n\nThe presence of these options in the Makefile output should not\ncompromise the derived build structure. They should be ignored.\n\nAdd tests to remove these non linker options, in same vein as\n74cf9bd (engine.pl: Fix a recent breakage of the buildsystem\ngenerator, 2010-01-22).\n\nSigned-off-by: Philip Oakley <philipoakley@iee.org>\n---\n contrib/buildsystems/engine.pl | 6 ++++++\n 1 file changed, 6 insertions(+)\n\ndiff --git a/contrib/buildsystems/engine.pl b/contrib/buildsystems/engine.pl\nindex ccb59fd..73f2472 100755\n--- a/contrib/buildsystems/engine.pl\n+++ b/contrib/buildsystems/engine.pl\n@@ -141,6 +141,12 @@ sub parseMakeOutput\n             next;\n         }\n \n+        if ($text =~ /^(mkdir|msgfmt) /) {\n+            # options to the Portable Object translations\n+            # the line \"mkdir ... && msgfmt ...\" contains no linker options\n+            next;\n+        }\n+\n         if($text =~ / -c /) {\n             # compilation\n             handleCompileLine($text, $line);\n-- \n2.3.1\n\n-- \n-- \n*** Please reply-to-all at all times ***\n*** (do not pretend to know who is subscribed and who is not) ***\n*** Please avoid top-posting. ***\nThe msysGit Wiki is here: https://github.com/msysgit/msysgit/wiki - Github accounts are free.\n\nYou received this message because you are subscribed to the Google\nGroups \"msysGit\" group.\nTo post to this group, send email to msysgit@googlegroups.com\nTo unsubscribe from this group, send email to\nmsysgit+unsubscribe@googlegroups.com\nFor more options, and view previous threads, visit this group at\nhttp://groups.google.com/group/msysgit?hl=en_US?hl=en\n\n--- \nYou received this message because you are subscribed to the Google Groups \"Git for Windows\" group.\nTo unsubscribe from this group and stop receiving emails from it, send an email to msysgit+unsubscribe@googlegroups.com.\nFor more options, visit https://groups.google.com/d/optout.\n"},{"id":"264797","messageId":"1435190633-2208-10-git-send-email-philipoakley@iee.org","threadId":"39715","inReplyTo":"1435190633-2208-1-git-send-email-philipoakley@iee.org","subject":"[PATCH 09/17] engine.pl: ignore invalidcontinue.obj which is known to MSVC","fromName":"Philip Oakley","fromEmail":"philipoakley@iee.org","sentAt":"2015-06-25T00:03:45Z","receivedAt":"2015-06-25T00:03:45Z","isPatch":true,"sender":{"key":"philipoakley@iee.email","avatar":"https://avatars.githubusercontent.com/u/914343?v=4"},"body":"Commit 4b623d8 (MSVC: link in invalidcontinue.obj for better\nPOSIX compatibility, 2014-03-29) is not processed correctly\nby the buildsystem. Ignore it.\n\nAlso split the .o and .obj processing; 'make' does not produce .obj\nfiles. Only substitute filenames ending with .o when generating the\nsource .c filename.\n\nSigned-off-by: Philip Oakley <philipoakley@iee.org>\n---\n contrib/buildsystems/engine.pl | 10 +++++++---\n 1 file changed, 7 insertions(+), 3 deletions(-)\n\ndiff --git a/contrib/buildsystems/engine.pl b/contrib/buildsystems/engine.pl\nindex 73f2472..e8aa8ea 100755\n--- a/contrib/buildsystems/engine.pl\n+++ b/contrib/buildsystems/engine.pl\n@@ -289,7 +289,7 @@ sub handleLibLine\n #    exit(1);\n     foreach (@objfiles) {\n         my $sourcefile = $_;\n-        $sourcefile =~ s/\\.o/.c/;\n+        $sourcefile =~ s/\\.o$/.c/;\n         push(@sources, $sourcefile);\n         push(@cflags, @{$compile_options{\"${sourcefile}_CFLAGS\"}});\n         push(@defines, @{$compile_options{\"${sourcefile}_DEFINES\"}});\n@@ -333,8 +333,12 @@ sub handleLinkLine\n         } elsif ($part =~ /\\.(a|lib)$/) {\n             $part =~ s/\\.a$/.lib/;\n             push(@libs, $part);\n-        } elsif ($part =~ /\\.(o|obj)$/) {\n+        } elsif ($part eq 'invalidcontinue.obj') {\n+            # ignore - known to MSVC\n+        } elsif ($part =~ /\\.o$/) {\n             push(@objfiles, $part);\n+        } elsif ($part =~ /\\.obj$/) {\n+            # do nothing, 'make' should not be producing .obj, only .o files\n         } else {\n             die \"Unhandled link option @ line $lineno: *$part*\";\n         }\n@@ -343,7 +347,7 @@ sub handleLinkLine\n #    exit(1);\n     foreach (@objfiles) {\n         my $sourcefile = $_;\n-        $sourcefile =~ s/\\.o/.c/;\n+        $sourcefile =~ s/\\.o$/.c/;\n         push(@sources, $sourcefile);\n         push(@cflags, @{$compile_options{\"${sourcefile}_CFLAGS\"}});\n         push(@defines, @{$compile_options{\"${sourcefile}_DEFINES\"}});\n-- \n2.3.1\n\n-- \n-- \n*** Please reply-to-all at all times ***\n*** (do not pretend to know who is subscribed and who is not) ***\n*** Please avoid top-posting. ***\nThe msysGit Wiki is here: https://github.com/msysgit/msysgit/wiki - Github accounts are free.\n\nYou received this message because you are subscribed to the Google\nGroups \"msysGit\" group.\nTo post to this group, send email to msysgit@googlegroups.com\nTo unsubscribe from this group, send email to\nmsysgit+unsubscribe@googlegroups.com\nFor more options, and view previous threads, visit this group at\nhttp://groups.google.com/group/msysgit?hl=en_US?hl=en\n\n--- \nYou received this message because you are subscribed to the Google Groups \"Git for Windows\" group.\nTo unsubscribe from this group and stop receiving emails from it, send an email to msysgit+unsubscribe@googlegroups.com.\nFor more options, visit https://groups.google.com/d/optout.\n"},{"id":"264800","messageId":"1435190633-2208-11-git-send-email-philipoakley@iee.org","threadId":"39715","inReplyTo":"1435190633-2208-1-git-send-email-philipoakley@iee.org","subject":"[PATCH 10/17] engine.pl: name the msvc buildsystem's makedry error file","fromName":"Philip Oakley","fromEmail":"philipoakley@iee.org","sentAt":"2015-06-25T00:03:46Z","receivedAt":"2015-06-25T00:03:46Z","isPatch":true,"sender":{"key":"philipoakley@iee.email","avatar":"https://avatars.githubusercontent.com/u/914343?v=4"},"body":"Save the stderr from the dry MSVC make to a well named file for\nlater review. Use 'msvc-build-makedryerrors.txt' which should be\nobvious as to its source, and is not ignored by 'git status'.\n\nSigned-off-by: Philip Oakley <philipoakley@iee.org>\n---\n contrib/buildsystems/engine.pl | 5 ++++-\n 1 file changed, 4 insertions(+), 1 deletion(-)\n mode change 100755 => 100644 contrib/buildsystems/engine.pl\n\ndiff --git a/contrib/buildsystems/engine.pl b/contrib/buildsystems/engine.pl\nold mode 100755\nnew mode 100644\nindex e8aa8ea..7eba870\n--- a/contrib/buildsystems/engine.pl\n+++ b/contrib/buildsystems/engine.pl\n@@ -73,7 +73,10 @@ Running GNU Make to figure out build structure...\n EOM\n \n # Pipe a make --dry-run into a variable, if not already loaded from file\n-@makedry = `cd $git_dir && make -n MSVC=1 NO_PERL=1 V=1 2>/dev/null` if !@makedry;\n+# Capture the make dry stderr to file for review (will be empty for a release build).\n+\n+my $ErrsFile = \"msvc-build-makedryerrors.txt\";\n+@makedry = `cd $git_dir && make -n MSVC=1 NO_PERL=1 V=1 2>$ErrsFile` if !@makedry;\n \n # Parse the make output into usable info\n parseMakeOutput();\n-- \n2.3.1\n\n-- \n-- \n*** Please reply-to-all at all times ***\n*** (do not pretend to know who is subscribed and who is not) ***\n*** Please avoid top-posting. ***\nThe msysGit Wiki is here: https://github.com/msysgit/msysgit/wiki - Github accounts are free.\n\nYou received this message because you are subscribed to the Google\nGroups \"msysGit\" group.\nTo post to this group, send email to msysgit@googlegroups.com\nTo unsubscribe from this group, send email to\nmsysgit+unsubscribe@googlegroups.com\nFor more options, and view previous threads, visit this group at\nhttp://groups.google.com/group/msysgit?hl=en_US?hl=en\n\n--- \nYou received this message because you are subscribed to the Google Groups \"Git for Windows\" group.\nTo unsubscribe from this group and stop receiving emails from it, send an email to msysgit+unsubscribe@googlegroups.com.\nFor more options, visit https://groups.google.com/d/optout.\n"},{"id":"264793","messageId":"1435190633-2208-12-git-send-email-philipoakley@iee.org","threadId":"39715","inReplyTo":"1435190633-2208-1-git-send-email-philipoakley@iee.org","subject":"[PATCH 11/17] engine.pl: delete the captured stderr file if empty","fromName":"Philip Oakley","fromEmail":"philipoakley@iee.org","sentAt":"2015-06-25T00:03:47Z","receivedAt":"2015-06-25T00:03:47Z","isPatch":true,"sender":{"key":"philipoakley@iee.email","avatar":"https://avatars.githubusercontent.com/u/914343?v=4"},"body":"Keep the build clean of extraneous files if it is indeed clean.\nOtherwise leave the msvc-build-makedryerrors.txt file both as\na flag for any CI system or for manual debugging.\n\nNote that the file will contain the new values of the GIT_VERSION\nand GITGUI_VERSION if they were generated by the make file. They\nare omitted if the release is tagged and indentically defined in\ntheir respective GIT_VERSION_GEN file DEF_VER variables.\n\nSigned-off-by: Philip Oakley <philipoakley@iee.org>\n---\n contrib/buildsystems/engine.pl | 2 ++\n 1 file changed, 2 insertions(+)\n\ndiff --git a/contrib/buildsystems/engine.pl b/contrib/buildsystems/engine.pl\nindex 7eba870..27884f7 100644\n--- a/contrib/buildsystems/engine.pl\n+++ b/contrib/buildsystems/engine.pl\n@@ -77,6 +77,8 @@ EOM\n \n my $ErrsFile = \"msvc-build-makedryerrors.txt\";\n @makedry = `cd $git_dir && make -n MSVC=1 NO_PERL=1 V=1 2>$ErrsFile` if !@makedry;\n+# test for an empty Errors file and remove it\n+for ($ErrsFile) {unlink $_ if (-f $_) && (!-s $_);}\n \n # Parse the make output into usable info\n parseMakeOutput();\n-- \n2.3.1\n\n-- \n-- \n*** Please reply-to-all at all times ***\n*** (do not pretend to know who is subscribed and who is not) ***\n*** Please avoid top-posting. ***\nThe msysGit Wiki is here: https://github.com/msysgit/msysgit/wiki - Github accounts are free.\n\nYou received this message because you are subscribed to the Google\nGroups \"msysGit\" group.\nTo post to this group, send email to msysgit@googlegroups.com\nTo unsubscribe from this group, send email to\nmsysgit+unsubscribe@googlegroups.com\nFor more options, and view previous threads, visit this group at\nhttp://groups.google.com/group/msysgit?hl=en_US?hl=en\n\n--- \nYou received this message because you are subscribed to the Google Groups \"Git for Windows\" group.\nTo unsubscribe from this group and stop receiving emails from it, send an email to msysgit+unsubscribe@googlegroups.com.\nFor more options, visit https://groups.google.com/d/optout.\n"},{"id":"264792","messageId":"1435190633-2208-13-git-send-email-philipoakley@iee.org","threadId":"39715","inReplyTo":"1435190633-2208-1-git-send-email-philipoakley@iee.org","subject":"[PATCH 12/17] engine.pl: add debug line to capture the dry-run","fromName":"Philip Oakley","fromEmail":"philipoakley@iee.org","sentAt":"2015-06-25T00:03:48Z","receivedAt":"2015-06-25T00:03:48Z","isPatch":true,"sender":{"key":"philipoakley@iee.email","avatar":"https://avatars.githubusercontent.com/u/914343?v=4"},"body":"Add a debug suggestion for capturing to file the stdout from the dry-run\nof the make file used in determining the msvc-build structure for easy\ndebugging.\n\nSigned-off-by: Philip Oakley <philipoakley@iee.org>\n---\n contrib/buildsystems/engine.pl | 1 +\n 1 file changed, 1 insertion(+)\n\ndiff --git a/contrib/buildsystems/engine.pl b/contrib/buildsystems/engine.pl\nindex 27884f7..7a2aeef 100644\n--- a/contrib/buildsystems/engine.pl\n+++ b/contrib/buildsystems/engine.pl\n@@ -76,6 +76,7 @@ EOM\n # Capture the make dry stderr to file for review (will be empty for a release build).\n \n my $ErrsFile = \"msvc-build-makedryerrors.txt\";\n+#@makedry = `cd $git_dir && make -n MSVC=1 NO_PERL=1 V=1 1>makedry.txt 2>$ErrsFile`; # capture the dry run as a text file\n @makedry = `cd $git_dir && make -n MSVC=1 NO_PERL=1 V=1 2>$ErrsFile` if !@makedry;\n # test for an empty Errors file and remove it\n for ($ErrsFile) {unlink $_ if (-f $_) && (!-s $_);}\n-- \n2.3.1\n\n-- \n-- \n*** Please reply-to-all at all times ***\n*** (do not pretend to know who is subscribed and who is not) ***\n*** Please avoid top-posting. ***\nThe msysGit Wiki is here: https://github.com/msysgit/msysgit/wiki - Github accounts are free.\n\nYou received this message because you are subscribed to the Google\nGroups \"msysGit\" group.\nTo post to this group, send email to msysgit@googlegroups.com\nTo unsubscribe from this group, send email to\nmsysgit+unsubscribe@googlegroups.com\nFor more options, and view previous threads, visit this group at\nhttp://groups.google.com/group/msysgit?hl=en_US?hl=en\n\n--- \nYou received this message because you are subscribed to the Google Groups \"Git for Windows\" group.\nTo unsubscribe from this group and stop receiving emails from it, send an email to msysgit+unsubscribe@googlegroups.com.\nFor more options, visit https://groups.google.com/d/optout.\n"},{"id":"264799","messageId":"1435190633-2208-14-git-send-email-philipoakley@iee.org","threadId":"39715","inReplyTo":"1435190633-2208-1-git-send-email-philipoakley@iee.org","subject":"[PATCH 13/17] engine.pl: provide more debug print statements","fromName":"Philip Oakley","fromEmail":"philipoakley@iee.org","sentAt":"2015-06-25T00:03:49Z","receivedAt":"2015-06-25T00:03:49Z","isPatch":true,"sender":{"key":"philipoakley@iee.email","avatar":"https://avatars.githubusercontent.com/u/914343?v=4"},"body":"Assist developers transitioning between the two cultures\nby including appropriate, but commented out, debug statements.\n\nThe exception is when an unhandled compiler option is detected,\nwhere printing of the full line will supplement the line number and\noption part. Otherwise the OP has no immediate mechanism for\ninspecting the relevant part of the makedry output.\n\nThese debug print statements act as a guide for a poor man's --verbose\noption. The test suite doesn't cover the contrib/buildsystems (or\nMsysgit's msvc-build) contributions so fails to notice breakages there-in.\n\nIt is doubly hard to get developers to ride both horses so, contrary to\nnormal convention, retain selected debug statements as a safety net for\nthose willing to try.\n\nSigned-off-by: Philip Oakley <philipoakley@iee.org>\n---\n contrib/buildsystems/engine.pl | 4 ++++\n 1 file changed, 4 insertions(+)\n\ndiff --git a/contrib/buildsystems/engine.pl b/contrib/buildsystems/engine.pl\nindex 7a2aeef..ac2970a 100644\n--- a/contrib/buildsystems/engine.pl\n+++ b/contrib/buildsystems/engine.pl\n@@ -41,6 +41,7 @@ EOM\n # Parse command-line options\n while (@ARGV) {\n     my $arg = shift @ARGV;\n+\t#print \"Arg: $arg \\n\";\n     if (\"$arg\" eq \"-h\" || \"$arg\" eq \"--help\" || \"$arg\" eq \"-?\") {\n \tshowUsage();\n \texit(0);\n@@ -129,6 +130,7 @@ sub parseMakeOutput\n     print \"Parsing GNU Make output to figure out build structure...\\n\";\n     my $line = 0;\n     while (my $text = shift @makedry) {\n+\t\t#print \"Make: $text\\n\"; # show the makedry line\n         my $ate_next;\n         do {\n             $ate_next = 0;\n@@ -263,6 +265,7 @@ sub handleCompileLine\n         } elsif ($part =~ /\\.(c|cc|cpp)$/) {\n             $sourcefile = $part;\n         } else {\n+            print \"full line: $line\\n\";\n             die \"Unhandled compiler option @ line $lineno: $part\";\n         }\n     }\n@@ -288,6 +291,7 @@ sub handleLibLine\n             $libout = $part;\n             $libout =~ s/\\.a$//;\n         } else {\n+            print \"full line: $line\\n\";\n             die \"Unhandled lib option @ line $lineno: $part\";\n         }\n     }\n-- \n2.3.1\n\n-- \n-- \n*** Please reply-to-all at all times ***\n*** (do not pretend to know who is subscribed and who is not) ***\n*** Please avoid top-posting. ***\nThe msysGit Wiki is here: https://github.com/msysgit/msysgit/wiki - Github accounts are free.\n\nYou received this message because you are subscribed to the Google\nGroups \"msysGit\" group.\nTo post to this group, send email to msysgit@googlegroups.com\nTo unsubscribe from this group, send email to\nmsysgit+unsubscribe@googlegroups.com\nFor more options, and view previous threads, visit this group at\nhttp://groups.google.com/group/msysgit?hl=en_US?hl=en\n\n--- \nYou received this message because you are subscribed to the Google Groups \"Git for Windows\" group.\nTo unsubscribe from this group and stop receiving emails from it, send an email to msysgit+unsubscribe@googlegroups.com.\nFor more options, visit https://groups.google.com/d/optout.\n"},{"id":"264790","messageId":"1435190633-2208-15-git-send-email-philipoakley@iee.org","threadId":"39715","inReplyTo":"1435190633-2208-1-git-send-email-philipoakley@iee.org","subject":"[PATCH 14/17] Vcproj.pm: list git.exe first to be startup project","fromName":"Philip Oakley","fromEmail":"philipoakley@iee.org","sentAt":"2015-06-25T00:03:50Z","receivedAt":"2015-06-25T00:03:50Z","isPatch":true,"sender":{"key":"philipoakley@iee.email","avatar":"https://avatars.githubusercontent.com/u/914343?v=4"},"body":"Visual Studio take the first listed application/library as the default\nstartup project [1]. Parse the application list for git.exe, then list\nthe libraries, then the other git dashed forms in the git.sln file.\n\nDetect the 'git' project and place it the head of the apps list, rather\nthan the tail.\n\nExport the apps list before libs list for both the projects and global\nstructures of the .sln file.\n\n[1] http://stackoverflow.com/questions/1238553/\nvs2008-where-is-the-startup-project-setting-stored-for-a-solution\n    \"In the solution file, there are a list of pseudo-XML \"Project\"\n    entries. It turns out that whatever is the first one ends up as\n    the Startup Project, unless it’s overridden in the suo file. Argh.\n    I just rearranged the order in the file and it’s good.\"\n\n    \"just moving the pseudo-xml isn't enough. You also have to move the\n    group of entries in the \"GlobalSection(ProjectConfigurationPlatforms)\n    = postSolution\" group that has the GUID of the project you moved to\n    the top. So there are two places to move lines.\"\n\nSigned-off-by: Philip Oakley <philipoakley@iee.org>\n---\n contrib/buildsystems/Generators/Vcproj.pm | 33 ++++++++++++++++++-------------\n 1 file changed, 19 insertions(+), 14 deletions(-)\n\ndiff --git a/contrib/buildsystems/Generators/Vcproj.pm b/contrib/buildsystems/Generators/Vcproj.pm\nindex 1b01d58..cc2fa21 100644\n--- a/contrib/buildsystems/Generators/Vcproj.pm\n+++ b/contrib/buildsystems/Generators/Vcproj.pm\n@@ -560,20 +560,18 @@ sub createGlueProject {\n     foreach (@apps) {\n         $_ =~ s/\\//_/g;\n         $_ =~ s/\\.exe//;\n-        push(@tmp, $_);\n+        if ($_ eq \"git\" ) {\n+            unshift(@tmp, $_);\n+        } else {\n+            push(@tmp, $_);\n+        }\n     }\n     @apps = @tmp;\n \n     open F, \">git.sln\" || die \"Could not open git.sln for writing!\\n\";\n     binmode F, \":crlf\";\n     print F \"$SLN_HEAD\";\n-    foreach (@libs) {\n-        my $libname = $_;\n-        my $uuid = $build_structure{\"LIBS_${libname}_GUID\"};\n-        print F \"$SLN_PRE\";\n-        print F \"\\\"${libname}\\\", \\\"${libname}\\\\${libname}.vcproj\\\", \\\"${uuid}\\\"\";\n-        print F \"$SLN_POST\";\n-    }\n+\n     my $uuid_libgit = $build_structure{\"LIBS_libgit_GUID\"};\n     my $uuid_xdiff_lib = $build_structure{\"LIBS_xdiff_lib_GUID\"};\n     foreach (@apps) {\n@@ -587,6 +585,13 @@ sub createGlueProject {\n         print F \"\tEndProjectSection\";\n         print F \"$SLN_POST\";\n     }\n+    foreach (@libs) {\n+        my $libname = $_;\n+        my $uuid = $build_structure{\"LIBS_${libname}_GUID\"};\n+        print F \"$SLN_PRE\";\n+        print F \"\\\"${libname}\\\", \\\"${libname}\\\\${libname}.vcproj\\\", \\\"${uuid}\\\"\";\n+        print F \"$SLN_POST\";\n+    }\n \n     print F << \"EOM\";\n Global\n@@ -598,17 +603,17 @@ EOM\n     print F << \"EOM\";\n \tGlobalSection(ProjectConfigurationPlatforms) = postSolution\n EOM\n-    foreach (@libs) {\n-        my $libname = $_;\n-        my $uuid = $build_structure{\"LIBS_${libname}_GUID\"};\n+    foreach (@apps) {\n+        my $appname = $_;\n+        my $uuid = $build_structure{\"APPS_${appname}_GUID\"};\n         print F \"\\t\\t${uuid}.Debug|Win32.ActiveCfg = Debug|Win32\\n\";\n         print F \"\\t\\t${uuid}.Debug|Win32.Build.0 = Debug|Win32\\n\";\n         print F \"\\t\\t${uuid}.Release|Win32.ActiveCfg = Release|Win32\\n\";\n         print F \"\\t\\t${uuid}.Release|Win32.Build.0 = Release|Win32\\n\";\n     }\n-    foreach (@apps) {\n-        my $appname = $_;\n-        my $uuid = $build_structure{\"APPS_${appname}_GUID\"};\n+    foreach (@libs) {\n+        my $libname = $_;\n+        my $uuid = $build_structure{\"LIBS_${libname}_GUID\"};\n         print F \"\\t\\t${uuid}.Debug|Win32.ActiveCfg = Debug|Win32\\n\";\n         print F \"\\t\\t${uuid}.Debug|Win32.Build.0 = Debug|Win32\\n\";\n         print F \"\\t\\t${uuid}.Release|Win32.ActiveCfg = Release|Win32\\n\";\n-- \n2.3.1\n\n-- \n-- \n*** Please reply-to-all at all times ***\n*** (do not pretend to know who is subscribed and who is not) ***\n*** Please avoid top-posting. ***\nThe msysGit Wiki is here: https://github.com/msysgit/msysgit/wiki - Github accounts are free.\n\nYou received this message because you are subscribed to the Google\nGroups \"msysGit\" group.\nTo post to this group, send email to msysgit@googlegroups.com\nTo unsubscribe from this group, send email to\nmsysgit+unsubscribe@googlegroups.com\nFor more options, and view previous threads, visit this group at\nhttp://groups.google.com/group/msysgit?hl=en_US?hl=en\n\n--- \nYou received this message because you are subscribed to the Google Groups \"Git for Windows\" group.\nTo unsubscribe from this group and stop receiving emails from it, send an email to msysgit+unsubscribe@googlegroups.com.\nFor more options, visit https://groups.google.com/d/optout.\n"},{"id":"264783","messageId":"1435190633-2208-16-git-send-email-philipoakley@iee.org","threadId":"39715","inReplyTo":"1435190633-2208-1-git-send-email-philipoakley@iee.org","subject":"[PATCH 15/17] vcbuild/readme: Improve layout and reference msvc-build script","fromName":"Philip Oakley","fromEmail":"philipoakley@iee.org","sentAt":"2015-06-25T00:03:51Z","receivedAt":"2015-06-25T00:03:51Z","isPatch":true,"sender":{"key":"philipoakley@iee.email","avatar":"https://avatars.githubusercontent.com/u/914343?v=4"},"body":"Layout the 'either/or' with more white space to clarify\nwhich alternatives are matched up.\n\nReference the Msysgit build script which automates one sequence of options.\n\nSigned-off-by: Philip Oakley <philipoakley@iee.org>\n---\n compat/vcbuild/README | 27 +++++++++++++++++++--------\n 1 file changed, 19 insertions(+), 8 deletions(-)\n\ndiff --git a/compat/vcbuild/README b/compat/vcbuild/README\nindex df8a657..7548dc4 100644\n--- a/compat/vcbuild/README\n+++ b/compat/vcbuild/README\n@@ -3,20 +3,24 @@ The Steps of Build Git with VS2008\n 1. You need the build environment, which contains the Git dependencies\n    to be able to compile, link and run Git with MSVC.\n \n-   You can either use the binary repository:\n+   You can either:\n+      use the binary repository:\n \n        WWW: http://repo.or.cz/w/msvcgit.git\n        Git: git clone git://repo.or.cz/msvcgit.git\n        Zip: http://repo.or.cz/w/msvcgit.git?a=snapshot;h=master;sf=zip\n \n-   and call the setup_32bit_env.cmd batch script before compiling Git,\n-   (see repo/package README for details), or the source repository:\n+      and call the setup_32bit_env.cmd batch script before compiling Git,\n+     (see repo/package README for details),\n+\n+   or:\n+      use the source repository:\n \n        WWW: http://repo.or.cz/w/gitbuild.git\n        Git: git clone git://repo.or.cz/gitbuild.git\n        Zip: (None, as it's a project with submodules)\n \n-   and build the support libs as instructed in that repo/package.\n+     and build the support libs as instructed in that repo/package.\n \n 2. Ensure you have the msysgit environment in your path, so you have\n    GNU Make, bash and perl available.\n@@ -33,18 +37,25 @@ The Steps of Build Git with VS2008\n        make common-cmds.h\n    to generate the common-cmds.h file needed to compile git.\n \n-4. Then either build Git with the GNU Make Makefile in the Git projects\n-   root\n+4. Then either\n+\n+     build Git with the GNU Make Makefile in the Git projects root\n        make MSVC=1\n-   or generate Visual Studio solution/projects (.sln/.vcproj) with the\n+   or\n+\n+   generate Visual Studio solution/projects (.sln/.vcproj) with the\n    command\n        perl contrib/buildsystems/generate -g Vcproj\n    and open and build the solution with the IDE\n        devenv git.sln /useenv\n-   or build with the IDE build engine directly from the command line\n+     or\n+\n+   build with the IDE build engine directly from the command line\n        devenv git.sln /useenv /build \"Release|Win32\"\n    The /useenv option is required, so Visual Studio picks up the\n    environment variables for the support libraries required to build\n    Git, which you set up in step 1.\n \n Done!\n+\n+Or, use the Msysgit msvc-build script; available from that project.\n-- \n2.3.1\n\n-- \n-- \n*** Please reply-to-all at all times ***\n*** (do not pretend to know who is subscribed and who is not) ***\n*** Please avoid top-posting. ***\nThe msysGit Wiki is here: https://github.com/msysgit/msysgit/wiki - Github accounts are free.\n\nYou received this message because you are subscribed to the Google\nGroups \"msysGit\" group.\nTo post to this group, send email to msysgit@googlegroups.com\nTo unsubscribe from this group, send email to\nmsysgit+unsubscribe@googlegroups.com\nFor more options, and view previous threads, visit this group at\nhttp://groups.google.com/group/msysgit?hl=en_US?hl=en\n\n--- \nYou received this message because you are subscribed to the Google Groups \"Git for Windows\" group.\nTo unsubscribe from this group and stop receiving emails from it, send an email to msysgit+unsubscribe@googlegroups.com.\nFor more options, visit https://groups.google.com/d/optout.\n"},{"id":"264794","messageId":"1435190633-2208-17-git-send-email-philipoakley@iee.org","threadId":"39715","inReplyTo":"1435190633-2208-1-git-send-email-philipoakley@iee.org","subject":"[PATCH 16/17] msvc-build: add complete Microsoft Visual C compilation script","fromName":"Philip Oakley","fromEmail":"philipoakley@iee.org","sentAt":"2015-06-25T00:03:52Z","receivedAt":"2015-06-25T00:03:52Z","isPatch":true,"sender":{"key":"philipoakley@iee.email","avatar":"https://avatars.githubusercontent.com/u/914343?v=4"},"body":"Implement the README to facilitate cross community development.\nInclude comments for those Windows folks not yet fully familiar\nwith bash commands.\n\nThis is identical to the msysgit script, except for the 'cd toplevel'\nstep, and comments for the edification of converts from Windows.\nOriginal author: Johannes Schindelin (2011-11-01 3142da4 : Add a script\nto make the MSVC build more convenient).\n\nSigned-off-by: Philip Oakley <philipoakley@iee.org>\n---\n\nTODO:\nAlso resolve the cleaning of newer VS2010 products.\n---\n compat/vcbuild/README             |  2 +-\n compat/vcbuild/scripts/msvc-build | 89 +++++++++++++++++++++++++++++++++++++++\n 2 files changed, 90 insertions(+), 1 deletion(-)\n create mode 100644 compat/vcbuild/scripts/msvc-build\n\ndiff --git a/compat/vcbuild/README b/compat/vcbuild/README\nindex 7548dc4..faaea69 100644\n--- a/compat/vcbuild/README\n+++ b/compat/vcbuild/README\n@@ -58,4 +58,4 @@ The Steps of Build Git with VS2008\n \n Done!\n \n-Or, use the Msysgit msvc-build script; available from that project.\n+Or, use the msvc-build script; available from /compat/vcbuild/scripts/.\ndiff --git a/compat/vcbuild/scripts/msvc-build b/compat/vcbuild/scripts/msvc-build\nnew file mode 100644\nindex 0000000..52b925d\n--- /dev/null\n+++ b/compat/vcbuild/scripts/msvc-build\n@@ -0,0 +1,89 @@\n+#!/bin/sh\n+\n+# This msvc-build command should be executed from the msysgit directory level\n+# This is so that the 'cd/git' step works and the subequent operations have the right msysgit super directory.\n+set -e # Exit immediately if a command exits with a nonzero exit status.\n+\n+gui=\n+clean=\n+while test $# -gt 0\n+do\n+\tcase \"$1\" in\n+\t--gui|--dev|--devenv|--vs|--visual-studio)\n+\t\tgui=t\n+\t\t;;\n+\tclean)\n+\t\tclean=t\n+\t\t;;\n+\t*)\n+\t\techo \"Usage: $0 [--vs] [clean]\" >&2\n+\t\texit 1\n+\t\t;;\n+\tesac\n+\tshift\n+done\n+\n+cd $(git rev-parse --show-toplevel)\n+\n+case \"$clean\" in\n+t)\n+\tcase \"$gui\" in\n+\tt)\n+\t\trm -rf git.sln libgit\n+\t\t# remove all the new VS2010 stuff as well\n+\t\t# rm -rf git.sdf\n+\t\t;;\n+\t'')\n+\t\tmake clean\n+\t\t# surely needs \"make clean MSVC=1\"\n+\t\t# otherwise it could assume the wrong make products [MinGW vs Windows].\n+\t\t;;\n+\tesac\n+\texit\n+\t;;\n+esac\n+\n+to_ignore=\"$(git ls-files --other --exclude-standard msvcgit msvc-build.cmd)\"\n+test -z \"$to_ignore\" || {\n+\tmkdir -p .git/info &&\n+\techo \"$to_ignore\" |\n+\tsed 's/^/\\//' >> .git/info/exclude\n+} || exit\n+\n+test -d msvcgit || git clone git://repo.or.cz/msvcgit.git\n+\n+vsvars=\n+# assume cl.exe will populate its relevant environment variables\n+# if cl.exe does not exist, populate vsvars with the most recent Visual Studio path\n+type cl.exe 2> /dev/null ||\n+vsvars=\"$(ls -t \\\n+\t\"$PROGRAMFILES/Microsoft Visual Studio\"*/Common7/Tools/vsvars32.bat |\n+\thead -n 1)\"\n+\n+\n+config_mak=\n+# if a config.mak file (dot, not underscore) exists, back it up,\n+# remember the backup file name in config_mak.\n+test -f config.mak &&\n+config_mak=config.mak.bup.$$ &&\n+mv config.mak $config_mak\n+\n+cat > config.mak << EOF\n+CFLAGS += -Imsvcgit/32bits/include\n+LDFLAGS += -Lmsvcgit/32bits/lib\n+EOF\n+\n+echo \"call \\\"$vsvars\\\"\" > msvc-build.cmd\n+if test -z \"$gui\"\n+then\n+\techo 'make MSVC=1' >> msvc-build.cmd\n+else\n+\techo 'perl contrib/buildsystems/generate -g Vcproj' >> msvc-build.cmd\n+\techo 'start git.sln' >> msvc-build.cmd\n+fi\n+\n+cmd /c msvc-build.cmd\n+\n+# if we made a backup file (name in config_mak), then restore it.\n+test -z \"$config_mak\" ||\n+mv $config_mak config.mak\n-- \n2.3.1\n\n-- \n-- \n*** Please reply-to-all at all times ***\n*** (do not pretend to know who is subscribed and who is not) ***\n*** Please avoid top-posting. ***\nThe msysGit Wiki is here: https://github.com/msysgit/msysgit/wiki - Github accounts are free.\n\nYou received this message because you are subscribed to the Google\nGroups \"msysGit\" group.\nTo post to this group, send email to msysgit@googlegroups.com\nTo unsubscribe from this group, send email to\nmsysgit+unsubscribe@googlegroups.com\nFor more options, and view previous threads, visit this group at\nhttp://groups.google.com/group/msysgit?hl=en_US?hl=en\n\n--- \nYou received this message because you are subscribed to the Google Groups \"Git for Windows\" group.\nTo unsubscribe from this group and stop receiving emails from it, send an email to msysgit+unsubscribe@googlegroups.com.\nFor more options, visit https://groups.google.com/d/optout.\n"},{"id":"264785","messageId":"1435190633-2208-18-git-send-email-philipoakley@iee.org","threadId":"39715","inReplyTo":"1435190633-2208-1-git-send-email-philipoakley@iee.org","subject":"[PATCH 17/17] config.mak.uname: add MSVC No_SafeExeceptionHandler option","fromName":"Philip Oakley","fromEmail":"philipoakley@iee.org","sentAt":"2015-06-25T00:03:53Z","receivedAt":"2015-06-25T00:03:53Z","isPatch":true,"sender":{"key":"philipoakley@iee.email","avatar":"https://avatars.githubusercontent.com/u/914343?v=4"},"body":"Signed-off-by: Philip Oakley <philipoakley@iee.org>\n---\n config.mak.uname | 9 +++++++++\n 1 file changed, 9 insertions(+)\n\ndiff --git a/config.mak.uname b/config.mak.uname\nindex 943c439..1c27828 100644\n--- a/config.mak.uname\n+++ b/config.mak.uname\n@@ -1,5 +1,9 @@\n # Platform specific Makefile tweaks based on uname detection\n \n+# Define NO_SAFESEH if you need MSVC/Visual Studio to ignore the lack of\n+# Microsoft's Safe Exception Handling in libraries (such as zlib).\n+# Typically required for VS2013+/32-bit compilation on Vista+ versions.\n+\n uname_S := $(shell sh -c 'uname -s 2>/dev/null || echo not')\n uname_M := $(shell sh -c 'uname -m 2>/dev/null || echo not')\n uname_O := $(shell sh -c 'uname -o 2>/dev/null || echo not')\n@@ -385,6 +389,11 @@ ifeq ($(uname_S),Windows)\n \tPTHREAD_LIBS =\n \tlib =\n \tBASIC_CFLAGS += -DPROTECT_NTFS_DEFAULT=1\n+\n+ifdef NO_SAFESEH\n+\tLDFLAGS += -SAFESEH:NO\n+endif\n+\n ifndef DEBUG\n \tBASIC_CFLAGS += -GL -Os -MD\n \tBASIC_LDFLAGS += -LTCG\n-- \n2.3.1\n\n-- \n-- \n*** Please reply-to-all at all times ***\n*** (do not pretend to know who is subscribed and who is not) ***\n*** Please avoid top-posting. ***\nThe msysGit Wiki is here: https://github.com/msysgit/msysgit/wiki - Github accounts are free.\n\nYou received this message because you are subscribed to the Google\nGroups \"msysGit\" group.\nTo post to this group, send email to msysgit@googlegroups.com\nTo unsubscribe from this group, send email to\nmsysgit+unsubscribe@googlegroups.com\nFor more options, and view previous threads, visit this group at\nhttp://groups.google.com/group/msysgit?hl=en_US?hl=en\n\n--- \nYou received this message because you are subscribed to the Google Groups \"Git for Windows\" group.\nTo unsubscribe from this group and stop receiving emails from it, send an email to msysgit+unsubscribe@googlegroups.com.\nFor more options, visit https://groups.google.com/d/optout.\n"},{"id":"264855","messageId":"xmqqh9pv258w.fsf@gitster.dls.corp.google.com","threadId":"39715","inReplyTo":"1435190633-2208-1-git-send-email-philipoakley@iee.org","subject":"Re: [PATCH 00/17] Make the msvc-build scripts work again","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2015-06-25T15:10:39Z","receivedAt":"2015-06-25T15:10:39Z","isPatch":true,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Philip Oakley <philipoakley@iee.org> writes:\n\n> Hopefully it's not too late in the cycle for a review of this contrib/compat\n> item.\n\nHas this been discussed in the Windows land and folks are all happy\nwith this change?  If so the only thing we would need review on the\nmain list is the top-level change outside compat/ and contrib/, so\nit may be possible to sneak it in before -rc1.\n\nOtherwise, no, but we can still polish it during the prerelease\nfreeze and aim to merge it in the first batch after the upcoming\nrelease.\n\n\n> Philip Oakley (17):\n>   .gitignore: improve MSVC ignore patterns\n>   .gitignore: ignore library directories created by MSVC VS2008\n>     buildsystem\n>   (msvc-build) Vcproj.pm: remove duplicate GUID\n>   Makefile: a dry-run can error out if no perl. Document the issue\n>   engine.pl: fix error message (lib->link)\n>   engine.pl: Avoid complications with perl support\n>   engine.pl: Properly accept quoted spaces in filenames\n>   engine.pl: Fix i18n -o option in msvc buildsystem generator\n>   engine.pl: ignore invalidcontinue.obj which is known to MSVC\n>   engine.pl: name the msvc buildsystem's makedry error file\n>   engine.pl: delete the captured stderr file if empty\n>   engine.pl: add debug line to capture the dry-run\n>   engine.pl: provide more debug print statements\n>   Vcproj.pm: list git.exe first to be startup project\n>   vcbuild/readme: Improve layout and reference msvc-build script\n>   msvc-build: add complete Microsoft Visual C compilation script\n>   config.mak.uname: add MSVC No_SafeExeceptionHandler option\n>\n>  .gitignore                                |  8 ++-\n>  Makefile                                  |  3 ++\n>  compat/vcbuild/README                     | 27 +++++++---\n>  compat/vcbuild/scripts/msvc-build         | 89 +++++++++++++++++++++++++++++++\n>  config.mak.uname                          |  9 ++++\n>  contrib/buildsystems/Generators/Vcproj.pm | 34 ++++++------\n>  contrib/buildsystems/engine.pl            | 37 ++++++++++---\n>  7 files changed, 174 insertions(+), 33 deletions(-)\n>  create mode 100644 compat/vcbuild/scripts/msvc-build\n\n\n>  mode change 100755 => 100644 contrib/buildsystems/engine.pl\n\nWhy?\n\n-- \n-- \n*** Please reply-to-all at all times ***\n*** (do not pretend to know who is subscribed and who is not) ***\n*** Please avoid top-posting. ***\nThe msysGit Wiki is here: https://github.com/msysgit/msysgit/wiki - Github accounts are free.\n\nYou received this message because you are subscribed to the Google\nGroups \"msysGit\" group.\nTo post to this group, send email to msysgit@googlegroups.com\nTo unsubscribe from this group, send email to\nmsysgit+unsubscribe@googlegroups.com\nFor more options, and view previous threads, visit this group at\nhttp://groups.google.com/group/msysgit?hl=en_US?hl=en\n\n--- \nYou received this message because you are subscribed to the Google Groups \"Git for Windows\" group.\nTo unsubscribe from this group and stop receiving emails from it, send an email to msysgit+unsubscribe@googlegroups.com.\nFor more options, visit https://groups.google.com/d/optout.\n"},{"id":"264856","messageId":"xmqqd20j253w.fsf@gitster.dls.corp.google.com","threadId":"39715","inReplyTo":"1435190633-2208-2-git-send-email-philipoakley@iee.org","subject":"Re: [PATCH 01/17] .gitignore: improve MSVC ignore patterns","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2015-06-25T15:13:39Z","receivedAt":"2015-06-25T15:13:39Z","isPatch":true,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Philip Oakley <philipoakley@iee.org> writes:\n\n> Add the Microsoft .manifest pattern, and correct the generic 'Debug'\n> and 'Release' directory patterns which were mechanically adjusted way\n> back in c591d5f (gitignore: root most patterns at the top-level directory,\n> 2009-10-26) to allow multi-level projects within the Git suite.\n>\n> Signed-off-by: Philip Oakley <philipoakley@iee.org>\n> ---\n>  .gitignore | 5 +++--\n>  1 file changed, 3 insertions(+), 2 deletions(-)\n>\n> diff --git a/.gitignore b/.gitignore\n> index 422c538..55498c1 100644\n> --- a/.gitignore\n> +++ b/.gitignore\n> @@ -246,5 +246,6 @@\n>  *.user\n>  *.idb\n>  *.pdb\n> -/Debug/\n> -/Release/\n> +*.manifest\n> +**/Debug/\n> +**/Release/\n\nWhy \"**/\" there?  Wouldn't\n\n*.manifest\nDebug/\nRelease/\n\nsuffice?\n\n-- \n-- \n*** Please reply-to-all at all times ***\n*** (do not pretend to know who is subscribed and who is not) ***\n*** Please avoid top-posting. ***\nThe msysGit Wiki is here: https://github.com/msysgit/msysgit/wiki - Github accounts are free.\n\nYou received this message because you are subscribed to the Google\nGroups \"msysGit\" group.\nTo post to this group, send email to msysgit@googlegroups.com\nTo unsubscribe from this group, send email to\nmsysgit+unsubscribe@googlegroups.com\nFor more options, and view previous threads, visit this group at\nhttp://groups.google.com/group/msysgit?hl=en_US?hl=en\n\n--- \nYou received this message because you are subscribed to the Google Groups \"Git for Windows\" group.\nTo unsubscribe from this group and stop receiving emails from it, send an email to msysgit+unsubscribe@googlegroups.com.\nFor more options, visit https://groups.google.com/d/optout.\n"},{"id":"264859","messageId":"xmqq8ub724ls.fsf@gitster.dls.corp.google.com","threadId":"39715","inReplyTo":"1435190633-2208-5-git-send-email-philipoakley@iee.org","subject":"Re: [PATCH 04/17] Makefile: a dry-run can error out if no perl. Document the issue","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2015-06-25T15:24:31Z","receivedAt":"2015-06-25T15:24:31Z","isPatch":true,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Philip Oakley <philipoakley@iee.org> writes:\n\n> A 'make -n' dry-run is used as part of the /compat/vcbuild and\n> /contrib/buildsystems code. The commit ee9be06 (perl: detect new files\n> in MakeMaker builds, 2012-07-27) was not aware of that dry-run usage\n> and thus would not execute the target.\n>\n> Add a comment to the make file stating the issue and the available\n> solutions of either NO_PERL or a '+recipe'.\n\nI am not sure what this patch is trying to achieve.\n\nIf you are not touching what this Makefile actually does, then I\nwould imagine that you are running the \"buildsystems code\" that\nactually drives 'make -n' with some \"available solution\" (perhaps\nyou are running 'make -n NO_PERL=NoThanks' or something like that)?\nThen instead of a command like this that nobody would read in this\nfile, the same command can instead go there to explain what the\n\"workaround\" (e.g. unusual-looking 'make -n NO_PERL=NoThanks') is\ndoing?\n\nI suspect you mean by +recipe that you modify this makefile to make\nsuch a workaround unnecessary?  If that is the case, why isn't such\na change actually be done with this commit, instead of a comment?\n\nI am not sure what this patch is trying to achieve.\n\nPuzzled...\n\n>\n> Signed-off-by: Philip Oakley <philipoakley@iee.org>\n> ---\n>  Makefile | 3 +++\n>  1 file changed, 3 insertions(+)\n>\n> diff --git a/Makefile b/Makefile\n> index 149f1c7..22108bb 100644\n> --- a/Makefile\n> +++ b/Makefile\n> @@ -1746,6 +1746,9 @@ $(SCRIPT_PERL_GEN): perl/perl.mak\n>  \n>  perl/perl.mak: perl/PM.stamp\n>  \n> +# 'make -n' (dry-run) will not execute this target which creates/updates the PM.stamp file.\n> +# To avoid the error of failing to find the target PM.stamp, either use NO_PERL=1 (YesPlease),\n> +# or add a leading '+' to the recipe '+$(QUIET_GEN)$(FIND) perl ...' so that it is executed.\n>  perl/PM.stamp: FORCE\n>  \t@$(FIND) perl -type f -name '*.pm' | sort >$@+ && \\\n>  \t{ cmp $@+ $@ >/dev/null 2>/dev/null || mv $@+ $@; } && \\\n> -- \n> 2.3.1\n>\n> -- \n\n-- \n-- \n*** Please reply-to-all at all times ***\n*** (do not pretend to know who is subscribed and who is not) ***\n*** Please avoid top-posting. ***\nThe msysGit Wiki is here: https://github.com/msysgit/msysgit/wiki - Github accounts are free.\n\nYou received this message because you are subscribed to the Google\nGroups \"msysGit\" group.\nTo post to this group, send email to msysgit@googlegroups.com\nTo unsubscribe from this group, send email to\nmsysgit+unsubscribe@googlegroups.com\nFor more options, and view previous threads, visit this group at\nhttp://groups.google.com/group/msysgit?hl=en_US?hl=en\n\n--- \nYou received this message because you are subscribed to the Google Groups \"Git for Windows\" group.\nTo unsubscribe from this group and stop receiving emails from it, send an email to msysgit+unsubscribe@googlegroups.com.\nFor more options, visit https://groups.google.com/d/optout.\n"},{"id":"264886","messageId":"D5232F937FAC41C89F2DB0806A5ABE7B@PhilipOakley","threadId":"39715","inReplyTo":"xmqqh9pv258w.fsf@gitster.dls.corp.google.com","subject":"Re: [PATCH 00/17] Make the msvc-build scripts work again","fromName":"Philip Oakley","fromEmail":"philipoakley@iee.org","sentAt":"2015-06-25T19:31:48Z","receivedAt":"2015-06-25T19:31:48Z","isPatch":true,"sender":{"key":"philipoakley@iee.email","avatar":"https://avatars.githubusercontent.com/u/914343?v=4"},"body":"From: \"Junio C Hamano\" <gitster@pobox.com>\n> Philip Oakley <philipoakley@iee.org> writes:\n>\n>> Hopefully it's not too late in the cycle for a review of this \n>> contrib/compat\n>> item.\n>\n> Has this been discussed in the Windows land and folks are all happy\n> with this change?  If so the only thing we would need review on the\n> main list is the top-level change outside compat/ and contrib/, so\n> it may be possible to sneak it in before -rc1.\n\nYes this had been discussed previously on the MsysGit list, and in the \nreferenced Pull Request [msysgit/#318] \nhttps://github.com/msysgit/git/pull/318/files.\n\nI had aspirations of a slightly bigger series that would also allow the \nVS compiled output to be installed but that had stalled, so I cut back \nto fixing the basic 'make it work' steps.\n\nThe series has been reordered/rebased, and the recently noticed 05/17 \nerr msg fix added.\n\nThe one unknown is the last patch [17] for the Windows Safe Exception \nHandling in that the default acceptability was flipped in VS2013 so that \nzlib became unacceptable to ceratain OS versions without the addition of \nthat option -SAFESEH:NO, but I haven't been able to test that myself (I \ndon't have a complaining system).\n\n>\n> Otherwise, no, but we can still polish it during the prerelease\n> freeze and aim to merge it in the first batch after the upcoming\n> release.\n>\n>\n>> Philip Oakley (17):\n>>   .gitignore: improve MSVC ignore patterns\n>>   .gitignore: ignore library directories created by MSVC VS2008\n>>     buildsystem\n>>   (msvc-build) Vcproj.pm: remove duplicate GUID\n>>   Makefile: a dry-run can error out if no perl. Document the issue\n>>   engine.pl: fix error message (lib->link)\n>>   engine.pl: Avoid complications with perl support\n>>   engine.pl: Properly accept quoted spaces in filenames\n>>   engine.pl: Fix i18n -o option in msvc buildsystem generator\n>>   engine.pl: ignore invalidcontinue.obj which is known to MSVC\n>>   engine.pl: name the msvc buildsystem's makedry error file\n>>   engine.pl: delete the captured stderr file if empty\n>>   engine.pl: add debug line to capture the dry-run\n>>   engine.pl: provide more debug print statements\n>>   Vcproj.pm: list git.exe first to be startup project\n>>   vcbuild/readme: Improve layout and reference msvc-build script\n>>   msvc-build: add complete Microsoft Visual C compilation script\n>>   config.mak.uname: add MSVC No_SafeExeceptionHandler option\n>>\n>>  .gitignore                                |  8 ++-\n>>  Makefile                                  |  3 ++\n>>  compat/vcbuild/README                     | 27 +++++++---\n>>  compat/vcbuild/scripts/msvc-build         | 89 \n>> +++++++++++++++++++++++++++++++\n>>  config.mak.uname                          |  9 ++++\n>>  contrib/buildsystems/Generators/Vcproj.pm | 34 ++++++------\n>>  contrib/buildsystems/engine.pl            | 37 ++++++++++---\n>>  7 files changed, 174 insertions(+), 33 deletions(-)\n>>  create mode 100644 compat/vcbuild/scripts/msvc-build\n>\n>\n>>  mode change 100755 => 100644 contrib/buildsystems/engine.pl\n>\n> Why?\n\nMistake on/by Windows? - My mistake, I hadn't noticed it had happened.\n\nI can search out the change step and re-roll.\n\n> --\nPhilip \n\n-- \n-- \n*** Please reply-to-all at all times ***\n*** (do not pretend to know who is subscribed and who is not) ***\n*** Please avoid top-posting. ***\nThe msysGit Wiki is here: https://github.com/msysgit/msysgit/wiki - Github accounts are free.\n\nYou received this message because you are subscribed to the Google\nGroups \"msysGit\" group.\nTo post to this group, send email to msysgit@googlegroups.com\nTo unsubscribe from this group, send email to\nmsysgit+unsubscribe@googlegroups.com\nFor more options, and view previous threads, visit this group at\nhttp://groups.google.com/group/msysgit?hl=en_US?hl=en\n\n--- \nYou received this message because you are subscribed to the Google Groups \"Git for Windows\" group.\nTo unsubscribe from this group and stop receiving emails from it, send an email to msysgit+unsubscribe@googlegroups.com.\nFor more options, visit https://groups.google.com/d/optout.\n"},{"id":"264887","messageId":"DDC36A35EBC548718762478AA7B80F67@PhilipOakley","threadId":"39715","inReplyTo":"xmqqd20j253w.fsf@gitster.dls.corp.google.com","subject":"Re: [PATCH 01/17] .gitignore: improve MSVC ignore patterns","fromName":"Philip Oakley","fromEmail":"philipoakley@iee.org","sentAt":"2015-06-25T19:32:10Z","receivedAt":"2015-06-25T19:32:10Z","isPatch":true,"sender":{"key":"philipoakley@iee.email","avatar":"https://avatars.githubusercontent.com/u/914343?v=4"},"body":"From: \"Junio C Hamano\" <gitster@pobox.com>\n> Philip Oakley <philipoakley@iee.org> writes:\n>\n>> Add the Microsoft .manifest pattern, and correct the generic 'Debug'\n>> and 'Release' directory patterns which were mechanically adjusted way\n>> back in c591d5f (gitignore: root most patterns at the top-level \n>> directory,\n>> 2009-10-26) to allow multi-level projects within the Git suite.\n>>\n>> Signed-off-by: Philip Oakley <philipoakley@iee.org>\n>> ---\n>>  .gitignore | 5 +++--\n>>  1 file changed, 3 insertions(+), 2 deletions(-)\n>>\n>> diff --git a/.gitignore b/.gitignore\n>> index 422c538..55498c1 100644\n>> --- a/.gitignore\n>> +++ b/.gitignore\n>> @@ -246,5 +246,6 @@\n>>  *.user\n>>  *.idb\n>>  *.pdb\n>> -/Debug/\n>> -/Release/\n>> +*.manifest\n>> +**/Debug/\n>> +**/Release/\n>\n> Why \"**/\" there?  Wouldn't\n>\n> *.manifest\n> Debug/\n> Release/\n>\n> suffice?\n>\nProbably. I was thinking of the 'at any level' aspect because some of \nthe 'projects' appeared two levels down and weren't caught by the rooted \nignore. Can change.\n\n--\nPhilip \n\n-- \n-- \n*** Please reply-to-all at all times ***\n*** (do not pretend to know who is subscribed and who is not) ***\n*** Please avoid top-posting. ***\nThe msysGit Wiki is here: https://github.com/msysgit/msysgit/wiki - Github accounts are free.\n\nYou received this message because you are subscribed to the Google\nGroups \"msysGit\" group.\nTo post to this group, send email to msysgit@googlegroups.com\nTo unsubscribe from this group, send email to\nmsysgit+unsubscribe@googlegroups.com\nFor more options, and view previous threads, visit this group at\nhttp://groups.google.com/group/msysgit?hl=en_US?hl=en\n\n--- \nYou received this message because you are subscribed to the Google Groups \"Git for Windows\" group.\nTo unsubscribe from this group and stop receiving emails from it, send an email to msysgit+unsubscribe@googlegroups.com.\nFor more options, visit https://groups.google.com/d/optout.\n"},{"id":"264888","messageId":"DBFC4D88D6F34023BA43F5F10134331E@PhilipOakley","threadId":"39715","inReplyTo":"xmqq8ub724ls.fsf@gitster.dls.corp.google.com","subject":"Re: [PATCH 04/17] Makefile: a dry-run can error out if no perl. Document the issue","fromName":"Philip Oakley","fromEmail":"philipoakley@iee.org","sentAt":"2015-06-25T19:33:04Z","receivedAt":"2015-06-25T19:33:04Z","isPatch":true,"sender":{"key":"philipoakley@iee.email","avatar":"https://avatars.githubusercontent.com/u/914343?v=4"},"body":"From: \"Junio C Hamano\" <gitster@pobox.com>\n> Philip Oakley <philipoakley@iee.org> writes:\n>\n>> A 'make -n' dry-run is used as part of the /compat/vcbuild and\n>> /contrib/buildsystems code. The commit ee9be06 (perl: detect new \n>> files\n>> in MakeMaker builds, 2012-07-27) was not aware of that dry-run usage\n>> and thus would not execute the target.\n>>\n>> Add a comment to the make file stating the issue and the available\n>> solutions of either NO_PERL or a '+recipe'.\n>\n> I am not sure what this patch is trying to achieve.\n\nIt was probably a bit of 'don't mess with working code', given that I'd \nused the NO_PERL solution, rather 'document the issue'. The issue had me \nstuck for a while. The possible use of '+' came later when driving down \nthrough the Makefile manual.\n\n>\n> If you are not touching what this Makefile actually does, then I\n> would imagine that you are running the \"buildsystems code\" that\n> actually drives 'make -n' with some \"available solution\" (perhaps\n> you are running 'make -n NO_PERL=NoThanks' or something like that)?\n> Then instead of a command like this that nobody would read in this\n> file, the same command can instead go there to explain what the\n> \"workaround\" (e.g. unusual-looking 'make -n NO_PERL=NoThanks') is\n> doing?\n>\n> I suspect you mean by +recipe that you modify this makefile to make\n> such a workaround unnecessary?  If that is the case, why isn't such\n> a change actually be done with this commit, instead of a comment?\n\nYes.  See above about the lack of 'fearless coding'; been working in \nreal world engineering too long ;-)\n\n>\n> I am not sure what this patch is trying to achieve.\n>\n> Puzzled...\n>\n>>\n>> Signed-off-by: Philip Oakley <philipoakley@iee.org>\n>> ---\n>>  Makefile | 3 +++\n>>  1 file changed, 3 insertions(+)\n>>\n>> diff --git a/Makefile b/Makefile\n>> index 149f1c7..22108bb 100644\n>> --- a/Makefile\n>> +++ b/Makefile\n>> @@ -1746,6 +1746,9 @@ $(SCRIPT_PERL_GEN): perl/perl.mak\n>>\n>>  perl/perl.mak: perl/PM.stamp\n>>\n>> +# 'make -n' (dry-run) will not execute this target which \n>> creates/updates the PM.stamp file.\n>> +# To avoid the error of failing to find the target PM.stamp, either \n>> use NO_PERL=1 (YesPlease),\n>> +# or add a leading '+' to the recipe '+$(QUIET_GEN)$(FIND) perl ...' \n>> so that it is executed.\n>>  perl/PM.stamp: FORCE\n>>  @$(FIND) perl -type f -name '*.pm' | sort >$@+ && \\\n>>  { cmp $@+ $@ >/dev/null 2>/dev/null || mv $@+ $@; } && \\\n>> -- \n>> 2.3.1\n>>\n>> -- \n> --\n> To unsubscribe from this list: send the line \"unsubscribe git\" in\n> the body of a message to majordomo@vger.kernel.org\n> More majordomo info at  http://vger.kernel.org/majordomo-info.html\n> \n"},{"id":"264892","messageId":"xmqqmvzny1xe.fsf@gitster.dls.corp.google.com","threadId":"39715","inReplyTo":"DBFC4D88D6F34023BA43F5F10134331E@PhilipOakley","subject":"Re: [PATCH 04/17] Makefile: a dry-run can error out if no perl. Document the issue","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2015-06-25T20:21:17Z","receivedAt":"2015-06-25T20:21:17Z","isPatch":true,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"\"Philip Oakley\" <philipoakley@iee.org> writes:\n\n> From: \"Junio C Hamano\" <gitster@pobox.com>\n>>\n>> I am not sure what this patch is trying to achieve.\n>\n> It was probably a bit of 'don't mess with working code', given that\n> I'd used the NO_PERL solution, rather 'document the issue'....\n\nThen this part applies, I think.\n\n>> If you are not touching what this Makefile actually does, then I\n>> would imagine that you are running the \"buildsystems code\" that\n>> actually drives 'make -n' with some \"available solution\" (perhaps\n>> you are running 'make -n NO_PERL=NoThanks' or something like that)?\n>> Then instead of a command like this that nobody would read in this\n>> file, the same command can instead go there to explain what the\n>> \"workaround\" (e.g. unusual-looking 'make -n NO_PERL=NoThanks') is\n>> doing?\n\nThanks.\n\n-- \n-- \n*** Please reply-to-all at all times ***\n*** (do not pretend to know who is subscribed and who is not) ***\n*** Please avoid top-posting. ***\nThe msysGit Wiki is here: https://github.com/msysgit/msysgit/wiki - Github accounts are free.\n\nYou received this message because you are subscribed to the Google\nGroups \"msysGit\" group.\nTo post to this group, send email to msysgit@googlegroups.com\nTo unsubscribe from this group, send email to\nmsysgit+unsubscribe@googlegroups.com\nFor more options, and view previous threads, visit this group at\nhttp://groups.google.com/group/msysgit?hl=en_US?hl=en\n\n--- \nYou received this message because you are subscribed to the Google Groups \"Git for Windows\" group.\nTo unsubscribe from this group and stop receiving emails from it, send an email to msysgit+unsubscribe@googlegroups.com.\nFor more options, visit https://groups.google.com/d/optout.\n"},{"id":"264893","messageId":"xmqqioaby1uo.fsf@gitster.dls.corp.google.com","threadId":"39715","inReplyTo":"DDC36A35EBC548718762478AA7B80F67@PhilipOakley","subject":"Re: [PATCH 01/17] .gitignore: improve MSVC ignore patterns","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2015-06-25T20:22:55Z","receivedAt":"2015-06-25T20:22:55Z","isPatch":true,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"\"Philip Oakley\" <philipoakley@iee.org> writes:\n\n>> Debug/\n>> Release/\n>>\n>> suffice?\n>>\n> Probably. I was thinking of the 'at any level' aspect...\n\nYeah, that is exactly the difference between rooted \"/Debug/\" and\n\"Debug/\" ;-).\n\n-- \n-- \n*** Please reply-to-all at all times ***\n*** (do not pretend to know who is subscribed and who is not) ***\n*** Please avoid top-posting. ***\nThe msysGit Wiki is here: https://github.com/msysgit/msysgit/wiki - Github accounts are free.\n\nYou received this message because you are subscribed to the Google\nGroups \"msysGit\" group.\nTo post to this group, send email to msysgit@googlegroups.com\nTo unsubscribe from this group, send email to\nmsysgit+unsubscribe@googlegroups.com\nFor more options, and view previous threads, visit this group at\nhttp://groups.google.com/group/msysgit?hl=en_US?hl=en\n\n--- \nYou received this message because you are subscribed to the Google Groups \"Git for Windows\" group.\nTo unsubscribe from this group and stop receiving emails from it, send an email to msysgit+unsubscribe@googlegroups.com.\nFor more options, visit https://groups.google.com/d/optout.\n"},{"id":"264917","messageId":"45344004B4CA4B16BD7FB174B4849D77@PhilipOakley","threadId":"39715","inReplyTo":"xmqqmvzny1xe.fsf@gitster.dls.corp.google.com","subject":"Re: [PATCH 04/17] Makefile: a dry-run can error out if no perl. Document the issue","fromName":"Philip Oakley","fromEmail":"philipoakley@iee.org","sentAt":"2015-06-25T23:34:38Z","receivedAt":"2015-06-25T23:34:38Z","isPatch":true,"sender":{"key":"philipoakley@iee.email","avatar":"https://avatars.githubusercontent.com/u/914343?v=4"},"body":"From: \"Junio C Hamano\" <gitster@pobox.com>\n> \"Philip Oakley\" <philipoakley@iee.org> writes:\n>\n>> From: \"Junio C Hamano\" <gitster@pobox.com>\n>>>\n>>> I am not sure what this patch is trying to achieve.\n>>\n>> It was probably a bit of 'don't mess with working code', given that\n>> I'd used the NO_PERL solution, rather 'document the issue'....\n>\n> Then this part applies, I think.\n>\n>>> If you are not touching what this Makefile actually does, then I\n>>> would imagine that you are running the \"buildsystems code\" that\n>>> actually drives 'make -n' with some \"available solution\" (perhaps\n>>> you are running 'make -n NO_PERL=NoThanks' or something like that)?\n>>> Then instead of a command like this that nobody would read in this\n>>> file, the same command can instead go there to explain what the\n>>> \"workaround\" (e.g. unusual-looking 'make -n NO_PERL=NoThanks') is\n>>> doing?\n>\nI was more of the view that this was about prevention (here), rather\nthan retrospective explanation of the code (there).\n\nIn my case the errors were showing problems with the PM.stamp in the\nmakefile (I didn't have the solution at that point).\n\nSo either a short comment \"#  consider using 'NO_PERL=YesPlease' for dry\nrun invocations\" (beware your double negative ;-), or the addition of\nthe '+recipe', would still be my preferred change, rather than leaving\nthe open manhole for others to fall into.\n\nThe thread on my difficulties is at $gmane/263656 (2015-02-10 22:51)\n\"\n    At the moment I'm getting (on my old WinXP machine, using Msysgit\n    1.9.5 as a basis)\n\n    $ make -n MSVC=1 V=1 1>makedry.txt\n    make[1]: *** No rule to make target `PM.stamp', needed by \n`perl.mak'.\n    Stop.\n    make: *** [perl/perl.mak] Error 2\n\"\nAs you can see, at that time the place to look would be the makefile,\nso I would do think a 'fix' there would still be appropriate.\n\nDo you have a preference among the three options (comment, +recipe, \ndrop)?\n--\nPhilip\n\n-- \n-- \n*** Please reply-to-all at all times ***\n*** (do not pretend to know who is subscribed and who is not) ***\n*** Please avoid top-posting. ***\nThe msysGit Wiki is here: https://github.com/msysgit/msysgit/wiki - Github accounts are free.\n\nYou received this message because you are subscribed to the Google\nGroups \"msysGit\" group.\nTo post to this group, send email to msysgit@googlegroups.com\nTo unsubscribe from this group, send email to\nmsysgit+unsubscribe@googlegroups.com\nFor more options, and view previous threads, visit this group at\nhttp://groups.google.com/group/msysgit?hl=en_US?hl=en\n\n--- \nYou received this message because you are subscribed to the Google Groups \"Git for Windows\" group.\nTo unsubscribe from this group and stop receiving emails from it, send an email to msysgit+unsubscribe@googlegroups.com.\nFor more options, visit https://groups.google.com/d/optout.\n"},{"id":"265037","messageId":"CAPig+cTpJ2cz49guBFOHpOsP1UEip=JV-c2fPyjfdSegzZACJQ@mail.gmail.com","threadId":"39715","inReplyTo":"1435190633-2208-4-git-send-email-philipoakley@iee.org","subject":"Re: [PATCH 03/17] (msvc-build) Vcproj.pm: remove duplicate GUID","fromName":"Eric Sunshine","fromEmail":"sunshine@sunshineco.com","sentAt":"2015-06-28T03:05:41Z","receivedAt":"2015-06-28T03:05:41Z","isPatch":true,"sender":{"key":"sunshine@sunshineco.com","avatar":"https://avatars.githubusercontent.com/u/163641?v=4"},"body":"On Wed, Jun 24, 2015 at 8:03 PM, Philip Oakley <philipoakley@iee.org> wrote:\n> Delete the duplicated GUID from the generation code for the Visual Studio\n> .sln project file.\n>\n> The duplicate GUID tended to be allocated to test-svn-fe, which was then\n> ignored by Visual Studio / MSVC, and it's omission from the build never\n\ns/it's/its/\n\n> noticed.\n>\n> Signed-off-by: Philip Oakley <philipoakley@iee.org>\n> ---\n>  contrib/buildsystems/Generators/Vcproj.pm | 1 -\n>  1 file changed, 1 deletion(-)\n>\n> diff --git a/contrib/buildsystems/Generators/Vcproj.pm b/contrib/buildsystems/Generators/Vcproj.pm\n> index cfa74ad..1b01d58 100644\n> --- a/contrib/buildsystems/Generators/Vcproj.pm\n> +++ b/contrib/buildsystems/Generators/Vcproj.pm\n> @@ -52,7 +52,6 @@ my @GUIDS = (\n>      \"{00785268-A9CC-4E40-AC29-BAC0019159CE}\",\n>      \"{4C06F56A-DCDB-46A6-B67C-02339935CF12}\",\n>      \"{3A62D3FD-519E-4EC9-8171-D2C1BFEA022F}\",\n> -    \"{3A62D3FD-519E-4EC9-8171-D2C1BFEA022F}\",\n>      \"{9392EB58-D7BA-410B-B1F0-B2FAA6BC89A7}\",\n>      \"{2ACAB2D5-E0CE-4027-BCA0-D78B2D7A6C66}\",\n>      \"{86E216C3-43CE-481A-BCB2-BE5E62850635}\",\n> --\n> 2.3.1\n\n-- \n-- \n*** Please reply-to-all at all times ***\n*** (do not pretend to know who is subscribed and who is not) ***\n*** Please avoid top-posting. ***\nThe msysGit Wiki is here: https://github.com/msysgit/msysgit/wiki - Github accounts are free.\n\nYou received this message because you are subscribed to the Google\nGroups \"msysGit\" group.\nTo post to this group, send email to msysgit@googlegroups.com\nTo unsubscribe from this group, send email to\nmsysgit+unsubscribe@googlegroups.com\nFor more options, and view previous threads, visit this group at\nhttp://groups.google.com/group/msysgit?hl=en_US?hl=en\n\n--- \nYou received this message because you are subscribed to the Google Groups \"Git for Windows\" group.\nTo unsubscribe from this group and stop receiving emails from it, send an email to msysgit+unsubscribe@googlegroups.com.\nFor more options, visit https://groups.google.com/d/optout.\n"},{"id":"265045","messageId":"27766BC958B74F8C805221782F93B2DE@PhilipOakley","threadId":"39715","inReplyTo":"CAPig+cTpJ2cz49guBFOHpOsP1UEip=JV-c2fPyjfdSegzZACJQ@mail.gmail.com","subject":"Re: [PATCH 03/17] (msvc-build) Vcproj.pm: remove duplicate GUID","fromName":"Philip Oakley","fromEmail":"philipoakley@iee.org","sentAt":"2015-06-28T08:44:18Z","receivedAt":"2015-06-28T08:44:18Z","isPatch":true,"sender":{"key":"philipoakley@iee.email","avatar":"https://avatars.githubusercontent.com/u/914343?v=4"},"body":"From: \"Eric Sunshine\" <sunshine@sunshineco.com>\n> On Wed, Jun 24, 2015 at 8:03 PM, Philip Oakley <philipoakley@iee.org> \n> wrote:\n>> Delete the duplicated GUID from the generation code for the Visual \n>> Studio\n>> .sln project file.\n>>\n>> The duplicate GUID tended to be allocated to test-svn-fe, which was \n>> then\n>> ignored by Visual Studio / MSVC, and it's omission from the build \n>> never\n>\n> s/it's/its/\n\nThanks, will fix.\n>\n>> noticed.\n>>\n>> Signed-off-by: Philip Oakley <philipoakley@iee.org>\n>> ---\n>>  contrib/buildsystems/Generators/Vcproj.pm | 1 -\n>>  1 file changed, 1 deletion(-)\n>>\n>> diff --git a/contrib/buildsystems/Generators/Vcproj.pm \n>> b/contrib/buildsystems/Generators/Vcproj.pm\n>> index cfa74ad..1b01d58 100644\n>> --- a/contrib/buildsystems/Generators/Vcproj.pm\n>> +++ b/contrib/buildsystems/Generators/Vcproj.pm\n>> @@ -52,7 +52,6 @@ my @GUIDS = (\n>>      \"{00785268-A9CC-4E40-AC29-BAC0019159CE}\",\n>>      \"{4C06F56A-DCDB-46A6-B67C-02339935CF12}\",\n>>      \"{3A62D3FD-519E-4EC9-8171-D2C1BFEA022F}\",\n>> -    \"{3A62D3FD-519E-4EC9-8171-D2C1BFEA022F}\",\n>>      \"{9392EB58-D7BA-410B-B1F0-B2FAA6BC89A7}\",\n>>      \"{2ACAB2D5-E0CE-4027-BCA0-D78B2D7A6C66}\",\n>>      \"{86E216C3-43CE-481A-BCB2-BE5E62850635}\",\n>> --\n>> 2.3.1\n> \n\n-- \n-- \n*** Please reply-to-all at all times ***\n*** (do not pretend to know who is subscribed and who is not) ***\n*** Please avoid top-posting. ***\nThe msysGit Wiki is here: https://github.com/msysgit/msysgit/wiki - Github accounts are free.\n\nYou received this message because you are subscribed to the Google\nGroups \"msysGit\" group.\nTo post to this group, send email to msysgit@googlegroups.com\nTo unsubscribe from this group, send email to\nmsysgit+unsubscribe@googlegroups.com\nFor more options, and view previous threads, visit this group at\nhttp://groups.google.com/group/msysgit?hl=en_US?hl=en\n\n--- \nYou received this message because you are subscribed to the Google Groups \"Git for Windows\" group.\nTo unsubscribe from this group and stop receiving emails from it, send an email to msysgit+unsubscribe@googlegroups.com.\nFor more options, visit https://groups.google.com/d/optout.\n"},{"id":"265190","messageId":"5591B845.8050201@gmail.com","threadId":"39715","inReplyTo":"1435190633-2208-14-git-send-email-philipoakley@iee.org","subject":"Re: [PATCH 13/17] engine.pl: provide more debug print statements","fromName":"Sebastian Schuberth","fromEmail":"sschuberth@gmail.com","sentAt":"2015-06-29T21:27:33Z","receivedAt":"2015-06-29T21:27:33Z","isPatch":true,"sender":{"key":"sschuberth@gmail.com","avatar":"https://avatars.githubusercontent.com/u/349154?v=4"},"body":"On 25.06.2015 02:03, Philip Oakley wrote:\n\n> --- a/contrib/buildsystems/engine.pl\n> +++ b/contrib/buildsystems/engine.pl\n> @@ -41,6 +41,7 @@ EOM\n>   # Parse command-line options\n>   while (@ARGV) {\n>       my $arg = shift @ARGV;\n> +\t#print \"Arg: $arg \\n\";\n>       if (\"$arg\" eq \"-h\" || \"$arg\" eq \"--help\" || \"$arg\" eq \"-?\") {\n>   \tshowUsage();\n>   \texit(0);\n> @@ -129,6 +130,7 @@ sub parseMakeOutput\n>       print \"Parsing GNU Make output to figure out build structure...\\n\";\n>       my $line = 0;\n>       while (my $text = shift @makedry) {\n> +\t\t#print \"Make: $text\\n\"; # show the makedry line\n\nPlease never commit code that's been commented out. Also see\n\nhttp://dev.solita.fi/2013/07/04/whats-in-a-good-commit.html\n\n;-)\n\n-- \nSebastian Schuberth\n\n-- \n-- \n*** Please reply-to-all at all times ***\n*** (do not pretend to know who is subscribed and who is not) ***\n*** Please avoid top-posting. ***\nThe msysGit Wiki is here: https://github.com/msysgit/msysgit/wiki - Github accounts are free.\n\nYou received this message because you are subscribed to the Google\nGroups \"msysGit\" group.\nTo post to this group, send email to msysgit@googlegroups.com\nTo unsubscribe from this group, send email to\nmsysgit+unsubscribe@googlegroups.com\nFor more options, and view previous threads, visit this group at\nhttp://groups.google.com/group/msysgit?hl=en_US?hl=en\n\n--- \nYou received this message because you are subscribed to the Google Groups \"Git for Windows\" group.\nTo unsubscribe from this group and stop receiving emails from it, send an email to msysgit+unsubscribe@googlegroups.com.\nFor more options, visit https://groups.google.com/d/optout.\n"},{"id":"265193","messageId":"5591B92A.9010907@gmail.com","threadId":"39715","inReplyTo":"1435190633-2208-14-git-send-email-philipoakley@iee.org","subject":"Re: [PATCH 13/17] engine.pl: provide more debug print statements","fromName":"Sebastian Schuberth","fromEmail":"sschuberth@gmail.com","sentAt":"2015-06-29T21:31:22Z","receivedAt":"2015-06-29T21:31:22Z","isPatch":true,"sender":{"key":"sschuberth@gmail.com","avatar":"https://avatars.githubusercontent.com/u/349154?v=4"},"body":"On 25.06.2015 02:03, Philip Oakley wrote:\n\n> --- a/contrib/buildsystems/engine.pl\n> +++ b/contrib/buildsystems/engine.pl\n> @@ -41,6 +41,7 @@ EOM\n>   # Parse command-line options\n>   while (@ARGV) {\n>       my $arg = shift @ARGV;\n> +\t#print \"Arg: $arg \\n\";\n>       if (\"$arg\" eq \"-h\" || \"$arg\" eq \"--help\" || \"$arg\" eq \"-?\") {\n>   \tshowUsage();\n>   \texit(0);\n> @@ -129,6 +130,7 @@ sub parseMakeOutput\n>       print \"Parsing GNU Make output to figure out build structure...\\n\";\n>       my $line = 0;\n>       while (my $text = shift @makedry) {\n> +\t\t#print \"Make: $text\\n\"; # show the makedry line\n\nPlease never commit code that's been commented out. Also see\n\nhttp://dev.solita.fi/2013/07/04/whats-in-a-good-commit.html\n\n;-)\n\n-- \nSebastian Schuberth\n\n-- \n-- \n*** Please reply-to-all at all times ***\n*** (do not pretend to know who is subscribed and who is not) ***\n*** Please avoid top-posting. ***\nThe msysGit Wiki is here: https://github.com/msysgit/msysgit/wiki - Github accounts are free.\n\nYou received this message because you are subscribed to the Google\nGroups \"msysGit\" group.\nTo post to this group, send email to msysgit@googlegroups.com\nTo unsubscribe from this group, send email to\nmsysgit+unsubscribe@googlegroups.com\nFor more options, and view previous threads, visit this group at\nhttp://groups.google.com/group/msysgit?hl=en_US?hl=en\n\n--- \nYou received this message because you are subscribed to the Google Groups \"Git for Windows\" group.\nTo unsubscribe from this group and stop receiving emails from it, send an email to msysgit+unsubscribe@googlegroups.com.\nFor more options, visit https://groups.google.com/d/optout.\n"},{"id":"265192","messageId":"5591B9AF.2000506@gmail.com","threadId":"39715","inReplyTo":"1435190633-2208-14-git-send-email-philipoakley@iee.org","subject":"Re: [PATCH 13/17] engine.pl: provide more debug print statements","fromName":"Sebastian Schuberth","fromEmail":"sschuberth@gmail.com","sentAt":"2015-06-29T21:33:35Z","receivedAt":"2015-06-29T21:33:35Z","isPatch":true,"sender":{"key":"sschuberth@gmail.com","avatar":"https://avatars.githubusercontent.com/u/349154?v=4"},"body":"On 25.06.2015 02:03, Philip Oakley wrote:\n\n> --- a/contrib/buildsystems/engine.pl\n> +++ b/contrib/buildsystems/engine.pl\n> @@ -41,6 +41,7 @@ EOM\n>   # Parse command-line options\n>   while (@ARGV) {\n>       my $arg = shift @ARGV;\n> +\t#print \"Arg: $arg \\n\";\n>       if (\"$arg\" eq \"-h\" || \"$arg\" eq \"--help\" || \"$arg\" eq \"-?\") {\n>   \tshowUsage();\n>   \texit(0);\n> @@ -129,6 +130,7 @@ sub parseMakeOutput\n>       print \"Parsing GNU Make output to figure out build structure...\\n\";\n>       my $line = 0;\n>       while (my $text = shift @makedry) {\n> +\t\t#print \"Make: $text\\n\"; # show the makedry line\n\nPlease never commit code that's been commented out. Also see\n\nhttp://dev.solita.fi/2013/07/04/whats-in-a-good-commit.html\n\n;-)\n\n-- \nSebastian Schuberth\n\n-- \n-- \n*** Please reply-to-all at all times ***\n*** (do not pretend to know who is subscribed and who is not) ***\n*** Please avoid top-posting. ***\nThe msysGit Wiki is here: https://github.com/msysgit/msysgit/wiki - Github accounts are free.\n\nYou received this message because you are subscribed to the Google\nGroups \"msysGit\" group.\nTo post to this group, send email to msysgit@googlegroups.com\nTo unsubscribe from this group, send email to\nmsysgit+unsubscribe@googlegroups.com\nFor more options, and view previous threads, visit this group at\nhttp://groups.google.com/group/msysgit?hl=en_US?hl=en\n\n--- \nYou received this message because you are subscribed to the Google Groups \"Git for Windows\" group.\nTo unsubscribe from this group and stop receiving emails from it, send an email to msysgit+unsubscribe@googlegroups.com.\nFor more options, visit https://groups.google.com/d/optout.\n"},{"id":"265778","messageId":"A555E0A67C1549A49531AD2A94879999@PhilipOakley","threadId":"39715","inReplyTo":"5591B845.8050201@gmail.com","subject":"Re: Re: [PATCH 13/17] engine.pl: provide more debug print statements","fromName":"Philip Oakley","fromEmail":"philipoakley@iee.org","sentAt":"2015-07-07T22:18:54Z","receivedAt":"2015-07-07T22:18:54Z","isPatch":true,"sender":{"key":"philipoakley@iee.email","avatar":"https://avatars.githubusercontent.com/u/914343?v=4"},"body":"From: \"Sebastian Schuberth\" <sschuberth@gmail.com>\n> On 25.06.2015 02:03, Philip Oakley wrote:\n>\n>> --- a/contrib/buildsystems/engine.pl\n>> +++ b/contrib/buildsystems/engine.pl\n>> @@ -41,6 +41,7 @@ EOM\n>>   # Parse command-line options\n>>   while (@ARGV) {\n>>       my $arg = shift @ARGV;\n>> + #print \"Arg: $arg \\n\";\n>>       if (\"$arg\" eq \"-h\" || \"$arg\" eq \"--help\" || \"$arg\" eq \"-?\") {\n>>   showUsage();\n>>   exit(0);\n>> @@ -129,6 +130,7 @@ sub parseMakeOutput\n>>       print \"Parsing GNU Make output to figure out build\n>> structure...\\n\";\n>>       my $line = 0;\n>>       while (my $text = shift @makedry) {\n>> + #print \"Make: $text\\n\"; # show the makedry line\n>\n> Please never commit code that's been commented out. Also see\n>\n> http://dev.solita.fi/2013/07/04/whats-in-a-good-commit.html\n>\n> ;-)\n\nThe gif was fun, even if it's a little OTT. It does smack of religious\ndogma though ;-)\n\n>\n> -- \n\nHi Sebastian,\n\nIt's \"deactivated code\", not dead code [1].\n\nI'd deliberately included this 'code', as per the commit message because\nI saw this as a clear part of aiding future maintenance, and it matches\nthe rest of the code style, i.e. the judicious placement of a comment\nthat says 'here's the place to pick out the status when debugging' -\nperhaps it's my engineering experience that sees the benefits.\n\nThese were the key debug points I used - other's I've removed from the \nseries.\n\nPhilip\n\n\n[1] In one of the replies to\nhttp://embeddedgurus.com/barr-code/2013/02/dead-code-the-law-and-unintended-consequences/\n\n:>> as per DO178B safety critical software development guideline\ndocument Terms \"Dead code\" and \"Deactivated Code\" have distinct \nmeanings:\n\nDead code : Dead code is source code (and it is a part of binary code)\nthat is not executed in the final system and it will be not having\ntraceability to any requirements (one can say unintentional code).\n\nDeactivated code: code which is commented out or removed via #ifdef's\n(it is not a part of final binary code) and it will be having\ntraceability to its low level requirements (its a intentional code and\nit can be activated in some configurations through hardware traps for\ndebugging or other purposes.\n\n\n-- \n-- \n*** Please reply-to-all at all times ***\n*** (do not pretend to know who is subscribed and who is not) ***\n*** Please avoid top-posting. ***\nThe msysGit Wiki is here: https://github.com/msysgit/msysgit/wiki - Github accounts are free.\n\nYou received this message because you are subscribed to the Google\nGroups \"msysGit\" group.\nTo post to this group, send email to msysgit@googlegroups.com\nTo unsubscribe from this group, send email to\nmsysgit+unsubscribe@googlegroups.com\nFor more options, and view previous threads, visit this group at\nhttp://groups.google.com/group/msysgit?hl=en_US?hl=en\n\n--- \nYou received this message because you are subscribed to the Google Groups \"Git for Windows\" group.\nTo unsubscribe from this group and stop receiving emails from it, send an email to msysgit+unsubscribe@googlegroups.com.\nFor more options, visit https://groups.google.com/d/optout.\n"},{"id":"266144","messageId":"0D1AA32B8D59471B8C528002A460E912@PhilipOakley","threadId":"39715","inReplyTo":"45344004B4CA4B16BD7FB174B4849D77@PhilipOakley","subject":"Re: [PATCH 04/17] Makefile: a dry-run can error out if no perl. Document the issue","fromName":"Philip Oakley","fromEmail":"philipoakley@iee.org","sentAt":"2015-07-14T22:42:13Z","receivedAt":"2015-07-14T22:42:13Z","isPatch":true,"sender":{"key":"philipoakley@iee.email","avatar":"https://avatars.githubusercontent.com/u/914343?v=4"},"body":"From: \"Philip Oakley\" <philipoakley@iee.org>\nSent: Friday, June 26, 2015 12:34 AM\n> From: \"Junio C Hamano\" <gitster@pobox.com>\n>> \"Philip Oakley\" <philipoakley@iee.org> writes:\n>>\n>>> From: \"Junio C Hamano\" <gitster@pobox.com>\n>>>>\n>>>> I am not sure what this patch is trying to achieve.\n\nI have been able to repeat the issue, more below.\n\n>>>\n>>> It was probably a bit of 'don't mess with working code', given that\n>>> I'd used the NO_PERL solution, rather 'document the issue'....\n>>\n>> Then this part applies, I think.\n>>\n>>>> If you are not touching what this Makefile actually does, then I\n>>>> would imagine that you are running the \"buildsystems code\" that\n>>>> actually drives 'make -n' with some \"available solution\" (perhaps\n>>>> you are running 'make -n NO_PERL=NoThanks' or something like that)?\n>>>> Then instead of a command like this that nobody would read in this\n>>>> file, the same command can instead go there to explain what the\n>>>> \"workaround\" (e.g. unusual-looking 'make -n NO_PERL=NoThanks') is\n>>>> doing?\n\nThe command sequence:\n $ git clean -dfx\n $ make -n MSVC=1 V=1 2>ErrsFile.txt 1>MakeDry.txt\n\nproduces the error\n make[1]: *** No rule to make target 'PM.stamp', needed by 'perl.mak'. \nStop.\n make: *** [perl/perl.mak] Error 2\n\nthe actual MakeDry.txt reaches\n\n echo \"$FLAGS\" >GIT-CFLAGS; \\\n            fi\n make[2]: Leaving directory '/c/msysgit195/git'\n make[1]: Leaving directory '/c/msysgit195/git/perl'\n Makefile:1758: recipe for target 'perl/perl.mak' failed\n\nMy understanding of the error is that, first, the PM.stamp is removed by \nthe clean, then the dryrun has by the error time passed the initial \nPM.stamp update code, but doesn't execute it (being a dry run), thus the \nfile PM.stamp still does not exist.\n\nThe makefile then descends into the 'perl/Makefile' pre-requisite to \n'perl/perl.mak', and (IIUC) at this point the L25#$(makfile): PM.stamp \nthen barfs because there is no PM.stamp to be a prerequisite for that \nline.\n\nAs noted in the patch, my response at the time (not fully understanding \nwhy) was simply to annotate the Makefile's PM.stamp (which is where the \nerror would first leads any future debugging).\n\nPossibly other options would be to add an extra PM.stamp target which, \nfor a dry-run (+recipe), creates any empty PM.stamp file if one does not \nexist, simply to allow the perl/perl.mak to succeed. Or perhaps simply \nadd the PM.stamp file to the code (or maybe not).\n\nA third option would be to simply convert the PM.stamp recipe to a \n+recipe so that it's executed during the dry-run, but that may be \ncontrary to the idea of being a dry-run.\n\nDo you have any preference for how I should resolve this? Ideally I like \nto drop the use of the NO_PERL in the dry run.\n\n--\nPhilip\n\n>>\n> I was more of the view that this was about prevention (here), rather\n> than retrospective explanation of the code (there).\n>\n> In my case the errors were showing problems with the PM.stamp in the\n> makefile (I didn't have the solution at that point).\n>\n> So either a short comment \"#  consider using 'NO_PERL=YesPlease' for \n> dry\n> run invocations\" (beware your double negative ;-), or the addition of\n> the '+recipe', would still be my preferred change, rather than leaving\n> the open manhole for others to fall into.\n>\n> The thread on my difficulties is at $gmane/263656 (2015-02-10 22:51)\n> \"\n>    At the moment I'm getting (on my old WinXP machine, using Msysgit\n>    1.9.5 as a basis)\n>\n>    $ make -n MSVC=1 V=1 1>makedry.txt\n>    make[1]: *** No rule to make target `PM.stamp', needed by \n> `perl.mak'.\n>    Stop.\n>    make: *** [perl/perl.mak] Error 2\n> \"\n> As you can see, at that time the place to look would be the makefile,\n> so I would do think a 'fix' there would still be appropriate.\n>\n> Do you have a preference among the three options (comment, +recipe, \n> drop)?\n> --\n> Philip\n>\n\n-- \n-- \n*** Please reply-to-all at all times ***\n*** (do not pretend to know who is subscribed and who is not) ***\n*** Please avoid top-posting. ***\nThe msysGit Wiki is here: https://github.com/msysgit/msysgit/wiki - Github accounts are free.\n\nYou received this message because you are subscribed to the Google\nGroups \"msysGit\" group.\nTo post to this group, send email to msysgit@googlegroups.com\nTo unsubscribe from this group, send email to\nmsysgit+unsubscribe@googlegroups.com\nFor more options, and view previous threads, visit this group at\nhttp://groups.google.com/group/msysgit?hl=en_US?hl=en\n\n--- \nYou received this message because you are subscribed to the Google Groups \"Git for Windows\" group.\nTo unsubscribe from this group and stop receiving emails from it, send an email to msysgit+unsubscribe@googlegroups.com.\nFor more options, visit https://groups.google.com/d/optout.\n"}]}