From 0af88b7eaea295debd7e17720aa05323c8c487df Mon Sep 17 00:00:00 2001 From: eadler Date: Thu, 6 Dec 2012 01:31:25 +0000 Subject: Clean up hardcoded ar(1) flags in the tree to use the global ARFLAGS in share/mk/sys.mk instead. This is part of a medium term project to permit deterministic builds of FreeBSD. Submitted by: Erik Cederstrand Reviewed by: imp, toolchain@ Approved by: cperciva MFC after: 2 weeks --- gnu/lib/libgcc/Makefile | 4 ++-- gnu/usr.bin/cc/cc_tools/Makefile | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) (limited to 'gnu') diff --git a/gnu/lib/libgcc/Makefile b/gnu/lib/libgcc/Makefile index 9c54377..52a0c2d 100644 --- a/gnu/lib/libgcc/Makefile +++ b/gnu/lib/libgcc/Makefile @@ -341,7 +341,7 @@ CLEANFILES += libgcc.map libgcc_eh.a: ${EH_OBJS_T} @${ECHO} building static gcc_eh library @rm -f ${.TARGET} - @${AR} cq ${.TARGET} `lorder ${EH_OBJS_T} | tsort -q` + @${AR} ${ARFLAGS} ${.TARGET} `lorder ${EH_OBJS_T} | tsort -q` ${RANLIB} ${.TARGET} all: libgcc_eh.a @@ -350,7 +350,7 @@ all: libgcc_eh.a libgcc_eh_p.a: ${EH_OBJS_P} @${ECHO} building profiled gcc_eh library @rm -f ${.TARGET} - @${AR} cq ${.TARGET} `lorder ${EH_OBJS_P} | tsort -q` + @${AR} ${ARFLAGS} ${.TARGET} `lorder ${EH_OBJS_P} | tsort -q` ${RANLIB} ${.TARGET} all: libgcc_eh_p.a .endif diff --git a/gnu/usr.bin/cc/cc_tools/Makefile b/gnu/usr.bin/cc/cc_tools/Makefile index 3cedd69..c697dd3 100644 --- a/gnu/usr.bin/cc/cc_tools/Makefile +++ b/gnu/usr.bin/cc/cc_tools/Makefile @@ -512,7 +512,7 @@ ${_src:R:S/$/.o/}: ${_src} ${LIBIBERTY}: ${LIBIBERTY_OBJS} @rm -f ${.TARGET} - @${AR} cq ${.TARGET} `lorder ${LIBIBERTY_OBJS} | tsort -q` + @${AR} ${ARFLAGS} ${.TARGET} `lorder ${LIBIBERTY_OBJS} | tsort -q` ${RANLIB} ${.TARGET} CLEANFILES+= ${LIBIBERTY} ${LIBIBERTY_OBJS} -- cgit v1.1 From a1795c288278b3904701b9a313c104496083d0a7 Mon Sep 17 00:00:00 2001 From: andrew Date: Sat, 15 Dec 2012 21:33:12 +0000 Subject: Also remove -Werror on arm with clang as there are warnings. --- gnu/usr.bin/binutils/as/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'gnu') diff --git a/gnu/usr.bin/binutils/as/Makefile b/gnu/usr.bin/binutils/as/Makefile index 1543bfb..17a3e19 100644 --- a/gnu/usr.bin/binutils/as/Makefile +++ b/gnu/usr.bin/binutils/as/Makefile @@ -8,7 +8,7 @@ .PATH: ${SRCDIR}/gas ${SRCDIR}/gas/config -.if ${TARGET_ARCH} == "powerpc64" +.if ${TARGET} == "arm" || ${TARGET_ARCH} == "powerpc64" NO_WERROR.clang= .endif -- cgit v1.1 From a825511a0fec7c1006ea0fa8612d31c374251617 Mon Sep 17 00:00:00 2001 From: ache Date: Mon, 17 Dec 2012 19:17:10 +0000 Subject: Fix: line 11: Malformed conditional (${TARGET} == "arm" || ${TARGET_ARCH} == "powerpc64") --- gnu/usr.bin/binutils/as/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'gnu') diff --git a/gnu/usr.bin/binutils/as/Makefile b/gnu/usr.bin/binutils/as/Makefile index 17a3e19..a27fed3 100644 --- a/gnu/usr.bin/binutils/as/Makefile +++ b/gnu/usr.bin/binutils/as/Makefile @@ -8,7 +8,7 @@ .PATH: ${SRCDIR}/gas ${SRCDIR}/gas/config -.if ${TARGET} == "arm" || ${TARGET_ARCH} == "powerpc64" +.if ${TARGET_ARCH} == "arm" || ${TARGET_ARCH} == "powerpc64" NO_WERROR.clang= .endif -- cgit v1.1 From d2da14c521ea858e8366bcf5b012ae64bf80dc88 Mon Sep 17 00:00:00 2001 From: ache Date: Tue, 18 Dec 2012 04:44:36 +0000 Subject: More correct version of prev. fix. --- gnu/usr.bin/binutils/as/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'gnu') diff --git a/gnu/usr.bin/binutils/as/Makefile b/gnu/usr.bin/binutils/as/Makefile index a27fed3..4436394 100644 --- a/gnu/usr.bin/binutils/as/Makefile +++ b/gnu/usr.bin/binutils/as/Makefile @@ -8,7 +8,7 @@ .PATH: ${SRCDIR}/gas ${SRCDIR}/gas/config -.if ${TARGET_ARCH} == "arm" || ${TARGET_ARCH} == "powerpc64" +.if ${TARGET_ARCH:Marm*} || ${TARGET_ARCH} == "powerpc64" NO_WERROR.clang= .endif -- cgit v1.1 From 3a4e3b814af8211f139991b6ab47d3c08a587f80 Mon Sep 17 00:00:00 2001 From: andrew Date: Tue, 18 Dec 2012 07:26:55 +0000 Subject: Get libcompiler-rt and libgcc building on ARM with clang. * Don't provide clear_cache or the __sync_* functions on ARM with clang as they are provided by clang as builtin functions. * Tell clang it is aloud to compile some libgcc code using heinous GCC extensions. --- gnu/lib/libgcc/Makefile | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'gnu') diff --git a/gnu/lib/libgcc/Makefile b/gnu/lib/libgcc/Makefile index 52a0c2d..c07ae87 100644 --- a/gnu/lib/libgcc/Makefile +++ b/gnu/lib/libgcc/Makefile @@ -38,13 +38,16 @@ OBJS= # added to below in various ways depending on TARGET_CPUARCH # # Library members defined in libgcc2.c. LIB2FUNCS= _muldi3 _negdi2 _lshrdi3 _ashldi3 _ashrdi3 \ - _cmpdi2 _ucmpdi2 _clear_cache \ + _cmpdi2 _ucmpdi2 \ _enable_execute_stack _trampoline __main _absvsi2 _absvdi2 _addvsi3 \ _addvdi3 _subvsi3 _subvdi3 _mulvsi3 _mulvdi3 _negvsi2 _negvdi2 _ctors \ _ffssi2 _ffsdi2 _clz _clzsi2 _clzdi2 _ctzsi2 _ctzdi2 _popcount_tab \ _popcountsi2 _popcountdi2 _paritysi2 _paritydi2 _powisf2 _powidf2 \ _powixf2 _powitf2 _mulsc3 _muldc3 _mulxc3 _multc3 _divsc3 _divdc3 \ _divxc3 _divtc3 +.if ${COMPILER_TYPE} != "clang" || ${TARGET_CPUARCH} != "arm" +LIB2FUNCS+= _clear_cache +.endif # The floating-point conversion routines that involve a single-word integer. .for mode in sf df xf @@ -106,6 +109,10 @@ LIB2_DIVMOD_FUNCS = _divdi3 _moddi3 _udivdi3 _umoddi3 _udiv_w_sdiv _udivmoddi4 .if ${TARGET_CPUARCH} == "arm" # from config/arm/t-strongarm-elf CFLAGS+= -Dinhibit_libc -fno-inline +.if ${COMPILER_TYPE} == "clang" +CFLAGS+= -fheinous-gnu-extensions +.endif + LIB1ASMSRC = lib1funcs.asm LIB1ASMFUNCS = _dvmd_tls _bb_init_func LIB2FUNCS_EXTRA = floatunsidf.c floatunsisf.c -- cgit v1.1 From 52bf5abd924bc78494905f16ffbd4bd67062240c Mon Sep 17 00:00:00 2001 From: nwhitehorn Date: Sun, 30 Dec 2012 04:22:34 +0000 Subject: Revert r241818 that updated dialog to 20120706. This turns out to horribly break mixed form dialogs in conjunction with the FreeBSD termcap, making the bsdinstall partition editor Add dialog, among other things, completely nonfunctional. This restores dialog 20110707. --- gnu/lib/libdialog/dlg_config.h | 21 +++++---------------- 1 file changed, 5 insertions(+), 16 deletions(-) (limited to 'gnu') diff --git a/gnu/lib/libdialog/dlg_config.h b/gnu/lib/libdialog/dlg_config.h index 3c73213..4dd6ab4 100644 --- a/gnu/lib/libdialog/dlg_config.h +++ b/gnu/lib/libdialog/dlg_config.h @@ -5,11 +5,9 @@ * $FreeBSD$ */ -#define CURSES_WACS_ARRAY _nc_wacs -#define DIALOG_PATCHDATE 20120706 +#define DIALOG_PATCHDATE 20100428 #define DIALOG_VERSION "1.1" #define HAVE_ALLOCA 1 -#define HAVE_BTOWC 1 #define HAVE_COLOR 1 #define HAVE_DIRENT_H 1 #define HAVE_DLG_FORMBOX 1 @@ -20,7 +18,6 @@ #define HAVE_FEOF_UNLOCKED 1 #define HAVE_FLUSHINP 1 #define HAVE_FSEEKO 1 -#define HAVE_GETATTRS 1 #define HAVE_GETBEGX 1 #define HAVE_GETBEGY 1 #define HAVE_GETBEGYX 1 @@ -42,18 +39,14 @@ #define HAVE_INTTYPES_H 1 #define HAVE_LANGINFO_CODESET 1 #define HAVE_LC_MESSAGES 1 +#define HAVE_LIBNCURSESW 1 #define HAVE_LIMITS_H 1 #define HAVE_LOCALE_H 1 -#define HAVE_MBLEN 1 -#define HAVE_MBRLEN 1 -#define HAVE_MBRTOWC 1 #define HAVE_MBSTATE_T 1 -#define HAVE_MBTOWC 1 #define HAVE_MEMORY_H 1 #define HAVE_MIXEDGAUGE 1 #define HAVE_MMAP 1 #define HAVE_MUNMAP 1 -#define HAVE_NCURSES_H 1 #define HAVE_NL_TYPES_H 1 #define HAVE_PUTENV 1 #define HAVE_RC_FILE 1 @@ -82,12 +75,7 @@ #define HAVE_UNISTD_H 1 #define HAVE_USE_DEFAULT_COLORS 1 #define HAVE_WAITPID 1 -#define HAVE_WCHGAT 1 -#define HAVE_WCSRTOMBS 1 -#define HAVE_WCSTOMBS 1 -#define HAVE_WCTOB 1 -#define HAVE_WCTOMB 1 -#define HAVE_WGETPARENT 1 +#define HAVE_WGET_WCH 1 #define HAVE_XDIALOG 1 #define HAVE__NC_FREE_AND_EXIT 1 #define ICONV_CONST const @@ -97,6 +85,7 @@ #define PACKAGE "dialog" #define RETSIGTYPE void #define STDC_HEADERS 1 -#define SYSTEM_NAME "freebsd10.0" +#define SYSTEM_NAME "freebsd9.0" #define TIME_WITH_SYS_TIME 1 #define TYPE_CHTYPE_IS_SCALAR 1 +#define USE_WIDE_CURSES 1 -- cgit v1.1 From 8b672151d0ab3e8e68f25134d8292fbce7655e9a Mon Sep 17 00:00:00 2001 From: antoine Date: Tue, 1 Jan 2013 18:31:21 +0000 Subject: Fix a dependency --- gnu/usr.bin/dialog/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'gnu') diff --git a/gnu/usr.bin/dialog/Makefile b/gnu/usr.bin/dialog/Makefile index 9b60974..e945b22 100644 --- a/gnu/usr.bin/dialog/Makefile +++ b/gnu/usr.bin/dialog/Makefile @@ -3,7 +3,7 @@ DIALOG= ${.CURDIR}/../../../contrib/dialog PROG= dialog -DPADD= ${LIBDIALOG} ${LIBNCURSES} ${LIBM} +DPADD= ${LIBDIALOG} ${LIBNCURSESW} ${LIBM} LDADD= -ldialog -lncursesw -lm CFLAGS+= -I${.CURDIR} -I${DIALOG} .PATH: ${DIALOG} -- cgit v1.1 From 4d844bb92fe4dcdef7ad7d30b87fe471847ea7e5 Mon Sep 17 00:00:00 2001 From: andrew Date: Sun, 6 Jan 2013 07:14:04 +0000 Subject: Set the correct relocation type for R_ARM_TARGET2 to R_ARM_GOT_PREL. The TARGET2 relocation is unused in the current ABI but this change is required for EABI support. --- gnu/usr.bin/binutils/ld/armelf_fbsd.sh | 1 + gnu/usr.bin/binutils/ld/armelfb_fbsd.sh | 1 + 2 files changed, 2 insertions(+) (limited to 'gnu') diff --git a/gnu/usr.bin/binutils/ld/armelf_fbsd.sh b/gnu/usr.bin/binutils/ld/armelf_fbsd.sh index a7f4740..0f888b0 100644 --- a/gnu/usr.bin/binutils/ld/armelf_fbsd.sh +++ b/gnu/usr.bin/binutils/ld/armelf_fbsd.sh @@ -1,6 +1,7 @@ # $FreeBSD$ . ${srcdir}/emulparams/armelf.sh . ${srcdir}/emulparams/elf_fbsd.sh +TARGET2_TYPE=got-rel MAXPAGESIZE=0x8000 GENERATE_PIE_SCRIPT=yes diff --git a/gnu/usr.bin/binutils/ld/armelfb_fbsd.sh b/gnu/usr.bin/binutils/ld/armelfb_fbsd.sh index 72aae15..39364ef 100644 --- a/gnu/usr.bin/binutils/ld/armelfb_fbsd.sh +++ b/gnu/usr.bin/binutils/ld/armelfb_fbsd.sh @@ -5,6 +5,7 @@ #OUTPUT_FORMAT="elf32-bigarm" . ${srcdir}/emulparams/armelf.sh . ${srcdir}/emulparams/elf_fbsd.sh +TARGET2_TYPE=got-rel MAXPAGESIZE=0x8000 GENERATE_PIE_SCRIPT=yes -- cgit v1.1 From 9b858bb6f0adb73473a948583965d4fc128312c8 Mon Sep 17 00:00:00 2001 From: andrew Date: Thu, 17 Jan 2013 05:56:28 +0000 Subject: Add compiler support for the ARM EABI. ARM EABI support is disabled by default and can be enabled by setting WITH_ARM_EABI when building, however only the kernel-toolchain target will work with this flag until the rest of the support is added. --- gnu/lib/csu/Makefile | 4 ++++ gnu/lib/libgcc/Makefile | 25 +++++++++++++++++-------- gnu/lib/libgcov/Makefile | 5 +++++ gnu/lib/libstdc++/Makefile | 10 +++++++++- gnu/usr.bin/cc/Makefile.inc | 4 ++++ gnu/usr.bin/cc/c++filt/Makefile | 4 +++- gnu/usr.bin/cc/cc1/Makefile | 3 ++- gnu/usr.bin/cc/cc1plus/Makefile | 3 ++- gnu/usr.bin/cc/cc_int/Makefile | 2 ++ gnu/usr.bin/cc/cc_tools/Makefile | 9 +++++++++ gnu/usr.bin/cc/doc/Makefile | 2 ++ gnu/usr.bin/cc/gcov/Makefile | 2 ++ gnu/usr.bin/cc/include/Makefile | 2 ++ gnu/usr.bin/cc/libcpp/Makefile | 2 ++ gnu/usr.bin/cc/libdecnumber/Makefile | 2 ++ gnu/usr.bin/cc/libiberty/Makefile | 2 ++ 16 files changed, 69 insertions(+), 12 deletions(-) (limited to 'gnu') diff --git a/gnu/lib/csu/Makefile b/gnu/lib/csu/Makefile index a65be66..1efe865 100644 --- a/gnu/lib/csu/Makefile +++ b/gnu/lib/csu/Makefile @@ -24,6 +24,10 @@ CFLAGS+= -I${GCCLIB}/include -I${GCCDIR}/config -I${GCCDIR} -I. \ CRTS_CFLAGS= -DCRTSTUFFS_O -DSHARED ${PICFLAG} MKDEP= -DCRT_BEGIN +.if ${TARGET_CPUARCH} == "arm" && ${MK_ARM_EABI} != "no" +CFLAGS+= -DTARGET_ARM_EABI +.endif + .if ${MACHINE_CPUARCH} == "ia64" BEGINSRC= crtbegin.asm ENDSRC= crtend.asm diff --git a/gnu/lib/libgcc/Makefile b/gnu/lib/libgcc/Makefile index c07ae87..73d9213 100644 --- a/gnu/lib/libgcc/Makefile +++ b/gnu/lib/libgcc/Makefile @@ -15,6 +15,10 @@ MK_SSP= no .include "${.CURDIR}/../../usr.bin/cc/Makefile.tgt" +.if ${TARGET_CPUARCH} == "arm" && ${MK_ARM_EABI} != "no" +CFLAGS+= -DTARGET_ARM_EABI +.endif + .if ${TARGET_CPUARCH} == "mips" LIB= gcc .endif @@ -55,10 +59,13 @@ LIB2FUNCS+= _fixuns${mode}si .endfor # Likewise double-word routines. +.if ${TARGET_CPUARCH} != "arm" || ${MK_ARM_EABI} == "no" +# These are implemented in an ARM specific file but will not be filtered out .for mode in sf df xf tf LIB2FUNCS+= _fix${mode}di _fixuns${mode}di LIB2FUNCS+= _floatdi${mode} _floatundi${mode} .endfor +.endif LIB2ADD = $(LIB2FUNCS_EXTRA) LIB2ADD_ST = $(LIB2FUNCS_STATIC_EXTRA) @@ -115,15 +122,14 @@ CFLAGS+= -fheinous-gnu-extensions LIB1ASMSRC = lib1funcs.asm LIB1ASMFUNCS = _dvmd_tls _bb_init_func -LIB2FUNCS_EXTRA = floatunsidf.c floatunsisf.c +.if ${MK_ARM_EABI} != "no" +LIB1ASMFUNCS+= _addsubdf3 _addsubsf3 _cmpdf2 _cmpsf2 _fixdfsi _fixsfsi \ + _fixunsdfsi _fixunsdfsi _muldivdf3 _muldivsf3 _udivsi3 -# Not now -#LIB1ASMFUNCS = _udivsi3 _divsi3 _umodsi3 _modsi3 _dvmd_tls _bb_init_func -#LIB1ASMFUNCS+= _call_via_rX _interwork_call_via_rX \ -# _lshrdi3 _ashrdi3 _ashldi3 \ -# _negdf2 _addsubdf3 _muldivdf3 _cmpdf2 _unorddf2 _fixdfsi _fixunsdfsi \ -# _truncdfsf2 _negsf2 _addsubsf3 _muldivsf3 _cmpsf2 _unordsf2 \ -# _fixsfsi _fixunssfsi _floatdidf _floatdisf +LIB2ADDEH = unwind-arm.c libunwind.S pr-support.c unwind-c.c +.else +LIB2FUNCS_EXTRA = floatunsidf.c floatunsisf.c +.endif .endif .if ${TARGET_CPUARCH} == mips @@ -329,6 +335,9 @@ CLEANFILES += cs-*.h option* SHLIB_MKMAP = ${GCCDIR}/mkmap-symver.awk SHLIB_MKMAP_OPTS = SHLIB_MAPFILES = ${GCCDIR}/libgcc-std.ver +.if ${TARGET_CPUARCH} == "arm" && ${MK_ARM_EABI} != "no" +SHLIB_MAPFILES += ${GCCDIR}/config/arm/libgcc-bpabi.ver +.endif VERSION_MAP = libgcc.map libgcc.map: ${SHLIB_MKMAP} ${SHLIB_MAPFILES} ${SOBJS} ${OBJS:R:S/$/.So/} diff --git a/gnu/lib/libgcov/Makefile b/gnu/lib/libgcov/Makefile index 680cdbf..dbefca2 100644 --- a/gnu/lib/libgcov/Makefile +++ b/gnu/lib/libgcov/Makefile @@ -15,6 +15,11 @@ CFLAGS+= -DIN_GCC -DIN_LIBGCC2 -D__GCC_FLOAT_NOT_NEEDED CFLAGS+= -D_PTHREADS -DGTHREAD_USE_WEAK CFLAGS+= -I${.CURDIR}/../../usr.bin/cc/cc_tools \ -I${GCCLIB}/include -I${GCCDIR}/config -I${GCCDIR} -I. + +.if ${TARGET_CPUARCH} == "arm" && ${MK_ARM_EABI} != "no" +CFLAGS+= -DTARGET_ARM_EABI +.endif + # # Library members defined in libgcov.c. # Defined in libgcov.c, included only in gcov library diff --git a/gnu/lib/libstdc++/Makefile b/gnu/lib/libstdc++/Makefile index 1005b5d..da88e70 100644 --- a/gnu/lib/libstdc++/Makefile +++ b/gnu/lib/libstdc++/Makefile @@ -1,5 +1,7 @@ # $FreeBSD$ +.include + GCCVER= 4.2 GCCDIR= ${.CURDIR}/../../../contrib/gcc GCCLIB= ${.CURDIR}/../../../contrib/gcclibs @@ -14,7 +16,7 @@ LIB= stdc++ SHLIB_MAJOR= 6 CFLAGS+= -DIN_GLIBCPP_V3 -DHAVE_CONFIG_H -.if ${MACHINE_CPUARCH} == "arm" +.if ${MACHINE_CPUARCH} == "arm" && ${MK_ARM_EABI} == "no" CFLAGS+= -D_GLIBCXX_SJLJ_EXCEPTIONS=1 .endif CFLAGS+= -I${.CURDIR} -I${SUPDIR} -I${GCCDIR} -I${SRCDIR}/include @@ -594,7 +596,13 @@ gthr-default.h: ${GCCDIR}/gthr-posix.h CLEANFILES+= ${THRHDRS} +.if ${MACHINE_CPUARCH} == "arm" && ${MK_ARM_EABI} != "no" +unwind.h: ${GCCDIR}/config/arm/unwind-arm.h +.else unwind.h: ${GCCDIR}/unwind-generic.h +.endif + +unwind.h: ln -sf ${.ALLSRC} ${.TARGET} SRCS+= unwind.h diff --git a/gnu/usr.bin/cc/Makefile.inc b/gnu/usr.bin/cc/Makefile.inc index 7a5991e..0302617 100644 --- a/gnu/usr.bin/cc/Makefile.inc +++ b/gnu/usr.bin/cc/Makefile.inc @@ -26,6 +26,10 @@ CSTD?= gnu89 CFLAGS+= -DCROSS_COMPILE .endif +.if ${TARGET_CPUARCH} == "arm" && ${MK_ARM_EABI} != "no" +CFLAGS+= -DTARGET_ARM_EABI +.endif + .if ${TARGET_ARCH} == "armeb" || ${TARGET_ARCH} == "armv6eb" CFLAGS += -DTARGET_ENDIAN_DEFAULT=MASK_BIG_END .endif diff --git a/gnu/usr.bin/cc/c++filt/Makefile b/gnu/usr.bin/cc/c++filt/Makefile index 03ad7c2..5379795 100644 --- a/gnu/usr.bin/cc/c++filt/Makefile +++ b/gnu/usr.bin/cc/c++filt/Makefile @@ -1,5 +1,8 @@ # $FreeBSD$ +NO_MAN= +.include + .include "../Makefile.inc" .include "../Makefile.fe" @@ -7,7 +10,6 @@ PROG= c++filt SRCS= cp-demangle.c -NO_MAN= CFLAGS+= -DSTANDALONE_DEMANGLER -DVERSION=\"$(GCC_VERSION)\" diff --git a/gnu/usr.bin/cc/cc1/Makefile b/gnu/usr.bin/cc/cc1/Makefile index 7b1e343..3c0d8fa 100644 --- a/gnu/usr.bin/cc/cc1/Makefile +++ b/gnu/usr.bin/cc/cc1/Makefile @@ -1,9 +1,10 @@ # $FreeBSD$ -.include "../Makefile.inc" NO_MAN= .include +.include "../Makefile.inc" + .PATH: ${GCCDIR} PROG= cc1 diff --git a/gnu/usr.bin/cc/cc1plus/Makefile b/gnu/usr.bin/cc/cc1plus/Makefile index dd3d524..83b0abb 100644 --- a/gnu/usr.bin/cc/cc1plus/Makefile +++ b/gnu/usr.bin/cc/cc1plus/Makefile @@ -1,9 +1,10 @@ # $FreeBSD$ -.include "../Makefile.inc" NO_MAN= .include +.include "../Makefile.inc" + .PATH: ${GCCDIR}/cp ${GCCDIR} PROG= cc1plus diff --git a/gnu/usr.bin/cc/cc_int/Makefile b/gnu/usr.bin/cc/cc_int/Makefile index e6051e1..86c1791 100644 --- a/gnu/usr.bin/cc/cc_int/Makefile +++ b/gnu/usr.bin/cc/cc_int/Makefile @@ -1,5 +1,7 @@ # $FreeBSD$ +.include + .include "../Makefile.inc" .include "../Makefile.ver" diff --git a/gnu/usr.bin/cc/cc_tools/Makefile b/gnu/usr.bin/cc/cc_tools/Makefile index c697dd3..8f75f43 100644 --- a/gnu/usr.bin/cc/cc_tools/Makefile +++ b/gnu/usr.bin/cc/cc_tools/Makefile @@ -51,6 +51,9 @@ TARGET_INC+= ${GCC_CPU}/elf.h .endif .if ${TARGET_CPUARCH} == "arm" TARGET_INC+= ${GCC_CPU}/aout.h +.if ${MK_ARM_EABI} != "no" +TARGET_INC+= ${GCC_CPU}/bpabi.h +.endif .endif .if ${TARGET_ARCH} == "powerpc64" TARGET_INC+= ${GCC_CPU}/biarch64.h @@ -349,7 +352,13 @@ gthr-default.h: ${GCCDIR}/gthr-posix.h GENSRCS+= gthr-default.h +.if ${TARGET_CPUARCH} == "arm" && ${MK_ARM_EABI} != "no" +unwind.h: ${GCCDIR}/config/arm/unwind-arm.h +.else unwind.h: ${GCCDIR}/unwind-generic.h +.endif + +unwind.h: ln -sf ${.ALLSRC} ${.TARGET} GENSRCS+= unwind.h diff --git a/gnu/usr.bin/cc/doc/Makefile b/gnu/usr.bin/cc/doc/Makefile index 840b694..a56231b 100644 --- a/gnu/usr.bin/cc/doc/Makefile +++ b/gnu/usr.bin/cc/doc/Makefile @@ -1,5 +1,7 @@ # $FreeBSD$ +.include + .include "../Makefile.inc" .include "../Makefile.ver" diff --git a/gnu/usr.bin/cc/gcov/Makefile b/gnu/usr.bin/cc/gcov/Makefile index f48d177..9a87c02 100644 --- a/gnu/usr.bin/cc/gcov/Makefile +++ b/gnu/usr.bin/cc/gcov/Makefile @@ -1,5 +1,7 @@ # $FreeBSD$ +.include + .include "../Makefile.inc" .include "../Makefile.ver" diff --git a/gnu/usr.bin/cc/include/Makefile b/gnu/usr.bin/cc/include/Makefile index 1698262..357bac0 100644 --- a/gnu/usr.bin/cc/include/Makefile +++ b/gnu/usr.bin/cc/include/Makefile @@ -1,5 +1,7 @@ # $FreeBSD$ +.include + .include "../Makefile.inc" INCSDIR=${INCLUDEDIR}/gcc/${GCCVER} diff --git a/gnu/usr.bin/cc/libcpp/Makefile b/gnu/usr.bin/cc/libcpp/Makefile index 23bc26e..bfaea7d 100644 --- a/gnu/usr.bin/cc/libcpp/Makefile +++ b/gnu/usr.bin/cc/libcpp/Makefile @@ -1,5 +1,7 @@ # $FreeBSD$ +.include + # Use our headers in preference to ones from ../cc_tools. CFLAGS+= -I${.CURDIR} -I. diff --git a/gnu/usr.bin/cc/libdecnumber/Makefile b/gnu/usr.bin/cc/libdecnumber/Makefile index 82df5a9..2987c1c 100644 --- a/gnu/usr.bin/cc/libdecnumber/Makefile +++ b/gnu/usr.bin/cc/libdecnumber/Makefile @@ -1,5 +1,7 @@ # $FreeBSD$ +.include + # Use our headers in preference to ones from ../cc_tools. CFLAGS+= -I${.CURDIR} -I. diff --git a/gnu/usr.bin/cc/libiberty/Makefile b/gnu/usr.bin/cc/libiberty/Makefile index 7446793..adaa128 100644 --- a/gnu/usr.bin/cc/libiberty/Makefile +++ b/gnu/usr.bin/cc/libiberty/Makefile @@ -1,5 +1,7 @@ # $FreeBSD$ +.include + # # Make sure we will pick up our config.h file first, not the one from # cc_tools. -- cgit v1.1 From c04b8a9f994dcdbd730335fce0e4256b7ca4f57c Mon Sep 17 00:00:00 2001 From: adrian Date: Mon, 21 Jan 2013 01:46:36 +0000 Subject: Add command-line support to kgdb to allow the baudrate to be set. This allows a remote session to be specified with '-r' as well as a non-default baudrate setting using '-b'. TODO: add to the kgdb manpage. MFC after: 2 weeks --- gnu/usr.bin/gdb/kgdb/main.c | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) (limited to 'gnu') diff --git a/gnu/usr.bin/gdb/kgdb/main.c b/gnu/usr.bin/gdb/kgdb/main.c index 9293f36..45a3dc0 100644 --- a/gnu/usr.bin/gdb/kgdb/main.c +++ b/gnu/usr.bin/gdb/kgdb/main.c @@ -333,11 +333,24 @@ main(int argc, char *argv[]) args.argv = malloc(sizeof(char *)); args.argv[0] = argv[0]; - while ((ch = getopt(argc, argv, "ac:d:fn:qr:vw")) != -1) { + while ((ch = getopt(argc, argv, "ab:c:d:fn:qr:vw")) != -1) { switch (ch) { case 'a': annotation_level++; break; + case 'b': + { + int i; + char *p; + + i = strtol (optarg, &p, 0); + if (i == 0 && p == optarg) + warnx("warning: could not set baud rate to `%s'.\n", + optarg); + else + baud_rate = i; + } + break; case 'c': /* use given core file. */ if (vmcore != NULL) { warnx("option %c: can only be specified once", -- cgit v1.1 From 9ce6a82d5da13da50c33f3215399e9062026dc7b Mon Sep 17 00:00:00 2001 From: davidxu Date: Tue, 22 Jan 2013 03:23:14 +0000 Subject: Make "-D skip" option work with FIFO by opening file in non-blocking mode. Reviewed by: jhb Tested by: delphij --- gnu/usr.bin/grep/grep.c | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'gnu') diff --git a/gnu/usr.bin/grep/grep.c b/gnu/usr.bin/grep/grep.c index 1684a82..0cab4a1 100644 --- a/gnu/usr.bin/grep/grep.c +++ b/gnu/usr.bin/grep/grep.c @@ -304,7 +304,7 @@ reset (int fd, char const *file, struct stats *stats) if (directories == SKIP_DIRECTORIES && S_ISDIR (stats->stat.st_mode)) return 0; #ifndef DJGPP - if (devices == SKIP_DEVICES && (S_ISCHR(stats->stat.st_mode) || S_ISBLK(stats->stat.st_mode) || S_ISSOCK(stats->stat.st_mode))) + if (devices == SKIP_DEVICES && (S_ISCHR(stats->stat.st_mode) || S_ISBLK(stats->stat.st_mode) || S_ISSOCK(stats->stat.st_mode) || S_ISFIFO(stats->stat.st_mode))) #else if (devices == SKIP_DEVICES && (S_ISCHR(stats->stat.st_mode) || S_ISBLK(stats->stat.st_mode))) #endif @@ -942,6 +942,7 @@ grepfile (char const *file, struct stats *stats) int desc; int count; int status; + int flags; if (! file) { @@ -950,7 +951,7 @@ grepfile (char const *file, struct stats *stats) } else { - while ((desc = open (file, O_RDONLY)) < 0 && errno == EINTR) + while ((desc = open (file, O_RDONLY | O_NONBLOCK)) < 0 && errno == EINTR) continue; if (desc < 0) @@ -990,6 +991,9 @@ grepfile (char const *file, struct stats *stats) return 1; } + flags = fcntl(desc, F_GETFL); + flags &= ~O_NONBLOCK; + fcntl(desc, F_SETFL, flags); filename = file; } -- cgit v1.1 From 75dc0fdd3895a77a7b2d8e209f8c69bad8af69aa Mon Sep 17 00:00:00 2001 From: theraven Date: Tue, 22 Jan 2013 17:49:51 +0000 Subject: Import new (BSDL) device tree compiler. Now built by default, so that it can't be used on the host system (and not installed on the device, if required). The GPL'd one is still available if there are any devices that need it (make universe passes with it, including kernels that use fdt, but there may be some out-of-tree ones). WITH_GPL_DTC can be used to select the old one, for now. Probably won't be MFC'd, but we'll remove the GPL'd version in head after the new one has had a lot more testing and ship it in 10.0. --- gnu/usr.bin/Makefile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'gnu') diff --git a/gnu/usr.bin/Makefile b/gnu/usr.bin/Makefile index 3a61327..386c957 100644 --- a/gnu/usr.bin/Makefile +++ b/gnu/usr.bin/Makefile @@ -30,7 +30,7 @@ _groff= groff _cvs= cvs .endif -.if ${MK_FDT} != "no" +.if ${MK_GPL_DTC} != "no" _dtc= dtc .endif -- cgit v1.1 From fd309737271993754984c9d12d5bd3f86e3fac12 Mon Sep 17 00:00:00 2001 From: brooks Date: Thu, 24 Jan 2013 15:18:41 +0000 Subject: Reorder so that NO_MAN is declared before bsd.own.mk is included and thus has an effect (not installed a g++.1 manpage over the g++.1(.gz) link created in ../cc). --- gnu/usr.bin/cc/c++/Makefile | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) (limited to 'gnu') diff --git a/gnu/usr.bin/cc/c++/Makefile b/gnu/usr.bin/cc/c++/Makefile index f434b34..54e8561 100644 --- a/gnu/usr.bin/cc/c++/Makefile +++ b/gnu/usr.bin/cc/c++/Makefile @@ -1,7 +1,5 @@ # $FreeBSD$ -.include - .include "../Makefile.inc" .include "../Makefile.fe" @@ -9,13 +7,16 @@ PROG= g++ SRCS+= g++spec.c -.if ${MK_CLANG_IS_CC} == "no" -LINKS= ${BINDIR}/g++ ${BINDIR}/c++ -LINKS+= ${BINDIR}/g++ ${BINDIR}/CC -.endif NO_MAN= DPADD= ${LIBCPP} ${LIBIBERTY} LDADD= ${LIBCPP} ${LIBIBERTY} +.include + +.if ${MK_CLANG_IS_CC} == "no" +LINKS= ${BINDIR}/g++ ${BINDIR}/c++ +LINKS+= ${BINDIR}/g++ ${BINDIR}/CC +.endif + .include -- cgit v1.1 From 7c6cedfc5960cf37c1945687db87c260055ee755 Mon Sep 17 00:00:00 2001 From: andrew Date: Fri, 25 Jan 2013 06:18:49 +0000 Subject: bsd.own.mk needs to be included before Makefil.inc so MK_ARM_EABI is defined --- gnu/usr.bin/cc/c++/Makefile | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'gnu') diff --git a/gnu/usr.bin/cc/c++/Makefile b/gnu/usr.bin/cc/c++/Makefile index 54e8561..98e1ea3 100644 --- a/gnu/usr.bin/cc/c++/Makefile +++ b/gnu/usr.bin/cc/c++/Makefile @@ -1,5 +1,8 @@ # $FreeBSD$ +NO_MAN= +.include + .include "../Makefile.inc" .include "../Makefile.fe" @@ -7,13 +10,10 @@ PROG= g++ SRCS+= g++spec.c -NO_MAN= DPADD= ${LIBCPP} ${LIBIBERTY} LDADD= ${LIBCPP} ${LIBIBERTY} -.include - .if ${MK_CLANG_IS_CC} == "no" LINKS= ${BINDIR}/g++ ${BINDIR}/c++ LINKS+= ${BINDIR}/g++ ${BINDIR}/CC -- cgit v1.1 From b923a5521baf7a53ffa6239bb920ea3b7d10e780 Mon Sep 17 00:00:00 2001 From: theraven Date: Mon, 28 Jan 2013 11:12:49 +0000 Subject: Fix some symbol version mismatches between libstdc++ and libsupc++/libcxxrt that were causing the runtime and STL libraries to see different versions of various classes and functions when libstdc++ is used as a filter. Note: This changes the ABI for libcxxrt, but libcxxrt is currently only in -STABLE for testing and is not used by anything unless explicitly enabled by the end user. No default compiler configurations use it. libc++ will need to be recompiled after this change. make buildworld will do this automatically, but make in lib/libc++ will not necessarily work unless the new libcxxrt is installed first. PR: kern/171610, stand/175453 Reviewed by: kib MFC after: 1 week --- gnu/lib/libsupc++/Version.map | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) (limited to 'gnu') diff --git a/gnu/lib/libsupc++/Version.map b/gnu/lib/libsupc++/Version.map index ec6303e..dbcf495 100644 --- a/gnu/lib/libsupc++/Version.map +++ b/gnu/lib/libsupc++/Version.map @@ -142,8 +142,37 @@ GLIBCXX_3.4 { _ZdaPvRKSt9nothrow_t; _ZdlPv; _ZdlPvRKSt9nothrow_t; + extern "C++" { + std::set_new_handler*; + std::set_terminate*; + std::set_unexpected*; + + std::bad_alloc; + std::bad_cast; + std::exception*; + + "typeinfo for std::bad_alloc"; + "typeinfo for std::bad_cast"; + "typeinfo for std::exception"; + + "typeinfo name for std::bad_alloc"; + "typeinfo name for std::bad_cast"; + "typeinfo name for std::exception"; + + "vtable for std::bad_alloc"; + "vtable for std::bad_cast"; + "vtable for std::exception"; + }; }; +GLIBCXX_3.4.9 { + extern "C++" { + "std::bad_alloc::what() const"; + "std::bad_cast::what() const"; + "std::bad_typeid::what() const"; + }; +} GLIBCXX_3.4; + CXXABI_1.3.1 { __cxa_get_exception_ptr; -- cgit v1.1 From d992e3eb2a38c97190fad5ec2287b67889a8c5b8 Mon Sep 17 00:00:00 2001 From: gabor Date: Tue, 29 Jan 2013 17:03:18 +0000 Subject: - Add a BSD-licensed patch, ported by Pedro F. Giffuni (pfg) from DragonflyBSD and install it as bsdpatch. WITH_BSD_PATCH makes it default and installs GNU patch as gnupatch. Submitted by: pfg Obtained from: The DragonflyBSD Project --- gnu/usr.bin/patch/Makefile | 13 ++++++++++++- 1 file changed, 12 insertions(+), 1 deletion(-) (limited to 'gnu') diff --git a/gnu/usr.bin/patch/Makefile b/gnu/usr.bin/patch/Makefile index 373efbb..76d28e8 100644 --- a/gnu/usr.bin/patch/Makefile +++ b/gnu/usr.bin/patch/Makefile @@ -1,6 +1,17 @@ # $FreeBSD$ -PROG= patch +.include + +.if ${MK_BSD_PATCH} == "yes" +PROG= gnupatch +CLEANFILES+= gnupatch.1 + +gnupatch.1: patch.1 + cp ${.ALLSRC} ${.TARGET} +.else +PROG= patch +.endif + SRCS= backupfile.c inp.c patch.c pch.c util.c version.c CFLAGS+=-DHAVE_CONFIG_H -- cgit v1.1