contrib/buildsystems: handle options starting with a slash
With the recent changes to allow building with MSVC=1, we now pass the /OPT:REF option to the compiler. This confuses the parser that wants to turn the output of a dry run into project definitions for QMake and Visual Studio: Unhandled link option @ line 213: /OPT:REF at [...] Let's just extend the code that passes through options that start with a dash, so that it passes through options that start with a slash, too. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Johannes Schindelin committed
Jul 29, 2019 at 13:08 UTC
4553f9de23f8d451bf801b566247bf987570626a
1 file changed
+1
-1
contrib/buildsystems/engine.pl
+1
-1
@@ -351,7 +351,7 @@ sub handleLinkLine
351
push(@libs, "expat.lib");
352
} elsif ("$part" eq "-liconv") {
353
push(@libs, "libiconv.lib");
354
- } elsif ($part =~ /^-/) {
354
+ } elsif ($part =~ /^[-\/]/) {
355
push(@lflags, $part);
356
} elsif ($part =~ /\.(a|lib)$/) {
357
$part =~ s/\.a$/.lib/;