How to impose D2 on gdc
Asked Answered
B

3

6

I have installed GDC from the software center of ubuntu.

The problem is that when I tried to compile a source that contain the keyword immutable, it gives me an error. Then I deduced that it compiles only D1.

If i want to compile D2 with GDC, what should I do?

Basuto answered 7/5, 2011 at 17:20 Comment(2)
Pretty sure the packaged GDC for Debian/Ubuntu is D1 only and an old version of GDC at that.Mongrel
That is correct. Ubuntu Maverick has the DMD-equivalent version 1.043 of GDC, and Natty has 1.063, according to packages.ubuntu.com.Balikpapan
P
5

Try looking here (warning: it's not yet complete in any shape or form).

Peptone answered 7/5, 2011 at 17:42 Comment(2)
Thanks for the reply. I'm wrong or what you linked is only for windows?Basuto
@Marco: Sorry, I was referring to the source code. I'm not sure they have binaries for Linux.Peptone
C
10

You need to pass -v2 to select D2 compiling, e.g.:

gdc -v2 main.d
Conjuration answered 7/5, 2011 at 23:52 Comment(0)
A
6

The packages in the linux repository are very out of date. To my knowledge, they are not compatible with D2 in any way. I've tried.

The only way that I know how to get D2 working with GDC would be to compile GDC from here: https://bitbucket.org/goshawk/gdc/downloads

If you follow the instruction on the wiki, you can optionally compile it to work with D2.

I have recently switched from dmd to gdc using this method and have had no problems. The code written and tested with dmd compiles cleanly with gdc.

Antherozoid answered 5/10, 2011 at 20:54 Comment(0)
P
5

Try looking here (warning: it's not yet complete in any shape or form).

Peptone answered 7/5, 2011 at 17:42 Comment(2)
Thanks for the reply. I'm wrong or what you linked is only for windows?Basuto
@Marco: Sorry, I was referring to the source code. I'm not sure they have binaries for Linux.Peptone

© 2022 - 2024 — McMap. All rights reserved.