makefiles: Automatically add missing source variables in make_makefiles.
authorAlexandre Julliard <julliard@winehq.org>
Sat, 1 Jan 2011 16:46:56 +0000 (17:46 +0100)
committerAlexandre Julliard <julliard@winehq.org>
Sat, 1 Jan 2011 16:46:56 +0000 (17:46 +0100)
dlls/wineps.drv/Makefile.in
programs/iexplore/Makefile.in
tools/make_makefiles

index 71d03de4d6a9207414805fa125385534b55b82ed..e16c7c0fe95fde51ae7ad598e96ba81fbd4dd3e0 100644 (file)
@@ -63,7 +63,7 @@ C_SRCS = \
        type1afm.c \
        type42.c
 
-RC_SRCS= \
+RC_SRCS = \
        wps_Bg.rc \
        wps_Cs.rc \
        wps_Da.rc \
index 921afac68d84a91bb9a0d9add17a87fdf0edbc16..547f8f003ab58eccf8a01fa40bd24105b229c900 100644 (file)
@@ -8,4 +8,6 @@ C_SRCS = \
 
 RC_SRCS = iexplore.rc
 
+SVG_SRCS = iexplore.svg
+
 @MAKE_PROG_RULES@
index 5f6ba96979bb6de1886dc2d62153784ea6bd2814..673c4cf42c0a9b737166184b105f57d17e8deb18 100755 (executable)
@@ -241,6 +241,7 @@ sub replace_makefile_variable($$)
 {
     my ($file, $var) = @_;
     my $make = $makefiles{$file};
+    my $replaced = 0;
 
     return unless defined ${$make}{"=$var"};
 
@@ -252,7 +253,7 @@ sub replace_makefile_variable($$)
     open OLD_FILE, "$file.in" or die "cannot open $file.in";
     while (<OLD_FILE>)
     {
-        if (/^\s*($var\s+)=/)
+        if (/^\s*($var\s*)=/)
         {
             # try to preserve formatting
             my $prefix = $1;
@@ -270,8 +271,13 @@ sub replace_makefile_variable($$)
             {
                 print NEW_FILE "$prefix= @values\n";
             }
+            $replaced = 1;
             next;
         }
+        if (/^\@MAKE/ && !$replaced)
+        {
+            print NEW_FILE "$var = \\\n\t" . join(" \\\n\t", sort @values) . "\n";
+        }
         print NEW_FILE $_;
     }
     close OLD_FILE;