[ntl] NTL_CLIENT / namespace
campagne
campagne at lal.in2p3.fr
Thu Feb 5 10:51:16 CST 2015
Hello
I would like to use "NTL/xdouble.h" on Mac Os X
The compilation/tests of NTL goes fine.
But in my simple program I have same troubles.
either I have
g++ -o ex_jec.exe ex_jec.cpp -I./include/ ./src/ntl.a -lm
Undefined symbols for architecture x86_64:
"(anonymous namespace)::to_xdouble(double)", referenced from:
_main in ccctuItC.o
"(anonymous namespace)::operator<<(std::basic_ostream<char,
std::char_traits<char> >&, (anonymous namespace)::xdouble const&)",
referenced from:
_main in ccctuItC.o
"(anonymous namespace)::operator*((anonymous namespace)::xdouble
const&, (anonymous namespace)::xdouble const&)", referenced from:
_main in ccctuItC.o
"(anonymous namespace)::operator-((anonymous namespace)::xdouble
const&)", referenced from:
_main in ccctuItC.o
ld: symbol(s) not found for architecture x86_64
Or if I add NTL_CLIENT after the #include "NTL/xdouble.h" I get
g++ -o ex_jec.exe ex_jec.cpp -I./include/ -L./src -lntl -lm
In file included from ./include/NTL/ZZ.h:19:0,
from ./include/NTL/xdouble.h:4,
from ex_jec.cpp:20:
./include/NTL/tools.h:31:50: error: expected identifier before ';' token
#define NTL_USE_NNS using namespace NTL_NAMESPACE;
^
./include/NTL/tools.h:66:32: note: in expansion of macro 'NTL_USE_NNS'
#define NTL_CLIENT NTL_USE_SNS NTL_USE_NNS
^
ex_jec.cpp:21:1: note: in expansion of macro 'NTL_CLIENT'
NTL_CLIENT
Some help needed.
Thanks
JE
More information about the ntl
mailing list