Discussion:
[omniORB] Compile with gcc on HP-UX 11i v2 (IA64)
lst_hoe01 at kwsoft.de ()
2006-07-13 13:33:57 UTC
Permalink
Hello

i have been tasked to manage the omniORB installation on our
development machines. On a new HP-UX machine with 11i v2 (11.23) IA64 i
get a fatal error from "ld" when trying to compile omniORB 4.0.7 :

ld: Unrecognized argument: -soname
Fatal error.
collect2: ld returned 1 exit status
gmake[4]: *** [_omniidlmodule.sl.1.0] Error 1
gmake[4]: Leaving directory
`/var/install/omniORB-4.0.7/build/src/tool/omniidl/cxx'
gmake[3]: *** [export] Error 1
gmake[3]: Leaving directory
`/var/install/omniORB-4.0.7/build/src/tool/omniidl'
gmake[2]: *** [export] Error 1
gmake[2]: Leaving directory `/var/install/omniORB-4.0.7/build/src/tool'
gmake[1]: *** [export] Error 1
gmake[1]: Leaving directory `/var/install/omniORB-4.0.7/build/src'
gmake: *** [all] Error 1

In fact the HP "ld" does not support the "-soname" so any hints where i
can alter this without breaking the build?

Used Versions :

uname -a
HP-UX hpux2 B.11.23 U ia64 2006875885 unlimited-user license

gcc -v
Using built-in specs.
Target: ia64-hp-hpux11.23
Configured with: ../gcc/configure
Thread model: posix
gcc version 4.1.1

gmake -v
GNU Make 3.80
Copyright (C) 2002 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.
There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A
PARTICULAR PURPOSE.

ld -V
ld: 92453-07 linker ld HP Itanium(R) B.12.34 IPF/IPF
ld: No input files

Thanxs

Andreas
Duncan Grisby
2006-07-14 15:50:55 UTC
Permalink
Post by lst_hoe01 at kwsoft.de ()
i have been tasked to manage the omniORB installation on our
development machines. On a new HP-UX machine with 11i v2 (11.23) IA64
It looks like you are trying to use the HP ld with gcc. The makefiles
assume that you're using GNU ld if you're using gcc. If you used the
configure script, you need to edit the HPUX section in
mk/beforeauto.mk.in; if you used the old platform configuration
mechanism, you need to edit the platform file you chose.

Cheers,

Duncan.
--
-- Duncan Grisby --
-- ***@grisby.org --
-- http://www.grisby.org --
lst_hoe01 at kwsoft.de ()
2006-07-14 20:28:39 UTC
Permalink
Post by Duncan Grisby
Post by lst_hoe01 at kwsoft.de ()
i have been tasked to manage the omniORB installation on our
development machines. On a new HP-UX machine with 11i v2 (11.23) IA64
It looks like you are trying to use the HP ld with gcc. The makefiles
assume that you're using GNU ld if you're using gcc. If you used the
configure script, you need to edit the HPUX section in
mk/beforeauto.mk.in; if you used the old platform configuration
mechanism, you need to edit the platform file you chose.
Thanxs for your hint

i changed the mk/beforeauto.mk.in to not include the "-soname" but now
i got trouble with Python/IDL. I have used the minimal Python binary
from the project website and set the PYTHON env to this binary. It is
recognized but something does not work as expected :

gmake[3]: Leaving directory
`/var/install/omniORB-4.0.7/build/src/lib/omnithread'
making export in src/lib/omniORB...
gmake[3]: Entering directory
`/var/install/omniORB-4.0.7/build/src/lib/omniORB'
../../../bin/omniidl -bcxx -Wba -p../../../../src/lib/omniORB -Wbdebug
-v -ComniORB4 ../../../../idl/Naming.idl

omniidl: ERROR!

omniidl: Could not open IDL compiler module _omniidlmodule.so
omniidl: Please make sure it is in directory
/var/install/omniORB-4.0.7/build/lib
omniidl: (or set the PYTHONPATH environment variable)

omniidl: (The error was 'Failed to load
/var/install/omniORB-4.0.7/build/lib/_omniidlmodule.sl')

Strange the file is there :

#ll lib
total 2688
lrwxr-xr-x 1 root sys 19 Jul 14 16:19
_omniidlmodule.sl -> _omniidlmodule.sl.1
lrwxr-xr-x 1 root sys 21 Jul 14 16:19
_omniidlmodule.sl.1 -> _omniidlmodule.sl.1.0
-rwxr-xr-x 1 root sys 966532 Jul 14 16:15
_omniidlmodule.sl.1.0
-rwxr-xr-x 1 root sys 36076 Jul 14 16:19 libomnithread.a
lrwxr-xr-x 1 root sys 18 Jul 14 16:19
libomnithread.sl -> libomnithread.sl.3
lrwxr-xr-x 1 root sys 20 Jul 14 16:19
libomnithread.sl.3 -> libomnithread.sl.3.2
-rwxr-xr-x 1 root sys 79192 Jul 14 16:15 libomnithread.sl.3.2
-rwxr-xr-x 1 root sys 279460 Jul 14 16:15 omnicpp
drwxrwxr-x 4 root sys 96 Jul 14 16:15 python

Is this Python just too old or do miss something?

../bin/hppa_hpux_11.00/omnipython
Python 1.5.2 (#24, Jul 10 2000, 12:43:26) [GCC 2.95.2 19991024
(release)] on hp-uxB
Copyright 1991-1995 Stichting Mathematisch Centrum, Amsterdam
Thanxs for any help

Regards

Andreas
lst_hoe01 at kwsoft.de ()
2006-07-18 19:33:19 UTC
Permalink
Hi Andreas,
Post by lst_hoe01 at kwsoft.de ()
omniidl: (The error was 'Failed to load
/var/install/omniORB-4.0.7/build/lib/_omniidlmodule.sl')
#ll lib
total 2688
lrwxr-xr-x 1 root sys 19 Jul 14 16:19
_omniidlmodule.sl -> _omniidlmodule.sl.1
lrwxr-xr-x 1 root sys 21 Jul 14 16:19
_omniidlmodule.sl.1 -> _omniidlmodule.sl.1.0
-rwxr-xr-x 1 root sys 966532 Jul 14 16:15
_omniidlmodule.sl.1.0
Is this Python just too old or do miss something?
I assume that you have created 64-bit _omniidlmodule.so in the compile
process. If that is true, then the failure indicates that 32-bit Python was
not able to load 64-bit module: you will have to get or compile 64-bit
Python as well.
The next one ...
I have fetched the source from Python.org and compiled it succesfully.

# /var/install/Python-2.4.3/python
Python 2.4.3 (#1, Jul 18 2006, 14:24:08)
[GCC 4.1.1] on hp-ux11
Type "help", "copyright", "credits" or "license" for more information.
With this i tried a new build and get the following :

../../../../../src/tool/omniidl/cxx/idlpython.cc:1569: error: expected
initializer before '*' token
../../../../../src/tool/omniidl/cxx/idlpython.cc:1579: error:
'PyMethodDef' does not name a type
../../../../../src/tool/omniidl/cxx/idlpython.cc: In function 'void
init_omniidl()':
../../../../../src/tool/omniidl/cxx/idlpython.cc:1596: error:
'PyObject' was not declared in this scope
../../../../../src/tool/omniidl/cxx/idlpython.cc:1596: error: 'm' was
not declared in this scope
../../../../../src/tool/omniidl/cxx/idlpython.cc:1596: error:
'omniidl_methods' was not declared in this scope
../../../../../src/tool/omniidl/cxx/idlpython.cc:1596: error:
'Py_InitModule' was not declared in this scope
../../../../../src/tool/omniidl/cxx/idlpython.cc:1598: error:
'PyString_FromString' was not declared in this scope
../../../../../src/tool/omniidl/cxx/idlpython.cc:1598: error:
'PyObject_SetAttrString' was not declared in this scope
gmake[4]: *** [idlpython.o] Error 1
gmake[4]: Leaving directory
`/var/install/omniORB-4.0.7/build/src/tool/omniidl/cxx'
gmake[3]: *** [export] Error 1
gmake[3]: Leaving directory
`/var/install/omniORB-4.0.7/build/src/tool/omniidl'
gmake[2]: *** [export] Error 1
gmake[2]: Leaving directory `/var/install/omniORB-4.0.7/build/src/tool'
gmake[1]: *** [export] Error 1
gmake[1]: Leaving directory `/var/install/omniORB-4.0.7/build/src'
gmake: *** [all] Error 1

Ayn hints if it is possible to build omniORB 4.0.7 at all on HP-UX with
gcc/g++??

Thanxs & Regards

Andreas
Eric McMillan
2006-07-18 21:39:11 UTC
Permalink
HP-UX/Itanium requires an extension of .so instead of .sl. You will need to
change beforemake.mk.in and src/tool/omniidl/cxx/dir.mk. The dir.mk file
hard-codes the module name as _omniidlmodule.sl, while the beforemake file
determines all the other library extensions.

There is one other problem. Configure doesn't check for a system supplied
alloca.h and, as a result, it defaults to the omniORB supplied one when
building omnicpp. A quick and dirty fix is to edit acconfig.h after running
configure to add a #define HAVE_ALLOCA and a #include <alloca.h>.

I haven't tried building this with gcc/g++, but I've successfully built it
using HP's AnsiC and aCC compilers.

Eric

-----Original Message-----
From: omniorb-list-***@omniorb-support.com
[mailto:omniorb-list-***@omniorb-support.com] On Behalf Of
***@kwsoft.de
Sent: Tuesday, July 18, 2006 6:33 AM
To: omniorb-***@omniorb-support.com
Subject: Re: [omniORB] Compile with gcc on HP-UX 11i v2 (IA64)
Hi Andreas,
Post by lst_hoe01 at kwsoft.de ()
omniidl: (The error was 'Failed to load
/var/install/omniORB-4.0.7/build/lib/_omniidlmodule.sl')
#ll lib
total 2688
lrwxr-xr-x 1 root sys 19 Jul 14 16:19
_omniidlmodule.sl -> _omniidlmodule.sl.1
lrwxr-xr-x 1 root sys 21 Jul 14 16:19
_omniidlmodule.sl.1 -> _omniidlmodule.sl.1.0
-rwxr-xr-x 1 root sys 966532 Jul 14 16:15
_omniidlmodule.sl.1.0
Is this Python just too old or do miss something?
I assume that you have created 64-bit _omniidlmodule.so in the compile
process. If that is true, then the failure indicates that 32-bit Python
was
not able to load 64-bit module: you will have to get or compile 64-bit
Python as well.
The next one ...
I have fetched the source from Python.org and compiled it succesfully.

# /var/install/Python-2.4.3/python
Python 2.4.3 (#1, Jul 18 2006, 14:24:08)
[GCC 4.1.1] on hp-ux11
Type "help", "copyright", "credits" or "license" for more information.
With this i tried a new build and get the following :

../../../../../src/tool/omniidl/cxx/idlpython.cc:1569: error: expected
initializer before '*' token
../../../../../src/tool/omniidl/cxx/idlpython.cc:1579: error:
'PyMethodDef' does not name a type
../../../../../src/tool/omniidl/cxx/idlpython.cc: In function 'void
init_omniidl()':
../../../../../src/tool/omniidl/cxx/idlpython.cc:1596: error:
'PyObject' was not declared in this scope
../../../../../src/tool/omniidl/cxx/idlpython.cc:1596: error: 'm' was
not declared in this scope
../../../../../src/tool/omniidl/cxx/idlpython.cc:1596: error:
'omniidl_methods' was not declared in this scope
../../../../../src/tool/omniidl/cxx/idlpython.cc:1596: error:
'Py_InitModule' was not declared in this scope
../../../../../src/tool/omniidl/cxx/idlpython.cc:1598: error:
'PyString_FromString' was not declared in this scope
../../../../../src/tool/omniidl/cxx/idlpython.cc:1598: error:
'PyObject_SetAttrString' was not declared in this scope
gmake[4]: *** [idlpython.o] Error 1
gmake[4]: Leaving directory
`/var/install/omniORB-4.0.7/build/src/tool/omniidl/cxx'
gmake[3]: *** [export] Error 1
gmake[3]: Leaving directory
`/var/install/omniORB-4.0.7/build/src/tool/omniidl'
gmake[2]: *** [export] Error 1
gmake[2]: Leaving directory `/var/install/omniORB-4.0.7/build/src/tool'
gmake[1]: *** [export] Error 1
gmake[1]: Leaving directory `/var/install/omniORB-4.0.7/build/src'
gmake: *** [all] Error 1

Ayn hints if it is possible to build omniORB 4.0.7 at all on HP-UX with
gcc/g++??

Thanxs & Regards

Andreas

Loading...