[omniORB] OmniORB 3.0.2 on HP-UX 10.20 using gcc 2.95.2 and Python 2.0

Gary D. Duzan gdd0@gte.com
Fri, 16 Feb 2001 17:13:13 -0500


In Message <3owvb1m4qc.fsf@neem.uk.research.att.com> ,
   Sai-Lai Lo <S.Lo@uk.research.att.com> wrote:

=>I think using gcc on HPUX for any kind of thread safe C++ is a lose course.
=>So far I have not heard anyone who has succeeded in doing so.
=>
=>AFAIK, omniORB works when compile with HP aC++ on HP-UX 10.20. I don't have
=>access to a 10.20 machine so cannot say for sure. It definitely works on
=>HP-UX 11.00 and we provide the binary for download.

   I just finished building from CVS on 10.20 with aCC, and it
seems to be working fine. The biggest challenge was digging up
the 10.20 release media and installing the DCEProg package in
order to get pthreads. The only change I made to the config was
to use "-O" instead of "-O2", which aCC warns about. ("+O2" is
the right thing for aCC; "-O2" is treated as "-O -2". "-O" is
the same as "+O2".) Once I set SHLIB_PATH to point to the lib
directory, everything worked fine.

=>The only drawback with using HP aC++ is that python can't load the shared
=>library built by that compiler. For the full story please read the readme
=>on HPUX.

   If you are using Python 2.0, you can configure it like so:

./configure  --without-gcc --with-cxx=/opt/aCC/bin/aCC

and get a Python that works fine with omniidl and omniORBpy. It
passes all the type tests, though the performance tests have yet
to get past single longs on my D380/2. I'm not sure what is going
on in this case.  It isn't even taking up much CPU on either end.
   Oh, there was one thing I did have to change to get _omnipymodule
to compile. In /usr/local/include/python2.0/config.h, change:

/* Define as __inline if that's what the C compiler calls it.  */
#define inline

  to:

/* Define as __inline if that's what the C compiler calls it.  */
#ifndef __cplusplus
#define inline
#endif

   aCC gets really confused when C++'s inline attribute is ignored,
causing numerous linking problems. Come to think of it, I think I
had to do this on AIX with xlC, as well. I'll have to check and see
if the Python developers will pick up this change.
   I'd be interested in hearing anyone else's experiences with OmniORB
on HP-UX 10.20. We're in the process of designing an agent for a system
running on HP-UX, and OmniORB is looking like the tool to use assuming
it will work for us.

					Gary Duzan
					Verizon Laboratories



=>>>>>> Manning, Kevin J writes:
=>
=>> I am having problems building OmniORB 3.0.2 on HP-UX 10.20 using gcc 2.95.2, Python 2.0 and GNU pth.  
=>
=>> I have made a few mods to the make files and soure for omnithreads in order to switch from the HP aC++ compiler and to u
se GNU pth.  The omnithreads library built successfuly. omniidl linked succesfully with python2.0 and GNU pth (-lpthread).  
However there is a Bus error core dump when making the Naming service i.e. ../../../bin/hppa_hpux_10.20/omniidl -bcxx -Wba -
p../../../src/lib/omniORB2  -ComniORB3 ../../../idl/Naming.idl in directory omni/src/lib/omniORB2.
=>
=>> Make transcript extract:
=>
=>> g++ -c -g -I/software_hp/include -Wall -Wno-unused -g -D_REENTRANT  -DPthreadDraftVersion=10 -DNO_PTHREAD_GET_EXPIRATION
_NP -I.  -I../../../include -D__hppa__ -D__hpux__ -D__OSVERSION__=10 posix.cc -o posix.o
=>> + rm -f libomnithread.a
=>> + ar cq libomnithread.a posix.o
=>> + ranlib libomnithread.a
=>> + ../../../bin/scripts/install-sh -c -m 0755 libomnithread.a ../../../lib/hppa_hpux_10.20
=>> gnumake[2]: Leaving directory `/users/smit/kjm/hp/omni/src/lib/omnithread'
=>> making export in src/lib/omniORB2...
=>> gnumake[2]: Entering directory `/users/smit/kjm/hp/omni/src/lib/omniORB2'
=>> ../../../bin/hppa_hpux_10.20/omniidl -bcxx -Wba -p../../../src/lib/omniORB2  -ComniORB3 ../../../idl/Naming.idl
=>> gnumake[2]: *** [omniORB3/Naming.hh] Bus error (core dumped)
=>> gnumake[2]: Leaving directory `/users/smit/kjm/hp/omni/src/lib/omniORB2'
=>> gnumake[1]: *** [export] Error 1
=>> gnumake[1]: Leaving directory `/users/smit/kjm/hp/omni/src/lib'
=>> gnumake: *** [export] Error 1
=>
=>> gdb analysis:
=>
=>> bash-2.02$ gdb ../../../bin/hppa_hpux_10.20/omniidl core
=>> GNU gdb 4.18
=>> Copyright 1998 Free Software Foundation, Inc.
=>> GDB is free software, covered by the GNU General Public License, and you are
=>> welcome to change it and/or distribute copies of it under certain conditions.
=>> Type "show copying" to see the conditions.
=>> There is absolutely no warranty for GDB.  Type "show warranty" for details.
=>> This GDB was configured as "hppa1.1-hp-hpux10.20"...
=>> Core was generated by `omniidl'.
=>> Program terminated with signal 10, Bus error.
=>
=>> warning: The shared libraries were not privately mapped; setting a
=>> breakpoint in a shared library will not work until you rerun the program.
=>
=>> Reading symbols from ../../../bin/hppa_hpux_10.20/omniidl...done.
=>> Reading symbols from /software_hp/lib/libpthread.sl.13...done.
=>> Reading symbols from /usr/lib/libc.1...done.
=>> Reading symbols from /usr/lib/libdld.1...done.
=>> #0  0x3dfd4 in IdlType::init () at idltype.cc:145
=>> 145         BaseType::nullType                = new BaseType(IdlType::tk_null);
=>> (gdb) where
=>> #0  0x3dfd4 in IdlType::init () at idltype.cc:145
=>> #1  0x60408 in AST::process (f=0x4016d5e4, 
=>>     name=0x4014ed8c "../../../bin/hppa_hpux_10.20/omnicpp -lang-c++ -undef -D__OMNIIDL__=0x2301 -D__OMNIIDL_CXX__ ../../
../idl/Naming.idl") at idlast.cc:241
=>> #2  0x80fa0 in IdlPyCompile (self=0x0, args=0x400e0734) at idlpython.cc:1257
=>> #3  0xc6930 in call_builtin () from ../../../bin/hppa_hpux_10.20/omniidl
=>> #4  0xc67d0 in PyEval_CallObjectWithKeywords ()
=>>    from ../../../bin/hppa_hpux_10.20/omniidl
=>> #5  0xc4fa8 in $000000BF () from ../../../bin/hppa_hpux_10.20/omniidl
=>> #6  0xc4b2c in $000000BF () from ../../../bin/hppa_hpux_10.20/omniidl
=>> #7  0xc11a0 in PyEval_EvalCode () from ../../../bin/hppa_hpux_10.20/omniidl
=>> #8  0xa4350 in run_node () from ../../../bin/hppa_hpux_10.20/omniidl
=>> #9  0xa4308 in run_err_node () from ../../../bin/hppa_hpux_10.20/omniidl
=>> #10 0xa4264 in PyRun_String () from ../../../bin/hppa_hpux_10.20/omniidl
=>> #11 0xa389c in PyRun_SimpleString () from ../../../bin/hppa_hpux_10.20/omniidl
=>> #12 0x81e30 in main (argc=6, argv=0x7b03a
=>
=>> My questions are:  
=>
=>> Has anyone else built a similar configuration?
=>> Is it worth pursuing an OmniOrb build with this type of configuration?
=>> Is it worth purchasing the HP C++ compiler? 
=>
=>> Regards,
=>
=>> Kevin Manning
=>
=>
=>
=>
=>-- 
=>Sai-Lai Lo                                   S.Lo@uk.research.att.com
=>AT&T Laboratories Cambridge           WWW:   http://www.uk.research.att.com 
=>24a Trumpington Street                Tel:   +44 1223 343000
=>Cambridge CB2 1QA                     Fax:   +44 1223 313542
=>ENGLAND
=>
=>