* PARROT_CPU_ARCH is defined as "i386" and PARROT_OS_NAME is "nojit" when jit determination fails. It now correctly (?) reports 'x86_64' and 'linux'. * Memory alignment tests warn about a pointer size difference in cast. A new configuration setting ptrcast is either 'int' or 'long' depending on what type a pointer is safe to cast to/from. I suspect that all cases will be 'long', but you never really know.
* cast warnings in default.pmc. Changing static int cant_do_method to static long cant_do_method makes it compile without warnings, but its not the right fix. * Build fails with: gcc -shared -fPIC -g \ -o runtime/parrot/dynext/libnci.so src/nci_test.o /usr/bin/ld: src/nci_test.o: relocation R_X86_64_32 can not be used when making a shared object; recompile with -fPIC src/nci_test.o: could not read symbols: Bad value collect2: ld returned 1 exit status make: *** [runtime/parrot/dynext/libnci.so] Error 1 No idea how to fix this one...adding --ccflags=-fPIC doesn't help the compile. Below is a patch which fixes the first 3. Brian Wheeler [EMAIL PROTECTED] diff -ur ../parrot-0.1.1/classes/default.pmc ./classes/default.pmc --- ../parrot-0.1.1/classes/default.pmc 2004-10-06 10:55:36.000000000 -0500 +++ ./classes/default.pmc 2004-10-13 23:22:01.089477209 -0500 @@ -52,7 +52,7 @@ */ -static int +static long cant_do_method(Parrot_Interp interpreter, PMC * pmc, const char *methname) { internal_exception(ILL_INHERIT, diff -ur ../parrot-0.1.1/config/auto/jit.pl ./config/auto/jit.pl --- ../parrot-0.1.1/config/auto/jit.pl 2004-03-08 04:29:29.000000000 -0500 +++ ./config/auto/jit.pl 2004-10-13 22:59:05.551927726 -0500 @@ -171,9 +171,9 @@ else { Configure::Data->set( jitarchname => 'nojit', - jitcpuarch => 'i386', - jitcpu => 'I386', - jitosname => 'nojit', + jitcpuarch => $cpuarch, + jitcpu => $cpuarch, + jitosname => $osname, jitcapable => 0, execcapable => 0, cc_hasjit => '', diff -ur ../parrot-0.1.1/config/auto/memalign/test_c2.in ./config/auto/memalign/test_c2.in --- ../parrot-0.1.1/config/auto/memalign/test_c2.in 2003-07-13 13:52:58.000000000 -0500 +++ ./config/auto/memalign/test_c2.in 2004-10-13 23:09:54.875709999 -0500 @@ -20,6 +20,6 @@ * arbitrary allocation size) */ int i = posix_memalign(&p, s, 177); - puts(((int)p & 0xff) == 0 && i == 0 ? "ok" : "nix"); + puts(((${ptrcast})p & 0xff) == 0 && i == 0 ? "ok" : "nix"); return i; } diff -ur ../parrot-0.1.1/config/auto/memalign/test_c.in ./config/auto/memalign/test_c.in --- ../parrot-0.1.1/config/auto/memalign/test_c.in 2003-07-13 13:52:58.000000000 -0500 +++ ./config/auto/memalign/test_c.in 2004-10-13 23:09:59.903596577 -0500 @@ -9,6 +9,6 @@ int main(int argc, char **argv) { void *ptr = memalign(256, 17); - puts(ptr && ((int)ptr & 0xff) == 0 ? "ok" : "nix"); + puts(ptr && ((${ptrcast})ptr & 0xff) == 0 ? "ok" : "nix"); return 0; } diff -ur ../parrot-0.1.1/config/auto/memalign.pl ./config/auto/memalign.pl --- ../parrot-0.1.1/config/auto/memalign.pl 2004-03-13 13:46:24.000000000 -0500 +++ ./config/auto/memalign.pl 2004-10-13 23:09:48.870037359 -0500 @@ -39,6 +39,14 @@ Configure::Data->set('malloc_header', 'stdlib.h'); } + if (Configure::Data->get('ptrsize') == Configure::Data->get('intsize')) { + Configure::Data->set('ptrcast','int'); + } + else { + Configure::Data->set('ptrcast','long'); + } + + cc_gen('config/auto/memalign/test_c.in'); eval { cc_build(); }; unless ($@ || cc_run_capture() !~ /ok/) {