arm-wince D crosscompiler on the way, request help with mmap

kris foo at bar.com
Sun Apr 23 10:20:33 PDT 2006


Sean Kelly wrote:
> Chad J > wrote:
> 
>> I've been working on a cross compiler that runs in linux and compiles 
>> D code for Windows CE/Windows Mobile on the Arm/Xscale processor.  I 
>> have a working C/C++ cross compiler that I configured myself, and I am 
>> currently building one with D included.
>>
>> I've also run into a problem that I feel would be best handled by 
>> asking for help here.  While the xcompiler is building, it gets to the 
>> point where it checks for the C standard mmap function.  mmap does not 
>> exist. 
> 
> 
> mmap isn't a standard C function, it's a POSIX function.  Slight 
> difference, but important.
> 
>>  Then the make fails.  I looked at phobos, and it seems like mmap 
>> isn't entirely essential because most of the code can use equivelant 
>> Windows calls, which are available in WinCE.  One exception to that 
>> seems to be in phobos/internal/gc/gcgcc.d, where the alternative to 
>> "version (GC_Use_Alloc_MMap)" has //TODO written in it and no code to 
>> show.  I suppose there could be more if I haven't looked in enough files.
> 
> 
> It sounds like you're using the GDC Phobos library--the DMD version 
> doesn't have that file.  If you're targeting WinCE, the compiled code 
> will probably be linking to the DMD Phobos.  It has all the necessary 
> Windows calls in place.  Alternately, you may simply have to move some 
> DMD Phobos code into GDC or compile a slightly different set of object 
> files.  If it's any help, the GC files needed for Windows are:
> 
>     gc.obj
>     gcbits.obj
>     gcx.obj
>     win32.obj
> 
> gcstats.obj is required as well, but that should build as a part of 
> phobos/std.


PocketPC compiler? That's great to hear!

To make it easier on yourself, you might try to use Ares instead of 
Phobos? It's much smaller, much more concise, and Sean is very 
repsonsive in resolving any problem or question.

http://dsource.org/projects/ares

2 Cents



More information about the D.gnu mailing list