From: | "Merlin Moncure" <merlin(dot)moncure(at)rcsonline(dot)com> |
---|---|
To: | <pgsql-hackers-win32(at)postgresql(dot)org> |
Subject: | problem compiling C++ modules in /contrib |
Date: | 2004-06-17 16:46:00 |
Message-ID: | 6EE64EF3AB31D5448D0007DD34EEB34101AE5F@Herge.rcsinc.local |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers-win32 |
Inside /contrib under mingw, all the modules are built with dllwrap to
make them into loadable modules.
For C++ modules, the option --driver-name g++ has to be added to dllwrap
or they don't link properly. Is there a way to edit the makefile safely
so thips option gets passed to dllwrap?
In other words, with the standard makefile, we get:
g++ -O2 -fno-strict-aliasing -Wall -Wmissing-prototypes
-Wmissing-declarations -I. -I../../src/include
-I./src/include/port/win32 -DEXEC_BACKEND
"-I../../src/include/port/win32" -c -o lockmgr.o lockmgr.cc
dlltool --export-all --output-def lockmgr.def lockmgr.o
dllwrap -o lockmgr.dll --def lockmgr.def lockmgr.o -L../../src/backend
-lpostgres
and we need (which compiles and links):
g++ -O2 -fno-strict-aliasing -Wall -Wmissing-prototypes
-Wmissing-declarations -I. -I../../src/include
-I./src/include/port/win32 -DEXEC_BACKEND
"-I../../src/include/port/win32" -c -o lockmgr.o lockmgr.cc
dlltool --export-all --output-def lockmgr.def lockmgr.o
dllwrap -o lockmgr.dll --driver-name g++ --def lockmgr.def lockmgr.o
-L../../src/backend -lpostgres
Merlin
From | Date | Subject | |
---|---|---|---|
Next Message | Andrew Dunstan | 2004-06-17 19:02:56 | Re: pg_ctl vs. Windows locking |
Previous Message | Bruce Momjian | 2004-06-16 02:50:03 | Re: Fix for erroneous warning on Shutdown |