Skip site navigation (1) Skip section navigation (2)

problem compiling C++ modules in /contrib

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 (view raw or flat)
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

pgsql-hackers-win32 by date

Next:From: Andrew DunstanDate: 2004-06-17 19:02:56
Subject: Re: pg_ctl vs. Windows locking
Previous:From: Bruce MomjianDate: 2004-06-16 02:50:03
Subject: Re: Fix for erroneous warning on Shutdown

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group