D to Javascript converter (a hacked up dmd)

Johannes Pfau nospam at example.com
Fri Mar 2 00:45:55 PST 2012


Am Thu, 01 Mar 2012 21:13:41 +0100
schrieb Bystroushaak <bystrousak at kitakitsune.org>:

> I've played with gdc, but it's pretty complicated. I have few ADM 5120
> routers with debwrt and it would be nice to be able compile D2 code
> there, but so far, it was just fail.
> 

ADM 5120 is MIPS, right? Are you trying to build a cross compiler or a
compiler running on the MIPS itself? Making a cross-compiler is never
easy. Assuming you already have a C cross-compiler, you have to patch
the build process to include D at some point. You could also try
https://bitbucket.org/goshawk/gdc/wiki/crosstool-ng
but then you need a compatible 'sysroot' (a folder including the basic
libraries & headers as on your target system, must include libc &
some kernel headers, afaik) for your router.

Another issue: druntime/phobos might not compile (as long as
debwrt uses glibc it could work though), so configure with
--disable-phobos to disable both druntime and phobos. You'll only get
the compiler this way.

And MIPS is probably also affected by GDC issue 120, so you have to
configure like this:
DFLAGS="-fno-section-anchors" ./configure [configure arguments here]


More information about the Digitalmars-d-announce mailing list