CC={- $target{cc} -}
CFLAGS={- join(" ",(map { "-D".$_} @{$target{defines}}, @{$config{defines}})) -} {- join(" ", quotify_l("-DENGINESDIR=\"$enginesdir\"", "-DOPENSSLDIR=\"$openssldir\"")) -} {- $target{cflags} -} {- $config{cflags} -}
COUTFLAG={- $target{coutflag} || "/Fo" -}
+RC={- $target{rc} || "rc" -}
+RCOUTFLAG={- $target{rcoutflag} || "/fo" -}
LD={- $target{ld} || "link" -}
LDFLAGS={- $target{lflags} -}
LDOUTFLAG={- $target{loutflag} || "/out:" -}
my $mkdef_pl = abs2rel(rel2abs(catfile($config{sourcedir},
"util", "mkdef.pl")),
rel2abs($config{builddir}));
+ my $mkrc_pl = abs2rel(rel2abs(catfile($config{sourcedir},
+ "util", "mkrc.pl")),
+ rel2abs($config{builddir}));
my $target = shlib_import($lib);
return <<"EOF"
$target: $deps $ordinalsfile $mkdef_pl
\$(PERL) $mkdef_pl "$mkdef_key" 32 > $shlib.def
\$(PERL) -i.tmp -pe "s|^LIBRARY\\s+${mkdef_key}32|LIBRARY $shlib|;" $shlib.def
DEL $shlib.def.tmp
+ \$(PERL) $mkrc_pl $shlib$shlibext > $shlib.rc
+ \$(RC) \$(RCOUTFLAG)$shlib.res $shlib.rc
\$(LD) \$(LDFLAGS) \$(LIB_LDFLAGS) \\
/implib:$target \$(LDOUTFLAG)$shlib$shlibext /def:$shlib.def @<<
-$objs$linklibs \$(EX_LIBS)
+$objs $shlib.res$linklibs \$(EX_LIBS)
<<
DEL /F apps\\$shlib$shlibext
DEL /F test\\$shlib$shlibext
my $platform = shift;
# The only reason we do this is to have something to build MINFO from
build_Makefile();
-
- # create the ms/version32.rc file if needed
- my ($v1, $v2, $v3, $v4);
- if ($config{version_num} =~ /^0x([0-9a-f]{1})([0-9a-f]{2})([0-9a-f]{2})([0-9a-f]{2})([0-9a-f]{1})L$/i) {
- $v1=hex $1;
- $v2=hex $2;
- $v3=hex $3;
- $v4=hex $4;
- }
- open (OUT,">ms/version32.rc") || die "Can't open ms/version32.rc";
- print OUT <<"EOF";
-#include <winver.h>
-
-LANGUAGE 0x09,0x01
-
-1 VERSIONINFO
- FILEVERSION $v1,$v2,$v3,$v4
- PRODUCTVERSION $v1,$v2,$v3,$v4
- FILEFLAGSMASK 0x3fL
-#ifdef _DEBUG
- FILEFLAGS 0x01L
-#else
- FILEFLAGS 0x00L
-#endif
- FILEOS VOS__WINDOWS32
- FILETYPE VFT_DLL
- FILESUBTYPE 0x0L
-BEGIN
- BLOCK "StringFileInfo"
- BEGIN
- BLOCK "040904b0"
- BEGIN
- // Required:
- VALUE "CompanyName", "The OpenSSL Project, http://www.openssl.org/\\0"
- VALUE "FileDescription", "OpenSSL Shared Library\\0"
- VALUE "FileVersion", "$config{version}\\0"
-#if defined(CRYPTO)
- VALUE "InternalName", "libcrypto32\\0"
- VALUE "OriginalFilename", "libcrypto32.dll\\0"
-#elif defined(SSL)
- VALUE "InternalName", "libssl32\\0"
- VALUE "OriginalFilename", "libssl32.dll\\0"
-#endif
- VALUE "ProductName", "The OpenSSL Toolkit\\0"
- VALUE "ProductVersion", "$config{version}\\0"
- // Optional:
- //VALUE "Comments", "\\0"
- VALUE "LegalCopyright", "Copyright © 1998-2015 The OpenSSL Project. Copyright © 1995-1998 Eric A. Young, Tim J. Hudson. All rights reserved.\\0"
- //VALUE "LegalTrademarks", "\\0"
- //VALUE "PrivateBuild", "\\0"
- //VALUE "SpecialBuild", "\\0"
- END
- END
- BLOCK "VarFileInfo"
- BEGIN
- VALUE "Translation", 0x409, 0x4b0
- END
-END
-EOF
- close(OUT);
},
);