-<!-- $PostgreSQL: pgsql/doc/src/sgml/install-win32.sgml,v 1.36 2007/03/23 09:57:55 mha Exp $ -->
+<!-- $PostgreSQL: pgsql/doc/src/sgml/install-win32.sgml,v 1.37 2007/03/24 22:16:49 mha Exp $ -->
<chapter id="install-win32">
<title>Installation on <productname>Windows</productname></title>
</para></listitem>
</varlistentry>
+ <varlistentry>
+ <term><productname>Gettext</productname></term>
+ <listitem><para>
+ Gettext is required to build with NLS support, and can be downloaded
+ from <ulink url="http://gnuwin32.sourceforge.net"></>. Note that binaries,
+ dependencies and developer files are all needed.
+ </para></listitem>
+ </varlistentry>
+
<varlistentry>
<term><productname>Microsoft Platform SDK</productname></term>
<listitem><para>
#
# Package that provides 'make install' functionality for msvc builds
#
-# $PostgreSQL: pgsql/src/tools/msvc/Install.pm,v 1.3 2007/03/24 15:28:48 mha Exp $
+# $PostgreSQL: pgsql/src/tools/msvc/Install.pm,v 1.4 2007/03/24 22:16:49 mha Exp $
#
use strict;
use warnings;
$| = 1;
my $target = shift;
+ our $config;
+ require 'config.pl';
chdir("../../..") if (-f "../../../configure");
my $conf = "";
GenerateConversionScript($target);
GenerateTimezoneFiles($target,$conf);
CopyContribFiles($target);
+
+ GenerateNLSFiles($target,$config->{nls}) if ($config->{nls});
}
sub EnsureDirectories
return $flist;
}
+sub GenerateNLSFiles
+{
+ my $target = shift;
+ my $nlspath = shift;
+ my $D;
+
+ print "Installing NLS files...";
+ EnsureDirectories($target, "share/locale");
+ open($D,"dir /b /s nls.mk|") || croak "Could not list nls.mk\n";
+ while (<$D>)
+ {
+ chomp;
+ s/nls.mk/po/;
+ my $dir = $_;
+ next unless ($dir =~ /([^\\]+)\\po$/);
+ my $prgm = $1;
+ $prgm = 'postgres' if ($prgm eq 'backend');
+ my $E;
+ open($E,"dir /b $dir\\*.po|") || croak "Could not list contents of $_\n";
+
+ while (<$E>)
+ {
+ chomp;
+ my $lang;
+ next unless /^(.*)\.po/;
+ $lang = $1;
+
+ EnsureDirectories($target, "share/locale/$lang", "share/locale/$lang/LC_MESSAGES");
+ system(
+"$nlspath\\bin\\msgfmt -o $target\\share\\locale\\$lang\\LC_MESSAGES\\$prgm.mo $dir\\$_"
+ )
+ && croak("Could not run msgfmt on $dir\\$_");
+ print ".";
+ }
+ close($E);
+ }
+ close($D);
+ print "\n";
+}
+
sub read_file
{
my $filename = shift;
#
# Package that encapsulates a Visual C++ solution file generation
#
-# $PostgreSQL: pgsql/src/tools/msvc/Solution.pm,v 1.18 2007/03/23 08:43:51 mha Exp $
+# $PostgreSQL: pgsql/src/tools/msvc/Solution.pm,v 1.19 2007/03/24 22:16:49 mha Exp $
#
use Carp;
use strict;
if ($self->{options}->{nls})
{
$proj->AddIncludeDir($self->{options}->{nls} . '\include');
- $proj->AddLibrary($self->{options}->{nls} . '\lib\intl.lib');
+ $proj->AddLibrary($self->{options}->{nls} . '\lib\libintl.lib');
}
if ($self->{options}->{krb5})
{