Error on compiling

Hi all,
I can't find why I have the following error during compilation:

fboriero@marvin:~/workspace/stem/sensPhantom/build$ make
[ 0%] Built target rospack_genmsg_libexe
[ 0%] Built target rosbuild_precompile
Linking CXX shared
library ../lib/orocos/gnulinux/libsensPhantom-gnulinux.so
CMakeFiles/sensPhantom.dir/src/sensPhantom-component.cpp.o: In function
`__static_initialization_and_destruction_0':
/usr/include/omnithread.h:648: undefined reference to
`omni_thread::init_t::init_t()'
/usr/include/omnithread.h:648: undefined reference to
`omni_thread::init_t::~init_t()'
CMakeFiles/sensPhantom.dir/src/sensPhantom-component.cpp.o: In function
`__static_initialization_and_destruction_0':
/usr/include/omniORB4/finalCleanup.h:41: undefined reference to
`_omniFinalCleanup::_omniFinalCleanup()'
/usr/include/omniORB4/finalCleanup.h:41: undefined reference to
`_omniFinalCleanup::~_omniFinalCleanup()'
collect2: ld returned 1 exit status
make[2]: *** [../lib/orocos/gnulinux/libsensPhantom-gnulinux.so] Error 1
make[1]: *** [CMakeFiles/sensPhantom.dir/all] Error 2
make: *** [all] Error 2

I'm using and updated Ubuntu LTS 10.04 with the v2.32
orocos_toolchain_ros.

all the omniorb packages are installed.
Greatings,

Fabrizio

Error on compiling

On Thu, May 12, 2011 at 12:41 PM, Fabrizio <fabrizio [dot] boriero [..] ...> wrote:
> Hi all,
> I can't find why I have the following error during compilation:
>
> fboriero@marvin:~/workspace/stem/sensPhantom/build$ make
> [  0%] Built target rospack_genmsg_libexe
> [  0%] Built target rosbuild_precompile
> Linking CXX shared
> library ../lib/orocos/gnulinux/libsensPhantom-gnulinux.so
> CMakeFiles/sensPhantom.dir/src/sensPhantom-component.cpp.o: In function
> `__static_initialization_and_destruction_0':
> /usr/include/omnithread.h:648: undefined reference to
> `omni_thread::init_t::init_t()'
> /usr/include/omnithread.h:648: undefined reference to
> `omni_thread::init_t::~init_t()'
> CMakeFiles/sensPhantom.dir/src/sensPhantom-component.cpp.o: In function
> `__static_initialization_and_destruction_0':
> /usr/include/omniORB4/finalCleanup.h:41: undefined reference to
> `_omniFinalCleanup::_omniFinalCleanup()'
> /usr/include/omniORB4/finalCleanup.h:41: undefined reference to
> `_omniFinalCleanup::~_omniFinalCleanup()'
> collect2: ld returned 1 exit status
> make[2]: *** [../lib/orocos/gnulinux/libsensPhantom-gnulinux.so] Error 1
> make[1]: *** [CMakeFiles/sensPhantom.dir/all] Error 2
> make: *** [all] Error 2
>
>
> I'm using and updated Ubuntu LTS 10.04 with the v2.32
> orocos_toolchain_ros.
>
> all the omniorb packages are installed.

Are you including any of the <rtt/transport/corba/*...> headers ?

If so, then you must link against the corba transport. This is done by
adding this line to your cmakelists.txt file:

target_link_libraries( sensPhantom ${OROCOS-RTT_CORBA_LIBRARIES} )

you can find these variables here :
http://www.orocos.org/wiki/orocos/toolchain/getting-started/cmake-and-bu...

Why are you including corba headers in your component ?

Peter
--
Orocos-Users mailing list
Orocos-Users [..] ...
http://lists.mech.kuleuven.be/mailman/listinfo/orocos-users

Error on compiling

On Thu, 2011-05-12 at 13:51 +0200, Peter Soetens wrote:
> On Thu, May 12, 2011 at 12:41 PM, Fabrizio <fabrizio [dot] boriero [..] ...> wrote:
> > Hi all,
> > I can't find why I have the following error during compilation:
> >
> > fboriero@marvin:~/workspace/stem/sensPhantom/build$ make
> > [ 0%] Built target rospack_genmsg_libexe
> > [ 0%] Built target rosbuild_precompile
> > Linking CXX shared
> > library ../lib/orocos/gnulinux/libsensPhantom-gnulinux.so
> > CMakeFiles/sensPhantom.dir/src/sensPhantom-component.cpp.o: In function
> > `__static_initialization_and_destruction_0':
> > /usr/include/omnithread.h:648: undefined reference to
> > `omni_thread::init_t::init_t()'
> > /usr/include/omnithread.h:648: undefined reference to
> > `omni_thread::init_t::~init_t()'
> > CMakeFiles/sensPhantom.dir/src/sensPhantom-component.cpp.o: In function
> > `__static_initialization_and_destruction_0':
> > /usr/include/omniORB4/finalCleanup.h:41: undefined reference to
> > `_omniFinalCleanup::_omniFinalCleanup()'
> > /usr/include/omniORB4/finalCleanup.h:41: undefined reference to
> > `_omniFinalCleanup::~_omniFinalCleanup()'
> > collect2: ld returned 1 exit status
> > make[2]: *** [../lib/orocos/gnulinux/libsensPhantom-gnulinux.so] Error 1
> > make[1]: *** [CMakeFiles/sensPhantom.dir/all] Error 2
> > make: *** [all] Error 2
> >
> >
> > I'm using and updated Ubuntu LTS 10.04 with the v2.32
> > orocos_toolchain_ros.
> >
> > all the omniorb packages are installed.
>
> Are you including any of the <rtt/transport/corba/*...> headers ?
>
> If so, then you must link against the corba transport. This is done by
> adding this line to your cmakelists.txt file:
>
> target_link_libraries( sensPhantom ${OROCOS-RTT_CORBA_LIBRARIES} )
>
> you can find these variables here :
> http://www.orocos.org/wiki/orocos/toolchain/getting-started/cmake-and-bu...
>
> Why are you including corba headers in your component ?

Was a mistake... I delete the include and now runs...
Thanks a lot!

> Peter
Fabrizio