Mailing list archive (omnetpp-l at omnetpp.org)
[
Date Prev][
Date Next][
Thread Prev][
Thread Next][
Date Index][
Thread Index]
Re: [Omnetpp-l] omnet with cgal library: compilation problem because ofmacros
Hi Paolo,
Likely some #defines in OMNeT++ conflict with CGAL ones. Can you figure out
which ones?
Andras
> -----Original Message-----
> From: omnetpp-l-bounces at xxx [mailto:omnetpp-l-bounces at xxx]
> On Behalf Of Paolo Masci
> Sent: Friday, July 18, 2008 2:03 PM
> To: omnetpp-l at xxx
> Subject: [Omnetpp-l] omnet with cgal library: compilation problem because
> ofmacros
>
> Hi,
>
> I'm trying to use the cgal library within the omnet network simulator.
> I get lot of compile errors because of macros when including
> cgal headers in my files.
>
> Here's a partial snapshot of what I get:
>
> ------
> g++ -c -O2 -DNDEBUG=1 -DWITH_PARSIM -DWITH_NETBUILDER -
> I/opt/omnetpp/include
> txc1.cc
> In file included from /usr/include/CGAL/gmpxx.h:43,
> from /usr/include/CGAL/number_type_basic.h:91,
> from /usr/include/CGAL/basic.h:35,
> from /usr/include/CGAL/Cartesian/Cartesian_base.h:29,
> from /usr/include/CGAL/Cartesian.h:27,
> from txc1.cc:7:
> /usr/include/gmpxx.h:3103:62: error: macro "sgn" passed 2 arguments, but
> takes
> just 1
> ------
>
>
> I've tried to place #undef sgn in gmpxx.h, but there are still problems
> (maybe because the macro is used somewhere, and I'm undefining it).
> Here's another partial snapshot of the errors:
>
> ------
> In file included from /usr/include/CGAL/number_type_basic.h:68,
> from /usr/include/CGAL/basic.h:35,
> from /usr/include/CGAL/Cartesian/Cartesian_base.h:29,
> from /usr/include/CGAL/Cartesian.h:27,
> from txc1.cc:7:
> /usr/include/CGAL/utils_classes.h:65: error: expected unqualified-id
> before
> '{' token
> /usr/include/CGAL/utils_classes.h:66: error: 'c_' was not declared in this
> scope
> /usr/include/CGAL/utils_classes.h:66: error: a function call cannot appear
> in a
> constant-expression
> /usr/include/CGAL/utils_classes.h:66: error: expected ';' before '{'
> token
> /usr/include/CGAL/utils_classes.h:67: error: expected `;' before 'NT'
> /usr/include/CGAL/utils_classes.h:75: error: expected unqualified-id
> before
> '{' token
> /usr/include/CGAL/utils_classes.h:76: error: 'c_' was not declared in this
> scope
> /usr/include/CGAL/utils_classes.h:76: error: a function call cannot appear
> in a
> constant-expression
> /usr/include/CGAL/utils_classes.h:76: error: expected ';' before '{'
> token
> /usr/include/CGAL/utils_classes.h:77: error: expected `;' before 'NT'
> ------
>
>
> I'm working under ubuntu linux, g++ version 4.2.3.
> What am I missing? Is there a way to override this problem?
>
> Thanks in advance.
>
> Regards, Paolo
> _______________________________________________
> Omnetpp-l mailing list
> Omnetpp-l at xxx
> http://lists.omnetpp.org/mailman/listinfo/omnetpp-l
_______________________________________________
Omnetpp-l mailing list
Omnetpp-l at xxx
http://lists.omnetpp.org/mailman/listinfo/omnetpp-l
Home |
Main Index |
Thread Index