[omniORB] Compiling an application on Win NT using gcc
Reiner Beck
R.K.Beck@t-online.de
Thu, 21 Jun 2001 13:55:37 +0200
Hello List,
I am porting an application from Linux to Win NT 4.0/SR 6 and try to
re-use my gnu environment including the gcc compiler. (I don't want to
change my existing kdevelop project (based on autoconf/automake/gcc ..)
into a MSVC++ Project.)
When I link my application I get an "Undefined reference to
omni_thread::init_t::init_t(void)" (detailed output see below)
Is it possible at all to build an omniORB application with the gnu
compiler on Win NT? (omniORB itself is compiled using MSVC)
Am I using the right lib's or are there any lib's missing?
Am I missing something here?
Any help is appreciated! Thanks!
BTW: I am using the omniORB 2.8.0 binary distribution for WinNT
Please note that the macros "__WIN32__", "__x86__", "__NT__",
"__OSVERSION__=4" are defined in an include file "sitedef.h" and are not
shown on the c++ command line. As I am using the static libraries (OK,
try too :-/ ) , the macro "_WINSTATIC" is defined there as well.
--- cut here ---
$ make
cd . && autoheader
make all-recursive
make[1]: Entering directory `/opt/Projects/vis/visco_init'
Making all in visco_init
make[2]: Entering directory `/opt/Projects/vis/visco_init/visco_init'
Making all in docs
make[3]: Entering directory
`/opt/Projects/vis/visco_init/visco_init/docs'
Making all in en
make[4]: Entering directory
`/opt/Projects/vis/visco_init/visco_init/docs/en'
make[4]: Nothing to be done for `all'.
make[4]: Leaving directory
`/opt/Projects/vis/visco_init/visco_init/docs/en'
make[4]: Entering directory
`/opt/Projects/vis/visco_init/visco_init/docs'
make[4]: Nothing to be done for `all-am'.
make[4]: Leaving directory
`/opt/Projects/vis/visco_init/visco_init/docs'
make[3]: Leaving directory
`/opt/Projects/vis/visco_init/visco_init/docs'
make[3]: Entering directory `/opt/Projects/vis/visco_init/visco_init'
c++ -DHAVE_CONFIG_H -I. -I. -I.. -I/opt/Projects/vis/include -I
/opt/Projects/SGI_STL -D_REENTRANT -I/opt/omniORB/include -g -O2 -c
vis_proc_tracer.cpp
c++ -DHAVE_CONFIG_H -I. -I. -I.. -I/opt/Projects/vis/include -I
/opt/Projects/SGI_STL -D_REENTRANT -I/opt/omniORB/include -g -O2 -c
vis_launcher.cpp
c++ -DHAVE_CONFIG_H -I. -I. -I.. -I/opt/Projects/vis/include -I
/opt/Projects/SGI_STL -D_REENTRANT -I/opt/omniORB/include -g -O2 -c
main.cpp
c++ -g -O2 -o visco_init vis_proc_tracer.o vis_launcher.o main.o
-L/lib/w32api -L/opt/omniORB/lib/x86_win32 -L/opt/Projects/vis/lib
-lwsock32 -ladvapi32 -lomniORB2 -lomnithread -lcorba -lcygipc
vis_launcher.o: In function `_static_initialization_and_destruction_0':
/opt/omniORB/include/omnithread.h:521: undefined reference to
`omni_thread::init_t::init_t(void)'
main.o: In function `_static_initialization_and_destruction_0':
/opt/omniORB/include/omnithread.h:521: undefined reference to
`omni_thread::init_t::init_t(void)'
/opt/Projects/vis/lib/libcorba.a(vis_config.o): In function
`_static_initialization_and_destruction_0':
/opt/omniORB/include/omnithread.h:521: undefined reference to
`omni_thread::init_t::init_t(void)'
/opt/Projects/vis/lib/libcorba.a(vg_ipc_msg_queue.o): In function
`_static_initialization_and_destruction_0':
/opt/omniORB/include/omnithread.h:521: undefined reference to
`omni_thread::init_t::init_t(void)'
/opt/Projects/vis/lib/libcorba.a(vg_ipc_base.o): In function
`_static_initialization_and_destruction_0':
/opt/omniORB/include/omnithread.h:521: undefined reference to
`omni_thread::init_t::init_t(void)'
collect2: ld returned 1 exit status
make[3]: *** [visco_init] Error 1
make[3]: Leaving directory `/opt/Projects/vis/visco_init/visco_init'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/opt/Projects/vis/visco_init/visco_init'
make[1]: *** [all-recursive] Error 1
make[1]: Leaving directory `/opt/Projects/vis/visco_init'
make: *** [all-recursive-am] Error 2
--- cut here ---