Here are the code snippets... #include<iostream> #include "dbtrax.h"
using namespace std; dbtrax::dbtrax() {} dbtrax::~dbtrax() {} void dbtrax::print(char* str) { cout<< str<< endl; } void dbtrax::getName() { cout<< "getName()"<< endl; } dbtrax.h #ifndef DBTRAX_H_ #define DBTRAX_H_ #include<iostream> using namespace std; class dbtrax { public: dbtrax(); virtual ~dbtrax(); void print(char* str); void getName(); }; #endif /* DBTRAX_H_ */ wrapper.cc #ifndef CUSTOMERWRAPPER_H_ #define CUSTOMERWRAPPER_H_ #include<iostream> #include "wrapper.h" #include "dbtrax.h" using namespace std; void getName() { dbtrax dbt; dbt.getName(); // cout<< "a"<< endl; } #endif /* DBTRAX_H_ */ wrapper.h #ifndef CUSTOMERWRAPPER_H_ #define CUSTOMERWRAPPER_H_ #include<iostream> using namespace std; void getName(); #endif /* DBTRAX_H_ */ On 12/10/2010 1:05 PM, Myoungkyu Song wrote: > Hello, X10 users > > I am writing this post about the problem that is related to the calling the > external C++ code. > I've got the following compile error message. > When I called the wrapper function without referencing any class, it worked. > However, if I tried to use another class within the wrapper, I've got error > messages. > I think there is a X10++ compiling option. > > r...@smk-laptop:/home/smk/odb/x10test# x10c++ -o HelloWorld HelloWorld.x10 > -x10rt standalone > x10c++: /tmp/ccwBHaV2.o: In function `getName()': > /home/smk/odb/x10test/wrapper.cc:10: undefined reference to > `dbtrax::dbtrax()' > /home/smk/odb/x10test/wrapper.cc:11: undefined reference to > `dbtrax::getName()' > /home/smk/odb/x10test/wrapper.cc:11: undefined reference to > `dbtrax::~dbtrax()' > /home/smk/odb/x10test/wrapper.cc:11: undefined reference to > `dbtrax::~dbtrax()' > collect2: ld returned 1 exit status > x10c++: Non-zero return code: 1 > 2 errors. > > Best regards, > Myoungkyu Song > > > ------------------------------------------------------------------------------ > Oracle to DB2 Conversion Guide: Learn learn about native support for PL/SQL, > new data types, scalar functions, improved concurrency, built-in packages, > OCI, SQL*Plus, data movement tools, best practices and more. > http://p.sf.net/sfu/oracle-sfdev2dev > > > _______________________________________________ > X10-users mailing list > X10-users@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/x10-users ------------------------------------------------------------------------------ Oracle to DB2 Conversion Guide: Learn learn about native support for PL/SQL, new data types, scalar functions, improved concurrency, built-in packages, OCI, SQL*Plus, data movement tools, best practices and more. http://p.sf.net/sfu/oracle-sfdev2dev _______________________________________________ X10-users mailing list X10-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/x10-users