pkgsrc-Bugs archive

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

pkg/45814: lang/gcc45 doesn't build on 5.99.5x/i386



>Number:         45814
>Category:       pkg
>Synopsis:       lang/gcc45 doesn't build on 5.99.5x/i386
>Confidential:   no
>Severity:       critical
>Priority:       medium
>Responsible:    pkg-manager
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Tue Jan 10 19:00:00 +0000 2012
>Originator:     B.ICT A.P. deBROUWER Jr.
>Release:        5.99.59
>Organization:
-none-
>Environment:
NetBSD 10.0.2.17 5.99.59 NetBSD 5.99.59 (MONOLITHIC) #0: Tue Dec 27 01:19:12 
UTC 2011  
builds%b8.netbsd.org@localhost:/home/builds/ab/HEAD/i386/201112261820Z-obj/home/builds/ab/HEAD/src/sys/arch/i386/compile/MONOLITHIC
 i386
>Description:
am running nbsd/i386 on amd64 hw.
am able to build gcc45 on 5.1 and pkgsrc 10Q4 as well as pkgsrc-current.


Using NetBSD 5.99.55 5.99.56 5.99.59/i386 with pkgsrc-current (HEAD)
i can't build gcc45 gcc46 nor wip/gcc43 nor wip/gcc47.
(first pkgsrc-current i did try was in Oct.)
(gcc44 and lower does build.)

Whenever i tried to build (unpatched) got:

if [ x"-fpic" != x ]; then \
  gcc -c -DHAVE_CONFIG_H -g -fkeep-inline-functions 
-I/obj/lang/gcc45/work/.buildlink/include -I/usr/include -I/usr/pkg/include -I. 
-I/obj/lang/gcc45/work/gcc-4.5.3/libiberty/../include  -W -Wall -Wwrite-strings 
-Wc++-compat -Wstrict-prototypes -pedantic  -fpic 
/obj/lang/gcc45/work/gcc-4.5.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 `/obj/lang/gcc45/work/obj/libiberty'
gmake[2]: *** [all-stage1-libiberty] Error 2
gmake[2]: Leaving directory `/obj/lang/gcc45/work/obj'
gmake[1]: *** [stage1-bubble] Error 2
gmake[1]: Leaving directory `/obj/lang/gcc45/work/obj'
gmake: *** [all] Error 2
*** Error code 2

If i do patch conform below i get a build done.
I suspect it has to be patched whole different(?) and am able to
supply a test-build in i386 when needed/up-on request.
>How-To-Repeat:
install nbsd current/i386 & pkgsrc
cd lang/gcc45 && make
>Fix:
inspired by: http://mapopa.blogspot.com/2010/07/error-bad-register-name-sil.html

--- /usr/include/x86/lock.h.orig        2011-10-31 22:34:14.000000000 +0000
+++ /usr/include/x86/lock.h     2011-11-01 10:39:57.000000000 +0000
@@ -106,8 +106,8 @@
 
        val = __SIMPLELOCK_LOCKED;
        __asm volatile ("xchgb %0,(%2)" : 
-           "=r" (val)
-           :"0" (val), "r" (lockp));
+           "=q" (val)
+           :"0" (val), "q" (lockp));
        __insn_barrier();
        return val == __SIMPLELOCK_UNLOCKED;
 }



Home | Main Index | Thread Index | Old Index