提交 2cc8fe11 编写于 作者: R Richard Levitte

Windows builds: remove over-quotation of LIBZ macro

The LIBZ macro definition was already quoted in BASE_windows, then got
quotified once more in windows-makefile.tmpl.  That's a bit too much
quotations, ending up with the compiler being asked to define the
macro |"LIBZ=\"ZLIB1\""| (no, not the macro LIBZ with the value
"ZLIB1").  This is solved by removing the extra quoting in
BASE_windows.

Along with this, change the quotation of macro definitions and include
file specification, so we end up with things like -I"QuotedPath" and
-D"Macro=\"some weird value\"" rather than "-IQuotedPath" and
"-DMacro=\"some weird value\"".

Fixes #5827
Reviewed-by: NAndy Polyakov <appro@openssl.org>
(Merged from https://github.com/openssl/openssl/pull/5833)
上级 2a70d65b
...@@ -114,7 +114,7 @@ my %targets=( ...@@ -114,7 +114,7 @@ my %targets=(
my @defs = (); my @defs = ();
unless ($disabled{"zlib-dynamic"}) { unless ($disabled{"zlib-dynamic"}) {
my $zlib = $withargs{zlib_lib} // "ZLIB1"; my $zlib = $withargs{zlib_lib} // "ZLIB1";
push @defs, quotify("perl", 'LIBZ="' . $zlib . '"'); push @defs, 'LIBZ=' . (quotify("perl", $zlib))[0];
} }
return [ @defs ]; return [ @defs ];
}, },
......
...@@ -207,10 +207,10 @@ CNF_ASFLAGS={- join(' ', $target{asflags} || (), ...@@ -207,10 +207,10 @@ CNF_ASFLAGS={- join(' ', $target{asflags} || (),
@{$config{asflags}}) -} @{$config{asflags}}) -}
CNF_CPPFLAGS={- our $cppfags2 = CNF_CPPFLAGS={- our $cppfags2 =
join(' ', $target{cppflags} || (), join(' ', $target{cppflags} || (),
(map { quotify_l("-D".$_) } @{$target{defines}}, (map { '-D'.quotify1($_) } @{$target{defines}},
@{$config{defines}}), @{$config{defines}}),
(map { quotify_l("-I".$_) } @{$target{includes}}, (map { '-I'.quotify1($_) } @{$target{includes}},
@{$config{includes}}), @{$config{includes}}),
@{$config{cppflags}}) -} @{$config{cppflags}}) -}
CNF_CFLAGS={- join(' ', $target{cflags} || (), CNF_CFLAGS={- join(' ', $target{cflags} || (),
@{$config{cflags}}) -} @{$config{cflags}}) -}
...@@ -233,12 +233,12 @@ LIB_ASFLAGS={- join(' ', $target{lib_asflags} || (), ...@@ -233,12 +233,12 @@ LIB_ASFLAGS={- join(' ', $target{lib_asflags} || (),
LIB_CPPFLAGS={- our $lib_cppflags = LIB_CPPFLAGS={- our $lib_cppflags =
join(' ', $target{lib_cppflags} || (), join(' ', $target{lib_cppflags} || (),
$target{shared_cppflag} || (), $target{shared_cppflag} || (),
(map { quotify_l("-D".$_) } (map { '-D'.quotify1($_) }
@{$target{lib_defines}}, @{$target{lib_defines}},
@{$target{shared_defines}}, @{$target{shared_defines}},
@{$config{lib_defines}}, @{$config{lib_defines}},
@{$config{shared_defines}}), @{$config{shared_defines}}),
(map { quotify_l("-I".$_) } (map { '-I'.quotify1($_) }
@{$target{lib_includes}}, @{$target{lib_includes}},
@{$target{shared_includes}}, @{$target{shared_includes}},
@{$config{lib_includes}}, @{$config{lib_includes}},
...@@ -246,7 +246,7 @@ LIB_CPPFLAGS={- our $lib_cppflags = ...@@ -246,7 +246,7 @@ LIB_CPPFLAGS={- our $lib_cppflags =
@{$config{lib_cppflags}}, @{$config{lib_cppflags}},
@{$config{shared_cppflag}}); @{$config{shared_cppflag}});
join(' ', $lib_cppflags, join(' ', $lib_cppflags,
(map { quotify_l("-D".$_) } (map { '-D'.quotify1($_) }
"OPENSSLDIR=\"$openssldir\"", "OPENSSLDIR=\"$openssldir\"",
"ENGINESDIR=\"$enginesdir\""), "ENGINESDIR=\"$enginesdir\""),
'$(CNF_CPPFLAGS)', '$(CPPFLAGS)') -} '$(CNF_CPPFLAGS)', '$(CPPFLAGS)') -}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册