From: Philip Oakley <philipoakley@iee.org>
To: GitList <git@vger.kernel.org>
Cc: Junio C Hamano <gitster@pobox.com>,
Marius Storm-Olsen <mstormo@gmail.com>,
Ramsay Jones <ramsay@ramsay1.demon.co.uk>,
Jonathan Nieder <jrnieder@gmail.com>,
Johannes Schindelin <Johannes.Schindelin@gmx.de>,
Msysgit <msysgit@googlegroups.com>
Subject: [PATCH 3/5] engine.pl: ignore invalidcontinue.obj which is known to MSVC
Date: Wed, 24 Dec 2014 10:47:12 +0000 [thread overview]
Message-ID: <1419418034-6276-4-git-send-email-philipoakley@iee.org> (raw)
In-Reply-To: <1419418034-6276-1-git-send-email-philipoakley@iee.org>
Commit 4b623d8 (MSVC: link in invalidcontinue.obj for better
POSIX compatibility, 2014-03-29) is not processed correctly
by the buildsystem. Ignore it.
Also split the .o and .obj processing; 'make' does not produce .obj
files. Only substitute filenames ending with .o when generating the
source .c filename.
Signed-off-by: Philip Oakley <philipoakley@iee.org>
---
contrib/buildsystems/engine.pl | 10 +++++++---
1 file changed, 7 insertions(+), 3 deletions(-)
diff --git a/contrib/buildsystems/engine.pl b/contrib/buildsystems/engine.pl
index 7f45b80..e913280 100755
--- a/contrib/buildsystems/engine.pl
+++ b/contrib/buildsystems/engine.pl
@@ -289,7 +289,7 @@ sub handleLibLine
# exit(1);
foreach (@objfiles) {
my $sourcefile = $_;
- $sourcefile =~ s/\.o/.c/;
+ $sourcefile =~ s/\.o$/.c/;
push(@sources, $sourcefile);
push(@cflags, @{$compile_options{"${sourcefile}_CFLAGS"}});
push(@defines, @{$compile_options{"${sourcefile}_DEFINES"}});
@@ -333,8 +333,12 @@ sub handleLinkLine
} elsif ($part =~ /\.(a|lib)$/) {
$part =~ s/\.a$/.lib/;
push(@libs, $part);
- } elsif ($part =~ /\.(o|obj)$/) {
+ } elsif ($part eq 'invalidcontinue.obj') {
+ # ignore - known to MSVC
+ } elsif ($part =~ /\.o$/) {
push(@objfiles, $part);
+ } elsif ($part =~ /\.obj$/) {
+ # do nothing, 'make' should not be producing .obj, only .o files
} else {
die "Unhandled lib option @ line $lineno: $part";
}
@@ -343,7 +347,7 @@ sub handleLinkLine
# exit(1);
foreach (@objfiles) {
my $sourcefile = $_;
- $sourcefile =~ s/\.o/.c/;
+ $sourcefile =~ s/\.o$/.c/;
push(@sources, $sourcefile);
push(@cflags, @{$compile_options{"${sourcefile}_CFLAGS"}});
push(@defines, @{$compile_options{"${sourcefile}_DEFINES"}});
--
2.1.0
next prev parent reply other threads:[~2014-12-24 10:47 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-12-24 10:47 [PATCH 0/5] Fix the Visual Studio 2008 .sln generator Philip Oakley
2014-12-24 10:47 ` [PATCH 1/5] engine.pl: Fix i18n -o option in msvc buildsystem generator Philip Oakley
2014-12-26 18:51 ` Philip Oakley
2014-12-24 10:47 ` [PATCH 2/5] engine.pl: Properly accept quoted spaces in filenames Philip Oakley
2014-12-24 10:47 ` Philip Oakley [this message]
2014-12-24 10:47 ` [PATCH 4/5] vcbuild/readme: Improve layout and reference msvc-build script Philip Oakley
2014-12-24 10:47 ` [PATCH 5/5] engine.pl: provide more debug print statements Philip Oakley
2014-12-26 14:25 ` [PATCH 0/5] Fix the Visual Studio 2008 .sln generator Philip Oakley
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1419418034-6276-4-git-send-email-philipoakley@iee.org \
--to=philipoakley@iee.org \
--cc=Johannes.Schindelin@gmx.de \
--cc=git@vger.kernel.org \
--cc=gitster@pobox.com \
--cc=jrnieder@gmail.com \
--cc=mstormo@gmail.com \
--cc=msysgit@googlegroups.com \
--cc=ramsay@ramsay1.demon.co.uk \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).