> We have a directive called WIN32_ONLY_COMPILER that's used for this.
> It'll pick up MSVC and Borland C++ which normally behave at
> least almost the same.
>
>
> > I am installing mingw to test the patch there. Chances are
> it will break
> > because mingw does __declspec(dllimport) differently than msvc
>
> Thanks.
>
> //Magnus
Humm... I was expecting it to break... but it compiled just fine :)
Here are the steps I took..
On a Win 2003 VM (VMWare):
1. Installed MinGW-5.1.3.exe
2. Installed MSYS-1.0.10.exe
3. Installed msysDTK-1.0.1.exe
4. Installed gettext-0.14.4.exe into C:\MinGW
4. Downloaded sources tarbal
5. ./configure --prefix=/home/gevik/build --without-zlib --enable-nls
6. make check, every thing was OK and 114 tests passed :)
7. make install,....initdb...createdb....etc..etc..
8. set LC_MESSAGES and tested. See attachment :)
The patch works both for MSVC and MINGW.
Regards,
Gevik.
C:\msys\1.0\home\gevik\build\bin>psql
Welcome to psql 8.3.0, the PostgreSQL interactive terminal.
Type: \copyright for distribution terms
\h for help with SQL commands
\? for help with psql commands
\g or terminate with semicolon to execute query
\q to quit
Warning: Console code page (437) differs from Windows code page (1252)
8-bit characters might not work correctly. See psql reference
page "Notes for Windows users" for details.
gevik=# set lc_messages to 'sv_SE';
SET
gevik=# select to_char((current_date + s.a),'TMDay TMMonth YYYY') as dates from
generate_series(0,6) as s(a);
dates
-----------------------
Torsdag Februari 2008
Fredag Februari 2008
Lrdag Februari 2008
Sndag Februari 2008
Mndag Februari 2008
Tisdag Februari 2008
Onsdag Februari 2008
(7 rows)
gevik=# set lc_messages to 'de_DE';
SET
gevik=# select to_char((current_date + s.a),'TMDay TMMonth YYYY') as dates from
generate_series(0,6) as s(a);
dates
-------------------------
Donnerstag Februar 2008
Freitag Februar 2008
Samstag Februar 2008
Sonntag Februar 2008
Montag Februar 2008
Dienstag Februar 2008
Mittwoch Februar 2008
(7 rows)
gevik=# set lc_messages to 'English_United_States';
SET
gevik=# select to_char((current_date + s.a),'TMDay TMMonth YYYY') as dates from
generate_series(0,6) as s(a);
dates
-------------------------
Thursday February 2008
Friday February 2008
Saturday February 2008
Sunday February 2008
Monday February 2008
Tuesday February 2008
Wednesday February 2008
(7 rows)
gevik=# set lc_messages to 'tr-TR';
SET
gevik=# select to_char((current_date + s.a),'TMDay TMMonth YYYY') as dates from
generate_series(0,6) as s(a);
dates
----------------------
Persembe Subat 2008
Cuma Subat 2008
Cumartesi Subat 2008
Pazar Subat 2008
Pazartesi Subat 2008
Sali Subat 2008
arsamba Subat 2008
(7 rows)
gevik=# set lc_messages to 'fr';
SET
gevik=# select to_char((current_date + s.a),'TMDay TMMonth YYYY') as dates from
generate_series(0,6) as s(a);
dates
----------------------
Jeudi Fvrier 2008
Vendredi Fvrier 2008
Samedi Fvrier 2008
Dimanche Fvrier 2008
Lundi Fvrier 2008
Mardi Fvrier 2008
Mercredi Fvrier 2008
(7 rows)
gevik=# set lc_messages to 'Spanish_Spain';
SET
gevik=# select to_char((current_date + s.a),'TMDay TMMonth YYYY') as dates from
generate_series(0,6) as s(a);
dates
-----------------------
Jueves Febrero 2008
Viernes Febrero 2008
Sbado Febrero 2008
Domingo Febrero 2008
Lunes Febrero 2008
Martes Febrero 2008
Mircoles Febrero 2008
(7 rows)
gevik=#
---------------------------(end of broadcast)---------------------------
TIP 4: Have you searched our list archives?
http://archives.postgresql.org