[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Newsgroup Home]
[news.eclipse.dsdp.rtsc] Re: XDC on Mac OS X

Amichi Amar wrote:
It is possible to help out now. The RTSC tools include a number of native executables (e.g., xs, xdc, and xdcpkg, see

There currently isn't a cross compiler from windows to os x so I need to build xs, xdc etc from scratch to get them onto os x. Are these sources available?
We're working on getting the xdc, xs, sources available; we still need to get them through the eclipse IP process.


Otherwise, I could put together a target (simple copy of the Linux86 target) - but I have no way to test anything out (i.e. can't build native code etc).


So, what to do?
Good question.  It's tricky but possible ...

We use the xdc tools on Linux to build Solaris executables _without_ a Linux-to-Solaris cross compiler. I think we can do the same with OS X.

The way it works is to create a target (like gnu.targets.Sparc) which can be setup to remotely execute the compiler/linker/archiver on a different host. Recall that targets simply provide _any_ command sufficient to convert a .c to a .obj. Without a cross-compiler, the target supplies a command that simply rsh's to an appropriate host and does the compile.

When building on Linux, for example, the Linux host will rsh the compiler command to a specified Solaris host (see the remoteHost config param of the gnu.targets.ITarget interface http://rtsc.eclipse.org/cdoc-tip/index.html#gnu/targets/ITarget.html#remote.Host). The current gnu.targets.ITarget requires a network file system seen by both hosts.

We even use this technique to build Windows executables from a Linux host _without_ a cross-compiler(!). This has additional complications because the file systems are so different between *nix and Windows, but among *nix hosts the process is fairly easy.

Amichi