I am using fltk-1.3.0rc3 on 64 bit Ubuntu 10.04.  What appears on those
two lines are :

/usr/include/pqxx/transaction_base.hxx:331:

  enum Status
  {
    st_nascent,
    st_active,
    st_aborted,
    st_committed,
    st_in_doubt
  };

and

/usr/include/pqxx/connection_base.hxx:791:


  int PQXX_PRIVATE Status() const throw ();

so it is almost certainly a name collision with a definition of "Status"
in fltk or something else fltk uses.
Is there anything I can do about it? 
The options to move includes around in Fluid 1.3 seem great at doing
everything except putting an include above the default FL/FL.h in my .h
file. 

Any help would be appreciated. 

-------- Original Message --------
Subject:        Compilation problem between fltk and pqxx
Date:   Wed, 20 Apr 2011 09:50:56 -0600
From:   Andrew Waldrum <[email protected]>
To:     [email protected]



I am having a problem when I try to compile an fltk derived class that
includes some database access code that included pqxx. If I order the
include files with FL/FL.h before kitchen.h (as Fluid wants to order
them) I get the following error:

g++ -c -pipe -O2 -Wall -W -D_REENTRANT -I. -I. -I../../screens/fluid
-I../../include -I. -I/usr/include/sigc++-2.0
-I/usr/lib/sigc++-2.0/include -I./include -o PatientSelect.o
../../screens/fluid/PatientSelect.cpp
In file included from /usr/include/pqxx/connection_base:19,
from /usr/include/pqxx/basic_connection.hxx:27,
from /usr/include/pqxx/basic_connection:19,
from /usr/include/pqxx/connection.hxx:26,
from /usr/include/pqxx/connection:19,
from /usr/include/pqxx/pqxx:18,
from ./include/DBAccess.h:15,
from ./include/DBTable.h:20,
from ./include/StructureVolume.h:15,
from ./include/kitchen.h:7,
from ../../screens/fluid/DataSelect.h:18,
from ../../screens/fluid/DataSelect.cpp:3:
/usr/include/pqxx/connection_base.hxx:791: error: expected
unqualified-id before ‘)’ token
In file included from /usr/include/pqxx/transaction_base:20,
from /usr/include/pqxx/cursor.hxx:32,
from /usr/include/pqxx/cursor:19,
from /usr/include/pqxx/pqxx:19,
from ./include/DBAccess.h:15,
from ./include/DBTable.h:20,
from ./include/StructureVolume.h:15,
from ./include/kitchen.h:7,
from ../../screens/fluid/DataSelect.h:18,
from ../../screens/fluid/DataSelect.cpp:3:
/usr/include/pqxx/transaction_base.hxx:331: error: expected identifier
before ‘int’
/usr/include/pqxx/transaction_base.hxx:332: error: expected
unqualified-id before ‘{’ token

If I put my kitchen.h include before the FL.h include(in
DataSelect.cpp), the same code compiles and works without error or
warning. Any idea what's going on here? I would like to keep using Fluid
without having to manually alter the generated code but at this point
every time I generate code from Fluid I have to swap the order on these
include files to make my program work.

This database code is used by several other developers(not working with
fltk) and has not had this type of problem with other libraries.



_______________________________________________
fltk mailing list
[email protected]
http://lists.easysw.com/mailman/listinfo/fltk

Reply via email to