[Mono-devel-list] Mono on AIX [Virus checked]

Winfried.Harbecke at Extern.Sparkassen-Informatik.de Winfried.Harbecke at Extern.Sparkassen-Informatik.de
Tue Nov 30 11:08:37 EST 2004


as a follow up to my status report I would appreciate if Paolo could have a
at the basic patches that will be required to start with the real work on
the AIX

It seems to me that I have arrived at a point where the real work can take
off, I get
assertion violations in mint:

/bin/sh ../../mkinstalldirs /opt/freeware/lib/mono/1.0
 ../.././install-sh -c -m 644 mscorlib.dll
MONO_PATH=. ../../mono/interpreter/mint --config ../../data/config
./../gacutil.exe /i ./Accessibility.dll /f /package 1.0 /gacdir
/opt/freeware/lib /root /opt/freeware/lib

** (./../gacutil.exe:20402): WARNING **: Using non-atomic functions!

** ERROR **: file interp.c: line 4153 (add_signal_handler): assertion
failed: (sigaction (signo, &sa, NULL) != -1)
/bin/sh: 20402 IOT/Abbruch-Trap(coredump)

I have been in touch with Bernard Solomon - it looks like he is tied down
other work, but he got my status report. In case I get tied down with other
at least I could help preparing the ground. I did start looking at Power PC
instruction set and AIX linkage conventions, so in case someone else wants
to jump in, I can provide some pointers. Since the list archives don't
provide a
global search function, it might be a good idea to put my collection of AIX
experiences into an easily accessible place - any ideas? At least, I need
document the RPMs I used, the URLs where they were obtained, and
the configure and compile details.

These are patches for GCC 3.3.4 running with native as and ld against AIX
(you have to install bos.adt.libm from AIX installation CD 1 after
installing the plain OS).
For native xlc (Visual Age), it should suffice to replace "-Wl,-brtl" with
"-brtl" and drop

The patches themselves are trivial, tackling the environmental noise was
the hard
part - I had to find out all about AIX ld that I never wanted to know.

/opt/freeware/bin/diff -crN ../mono-1.1.1/configure.in ./configure.in
*** ../mono-1.1.1/configure.in      2004-09-21 13:28:22.000000000 -0500
--- ./configure.in      2004-11-29 08:51:02.000000000 -0600
*** 171,176 ****
--- 171,187 ----
+     *-*-aix*)
+           platform_win32=no
+           libmono_cflags="-D_REENTRANT -D_THREAD_SAFE"
+           libgc_threads=pthreads
+           LDFLAGS=" -Wl,-brtl"
+           libmono_ldflags="-Wl,-brtl"
+           need_link_unlink=yes
+           libdl=
+           libgc_threads=pthreads
+           ;;
            AC_MSG_WARN([*** Please add $host to configure.in checks!])
*** 1239,1244 ****
--- 1250,1260 ----
+     powerpc-*-aix*)
+           TARGET=POWERPC;
+           arch_target=ppc;
+           JIT_SUPPORTED=no
+           ;;
      arm-*-linux-* | armv4l-*-linux-*)
/opt/freeware/bin/diff -crN ../mono-1.1.1/mono/arch/ppc/Makefile.in
*** ../mono-1.1.1/mono/arch/ppc/Makefile.in     2004-09-21
14:00:52.000000000 -0500
--- ./mono/arch/ppc/Makefile.in     2004-11-30 07:42:02.000000000 -0600
*** 145,151 ****

  test_SOURCES = test.c
  test_OBJECTS = test.$(OBJEXT)
! test_LDADD = $(LDADD)
  test_LDFLAGS =

--- 145,151 ----

  test_SOURCES = test.c
  test_OBJECTS = test.$(OBJEXT)
! test_LDADD = $(LDADD) $(GLIB_LIBS)
  test_LDFLAGS =

/opt/freeware/bin/diff -crN ../mono-1.1.1/mono/io-layer/threads.h
*** ../mono-1.1.1/mono/io-layer/threads.h 2004-06-03 13:58:23.000000000
--- ./mono/io-layer/threads.h 2004-11-29 08:46:48.000000000 -0600
*** 24,30 ****
--- 24,32 ----

+ #ifndef _AIX
  #define THREAD_TERMINATE          0x0001
+ #endif /* _AIX */
  #define THREAD_SUSPEND_RESUME           0x0002
  #define THREAD_GET_CONTEXT        0x0008
  #define THREAD_SET_CONTEXT        0x0010
/opt/freeware/bin/diff -crN ../mono-1.1.1/mono/io-layer/misc.c
*** ../mono-1.1.1/mono/io-layer/misc.c    2003-06-17 09:44:46.000000000
--- ./mono/io-layer/misc.c    2004-11-29 08:46:48.000000000 -0600
*** 10,15 ****
--- 10,20 ----
  #include <config.h>
  #include <glib.h>
  #include <sys/time.h>
+ #ifdef _AIX
+ #include <time.h>
+ #endif /* _AIX */
  #include <stdlib.h>

  #include "misc-private.h"

AIX 5 requires fewer patches than AIX 4.3, apparently IBM has fixed the
IPV6 implementation
and the asychronous IO stuff in <aio.h>. They also now provide distinct
errno values when
compiling with -D_LINUX_SOURCE_COMPAT. If I find a lot of time, I might
look at the
AIX 4.3 environment again, but IBM is not committing to its Linux toolbox
ftp site for 4.3,
and the Gnome people at Bull have also drastically reduced their support
for 4.3.
In my opinion, it makes sense to concentrate on AIX 5, even to the point of
having "*-*-aix5*)" instead of '"*-*-aix)" in configure.in.

Miguel has ben criticizing some of the patches that Eran Sandler has been
suggesting. Please let me know if I can improve my stuff so that it is
fully in line
with Mono general engineering priciples. I could also test any modified
against the CVS version if that is a requirement. In a strict
interpretation of POSIX,
the <sys/time.h> in mono/io-layer/misc.c is a bug,


            ... The <time.h> header shall declare the structure timespec,

The THREAD_* defines in mono/io-layer/misc.c are not being used anywhere
(except THREAD_ALL_ACCESS), it might make sense to reduce the potential
of name conflict by another prefix.

The glib library reference in the arch/ppc Makefile is required because the
asm macros
are pulling in the glib trace function "g_logv".

Paolo, there is a collection of slides that you apparently presented to an
audience  (at least it it accessible from an IBM page) - what was the
It looks like IBM is running some .NET integration projects, but I have a
that they have not made up their mind if they should put their resources
Open Source activities that (from their pserspective) support Microsoft.


More information about the Mono-devel-list mailing list