Download Reference Manual
The Developer's Library for D
About Wiki Forums Source Search Contact

Tango on OS X

Moderators: kris

Posted: 02/08/07 05:35:30

After building tango I tried building a simple "Hello World". This gives an error ... is there any reason why it is not recognizing my mac as a Posix system.

/usr/lib/gcc/i686-apple-darwin8/4.0.1/../../../../include/d/4.0.1/tango/sys/Common.d:77: static assert (0) is false

===Common==== else version (Posix)

{ private import tango.stdc.errno; private import tango.stdc.string; }


static assert(0);


Author Message

Posted: 02/09/07 02:32:32

Did you provide a version=Posix option to the compiler?

Posted: 03/11/07 21:52:20


I also am trying to install Tango on OS/X. I'm doing a source install from tango-0.95.1-src.tar.gz since the .sh installers are for linux. I'm getting the following error:

gdc -o aApplyR.o -g -frelease -O2 -fversion=GC_Use_Alloc_MMap -fversion=GC_Use_Stack_Fixed -fversion=GC_Use_Data_Dyld -nostdinc -fversion=Posix -I.. -I../.. -I../../.. -I . -I ./../../gc/gdc -I ./. -c aApplyR.d gdc -o adi.o -g -frelease -O2 -fversion=GC_Use_Alloc_MMap -fversion=GC_Use_Stack_Fixed -fversion=GC_Use_Data_Dyld -nostdinc -fversion=Posix -I.. -I../.. -I../../.. -I . -I ./../../gc/gdc -I ./. -c adi.d gdc -o arraycast.o -g -frelease -O2 -fversion=GC_Use_Alloc_MMap -fversion=GC_Use_Stack_Fixed -fversion=GC_Use_Data_Dyld -nostdinc -fversion=Posix -I.. -I../.. -I../../.. -I . -I ./../../gc/gdc -I ./. -c arraycast.d gdc -o arraycat.o -g -frelease -O2 -fversion=GC_Use_Alloc_MMap -fversion=GC_Use_Stack_Fixed -fversion=GC_Use_Data_Dyld -nostdinc -fversion=Posix -I.. -I../.. -I../../.. -I . -I ./../../gc/gdc -I ./. -c arraycat.d gdc -o cast.o -g -frelease -O2 -fversion=GC_Use_Alloc_MMap -fversion=GC_Use_Stack_Fixed -fversion=GC_Use_Data_Dyld -nostdinc -fversion=Posix -I.. -I../.. -I../../.. -I . -I ./../../gc/gdc -I ./. -c cast.d gcc -o critical.o -DHAVE_CONFIG_H -I . -I ./gcc -g -O2 -c critical.c gdc -o dgccmain2.o -g -frelease -O2 -fversion=GC_Use_Alloc_MMap -fversion=GC_Use_Stack_Fixed -fversion=GC_Use_Data_Dyld -nostdinc -fversion=Posix -I.. -I../.. -I../../.. -I . -I ./../../gc/gdc -I ./. -c dgccmain2.d gdc -o genobj.o -g -frelease -O2 -fversion=GC_Use_Alloc_MMap -fversion=GC_Use_Stack_Fixed -fversion=GC_Use_Data_Dyld -nostdinc -fversion=Posix -I.. -I../.. -I../../.. -I . -I ./../../gc/gdc -I ./. -c genobj.d /Users/dvdf/Data/Staging/r0.22rc2/gcc-5363/build/obj/src/gcc/d/dmd/toobj.c:417: failed assertion `classinfo->structsize == CLASSINFO_SIZE' genobj.d:181: internal compiler error: Abort trap Please submit a full bug report, with preprocessed source if appropriate. See <URL:> for instructions. make[1]: *** [genobj.o] Error 1 make: *** [lib] Error 2

Should I be doing a source install or using one of the other installers? If I should be using the source install, what should my build command look like? Do I need to specify a posix version? If so, how does that look?



Posted: 03/11/07 21:56:38

In theory, the should work (it has been reported to work on OSX for some). If you have any issues with it, please post them. Thanks!

Posted: 03/12/07 01:17:38

The CLASSINFO_SIZE bugs seem most often related to using a version of the runtime that was designed for a different compiler version. We try to keep the Tango trunk up to date with compiler releases, but the installable release is a bit behind at the moment.

Posted: 10/20/08 14:57:38

I've installed latest gdc and tango on mac os x, helloworld compiles and works. Tango version in core.Version is 0.99.7, but there isn't tango.util.Arguments - is it missed?

Posted: 10/20/08 15:59:50

Arguments made it in in earlier releases by a mistake - it is meant for re-inclusion after a review in 0.99.8 (I hope).

Posted: 10/20/08 16:10:25

Oh noes, it's so useful... ArgParser? seems harder to use.

Posted: 10/20/08 16:17:41

it should be fixed in the next release

Posted: 10/21/08 08:40:55

After some practice Arguments seems to miss a way to get not only count of flags, but all values of a flag, not only first. How to get this: myapp.exe -lmyarg1 -lmyarg2 -lmyarg3? argl? will return only "myarg1", and tho other values are lost...

Posted: 10/21/08 12:46:15

I was wrong - ArgParser? is easy to use and fully customizeable. Tango is very, very cool.

Posted: 10/21/08 13:56:21 -- Modified: 10/21/08 14:00:18 by

Same latest gdcmac, tango for mac: Stdout successfully prints everything except float types: when I try to stdout float (by (float) or .format( {}, float )), tango throws "tango.core.Exception.IllegalArgumentException?: Float.pow10 :: exponent too large". Layout!(char) also gives same exception when I try to give any float to it.