Tango 0.96 beta2 released

Frits van Bommel fvbommel at REMwOVExCAPSs.nl
Fri Mar 16 12:53:38 PDT 2007


Sean Kelly wrote:
> Okay, I've checked a fix into trunk.  If anyone is inclined to try it 
> out, please let me know if it works.

Sorry, but no. At first I get an error because you forgot to define 
va_list in std/c/stdarg.di. After copying
---
     private import gcc.builtins;
     alias __builtin_va_list va_list;
---
into the version(GNU) block, I get basically the same error message as 
before:
---
gdc -o lifetime.o -g -frelease -O2 -fversion=GC_Use_Alloc_MMap 
-fversion=GC_Use_Stack_GLibC -fversion=GC_Use_Data_Fixed -nostdinc -pipe 
-I../../..   \
         -c lifetime.d
../../../std/c/stdarg.di:16: Error: cannot have out or inout parameter 
of type ubyte[24][1]
../../../std/c/stdarg.di:815: template instance 
std.c.stdarg.va_start!(uint) error instantiating
lifetime.d:815: Error: cannot change reference to static array 'va'
make[2]: *** [lifetime.o] Error 1
make[2]: Leaving directory 
`/home/urxae/opt/tango/svn-trunk/lib/compiler/gdc'
make[1]: *** [all] Error 2
make[1]: Leaving directory 
`/home/urxae/opt/tango/svn-trunk/lib/compiler/gdc'
make: *** [lib] Error 2
---

However, copying GDC's std.c.stdarg module over it lets it compile a bit 
further. Unfortunately, it then chokes on something else:
---
gcc -c -O -m32 core/ThreadASM.S -ocore/ThreadASM.o
gcc -c -O -m32 stdc/wrap.c -ostdc/wrap.o
In file included from /usr/include/features.h:346,
                  from /usr/include/errno.h:29,
                  from stdc/wrap.c:1:
/usr/include/gnu/stubs.h:7:27: error: gnu/stubs-32.h: No such file or 
directory
make[1]: *** [stdc/wrap.o] Error 1
make[1]: Leaving directory 
`/home/urxae/opt/tango/svn-trunk/lib/common/tango'
make: *** [lib] Error 2
---

I've seen this error before when trying to get my 64-bit GCC to compile 
32-bit code[1], but I'm wondering *why* it tries to do that. I don't 
think it'll run properly (or perhaps even fail to link against 64-bit 
binaries) even *if* you get it to compile...
(Removing the -m32 and executing the second 'gcc' command manually works 
fine, by the way)
I guess the first command worked mostly because it doesn't contain any 
code outside "#if defined( __ppc__ )".

[a bit later]
After removing -m32 from CFLAGS in all relevant makefiles (and perhaps 
some irrelevant ones; the only one I left was in 
lib/compiler/dmd/posix.mak since I figured it wouldn't use that one :) ) 
  build-gdc.sh completes successfully.

I attached a patch, though I'm not sure how much use it'll be if you 
insist on your own version of std.c.stdarg ...


[1]: "-m32" means "emulate 32-bit compiler", right?
-------------- next part --------------
A non-text attachment was scrubbed...
Name: trunk-64.patch
Type: text/x-patch
Size: 3353 bytes
Desc: not available
Url : http://lists.puremagic.com/pipermail/digitalmars-d-announce/attachments/20070316/584af768/attachment.bin 


More information about the Digitalmars-d-announce mailing list