[omniORB] omniORBpy on AIX
Alex Tingle
alex.omniorb at firetree.net
Fri May 27 15:42:49 BST 2005
Hi Duncan,
This is the third time I've punted this patch. I'm hoping to get a response this time.
Currently omniORBpy does not link properly on AIX. This is because the make file does not follow the basic instructions for building a Python module on that platform.
This patch fixes that problem. What's it going to take to get it into CVS?
regards,
-Alex
--
On Wed, 27 Apr 2005 15:37:53 +0100
Alex Tingle <alex.tingle at bronermetals.com> wrote:
> Hi Duncan,
>
> This patch fixes a longstanding problem with omniORBpy on AIX. The
> problem was that it wouldn't link. And even when it did link, python
> would crash when you tried to import the CORBA module.
>
> I've read up in the subject, and discovered that the recommended way to
> build Python modules on AIX is through a script (ld_so_aix). For
> details see the file Misc/AIX-NOTES that is distributed with the Python
> source code.
>
> This patch changes omniORBpy to use this script on AIX. I've tested it,
> and it works perfectly. (First time I've ever seen omniORBpy work on
> the AIX - w00t!)
>
> I confess that I'm not very happy with the details of the patch.
> Basically, I've thrown out the idea of using the make variables
> `SharedLibraryPlatformLinkFlagsTemplate' &
> 'PythonLibraryPlatformLinkFlagsTemplate', and I've just redefined
> MakeCXXSharedLibrary instead. This means that `beforeauto.mk.in' now
> ONLY knows how to make Python shared libs, not any other kind of lib. I
> suppose that you would rather keep this file the same between omniORBpy
> & omniORB itself - this change does not achieve that.
>
> Anyway, this is still a major step forward, so I thought I'd share it.
>
> -Alex Tingle
>
--
:: alex tingle
:: http://www.firetree.net/consulting/
:: alex.tingle AT firetree.net +44-7901-552763
-------------- next part --------------
Index: mk/beforeauto.mk.in
===================================================================
RCS file: /cvsroot/omniorb/omniORBpy/mk/Attic/beforeauto.mk.in,v
retrieving revision 1.1.2.16
diff -c -r1.1.2.16 beforeauto.mk.in
*** mk/beforeauto.mk.in 15 Mar 2005 09:41:27 -0000 1.1.2.16
--- mk/beforeauto.mk.in 27 Apr 2005 14:22:25 -0000
***************
*** 944,951 ****
#SHAREDLIB_SUFFIX = so
PythonSHAREDLIB_SUFFIX = so
! # this works only for xlc version >= 5
! SharedLibraryPlatformLinkFlagsTemplate = -qmkshrobj
endif # compiler not gcc
endif # AIX
--- 944,970 ----
#SHAREDLIB_SUFFIX = so
PythonSHAREDLIB_SUFFIX = so
! # (Not used on AIX)
! SharedLibraryPlatformLinkFlagsTemplate :=
!
! # Need to use the script 'ld_so_aix' to make Python modules on AIX.
! # For details see the file Misc/AIX-NOTES that is distributed with the Python
! # source code.
!
! # The pythonX.Y/config directory only exists in Python v2.3+, so this solution
! # doesn't work for earlier versions of Python. (But omniORBpy did't work for
! # earlier versions of Python anyway.)
! PYCONFIGDIR := $(INSTALLPYTHONDIR)/../config
!
! define MakeCXXSharedLibrary
! $(ParseNameSpec); \
! soname=$(SharedLibrarySoNameTemplate); \
! set -x; \
! $(RM) $@; \
! PATH=$(PYCONFIGDIR):$$PATH \
! ld_so_aix $(CXX) -bI:$(PYCONFIGDIR)/python.exp -G -o $@ \
! $(IMPORT_LIBRARY_FLAGS) $(filter-out $(LibSuffixPattern),$^) $$extralibs;
! endef
endif # compiler not gcc
endif # AIX
More information about the omniORB-list
mailing list