]> granicus.if.org Git - postgresql/commitdiff
Properly set MODULE_PATHNAME based on module name instead of incorrectly based
authorMagnus Hagander <magnus@hagander.net>
Fri, 27 Apr 2007 16:45:54 +0000 (16:45 +0000)
committerMagnus Hagander <magnus@hagander.net>
Fri, 27 Apr 2007 16:45:54 +0000 (16:45 +0000)
on directory name. Fixes the generation of .sql files in contrib/spi.

Per complaint from Dave Page.

src/tools/msvc/Mkvcbuild.pm

index 28266646b5e3c9f501904dc50004a79e420a7eb8..35ccdcc4719307d868f551b0b55036d3d6792463 100644 (file)
@@ -3,7 +3,7 @@ package Mkvcbuild;
 #
 # Package that generates build files for msvc build
 #
-# $PostgreSQL: pgsql/src/tools/msvc/Mkvcbuild.pm,v 1.10 2007/04/26 14:09:12 mha Exp $
+# $PostgreSQL: pgsql/src/tools/msvc/Mkvcbuild.pm,v 1.11 2007/04/27 16:45:54 mha Exp $
 #
 use Carp;
 use Win32;
@@ -448,7 +448,8 @@ sub GenerateContribSqlFiles
             {
                 print "Building $out from $in (contrib/$n)...\n";
                 my $cont = Project::read_file("contrib/$n/$in");
-                my $dn = $n;
+                my $dn = $out;
+                $dn =~ s/\.sql$//;
                 if ($mf =~ /^MODULE_big\s*=\s*(.*)$/m) { $dn = $1 }
                 $cont =~ s/MODULE_PATHNAME/\$libdir\/$dn/g;
                 my $o;