adtools / amigaos-cross-toolchain

AmigaOS cross compiler for Linux / MacOSX / Windows
184 stars 48 forks source link

Compilation fixes for OS X 10.9.5 (Apple LLVM version 6.0) #8

Closed argasek closed 9 years ago

argasek commented 9 years ago

Hi,

Here's a couple of fixes to build the project. I'm not entirely sure why vlink compilation worked properly earlier, but I've tested it on 2 machines and now both of them exhibit a problem with missing "objects" directory:

gcc -o  objects/main.o -std=c9x -O2 -fomit-frame-pointer -c  main.c
Assembler messages:
Fatal error: can't create objects/main.o: No such file or directory
make: *** [objects/main.o] Error 1
argasek@somewhere:~/vlink$ gcc --version
gcc (Debian 4.4.5-8) 4.4.5
Copyright (C) 2010 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

Same happens on OS X 10.9.5 with Homebrew.

The second patch is probably related to the new version of LLVM, which fails to compile vbcc with something like this:

/supp.h:680:108: error: expected ')'
struct Var *declare_builtin(char *name,int ztyp,int q1typ,int q1reg,int q2typ,int q2reg,int nosidefx,char *asm);

because asm is being interpreted as a reserved keyword.