Commit 26c930b3 authored by Alexandre Julliard's avatar Alexandre Julliard

make_makefiles: Add rules for cross-compiling all import libs from the dlls directory.

parent e9a34e91
...@@ -528,7 +528,18 @@ sub update_dlls(@) ...@@ -528,7 +528,18 @@ sub update_dlls(@)
next unless defined $static_implibs{$mod}; next unless defined $static_implibs{$mod};
$text .= " \\\n\t$directories{$mod}/lib$importlibs{$mod}.\$(STATIC_IMPLIBEXT)"; $text .= " \\\n\t$directories{$mod}/lib$importlibs{$mod}.\$(STATIC_IMPLIBEXT)";
} }
$text .= "\n\nCROSS_IMPLIBS =";
foreach my $mod (sort @lib_symlinks)
{
$text .= sprintf " \\\n\tlib%s.a", $importlibs{$mod};
}
foreach my $mod (sort keys %importlibs)
{
next if defined $static_implibs{$mod};
$text .= " \\\n\t$directories{$mod}/lib$importlibs{$mod}.a";
}
$text .= "\n\n"; $text .= "\n\n";
$text .= "\$(TESTSUBDIRS:%=%/__crosstest__): \$(CROSS_IMPLIBS)\n\n";
$text .= "implib: \$(IMPORT_LIBS)\n\n"; $text .= "implib: \$(IMPORT_LIBS)\n\n";
$text .= ".PHONY: implib\n\n"; $text .= ".PHONY: implib\n\n";
...@@ -547,16 +558,19 @@ sub update_dlls(@) ...@@ -547,16 +558,19 @@ sub update_dlls(@)
} }
else else
{ {
$text .= sprintf "%s/lib%s.\$(IMPLIBEXT): %s/%s.spec \$(WINEBUILD)\n", $dir, $lib, $dir, $spec; $text .= sprintf "%s/lib%s.def %s/lib%s.a: %s/%s.spec \$(WINEBUILD)\n",
$text .= sprintf "\t\@cd %s && \$(MAKE) lib%s.\$(IMPLIBEXT)\n\n", $dir, $lib; $dir, $lib, $dir, $lib, $dir, $spec;
$text .= sprintf "\t\@cd %s && \$(MAKE) `basename \$\@`\n\n", $dir;
} }
} }
foreach my $mod (sort @lib_symlinks) foreach my $mod (sort @lib_symlinks)
{ {
my $dir = $directories{$mod}; my $dir = $directories{$mod};
my $lib = "lib" . $importlibs{$mod} . ".\$(IMPLIBEXT)"; my $lib = "lib" . $importlibs{$mod};
$text .= sprintf "%s: %s/%s\n", $lib, $dir, $lib; $text .= sprintf "%s.a: %s/%s.a\n", $lib, $dir, $lib;
$text .= sprintf "\t\$(RM) \$@ && \$(LN_S) %s/%s \$@\n\n", $dir, $lib; $text .= sprintf "\t\$(RM) \$@ && \$(LN_S) %s/%s.a \$@\n\n", $dir, $lib;
$text .= sprintf "%s.def: %s/%s.def\n", $lib, $dir, $lib;
$text .= sprintf "\t\$(RM) \$@ && \$(LN_S) %s/%s.def \$@\n\n", $dir, $lib;
} }
$text .= "\$(BUILDSUBDIRS): \$(IMPORT_LIBS)\n"; $text .= "\$(BUILDSUBDIRS): \$(IMPORT_LIBS)\n";
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment