[omniORB] Omniorb osx-arm64 cross compilation

Duncan Grisby duncan at grisby.org
Thu Oct 27 20:52:33 UTC 2022


Can you use omniORB 4.3.x rather than 4.2.5?  Cross compiling support
has been improved in 4.3.

It is by design that omniidl and omkdepend are not built when cross
compiling, because the build of omniORB must be able to run omniidl,
meaning it needs omniidl to be compiled for the system running the
build, not for the cross-compilation target.

Even if you had a native omniidl to use in the build, it would be
tricky to cross compile omniidl for the target architecture. It needs
to build a Python extension module that works with the target system's
Python, but the build runs Python to get various configuration details
from it including Python's name of the architecture that is embedded in
the library name. Obviously the cross-compile cannot run the target
system's Python, so it would run the build system's Python and get the
wrong details.

In 4.2.x, cross-compiling is activated with make variables calling it
an "EmbeddedSystem", with the expectation that it is a minimal small
system, and therefore it does not build things like omniNames or the
COS libraries. In 4.3.x, it now makes a clear split between cross
compiling and minimal embedded systems, so when cross compiling you get
those things. It still does not compile omniidl, though.

You can easily modify the 4.2.x build so it makes those things. If you
look at omniORB/src/dir.mk, you will see:

   ...
   
   ifndef EmbeddedSystem
   SUBDIRS += appl services
   endif
   

Simply removing the ifndef around that will cause it to build the appl
and services directories.

Duncan.


On Mon, 2022-10-17 at 11:14 +0000, Benjamin Bertrand via omniORB-list
wrote:
> Hello,
>  
> I have been trying to create a conda package of omniorb for Apple M1.
> On conda-forge we currently have to cross-compile.
> The compilation is successful, but I noticed that many files are
> missing (the COS include and libs, the bin and python omniidl module)
> compared to the intel version:
>  
> diff -u osx_64/omniorb-libs/files osx_arm64/omniorb-libs/files
> --- osx_64/omniorb-libs/files       2022-05-10 12:47:44.000000000
> +0200
> +++ osx_arm64/omniorb-libs/files            2022-05-10
> 14:01:24.000000000 +0200
> @@ -1,13 +1,3 @@
> -include/COS/COS_sysdep.h
> -include/COS/CosEventChannelAdmin.hh
> -include/COS/CosEventComm.hh
> -include/COS/CosLifeCycle.hh
> -include/COS/CosNotification.hh
> -include/COS/CosNotifyChannelAdmin.hh
> -include/COS/CosNotifyComm.hh
> -include/COS/CosNotifyFilter.hh
> -include/COS/CosTime.hh
> -include/COS/TimeBase.hh
> include/omniORB4/BiDirPolicy.h
> include/omniORB4/CORBA.h
> include/omniORB4/CORBA_AbstractBase.h
> @@ -196,12 +186,6 @@
> include/omnithread/nt.h
> include/omnithread/posix.h
> include/omnithread/pthread_nt.h
> -lib/libCOS4.2.5.dylib
> -lib/libCOS4.2.dylib
> -lib/libCOS4.dylib
> -lib/libCOSDynamic4.2.5.dylib
> -lib/libCOSDynamic4.2.dylib
> -lib/libCOSDynamic4.dylib
> lib/libomniCodeSets4.2.5.dylib
> lib/libomniCodeSets4.2.dylib
> lib/libomniCodeSets4.dylib
>  
> -bin/catior
> -bin/convertior
> -bin/genior
> -bin/nameclt
> -bin/omkdepend
> -bin/omniMapper
> -bin/omniNames
> -bin/omnicpp
> -bin/omniidl
> -bin/omniidlrun.py
>  
> Full
> log: https://dev.azure.com/conda-forge/84710dde-1620-425b-80d0-4cf5ba
> ca359d/_apis/build/builds/508418/logs/252
>  
> The bin and omniidl module are maybe not compiled by default when
> cross-compiling? Is there a way to force it?
> What could be the issue regarding the COS include and libs?
>  
> Thanks
>  
> Benjamin
>  
> _______________________________________________
> omniORB-list mailing list
> omniORB-list at omniorb-support.com
> https://www.omniorb-support.com/mailman/listinfo/omniorb-list

-- 
 -- Duncan Grisby --
  -- duncan at grisby.org --
   -- http://www.grisby.org --




More information about the omniORB-list mailing list