Don't use applink for static builds.
authorDr Stephen Henson <steve@openssl.org>
Tue, 8 Dec 2015 19:10:48 +0000 (19:10 +0000)
committerDr. Stephen Henson <steve@openssl.org>
Wed, 9 Dec 2015 00:30:27 +0000 (00:30 +0000)
Reviewed-by: Rich Salz <rsalz@openssl.org>
(cherry picked from commit 10119938215298ad414468e7c2779d7fd1a0b979)

util/pl/VC-32.pl

index e5abb97..88f0f7a 100644 (file)
@@ -345,9 +345,13 @@ sub do_link_rule
        $ret.="$target: $files $dep_libs";
        if ($standalone == 1)
                {
-               $ret.=" \$(OBJ_D)${o}applink.obj\n";
+               $ret.=" \$(OBJ_D)${o}applink.obj" if $shlib;
+               $ret.="\n";
                $ret.="  \$(LINK) \$(LFLAGS) $efile$target @<<\n\t";
-               $ret.= "\$(EX_LIBS) \$(OBJ_D)${o}applink.obj " if ($files =~ /O_FIPSCANISTER/ && !$fipscanisterbuild);
+               if ($files =~ /O_FIPSCANISTER/ && !$fipscanisterbuild) {
+                       $ret.= "\$(EX_LIBS) ";
+                       $ret.= "\$(OBJ_D)${o}applink.obj " if $shlib;
+               }
                $ret.="$files $libs\n<<\n";
                }
        elsif ($standalone == 2)