[Ace-users] [tao-users] Compile for TAO fails with:/usr/tools/ACE_wrappers/lib/libACEXML_Parser.so: undefined reference to `ACE_Obstack_T errors

Douglas C. Schmidt schmidt at dre.vanderbilt.edu
Wed Jan 16 16:08:24 CST 2008


Hi Martin,

   Thanks for using the PRF.

>     TAO VERSION: 1.6
>     ACE VERSION: 5.6

I believe that we this has been fixed in more recent releases.  Kitty,
do you recall the status here?

BTW, Martin, I recommend not using ACEXML since it's no longer
supported by us.  We've switched over to using Xerces ourselves.

Thanks,

        Doug

>     HOST MACHINE and OPERATING SYSTEM:
>     
>     Intel Xeon 3.0 GHz Dual Dual Core running  2.6.18-1.2798.fc6 #1 SMP Mon Oct 16 14:37:32 EDT 2006 i686 i686 i386 GNU/Linux
>     
>     gcc -v
>     Using built-in specs.
>     Target: i386-redhat-linux
>     Configured with: ../configure --prefix=/usr --mandir=/usr/share/man --infodir=/usr/share/info --enable-shared --enable-threads=posix --enable-checking=release --with-system-zlib --enable-__cxa_atexit --disable-libunwind-exceptions --enable-libgcj-multifile --enable-languages=c,c++,objc,obj-c++,java,fortran,ada --enable-java-awt=gtk --disable-dssi --enable-plugin --with-java-home=/usr/lib/jvm/java-1.4.2-gcj-1.4.2.0/jre --with-cpu=generic --host=i386-redhat-linux
>     Thread model: posix
>     gcc version 4.1.1 20061011 (Red Hat 4.1.1-30)
> 
>           
>         
>     TARGET MACHINE and OPERATING SYSTEM, if different from HOST:
>     COMPILER NAME AND VERSION (AND PATCHLEVEL):
> 
>     THE $ACE_ROOT/ace/config.h FILE [if you use a link to a platform-
>     specific file, simply state which one]:
>     
>     #include "ace/config-linux.h"
>     #define ACE_GCC_HAS_TEMPLATE_INSTANTIATION_VISIBILITY_ATTRS 1
>        
>     
> 
>     THE $ACE_ROOT/include/makeinclude/platform_macros.GNU FILE [if you
>     use a link to a platform-specific file, simply state which one
>     (unless this isn't used in this case, e.g., with Microsoft Visual
>     C++)]:
>     
>     include $(ACE_ROOT)/include/makeinclude/platform_linux.GNU
>       
>     
> 
>     CONTENTS OF $ACE_ROOT/bin/MakeProjectCreator/config/default.features
>     (used by MPC when you generate your own makefiles):
>     
>      file does not exist in this directory 
>     
>     
> 
>     AREA/CLASS/EXAMPLE AFFECTED:
> 
>     TAO failed to build: 
>     
>     GNUmakefile: /usr/tools/ACE_wrappers/TAO/orbsvcs/ImplRepo_Service/GNUmakefile.ImR_Activator_Service MAKEFLAGS=w
> 
>     g++ -fvisibility=hidden -fvisibility-inlines-hidden -W -Wall -Wpointer-arith -O3 -g -pipe    -pipe -DACE_HAS_LINUX_NPTL -D_REENTRANT -DACE_HAS_AIO_CALLS -D_GNU_SOURCE   -I/usr/tools/ACE_wrappers -I/usr/tools/ACE_wrappers/TAO -DACE_HAS_EXCEPTIONS -D__ACE_INLINE__ -I../../.. -I../.. -I../../../ACEXML/common -I../../orbsvcs  -c -o .obj/ImR_Activator.o ImR_Activator.cpp
>     g++ -fvisibility=hidden -fvisibility-inlines-hidden -W -Wall -Wpointer-arith -O3 -g -pipe    -pipe -DACE_HAS_LINUX_NPTL -D_REENTRANT -DACE_HAS_AIO_CALLS -D_GNU_SOURCE   -I/usr/tools/ACE_wrappers -I/usr/tools/ACE_wrappers/TAO -DACE_HAS_EXCEPTIONS -D__ACE_INLINE__ -I../../.. -I../.. -I../../../ACEXML/common -I../../orbsvcs  -c -o .obj/Activator_NT_Service.o Activator_NT_Service.cpp
>     g++ -fvisibility=hidden -fvisibility-inlines-hidden -W -Wall -Wpointer-arith -O3 -g -pipe    -pipe -DACE_HAS_LINUX_NPTL -D_REENTRANT -DACE_HAS_AIO_CALLS -D_GNU_SOURCE   -I/usr/tools/ACE_wrappers -I/usr/tools/ACE_wrappers/TAO -DACE_HAS_EXCEPTIONS -D__ACE_INLINE__ -I../../.. -I../.. -I../../../ACEXML/common -I../../orbsvcs  -Wl,-E -L/usr/tools/ACE_wrappers/ace -L./ -L/usr/tools/ACE_wrappers/lib -L/usr/tools/ACE_wrappers/TAO/tao -L. -L../../../lib -o ImR_Activator .obj/ImR_Activator.o .obj/Activator_NT_Service.o -lTAO_ImR_Activator -lTAO_ImR_Activator_IDL -lTAO_ImR_Locator_IDL -lTAO_ImR_Client -lTAO_Svc_Utils -lTAO_Messaging -lTAO_PI -lTAO_CodecFactory -lTAO_PortableServer -lTAO_Valuetype -lACEXML_Parser -lACEXML -lTAO_AnyTypeCode -lTAO -lACE -ldl -lpthread -lrt
>     /usr/tools/ACE_wrappers/lib/libACEXML_Parser.so: undefined reference to `ACE_Obstack_T<char>::grow(char)'
>     /usr/tools/ACE_wrappers/lib/libACEXML_Parser.so: undefined reference to `ACE_Obstack_T<char>::freeze()'
>     /usr/tools/ACE_wrappers/lib/libACEXML_Parser.so: undefined reference to `ACE_Obstack_T<char>::ACE_Obstack_T(unsigned int, ACE_Allocator*)'
>     /usr/tools/ACE_wrappers/lib/libACEXML_Parser.so: undefined reference to `ACE_Obstack_T<char>::release()'
>     /usr/tools/ACE_wrappers/lib/libACEXML_Parser.so: undefined reference to `ACE_Obstack_T<char>::unwind(void*)'
>     /usr/tools/ACE_wrappers/lib/libACEXML_Parser.so: undefined reference to `ACE_Obstack_T<char>::~ACE_Obstack_T()'
>     collect2: ld returned 1 exit status
>     make[1]: *** [ImR_Activator] Error 1
> 
>         
> 
> 
>     DOES THE PROBLEM AFFECT:
>         COMPILATION?   Yes
>             If so, what do your $ACE_ROOT/ace/config.h and
>             $ACE_ROOT/include/makeinclude/platform_macros.GNU contain?
>         
> 	
> 	 #include "ace/config-linux.h"
>          #define ACE_GCC_HAS_TEMPLATE_INSTANTIATION_VISIBILITY_ATTRS 1
> 	 
> 	 
> 	 include $(ACE_ROOT)/include/makeinclude/platform_linux.GNU
> 	
> 	
>     SYNOPSIS:
>  
>         Added #define ACE_GCC_HAS_TEMPLATE_INSTANTIATION_VISIBILITY_ATTRS 1 per the TAO Programmers Guide, Remedy IT, V. 0.17
> 	and TAO compile still fails due to the same error identified for FC6 in the FAQs.
> 	
>         used the following steps to build the ACE and TAO:
> 	
> 	Build ACE
> 	
> 	o       execute ACE_ROOT=/usr/tools/ACE_wrappers; export ACE_ROOT
> 	
> 	o       execute TAO_ROOT=$ACE_ROOT/TAO; export TAO_ROOT
> 	
> 	o       execute LD_LIBRARY_PATH=$ACE_ROOT/ace:$ACE_ROOT/lib:$LD_LIBRARY_PATH; export LD_LIBRARY_PATH
> 	
> 	o       Change directory to $ACE_ROOT/ace and create a file in that directory called “config.h” that contains the following two (2) lines:
>        		#include "ace/config-linux.h"
>        		#define ACE_GCC_HAS_TEMPLATE_INSTANTIATION_VISIBILITY_ATTRS 1
> 	
> 	o       Create a file in $ACE_ROOT/ace that directory called “platform_macros.GNU” that contains the following line:
> 		include $(ACE_ROOT)/include/makeinclude/platform_linux.GNU
> 
> 	o       Change directory to $ACE_ROOT/include/makeinclude
> 
> 	o       Create a file in that directory called “platform_macros.GNU” that contains the following line:
>        		include $(ACE_ROOT)/include/makeinclude/platform_linux.GNU
> 
> 	o       Change directory to $ACE_ROOT/ace
> 
> 	o       execute   make realclean
> 
> 	o       execute make
> 
> 	o       Change directory to $ACE_ROOT/apps/gperf
> 
> 	o       execute make clean
> 
> 	o       execute make
>  
>  
>         Build TAO
> 
> 	o       Change directory to $TAO_ROOT
> 
> 	o       Remove all of the pre-existing TAO GNUmakefile files, create custom GNUmakefiles, and run the make with the following four commands:
> 		
> 		find  .  -name ‘GNUmakefile.*’  -exec rm { } \;  (This command removes all existing GNUmakefiles)
>  
> 		$ACE_ROOT/bin/mwc.pl   TAO_ACE.mwc   -type   gnuace  (This command builds custom GNUmakefiles to create TAO core and orbsvcs libraries) 
>  
> 		make realclean  (ensure nothing is there that does not belong)
>  
> 		make 
>  
>  
> 
>     DESCRIPTION:
> 
>         Compile failure for ACE_Obstack_T undefined references.  Apparent fix does not work for this release of ACE/TAO.
> 
> 
>     REPEAT BY:
> [What you did to get the error; include test program or session
> transcript if at all possible.  ]
> 
>     SAMPLE FIX/WORKAROUND:
> [If available ]
> 



More information about the Ace-users mailing list