I tested gnstep-base-1.6.0 on darwin:
After I changed MFRAME_STRUCT_BYREF, Testing/nsconnection_server works,
and the client at least doesn't crash when passing structs.
With Google, I found the dlcompat library which helps loading dynamic
libraries at runtime: I just changed configure to recognize dladdr:
...
echo $ECHO_N "checking checking if dladdr() is available... $ECHO_C"
>&6
old_LDFLAGS="$LDFLAGS"
case "$target_os" in
linux-gnu*) LDFLAGS="$old_LDFLAGS -ldl";;
solaris*) LDFLAGS="$old_LDFLAGS -ldl";;
sysv4.2*) LDFLAGS="$old_LDFLAGS -ldl";;
darwin*) LDFLAGS="$old_LDFLAGS -ldl";;
...
To get a dynamic library (bundle) loaded at runtime, I changed
target.make
in section darwin:
BUNDLE_LD = /usr/bin/libtool
BUNDLE_LDFLAGS += -dynamic -flat_namespace -undefined warning
$(ARCH_FLAGS)
Unfortunately, although constructor functions work with cc and gcc,
configure cannot find a symbol called CTOR nor can the library at
runtime,
so Testing/nsbundle fails now with: