I've been reading the forum and I've found that a few people are interested in OSX support. So I grabbed the source for the runtimes and started to compile. Here's what I've done so far. I've basically copied the freebsd configure bits and changed the MACHTYPE (??) to look for "darwin", after which configure ran fine.
Code: Select all
*-*-darwin* )
cat >>confdefs.h <<\_ACEOF
#define TARGET_FREEBSD 1
_ACEOF
cat >>confdefs.h <<\_ACEOF
#define TARGET_BASE_UNIX 1
_ACEOF
FBRT_TARGET_BASE=unix
FBRT_TARGET=freebsd
;;
Code: Select all
gcc -DHAVE_CONFIG_H -g -O2 -I. -I./freebsd -I./unix -I./x86 -I. -include config.h -c ./static/fbrt0.c -o fbrt0.o
/var/tmp//ccwNwJAx.s:9:Expected comma after segment-name
/var/tmp//ccwNwJAx.s:9:Rest of line ignored. 1st junk character valued 32 ( ).
/var/tmp//ccwNwJAx.s:13:Expected comma after segment-name
/var/tmp//ccwNwJAx.s:13:Rest of line ignored. 1st junk character valued 32 ( ).
make: *** [fbrt0.o] Error 1
Here's the bits that I suspect:
Code: Select all
static void * priorityhDoInit __attribute__((section(".ctors.65435"), used)) = fb_hDoInit;
static void * priorityhDoExit __attribute__((section(".dtors.65435"), used)) = fb_hDoExit;
Thanks!