tech-pkg archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

gcc46/47 error being built inside 32bit chroot on amd64 machine


I'm trying to build lang/gcc46 or lang/gcc47 inside a pkg_comp-created
32bit chroot on an AMD64 machine, both netbsd-6.0_BETA:

NetBSD 6.0_BETA NetBSD 6.0_BETA (GENERIC) #0: Fri Mar  
9 13:21:26 CET 2012

I get this error while -liberty is built:

  gcc -c -DHAVE_CONFIG_H -g -fkeep-inline-functions -I/pkg_comp/obj/pkgsrc/lang/
  gcc46/default/.buildlink/include -I/usr/pkg/include -I/usr/include -I. 
  mp/obj/pkgsrc/lang/gcc46/default/gcc-4.6.3/libiberty/../include  -W -Wall 
  e-strings -Wc++-compat -Wstrict-prototypes -pedantic  -fpic 
  /lang/gcc46/default/gcc-4.6.3/libiberty/physmem.c -o pic/physmem.o; \
  else true; fi
  /usr/include/x86/lock.h: Assembler messages:
  /usr/include/x86/lock.h:108: Error: bad register name `%sil'
  gmake[3]: *** [physmem.o] Error 1
  gmake[3]: Leaving directory 
  gmake[2]: *** [all-stage1-libiberty] Error 2

The lines in question are:

static __inline int
__cpu_simple_lock_try(__cpu_simple_lock_t *lockp) 
        uint8_t val;
        val = __SIMPLELOCK_LOCKED;
        __asm volatile ("xchgb %0,(%2)" :               <<<< 108
            "=r" (val)
            :"0" (val), "r" (lockp));
        return val == __SIMPLELOCK_UNLOCKED;

%si is always 16bit, so no 8bit lower half is available; compiler problem?
The compiler is:

pkg_comp:32bit60b.conf# gcc -v
Using built-in specs.
Target: i486--netbsdelf
Configured with: /usr/src2/tools/gcc/../../external/gpl3/gcc/dist/configure 
--target=i486--netbsdelf --enable-long-long --enable-threads 
--with-bugurl= --with-pkgversion='NetBSD 
nb2 20111202' --enable-__cxa_atexit --with-arch=i486 --with-tune=nocona 
--with-gmp=/var/obj/mknative/i386/usr/src2/destdir.i386/usr --enable-tls 
--disable-multilib --disable-symvers --disable-libstdcxx-pch 
--build=x86_64-unknown-netbsd5.99.56 --host=i486--netbsdelf
Thread model: posix
gcc version 4.5.3 (NetBSD nb2 20110806) 

Where do we go from here? 


Home | Main Index | Thread Index | Old Index