ports/169662: [MAINTAINER] Split THREADS patches to better support GNU binutils
Luca Pizzamiglio
luca.pizzamiglio at gmail.com
Thu Jul 5 12:40:03 UTC 2012
>Number: 169662
>Category: ports
>Synopsis: [MAINTAINER] Split THREADS patches to better support GNU binutils
>Confidential: no
>Severity: non-critical
>Priority: medium
>Responsible: freebsd-ports-bugs
>State: open
>Quarter:
>Keywords:
>Date-Required:
>Class: maintainer-update
>Submitter-Id: current-users
>Arrival-Date: Thu Jul 05 12:40:02 UTC 2012
>Closed-Date:
>Last-Modified:
>Originator: Luca Pizzamiglio
>Release: FreeBSD 8.3-STABLE
>Organization:
>Environment:
FreeBSD pizzamig.xxx 8.3-STABLE FreeBSD 8.3-STABLE #7: Wed Jun 20 14:56:08 CEST 2012 root at pizzamig.xxx:/usr/obj/usr/src/sys/PIZZAMIG i386
>Description:
This patch improve the management of THREADS option patches.
The source file list always includes fbsd-threads.c, even if THREADS was off. The successful build is caused by a robust implementation of ar (ignoring file not found, it is not an error).
With this patch, the file list is coherent with patches.
The previous implementation created some problem with GNU ar (provided by binutils): this ar didn't ignore missing files, blocking build.
>How-To-Repeat:
>Fix:
Patch attached with submission follows:
diff -Nru devel/gdb.orig/Makefile devel/gdb/Makefile
--- devel/gdb.orig/Makefile 2012-06-26 21:27:41.000000000 +0200
+++ devel/gdb/Makefile 2012-07-04 14:41:19.000000000 +0200
@@ -2,7 +2,7 @@
# Date created: 16 November 2010
# Whom: Steven Kreuzer <skreuzer at FreeBSD.org>
#
-# $FreeBSD: ports/devel/gdb/Makefile,v 1.19 2012/06/26 19:27:41 sunpoet Exp $
+# $FreeBSD$
#
PORTNAME= gdb
@@ -61,6 +61,10 @@
.include <bsd.port.pre.mk>
+.if ${PORT_OPTIONS:MTHREADS}
+EXTRA_PATCHES= ${FILESDIR}/extrapatch-gdb-configure.tgt ${FILESDIR}/extrapatch-gdb-Makefile.in
+.endif
+
.if ${PORT_OPTIONS:MDEBUG}
CFLAGS+= -g
.endif
diff -Nru devel/gdb.orig/files/extrapatch-gdb-Makefile.in devel/gdb/files/extrapatch-gdb-Makefile.in
--- devel/gdb.orig/files/extrapatch-gdb-Makefile.in 1970-01-01 01:00:00.000000000 +0100
+++ devel/gdb/files/extrapatch-gdb-Makefile.in 2012-07-04 14:39:01.000000000 +0200
@@ -0,0 +1,29 @@
+--- gdb/Makefile.in.orig 2011-03-30 07:55:39.000000000 +0100
++++ gdb/Makefile.in 2011-10-29 08:02:29.600973609 +0100
+@@ -571,7 +571,7 @@
+ xstormy16-tdep.o \
+ xtensa-config.o xtensa-tdep.o xtensa-linux-tdep.o \
+ glibc-tdep.o \
+- bsd-uthread.o \
++ fbsd-threads.o \
+ nbsd-tdep.o obsd-tdep.o \
+ sol2-tdep.o \
+ solib-frv.o solib-irix.o solib-svr4.o solib-target.o \
+@@ -782,7 +782,7 @@
+ gnulib/stdint.in.h remote.h gdb.h sparc-nat.h \
+ gdbthread.h dwarf2-frame.h dwarf2-frame-tailcall.h nbsd-nat.h dcache.h \
+ amd64-nat.h s390-tdep.h arm-linux-tdep.h exceptions.h macroscope.h \
+-gdbarch.h bsd-uthread.h gdb_stat.h memory-map.h memrange.h \
++gdbarch.h gdb_stat.h memory-map.h memrange.h \
+ mdebugread.h m88k-tdep.h stabsread.h hppa-linux-offsets.h linux-fork.h \
+ ser-unix.h inf-ptrace.h terminal.h ui-out.h frame-base.h \
+ f-lang.h dwarf2loc.h value.h sparc-tdep.h defs.h target-descriptions.h \
+@@ -1452,7 +1452,7 @@
+ armnbsd-nat.c armbsd-tdep.c armnbsd-tdep.c armobsd-tdep.c \
+ avr-tdep.c \
+ bfin-linux-tdep.c bfin-tdep.c \
+- bsd-uthread.c bsd-kvm.c \
++ fbsd-threads.c bsd-kvm.c \
+ core-regset.c corelow.c \
+ dcache.c dicos-tdep.c darwin-nat.c \
+ exec.c \
diff -Nru devel/gdb.orig/files/extrapatch-gdb-configure.tgt devel/gdb/files/extrapatch-gdb-configure.tgt
--- devel/gdb.orig/files/extrapatch-gdb-configure.tgt 1970-01-01 01:00:00.000000000 +0100
+++ devel/gdb/files/extrapatch-gdb-configure.tgt 2012-07-04 14:39:01.000000000 +0200
@@ -0,0 +1,20 @@
+--- gdb/configure.tgt.orig 2010-09-30 13:38:12.841406000 -0400
++++ gdb/configure.tgt 2010-09-30 13:38:49.131127000 -0400
+@@ -169,7 +169,7 @@
+ i[34567]86-*-freebsd* | i[34567]86-*-kfreebsd*-gnu)
+ # Target: FreeBSD/i386
+ gdb_target_obs="i386-tdep.o i387-tdep.o i386bsd-tdep.o i386fbsd-tdep.o \
+- bsd-uthread.o corelow.o solib.o solib-svr4.o"
++ fbsd-threads.o corelow.o solib.o solib-svr4.o"
+ ;;
+ i[34567]86-*-netbsd* | i[34567]86-*-knetbsd*-gnu)
+ # Target: NetBSD/i386
+@@ -579,7 +579,7 @@
+ # Target: FreeBSD/amd64
+ gdb_target_obs="amd64-tdep.o amd64fbsd-tdep.o i386-tdep.o \
+ i387-tdep.o i386bsd-tdep.o i386fbsd-tdep.o \
+- bsd-uthread.o corelow.o solib.o solib-svr4.o"
++ fbsd-threads.o corelow.o solib.o solib-svr4.o"
+ ;;
+ x86_64-*-mingw*)
+ # Target: MingW/amd64
diff -Nru devel/gdb.orig/files/patch-gdb-Makefile.in devel/gdb/files/patch-gdb-Makefile.in
--- devel/gdb.orig/files/patch-gdb-Makefile.in 2012-02-25 12:57:56.000000000 +0100
+++ devel/gdb/files/patch-gdb-Makefile.in 2012-07-04 14:39:01.000000000 +0200
@@ -1,14 +1,5 @@
--- gdb/Makefile.in.orig 2011-03-30 07:55:39.000000000 +0100
+++ gdb/Makefile.in 2011-10-29 08:02:29.600973609 +0100
-@@ -571,7 +571,7 @@
- xstormy16-tdep.o \
- xtensa-config.o xtensa-tdep.o xtensa-linux-tdep.o \
- glibc-tdep.o \
-- bsd-uthread.o \
-+ fbsd-threads.o \
- nbsd-tdep.o obsd-tdep.o \
- sol2-tdep.o \
- solib-frv.o solib-irix.o solib-svr4.o solib-target.o \
@@ -758,7 +758,7 @@
osf-share/cma_deb_core.h osf-share/AT386/cma_thread_io.h \
osf-share/cma_sched.h proc-utils.h arm-tdep.h ax-gdb.h ppcnbsd-tdep.h \
@@ -18,15 +9,6 @@
i386bsd-nat.h xml-support.h xml-tdesc.h alphabsd-tdep.h gdb_obstack.h \
ia64-tdep.h ada-lang.h varobj.h frv-tdep.h nto-tdep.h serial.h \
c-lang.h d-lang.h frame.h event-loop.h block.h cli/cli-setshow.h \
-@@ -782,7 +782,7 @@
- gnulib/stdint.in.h remote.h gdb.h sparc-nat.h \
- gdbthread.h dwarf2-frame.h dwarf2-frame-tailcall.h nbsd-nat.h dcache.h \
- amd64-nat.h s390-tdep.h arm-linux-tdep.h exceptions.h macroscope.h \
--gdbarch.h bsd-uthread.h gdb_stat.h memory-map.h memrange.h \
-+gdbarch.h gdb_stat.h memory-map.h memrange.h \
- mdebugread.h m88k-tdep.h stabsread.h hppa-linux-offsets.h linux-fork.h \
- ser-unix.h inf-ptrace.h terminal.h ui-out.h frame-base.h \
- f-lang.h dwarf2loc.h value.h sparc-tdep.h defs.h target-descriptions.h \
@@ -1161,7 +1161,7 @@
# Removing the old gdb first works better if it is running, at least on SunOS.
gdb$(EXEEXT): gdb.o libgdb.a $(ADD_DEPS) $(CDEPS) $(TDEPLIBS)
@@ -36,12 +18,3 @@
-o gdb$(EXEEXT) gdb.o libgdb.a \
$(TDEPLIBS) $(TUI_LIBRARY) $(CLIBS) $(LOADLIBES)
-@@ -1452,7 +1452,7 @@
- armnbsd-nat.c armbsd-tdep.c armnbsd-tdep.c armobsd-tdep.c \
- avr-tdep.c \
- bfin-linux-tdep.c bfin-tdep.c \
-- bsd-uthread.c bsd-kvm.c \
-+ fbsd-threads.c bsd-kvm.c \
- core-regset.c corelow.c \
- dcache.c dicos-tdep.c darwin-nat.c \
- exec.c \
diff -Nru devel/gdb.orig/files/patch-gdb-configure.tgt devel/gdb/files/patch-gdb-configure.tgt
--- devel/gdb.orig/files/patch-gdb-configure.tgt 2010-11-16 21:39:48.000000000 +0100
+++ devel/gdb/files/patch-gdb-configure.tgt 1970-01-01 01:00:00.000000000 +0100
@@ -1,20 +0,0 @@
---- gdb/configure.tgt.orig 2010-09-30 13:38:12.841406000 -0400
-+++ gdb/configure.tgt 2010-09-30 13:38:49.131127000 -0400
-@@ -169,7 +169,7 @@
- i[34567]86-*-freebsd* | i[34567]86-*-kfreebsd*-gnu)
- # Target: FreeBSD/i386
- gdb_target_obs="i386-tdep.o i387-tdep.o i386bsd-tdep.o i386fbsd-tdep.o \
-- bsd-uthread.o corelow.o solib.o solib-svr4.o"
-+ fbsd-threads.o corelow.o solib.o solib-svr4.o"
- ;;
- i[34567]86-*-netbsd* | i[34567]86-*-knetbsd*-gnu)
- # Target: NetBSD/i386
-@@ -579,7 +579,7 @@
- # Target: FreeBSD/amd64
- gdb_target_obs="amd64-tdep.o amd64fbsd-tdep.o i386-tdep.o \
- i387-tdep.o i386bsd-tdep.o i386fbsd-tdep.o \
-- bsd-uthread.o corelow.o solib.o solib-svr4.o"
-+ fbsd-threads.o corelow.o solib.o solib-svr4.o"
- ;;
- x86_64-*-mingw*)
- # Target: MingW/amd64
>Release-Note:
>Audit-Trail:
>Unformatted:
More information about the freebsd-ports-bugs
mailing list