[Libpqxx-general] Problem with the tests using Visual Studio 2008 and libpqxx version 3.0

Andrew Maclean andrew.amaclean at gmail.com
Wed Jan 14 03:05:44 UTC 2009


On Tue, Jan 13, 2009 at 11:59 PM, Jeroen Vermeulen <jtv at xs4all.nl> wrote:
> Andrew Maclean wrote:
>
>> Things seem to build Ok in debug mode but I am still having trouble in
>> release mode. If I get some time I will look further into it. I have
>> switched to using the subversion repository.
>
> I can't find anything that would explain a difference between debug and
> release mode, assuming you're not getting stale object files or
> something like that.  Maybe TestStaticRelease and/or TestDllRelease
> haven't been created?
>
TestStaticRelease is created and all the tests are there as
testnnn.exe however runner.exe is not there - I think that is my
problem.


> If you're using the svn tree on a Windows system, do you run the
> tools/template2mak.py directly to generate these Makefiles?  Or do you
> use something like Cygwin and autogen.sh?
>
>


Yes I do the following:

>From the top-level directory, run:
python tools/template2mak.py win32/vc-libpqxx.mak.template win32/vc-libpqxx.mak
python tools/template2mak.py win32/vc-test.mak.template win32/vc-test.mak
Then run:
"C:\Program Files\Microsoft Visual Studio 9.0\VC\bin\vcvars32.bat"
Then run:
nmake -f win32/vc-libpqxx.mak ALL
nmake -f win32/vc-test.mak ALL

>> CMake will let you have a file like configure.h.in and depending upon
>> the cmake process it will configure a file called configure.h. Look at
>> http://www.cmake.org/Wiki/CMake, in particular
>> http://www.cmake.org/Wiki/CMake_HowToDoPlatformChecks. If you are
>> interested I have an example of this usage.
>
> The biggest problem is that, realistically, I don't think I'll have time
> to figure it out!
>
>
>> This is a constant problem on Windows (the drive names) if you look at
>> the CMake scripts, you can see that you can set an environment
>> variable LIBPQXX_ROOT to point to the root of the directory. Similarly
>> for FindPostgresql.cmake you can set the environment variable
>> POSTGRESQL_ROOT. If these are set, FindLibpqxx and FindPostgresql will
>> use these in preference to searching. A lot of the FindXXX scripts on
>> the modules subdirectory of CMake do this too.
>
> Is adding the right pg_config script to the execution path not an option
> with Windows?
>

Not really, for example I only build the interfaces part and there
seems to be no pg_config script there.
This is also separate from the actual database which is installed.


>
> Jeroen
> _______________________________________________
> Libpqxx-general mailing list
> Libpqxx-general at pgfoundry.org
> http://pgfoundry.org/mailman/listinfo/libpqxx-general
>



-- 
___________________________________________
Andrew J. P. Maclean
Centre for Autonomous Systems
The Rose Street Building J04
The University of Sydney  2006  NSW
AUSTRALIA
Ph: +61 2 9351 3283
Fax: +61 2 9351 7474
URL: http://www.acfr.usyd.edu.au/
___________________________________________


More information about the Libpqxx-general mailing list