[unixODBC-dev] SAP ODBC test porting

Peter Harvey pharvey at peterharvey.org
Fri Mar 25 16:46:08 GMT 2005


>Peter, if you prefer, I have no problem with using CPP conditional
>macros to preserve the original SAP SQL statements, which would allow
>the test to compile in SAP/MySQL-mode or generic/ODBC-mode.
>
>If you want to follow that path, can you recommend the best way to
>do this with qmake?
>
>  
>
I suppose that could work. If you want to do this you can have a line like;

DEFINES += SAP

and then in C you would do something like;

#ifdef SAP

If  you find that SAP does not exist in child directories then you can 
use an environment variable in qmake like;

DEFINES += BMODE=$(ENV_BMODE)

and in C just use BMODE like a constant..

#ifdef BMODE

or

#if BMODE > 0

or

if ( BMODE == x )


Peter




More information about the unixODBC-dev mailing list