Date: Wed, 13 Feb 2013 10:33:24 GMT From: Luca Pizzamiglio <luca.pizzamiglio@gmail.com> To: freebsd-gnats-submit@FreeBSD.org Subject: ports/176103: [MAINTAINER] Adding an option to disable TUI and correctly enabling all targets Message-ID: <201302131033.r1DAXO93032008@red.freebsd.org> Resent-Message-ID: <201302131040.r1DAe05a025676@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
>Number: 176103 >Category: ports >Synopsis: [MAINTAINER] Adding an option to disable TUI and correctly enabling all targets >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-ports-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: maintainer-update >Submitter-Id: current-users >Arrival-Date: Wed Feb 13 10:40:00 UTC 2013 >Closed-Date: >Last-Modified: >Originator: Luca Pizzamiglio >Release: FreeBSD 8.3-STABLE >Organization: >Environment: FreeBSD pizzamig.yyy.zz 8.3-STABLE FreeBSD 8.3-STABLE #0: Tue Jan 8 12:50:34 CET 2013 root@pizzamig.yyy.zz:/usr/obj/usr/src/sys/GENERIC i386 >Description: Update to: * add an option to disable the Text User Interface * fix a small configuration issue (thanks to Andreas Tobler) >How-To-Repeat: >Fix: Patch attached with submission follows: diff -uNr devel/gdb.orig/Makefile devel/gdb/Makefile --- devel/gdb.orig/Makefile 2012-12-16 17:50:52.000000000 +0100 +++ devel/gdb/Makefile 2013-02-13 11:26:27.000000000 +0100 @@ -1,5 +1,5 @@ # Created by: Steven Kreuzer <skreuzer@FreeBSD.org> -# $FreeBSD: ports/devel/gdb/Makefile,v 1.28 2012/12/16 16:50:52 svnexp Exp $ +# $FreeBSD$ PORTNAME= gdb PORTVERSION= 7.5.1 @@ -20,8 +20,7 @@ --with-gdb-datadir=${PREFIX}/share/gdb${PORTVERSION:S/.//g} \ --with-libiconv-prefix=${LOCALBASE} \ --without-libunwind-ia64 \ - --enable-target=all \ - --enable-tui + --enable-targets=all CFLAGS:= ${CFLAGS:C/ +$//} # blanks at EOL creep in sometimes CFLAGS+= -DRL_NO_COMPAT EXCLUDE= dejagnu expect sim texinfo intl @@ -33,14 +32,15 @@ ONLY_FOR_ARCHS= i386 amd64 # untested elsewhere, might work -OPTIONS_DEFINE= DEBUG EXPAT PYTHON THREADS GDB_LINK +OPTIONS_DEFINE= DEBUG EXPAT PYTHON THREADS TUI GDB_LINK OPTIONS_SINGLE_READLINE= BASE_READLINE BUNDLED_READLINE PORT_READLINE OPTIONS_SINGLE= READLINE -BASE_READLINE_DESC= from base system (EXPERIMENTAL) +BASE_READLINE_DESC= from base system(EXPERIMENTAL) BUNDLED_READLINE_DESC= from gdb distfile PORT_READLINE_DESC= from devel/readline port GDB_LINK_DESC= Create the gdb link -OPTIONS_DEFAULT= THREADS GDB_LINK PORT_READLINE +TUI_DESC= Text User Interface enabled +OPTIONS_DEFAULT= THREADS TUI GDB_LINK PORT_READLINE .include <bsd.port.options.mk> @@ -50,8 +50,12 @@ PLIST_SUB+= GDB_LINK="@comment " .endif -.if ${PORT_OPTIONS:MPYTHON} -USE_PYTHON= 2.5-2.7 +.if ${PORT_OPTIONS:MTUI} +CONFIGURE_ARGS+= --enable-tui +PLIST_SUB+= TUI_LINK="" +.else +CONFIGURE_ARGS+= --disable-tui +PLIST_SUB+= TUI_LINK="@comment " .endif .if empty(PORT_OPTIONS:MBUNDLED_READLINE) @@ -67,6 +71,16 @@ .if ${PORT_OPTIONS:MPORT_READLINE} USE_READLINE= port .endif + +.if ${PORT_OPTIONS:MPYTHON} +USE_PYTHON= 2.5-2.7 +CONFIGURE_ARGS+= --with-python=${PYTHON_CMD} +PLIST_SUB+= PYTHON="" +.else +CONFIGURE_ARGS+= --without-python +PLIST_SUB+= PYTHON="@comment " +.endif + .include <bsd.port.pre.mk> .if ${PORT_OPTIONS:MTHREADS} @@ -84,14 +98,6 @@ CONFIGURE_ARGS+= --without-expat .endif -.if ${PORT_OPTIONS:MPYTHON} -CONFIGURE_ARGS+= --with-python=${PYTHON_CMD} -PLIST_SUB+= PYTHON="" -.else -CONFIGURE_ARGS+= --without-python -PLIST_SUB+= PYTHON="@comment " -.endif - .if ${ARCH} == "amd64" CONFIGURE_TARGET= x86_64-portbld-freebsd${OSREL} .endif @@ -105,8 +111,10 @@ do-install: ${INSTALL_PROGRAM} ${WRKSRC}/gdb/gdb ${PREFIX}/bin/gdb${VER} - ${LN} -sf ${PREFIX}/bin/gdb${VER} ${PREFIX}/bin/gdbtui${VER} ${INSTALL_MAN} ${WRKSRC}/gdb/gdb.1 ${MAN1PREFIX}/man/man1/gdb${VER}.1 +.if ${PORT_OPTIONS:MTUI} + ${LN} -sf ${PREFIX}/bin/gdb${VER} ${PREFIX}/bin/gdbtui${VER} +.endif .if ${PORT_OPTIONS:MGDB_LINK} ${LN} -sf gdb${VER} ${PREFIX}/bin/gdb .endif diff -uNr devel/gdb.orig/files/extrapatch-gdb-Makefile.in devel/gdb/files/extrapatch-gdb-Makefile.in --- devel/gdb.orig/files/extrapatch-gdb-Makefile.in 2012-08-27 18:10:54.000000000 +0200 +++ devel/gdb/files/extrapatch-gdb-Makefile.in 2013-02-07 10:26:25.000000000 +0100 @@ -1,23 +1,13 @@ --- gdb/Makefile.in.orig 2012-07-02 17:29:33.000000000 +0200 +++ gdb/Makefile.in 2012-08-26 21:01:45.589052997 +0200 -@@ -572,7 +572,7 @@ - xstormy16-tdep.o \ +@@ -573,6 +573,7 @@ xtensa-config.o xtensa-tdep.o xtensa-linux-tdep.o \ glibc-tdep.o \ -- bsd-uthread.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 \ -@@ -779,7 +779,7 @@ - gnulib/import/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 \ @@ -1164,7 +1164,7 @@ # Removing the old gdb first works better if it is running, at least on SunOS. gdb$(EXEEXT): gdb.o $(LIBGDB_OBS) $(ADD_DEPS) $(CDEPS) $(TDEPLIBS) @@ -32,7 +22,7 @@ avr-tdep.c \ bfin-linux-tdep.c bfin-tdep.c \ - bsd-uthread.c bsd-kvm.c \ -+ fbsd-threads.c bsd-kvm.c \ ++ bsd-uthread.c fbsd-threads.c bsd-kvm.c \ core-regset.c \ dcache.c dicos-tdep.c darwin-nat.c \ exec.c \ diff -uNr devel/gdb.orig/files/fbsd-threads.c devel/gdb/files/fbsd-threads.c --- devel/gdb.orig/files/fbsd-threads.c 2012-11-17 06:55:44.000000000 +0100 +++ devel/gdb/files/fbsd-threads.c 2012-12-13 11:16:07.000000000 +0100 @@ -1,4 +1,4 @@ -/* $FreeBSD: ports/devel/gdb/files/fbsd-threads.c,v 1.8 2012/11/17 05:55:44 svnexp Exp $ */ +/* $FreeBSD$ */ /* FreeBSD libthread_db assisted debugging support. Copyright 1999, 2000, 2001 Free Software Foundation, Inc. diff -uNr devel/gdb.orig/files/patch-opcodes-i386-dis.c devel/gdb/files/patch-opcodes-i386-dis.c --- devel/gdb.orig/files/patch-opcodes-i386-dis.c 2012-12-24 23:41:19.000000000 +0100 +++ devel/gdb/files/patch-opcodes-i386-dis.c 2012-12-18 15:49:20.000000000 +0100 @@ -56,3 +56,4 @@ + oappend (&"%es:"[(short)intel_syntax]); ptr_reg (code, sizeflag); } + diff -uNr devel/gdb.orig/pkg-plist devel/gdb/pkg-plist --- devel/gdb.orig/pkg-plist 2012-08-24 04:54:50.000000000 +0200 +++ devel/gdb/pkg-plist 2013-02-12 11:47:32.000000000 +0100 @@ -1,6 +1,6 @@ %%GDB_LINK%%bin/gdb bin/gdb%%VER%% -bin/gdbtui%%VER%% +%%TUI_LINK%%bin/gdbtui%%VER%% %%PYTHON%%share/gdb%%VER%%/python/gdb/__init__.py %%PYTHON%%share/gdb%%VER%%/python/gdb/types.py %%PYTHON%%share/gdb%%VER%%/python/gdb/printing.py >Release-Note: >Audit-Trail: >Unformatted:
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201302131033.r1DAXO93032008>