From owner-svn-src-projects@FreeBSD.ORG Thu May 14 22:22:03 2015 Return-Path: Delivered-To: svn-src-projects@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [8.8.178.115]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 63C5AC1B; Thu, 14 May 2015 22:22:03 +0000 (UTC) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:1900:2254:2068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 4E9A11C22; Thu, 14 May 2015 22:22:03 +0000 (UTC) Received: from svn.freebsd.org ([127.0.1.70]) by svn.freebsd.org (8.14.9/8.14.9) with ESMTP id t4EMM3oA092530; Thu, 14 May 2015 22:22:03 GMT (envelope-from sbruno@FreeBSD.org) Received: (from sbruno@localhost) by svn.freebsd.org (8.14.9/8.14.9/Submit) id t4EMLqLc090551; Thu, 14 May 2015 22:21:52 GMT (envelope-from sbruno@FreeBSD.org) Message-Id: <201505142221.t4EMLqLc090551@svn.freebsd.org> X-Authentication-Warning: svn.freebsd.org: sbruno set sender to sbruno@FreeBSD.org using -f From: Sean Bruno Date: Thu, 14 May 2015 22:21:52 +0000 (UTC) To: src-committers@freebsd.org, svn-src-projects@freebsd.org Subject: svn commit: r282931 - in projects/ci20_mips: . cddl/contrib/opensolaris/common/ctf contrib/bmake contrib/bmake/mk contrib/bmake/unit-tests contrib/elftoolchain/addr2line contrib/elftoolchain/common... X-SVN-Group: projects MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-src-projects@freebsd.org X-Mailman-Version: 2.1.20 Precedence: list List-Id: "SVN commit messages for the src " projects" tree" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 14 May 2015 22:22:03 -0000 Author: sbruno Date: Thu May 14 22:21:50 2015 New Revision: 282931 URL: https://svnweb.freebsd.org/changeset/base/282931 Log: MFH @282930 Added: projects/ci20_mips/contrib/bmake/unit-tests/cond2.exp - copied unchanged from r282930, head/contrib/bmake/unit-tests/cond2.exp projects/ci20_mips/contrib/bmake/unit-tests/cond2.mk - copied unchanged from r282930, head/contrib/bmake/unit-tests/cond2.mk projects/ci20_mips/lib/libc/aarch64/gen/fabs.S - copied unchanged from r282930, head/lib/libc/aarch64/gen/fabs.S projects/ci20_mips/release/Makefile.mirrors - copied unchanged from r282930, head/release/Makefile.mirrors projects/ci20_mips/sys/arm64/arm64/gic_v3.c - copied unchanged from r282930, head/sys/arm64/arm64/gic_v3.c projects/ci20_mips/sys/arm64/arm64/gic_v3_fdt.c - copied unchanged from r282930, head/sys/arm64/arm64/gic_v3_fdt.c projects/ci20_mips/sys/arm64/arm64/gic_v3_reg.h - copied unchanged from r282930, head/sys/arm64/arm64/gic_v3_reg.h projects/ci20_mips/sys/arm64/arm64/gic_v3_var.h - copied unchanged from r282930, head/sys/arm64/arm64/gic_v3_var.h projects/ci20_mips/sys/powerpc/mpc85xx/pci_mpc85xx_pcib.c - copied unchanged from r282930, head/sys/powerpc/mpc85xx/pci_mpc85xx_pcib.c Modified: projects/ci20_mips/Makefile.inc1 projects/ci20_mips/ObsoleteFiles.inc projects/ci20_mips/cddl/contrib/opensolaris/common/ctf/ctf_create.c projects/ci20_mips/contrib/bmake/ChangeLog projects/ci20_mips/contrib/bmake/FILES projects/ci20_mips/contrib/bmake/Makefile projects/ci20_mips/contrib/bmake/cond.c projects/ci20_mips/contrib/bmake/machine.sh projects/ci20_mips/contrib/bmake/mk/ChangeLog projects/ci20_mips/contrib/bmake/mk/dirdeps.mk projects/ci20_mips/contrib/bmake/mk/install-mk projects/ci20_mips/contrib/bmake/nonints.h projects/ci20_mips/contrib/bmake/unit-tests/Makefile.in projects/ci20_mips/contrib/bmake/var.c projects/ci20_mips/contrib/elftoolchain/addr2line/addr2line.1 projects/ci20_mips/contrib/elftoolchain/addr2line/addr2line.c projects/ci20_mips/contrib/elftoolchain/common/native-elf-format projects/ci20_mips/contrib/elftoolchain/cxxfilt/c++filt.1 projects/ci20_mips/contrib/elftoolchain/elfcopy/elfcopy.1 projects/ci20_mips/contrib/elftoolchain/elfcopy/sections.c projects/ci20_mips/contrib/elftoolchain/elfcopy/segments.c projects/ci20_mips/contrib/elftoolchain/elfcopy/symbols.c projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf.3 projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_add_line_entry.3 projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_def_macro.3 projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_expand_frame_instructions.3 projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_formblock.3 projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_formflag.3 projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_formref.3 projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_formsig8.3 projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_formudata.3 projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_get_fde_info_for_all_regs.3 projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_get_fde_info_for_reg.3 projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_get_ranges.3 projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_hasattr.3 projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_next_cu_header.3 projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_producer_init.3 projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_whatattr.3 projects/ci20_mips/contrib/elftoolchain/libelf/elf.3 projects/ci20_mips/contrib/elftoolchain/libelf/elf_begin.3 projects/ci20_mips/contrib/elftoolchain/libelf/elf_cntl.3 projects/ci20_mips/contrib/elftoolchain/libelf/elf_getdata.3 projects/ci20_mips/contrib/elftoolchain/libelf/elf_open.3 projects/ci20_mips/contrib/elftoolchain/libelf/elf_update.c projects/ci20_mips/contrib/elftoolchain/libelf/gelf.3 projects/ci20_mips/contrib/elftoolchain/libelftc/elftc_demangle.3 projects/ci20_mips/contrib/elftoolchain/libelftc/elftc_symbol_table_create.3 projects/ci20_mips/contrib/elftoolchain/libelftc/libelftc_dem_gnu3.c projects/ci20_mips/contrib/elftoolchain/nm/nm.1 projects/ci20_mips/contrib/elftoolchain/readelf/readelf.1 projects/ci20_mips/contrib/elftoolchain/readelf/readelf.c projects/ci20_mips/contrib/elftoolchain/size/size.1 projects/ci20_mips/contrib/elftoolchain/size/size.c projects/ci20_mips/contrib/elftoolchain/strings/strings.1 projects/ci20_mips/etc/rc.d/hostid projects/ci20_mips/lib/Makefile projects/ci20_mips/lib/libc/aarch64/Symbol.map projects/ci20_mips/lib/libc/aarch64/gen/Makefile.inc projects/ci20_mips/lib/libc/arm/SYS.h projects/ci20_mips/lib/libc/arm/aeabi/aeabi_vfp_double.S projects/ci20_mips/lib/libc/arm/aeabi/aeabi_vfp_float.S projects/ci20_mips/lib/libc/arm/gen/_setjmp.S projects/ci20_mips/lib/libc/arm/gen/setjmp.S projects/ci20_mips/lib/libc/arm/sys/brk.S projects/ci20_mips/lib/libc/arm/sys/sbrk.S projects/ci20_mips/lib/libelftc/elftc_version.c projects/ci20_mips/lib/libmd/Makefile projects/ci20_mips/lib/libmd/md4c.c projects/ci20_mips/lib/libmd/md5c.c projects/ci20_mips/lib/libmd/mdXhl.c projects/ci20_mips/lib/libmd/rmd160c.c projects/ci20_mips/lib/libmd/sha1c.c projects/ci20_mips/lib/libmd/sha256c.c projects/ci20_mips/lib/libmd/sha512c.c projects/ci20_mips/release/tools/vmimage.subr projects/ci20_mips/sbin/devd/devd.conf.5 projects/ci20_mips/sbin/ifconfig/af_inet.c projects/ci20_mips/sbin/ifconfig/af_inet6.c projects/ci20_mips/sbin/ifconfig/ifconfig.8 projects/ci20_mips/sbin/ifconfig/iffib.c projects/ci20_mips/share/syscons/keymaps/INDEX.keymaps projects/ci20_mips/share/vt/keymaps/INDEX.keymaps projects/ci20_mips/sys/amd64/conf/GENERIC projects/ci20_mips/sys/arm/amlogic/aml8726/aml8726_machdep.c projects/ci20_mips/sys/arm/arm/cpufunc.c projects/ci20_mips/sys/arm/arm/exception.S projects/ci20_mips/sys/arm/arm/fusu.S projects/ci20_mips/sys/arm/arm/intr.c projects/ci20_mips/sys/arm/arm/machdep.c projects/ci20_mips/sys/arm/arm/mp_machdep.c projects/ci20_mips/sys/arm/arm/pmap-v6-new.c projects/ci20_mips/sys/arm/arm/stdatomic.c projects/ci20_mips/sys/arm/arm/swtch.S projects/ci20_mips/sys/arm/arm/syscall.c projects/ci20_mips/sys/arm/arm/undefined.c projects/ci20_mips/sys/arm/arm/vm_machdep.c projects/ci20_mips/sys/arm/broadcom/bcm2835/bcm2836_mp.c projects/ci20_mips/sys/arm/include/asm.h projects/ci20_mips/sys/arm/include/atomic.h projects/ci20_mips/sys/arm/include/cpu-v6.h projects/ci20_mips/sys/arm/include/pmap-v6.h projects/ci20_mips/sys/arm/include/smp.h projects/ci20_mips/sys/arm/ti/am335x/am335x_pmic.c projects/ci20_mips/sys/arm64/arm64/locore.S projects/ci20_mips/sys/arm64/conf/GENERIC projects/ci20_mips/sys/arm64/include/armreg.h projects/ci20_mips/sys/boot/efi/loader/arch/arm/ldscript.arm projects/ci20_mips/sys/boot/fdt/dts/arm/beaglebone-black.dts projects/ci20_mips/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/dmu_traverse.c projects/ci20_mips/sys/cddl/contrib/opensolaris/uts/common/fs/zfs/zfs_ioctl.c projects/ci20_mips/sys/cddl/dev/dtrace/amd64/dtrace_subr.c projects/ci20_mips/sys/cddl/dev/dtrace/i386/dtrace_subr.c projects/ci20_mips/sys/conf/files.arm64 projects/ci20_mips/sys/conf/files.powerpc projects/ci20_mips/sys/conf/options projects/ci20_mips/sys/dev/acpica/acpi_cpu.c projects/ci20_mips/sys/dev/if_ndis/if_ndis.c projects/ci20_mips/sys/dev/ofw/ofw_bus_subr.c projects/ci20_mips/sys/dev/ofw/ofw_bus_subr.h projects/ci20_mips/sys/dev/pci/pci_pci.c projects/ci20_mips/sys/dev/pci/pcib_private.h projects/ci20_mips/sys/dev/sfxge/sfxge.c projects/ci20_mips/sys/dev/sfxge/sfxge_port.c projects/ci20_mips/sys/dev/sfxge/sfxge_rx.c projects/ci20_mips/sys/dev/sfxge/sfxge_tx.c projects/ci20_mips/sys/dev/xen/netfront/netfront.c projects/ci20_mips/sys/fs/nfsclient/nfs_clbio.c projects/ci20_mips/sys/i386/conf/GENERIC projects/ci20_mips/sys/kern/kern_cpuset.c projects/ci20_mips/sys/kern/kern_racct.c projects/ci20_mips/sys/net/if_bridge.c projects/ci20_mips/sys/net/if_gif.c projects/ci20_mips/sys/net/if_gre.c projects/ci20_mips/sys/net/if_me.c projects/ci20_mips/sys/net80211/ieee80211.h projects/ci20_mips/sys/net80211/ieee80211_adhoc.c projects/ci20_mips/sys/net80211/ieee80211_hostap.c projects/ci20_mips/sys/net80211/ieee80211_input.h projects/ci20_mips/sys/net80211/ieee80211_mesh.c projects/ci20_mips/sys/net80211/ieee80211_output.c projects/ci20_mips/sys/net80211/ieee80211_scan.c projects/ci20_mips/sys/net80211/ieee80211_scan.h projects/ci20_mips/sys/net80211/ieee80211_scan_sta.c projects/ci20_mips/sys/net80211/ieee80211_scan_sw.c projects/ci20_mips/sys/net80211/ieee80211_scan_sw.h projects/ci20_mips/sys/net80211/ieee80211_sta.c projects/ci20_mips/sys/net80211/ieee80211_wds.c projects/ci20_mips/sys/netinet/sctp_input.c projects/ci20_mips/sys/netinet6/nd6.h projects/ci20_mips/sys/netinet6/nd6_nbr.c projects/ci20_mips/sys/netpfil/ipfw/ip_fw2.c projects/ci20_mips/sys/netpfil/ipfw/ip_fw_table_value.c projects/ci20_mips/sys/ofed/drivers/net/mlx4/en_netdev.c projects/ci20_mips/sys/ofed/include/linux/bitops.h projects/ci20_mips/sys/ofed/include/linux/jiffies.h projects/ci20_mips/sys/pc98/conf/GENERIC projects/ci20_mips/sys/powerpc/conf/GENERIC projects/ci20_mips/sys/powerpc/mpc85xx/pci_mpc85xx.c projects/ci20_mips/sys/sparc64/conf/GENERIC projects/ci20_mips/sys/sys/cdefs.h projects/ci20_mips/sys/sys/elf_common.h projects/ci20_mips/sys/sys/sockio.h projects/ci20_mips/usr.bin/bmake/Makefile projects/ci20_mips/usr.bin/bmake/unit-tests/Makefile projects/ci20_mips/usr.bin/elfdump/elfdump.c projects/ci20_mips/usr.bin/rctl/rctl.8 projects/ci20_mips/usr.bin/vtfontcvt/vtfontcvt.c projects/ci20_mips/usr.bin/whois/whois.1 projects/ci20_mips/usr.bin/whois/whois.c projects/ci20_mips/usr.sbin/bhyve/bhyve.8 projects/ci20_mips/usr.sbin/bhyve/block_if.c projects/ci20_mips/usr.sbin/bhyve/block_if.h projects/ci20_mips/usr.sbin/bhyve/pci_virtio_block.c projects/ci20_mips/usr.sbin/bhyve/pci_virtio_net.c projects/ci20_mips/usr.sbin/bhyve/pci_virtio_rnd.c projects/ci20_mips/usr.sbin/bhyve/virtio.c projects/ci20_mips/usr.sbin/crunch/crunchide/exec_elf32.c projects/ci20_mips/usr.sbin/kbdmap/kbdmap.c projects/ci20_mips/usr.sbin/pmcstat/pmcstat_log.c Directory Properties: projects/ci20_mips/ (props changed) projects/ci20_mips/cddl/ (props changed) projects/ci20_mips/cddl/contrib/opensolaris/ (props changed) projects/ci20_mips/contrib/bmake/ (props changed) projects/ci20_mips/contrib/elftoolchain/ (props changed) projects/ci20_mips/etc/ (props changed) projects/ci20_mips/lib/libc/ (props changed) projects/ci20_mips/sbin/ (props changed) projects/ci20_mips/share/ (props changed) projects/ci20_mips/sys/ (props changed) projects/ci20_mips/sys/boot/ (props changed) projects/ci20_mips/sys/cddl/contrib/opensolaris/ (props changed) projects/ci20_mips/sys/conf/ (props changed) projects/ci20_mips/usr.sbin/bhyve/ (props changed) Modified: projects/ci20_mips/Makefile.inc1 ============================================================================== --- projects/ci20_mips/Makefile.inc1 Thu May 14 21:39:03 2015 (r282930) +++ projects/ci20_mips/Makefile.inc1 Thu May 14 22:21:50 2015 (r282931) @@ -1660,13 +1660,7 @@ _prereq_libs= gnu/lib/libssp/libssp_nons # all shared libraries for ELF. # _startup_libs= gnu/lib/csu -.if exists(${.CURDIR}/lib/csu/${MACHINE_ARCH}-elf) -_startup_libs+= lib/csu/${MACHINE_ARCH}-elf -.elif exists(${.CURDIR}/lib/csu/${MACHINE_ARCH}) -_startup_libs+= lib/csu/${MACHINE_ARCH} -.else -_startup_libs+= lib/csu/${MACHINE_CPUARCH} -.endif +_startup_libs+= lib/csu _startup_libs+= gnu/lib/libgcc _startup_libs+= lib/libcompiler_rt _startup_libs+= lib/libc Modified: projects/ci20_mips/ObsoleteFiles.inc ============================================================================== --- projects/ci20_mips/ObsoleteFiles.inc Thu May 14 21:39:03 2015 (r282930) +++ projects/ci20_mips/ObsoleteFiles.inc Thu May 14 22:21:50 2015 (r282931) @@ -448,6 +448,33 @@ OLD_LIBS+=usr/lib32/libopie.so.7 OLD_FILES+=usr/bin/otp-sha OLD_FILES+=usr/share/man/man1/otp-sha.1.gz # 20140807: Remove private lib files that should not be installed. +OLD_FILES+=usr/lib32/private/libatf-c.a +OLD_FILES+=usr/lib32/private/libatf-c.so +OLD_FILES+=usr/lib32/private/libatf-c_p.a +OLD_FILES+=usr/lib32/private/libatf-c++.a +OLD_FILES+=usr/lib32/private/libatf-c++.so +OLD_FILES+=usr/lib32/private/libatf-c++_p.a +OLD_FILES+=usr/lib32/private/libbsdstat.a +OLD_FILES+=usr/lib32/private/libbsdstat.so +OLD_FILES+=usr/lib32/private/libbsdstat_p.a +OLD_FILES+=usr/lib32/private/libheimipcc.a +OLD_FILES+=usr/lib32/private/libheimipcc.so +OLD_FILES+=usr/lib32/private/libheimipcc_p.a +OLD_FILES+=usr/lib32/private/libheimipcs.a +OLD_FILES+=usr/lib32/private/libheimipcs.so +OLD_FILES+=usr/lib32/private/libheimipcs_p.a +OLD_FILES+=usr/lib32/private/libldns.a +OLD_FILES+=usr/lib32/private/libldns.so +OLD_FILES+=usr/lib32/private/libldns_p.a +OLD_FILES+=usr/lib32/private/libssh.a +OLD_FILES+=usr/lib32/private/libssh.so +OLD_FILES+=usr/lib32/private/libssh_p.a +OLD_FILES+=usr/lib32/private/libunbound.a +OLD_FILES+=usr/lib32/private/libunbound.so +OLD_FILES+=usr/lib32/private/libunbound_p.a +OLD_FILES+=usr/lib32/private/libucl.a +OLD_FILES+=usr/lib32/private/libucl.so +OLD_FILES+=usr/lib32/private/libucl_p.a OLD_FILES+=usr/lib/private/libatf-c.a OLD_FILES+=usr/lib/private/libatf-c.so OLD_FILES+=usr/lib/private/libatf-c_p.a @@ -468,7 +495,7 @@ OLD_FILES+=usr/lib/private/libldns.so OLD_FILES+=usr/lib/private/libldns_p.a OLD_FILES+=usr/lib/private/libssh.a OLD_FILES+=usr/lib/private/libssh.so -OLD_FILES+=usr/lib/private/libssh.p.a +OLD_FILES+=usr/lib/private/libssh_p.a OLD_FILES+=usr/lib/private/libunbound.a OLD_FILES+=usr/lib/private/libunbound.so OLD_FILES+=usr/lib/private/libunbound_p.a @@ -620,8 +647,12 @@ OLD_FILES+=usr/libexec/bsdconfig/070.use # 20140223: Remove libyaml OLD_FILES+=usr/lib/private/libyaml.a OLD_FILES+=usr/lib/private/libyaml.so -OLD_FILES+=usr/lib/private/libyaml.so.1 +OLD_LIBS+=usr/lib/private/libyaml.so.1 OLD_FILES+=usr/lib/private/libyaml_p.a +OLD_FILES+=usr/lib32/private/libyaml.a +OLD_FILES+=usr/lib32/private/libyaml.so +OLD_LIBS+=usr/lib32/private/libyaml.so.1 +OLD_FILES+=usr/lib32/private/libyaml_p.a # 20140216: new clang import which bumps version from 3.3 to 3.4. OLD_FILES+=usr/bin/llvm-prof OLD_FILES+=usr/bin/llvm-ranlib Modified: projects/ci20_mips/cddl/contrib/opensolaris/common/ctf/ctf_create.c ============================================================================== --- projects/ci20_mips/cddl/contrib/opensolaris/common/ctf/ctf_create.c Thu May 14 21:39:03 2015 (r282930) +++ projects/ci20_mips/cddl/contrib/opensolaris/common/ctf/ctf_create.c Thu May 14 22:21:50 2015 (r282931) @@ -1328,15 +1328,28 @@ ctf_add_type(ctf_file_t *dst_fp, ctf_fil * we are looking for. This is necessary to permit ctf_add_type() to * operate recursively on entities such as a struct that contains a * pointer member that refers to the same struct type. + * + * In the case of integer and floating point types, we match using the + * type encoding as well - else we may incorrectly return a bitfield + * type, for instance. */ if (dst_type == CTF_ERR && name[0] != '\0') { for (dtd = ctf_list_prev(&dst_fp->ctf_dtdefs); dtd != NULL && CTF_TYPE_TO_INDEX(dtd->dtd_type) > dst_fp->ctf_dtoldid; dtd = ctf_list_prev(dtd)) { - if (CTF_INFO_KIND(dtd->dtd_data.ctt_info) == kind && - dtd->dtd_name != NULL && - strcmp(dtd->dtd_name, name) == 0) - return (dtd->dtd_type); + if (CTF_INFO_KIND(dtd->dtd_data.ctt_info) != kind || + dtd->dtd_name == NULL || + strcmp(dtd->dtd_name, name) != 0) + continue; + if (kind == CTF_K_INTEGER || kind == CTF_K_FLOAT) { + if (ctf_type_encoding(src_fp, src_type, + &src_en) != 0) + continue; + if (bcmp(&src_en, &dtd->dtd_u.dtu_enc, + sizeof (ctf_encoding_t)) != 0) + continue; + } + return (dtd->dtd_type); } } Modified: projects/ci20_mips/contrib/bmake/ChangeLog ============================================================================== --- projects/ci20_mips/contrib/bmake/ChangeLog Thu May 14 21:39:03 2015 (r282930) +++ projects/ci20_mips/contrib/bmake/ChangeLog Thu May 14 22:21:50 2015 (r282931) @@ -1,3 +1,16 @@ +2015-05-05 Simon J. Gerraty + + * Makefile (MAKE_VERSION): 20150505 + Merge with NetBSD make, pick up + o cond.c: be strict about lhs of comparison when evaluating .if + but less so when called from variable expansion. + o unit-tests/cond2.mk: test various error conditions + +2015-05-04 Simon J. Gerraty + + * machine.sh (MACHINE): Add Bitrig + patch from joerg@netbsd.org + 2015-04-18 Simon J. Gerraty * Makefile (MAKE_VERSION): 20150418 Modified: projects/ci20_mips/contrib/bmake/FILES ============================================================================== --- projects/ci20_mips/contrib/bmake/FILES Thu May 14 21:39:03 2015 (r282930) +++ projects/ci20_mips/contrib/bmake/FILES Thu May 14 22:21:50 2015 (r282931) @@ -96,6 +96,8 @@ unit-tests/comment.exp unit-tests/comment.mk unit-tests/cond1.exp unit-tests/cond1.mk +unit-tests/cond2.exp +unit-tests/cond2.mk unit-tests/doterror.exp unit-tests/doterror.mk unit-tests/dotwait.exp Modified: projects/ci20_mips/contrib/bmake/Makefile ============================================================================== --- projects/ci20_mips/contrib/bmake/Makefile Thu May 14 21:39:03 2015 (r282930) +++ projects/ci20_mips/contrib/bmake/Makefile Thu May 14 22:21:50 2015 (r282931) @@ -1,7 +1,7 @@ -# $Id: Makefile,v 1.36 2015/04/18 19:58:53 sjg Exp $ +# $Id: Makefile,v 1.38 2015/05/05 21:58:05 sjg Exp $ # Base version on src date -MAKE_VERSION= 20150418 +MAKE_VERSION= 20150505 PROG= bmake @@ -94,7 +94,7 @@ SUBDIR+= unit-tests # we skip a lot of this when building as part of FreeBSD etc. # list of OS's which are derrived from BSD4.4 -BSD44_LIST= NetBSD FreeBSD OpenBSD DragonFly +BSD44_LIST= NetBSD FreeBSD OpenBSD DragonFly MirBSD Bitrig # we are... OS!= uname -s # are we 4.4BSD ? Modified: projects/ci20_mips/contrib/bmake/cond.c ============================================================================== --- projects/ci20_mips/contrib/bmake/cond.c Thu May 14 21:39:03 2015 (r282930) +++ projects/ci20_mips/contrib/bmake/cond.c Thu May 14 22:21:50 2015 (r282931) @@ -1,4 +1,4 @@ -/* $NetBSD: cond.c,v 1.67 2012/11/03 13:59:27 christos Exp $ */ +/* $NetBSD: cond.c,v 1.68 2015/05/05 21:51:09 sjg Exp $ */ /* * Copyright (c) 1988, 1989, 1990 The Regents of the University of California. @@ -70,14 +70,14 @@ */ #ifndef MAKE_NATIVE -static char rcsid[] = "$NetBSD: cond.c,v 1.67 2012/11/03 13:59:27 christos Exp $"; +static char rcsid[] = "$NetBSD: cond.c,v 1.68 2015/05/05 21:51:09 sjg Exp $"; #else #include #ifndef lint #if 0 static char sccsid[] = "@(#)cond.c 8.2 (Berkeley) 1/2/94"; #else -__RCSID("$NetBSD: cond.c,v 1.67 2012/11/03 13:59:27 christos Exp $"); +__RCSID("$NetBSD: cond.c,v 1.68 2015/05/05 21:51:09 sjg Exp $"); #endif #endif /* not lint */ #endif @@ -181,6 +181,15 @@ static Token condPushBack=TOK_NONE; /* static unsigned int cond_depth = 0; /* current .if nesting level */ static unsigned int cond_min_depth = 0; /* depth at makefile open */ +/* + * Indicate when we should be strict about lhs of comparisons. + * TRUE when Cond_EvalExpression is called from Cond_Eval (.if etc) + * FALSE when Cond_EvalExpression is called from var.c:ApplyModifiers + * since lhs is already expanded and we cannot tell if + * it was a variable reference or not. + */ +static Boolean lhsStrict; + static int istoken(const char *str, const char *tok, size_t len) { @@ -517,7 +526,7 @@ CondCvtArg(char *str, double *value) */ /* coverity:[+alloc : arg-*2] */ static char * -CondGetString(Boolean doEval, Boolean *quoted, void **freeIt) +CondGetString(Boolean doEval, Boolean *quoted, void **freeIt, Boolean strictLHS) { Buffer buf; char *cp; @@ -601,6 +610,16 @@ CondGetString(Boolean doEval, Boolean *q condExpr--; /* don't skip over next char */ break; default: + if (strictLHS && !qt && *start != '$' && + !isdigit((unsigned char) *start)) { + /* lhs must be quoted, a variable reference or number */ + if (*freeIt) { + free(*freeIt); + *freeIt = NULL; + } + str = NULL; + goto cleanup; + } Buf_AddByte(&buf, *condExpr); break; } @@ -648,7 +667,7 @@ compare_expression(Boolean doEval) * Parse the variable spec and skip over it, saving its * value in lhs. */ - lhs = CondGetString(doEval, &lhsQuoted, &lhsFree); + lhs = CondGetString(doEval, &lhsQuoted, &lhsFree, lhsStrict); if (!lhs) goto done; @@ -709,7 +728,7 @@ compare_expression(Boolean doEval) goto done; } - rhs = CondGetString(doEval, &rhsQuoted, &rhsFree); + rhs = CondGetString(doEval, &rhsQuoted, &rhsFree, FALSE); if (!rhs) goto done; @@ -1135,7 +1154,7 @@ CondE(Boolean doEval) *----------------------------------------------------------------------- */ int -Cond_EvalExpression(const struct If *info, char *line, Boolean *value, int eprint) +Cond_EvalExpression(const struct If *info, char *line, Boolean *value, int eprint, Boolean strictLHS) { static const struct If *dflt_info; const struct If *sv_if_info = if_info; @@ -1143,6 +1162,8 @@ Cond_EvalExpression(const struct If *inf Token sv_condPushBack = condPushBack; int rval; + lhsStrict = strictLHS; + while (*line == ' ' || *line == '\t') line++; @@ -1359,7 +1380,7 @@ Cond_Eval(char *line) } /* And evaluate the conditional expresssion */ - if (Cond_EvalExpression(ifp, line, &value, 1) == COND_INVALID) { + if (Cond_EvalExpression(ifp, line, &value, 1, TRUE) == COND_INVALID) { /* Syntax error in conditional, error message already output. */ /* Skip everything to matching .endif */ cond_state[cond_depth] = SKIP_TO_ELSE; Modified: projects/ci20_mips/contrib/bmake/machine.sh ============================================================================== --- projects/ci20_mips/contrib/bmake/machine.sh Thu May 14 21:39:03 2015 (r282930) +++ projects/ci20_mips/contrib/bmake/machine.sh Thu May 14 22:21:50 2015 (r282931) @@ -2,7 +2,7 @@ # derrived from /etc/rc_d/os.sh # RCSid: -# $Id: machine.sh,v 1.16 2010/10/17 00:05:51 sjg Exp $ +# $Id: machine.sh,v 1.17 2015/05/05 00:10:54 sjg Exp $ # # @(#) Copyright (c) 1994-2002 Simon J. Gerraty # @@ -49,6 +49,10 @@ OpenBSD) arch=`Which arch /usr/bin:/usr/ucb:$PATH` MACHINE_ARCH=`$arch -s`; ;; +Bitrig) + MACHINE=$OS$OSMAJOR.$machine + MACHINE_ARCH=`uname -m`; + ;; *BSD) MACHINE=$OS$OSMAJOR.$machine ;; Modified: projects/ci20_mips/contrib/bmake/mk/ChangeLog ============================================================================== --- projects/ci20_mips/contrib/bmake/mk/ChangeLog Thu May 14 21:39:03 2015 (r282930) +++ projects/ci20_mips/contrib/bmake/mk/ChangeLog Thu May 14 22:21:50 2015 (r282931) @@ -1,3 +1,9 @@ +2015-04-30 Simon J. Gerraty + + * install-mk (MK_VERSION): 20150430 + + * dirdeps.mk: fix _count_dirdeps for non-cache case. + 2015-04-16 Simon J. Gerraty * install-mk (MK_VERSION): 20150411 Modified: projects/ci20_mips/contrib/bmake/mk/dirdeps.mk ============================================================================== --- projects/ci20_mips/contrib/bmake/mk/dirdeps.mk Thu May 14 21:39:03 2015 (r282930) +++ projects/ci20_mips/contrib/bmake/mk/dirdeps.mk Thu May 14 22:21:50 2015 (r282931) @@ -1,4 +1,4 @@ -# $Id: dirdeps.mk,v 1.49 2015/03/11 21:39:28 sjg Exp $ +# $Id: dirdeps.mk,v 1.51 2015/05/06 06:07:30 sjg Exp $ # Copyright (c) 2010-2013, Juniper Networks, Inc. # All rights reserved. @@ -349,7 +349,7 @@ BUILD_DIRDEPS ?= yes .if !defined(NO_DIRDEPS) .if ${MK_DIRDEPS_CACHE} == "yes" # this is where we will cache all our work -DIRDEPS_CACHE?= ${_OBJDIR}/dirdeps.cache${.TARGETS:Nall:O:u:ts-:S,^,.,:N.} +DIRDEPS_CACHE?= ${_OBJDIR}/dirdeps.cache${.TARGETS:Nall:O:u:ts-:S,/,_,g:S,^,.,:N.} # just ensure this exists build-dirdeps: @@ -394,13 +394,14 @@ _count_dirdeps: .NOMETA @echo '.info $${.newline}$${TRACER}Makefiles read: total=${.MAKE.MAKEFILES:[#]} depend=${.MAKE.MAKEFILES:M*depend*:[#]} dirdeps=${.ALLTARGETS:M${SRCTOP}*:O:u:[#]}' >&3 .endif -.endif -.elif !target(_count_dirdeps) +.elif !make(dirdeps) && !target(_count_dirdeps) beforedirdeps: _count_dirdeps _count_dirdeps: .NOMETA @echo "${TRACER}Makefiles read: total=${.MAKE.MAKEFILES:[#]} depend=${.MAKE.MAKEFILES:M*depend*:[#]} dirdeps=${.ALLTARGETS:M${SRCTOP}*:O:u:[#]} seconds=`expr ${now_utc} - ${start_utc}`" .endif +.endif + .if ${BUILD_DIRDEPS} == "yes" .if ${DEBUG_DIRDEPS:@x@${DEP_RELDIR:M$x}${${DEP_RELDIR}.${DEP_MACHINE}:L:M$x}@} != "" _debug_reldir = 1 Modified: projects/ci20_mips/contrib/bmake/mk/install-mk ============================================================================== --- projects/ci20_mips/contrib/bmake/mk/install-mk Thu May 14 21:39:03 2015 (r282930) +++ projects/ci20_mips/contrib/bmake/mk/install-mk Thu May 14 22:21:50 2015 (r282931) @@ -55,7 +55,7 @@ # Simon J. Gerraty # RCSid: -# $Id: install-mk,v 1.109 2015/04/16 16:59:00 sjg Exp $ +# $Id: install-mk,v 1.110 2015/05/01 06:37:49 sjg Exp $ # # @(#) Copyright (c) 1994 Simon J. Gerraty # @@ -70,7 +70,7 @@ # sjg@crufty.net # -MK_VERSION=20150411 +MK_VERSION=20150430 OWNER= GROUP= MODE=444 Modified: projects/ci20_mips/contrib/bmake/nonints.h ============================================================================== --- projects/ci20_mips/contrib/bmake/nonints.h Thu May 14 21:39:03 2015 (r282930) +++ projects/ci20_mips/contrib/bmake/nonints.h Thu May 14 22:21:50 2015 (r282931) @@ -1,4 +1,4 @@ -/* $NetBSD: nonints.h,v 1.67 2014/09/07 20:55:34 joerg Exp $ */ +/* $NetBSD: nonints.h,v 1.68 2015/05/05 21:51:09 sjg Exp $ */ /*- * Copyright (c) 1988, 1989, 1990, 1993 @@ -91,7 +91,7 @@ int Compat_Make(void *, void *); /* cond.c */ struct If; -int Cond_EvalExpression(const struct If *, char *, Boolean *, int); +int Cond_EvalExpression(const struct If *, char *, Boolean *, int, Boolean); int Cond_Eval(char *); void Cond_restore_depth(unsigned int); unsigned int Cond_save_depth(void); Modified: projects/ci20_mips/contrib/bmake/unit-tests/Makefile.in ============================================================================== --- projects/ci20_mips/contrib/bmake/unit-tests/Makefile.in Thu May 14 21:39:03 2015 (r282930) +++ projects/ci20_mips/contrib/bmake/unit-tests/Makefile.in Thu May 14 22:21:50 2015 (r282931) @@ -1,6 +1,6 @@ -# $Id: Makefile.in,v 1.46 2014/11/06 01:47:57 sjg Exp $ +# $Id: Makefile.in,v 1.47 2015/05/05 21:58:06 sjg Exp $ # -# $NetBSD: Makefile,v 1.51 2014/10/20 23:21:11 sjg Exp $ +# $NetBSD: Makefile,v 1.52 2015/05/05 21:51:09 sjg Exp $ # # Unit tests for make(1) # The main targets are: @@ -27,6 +27,7 @@ UNIT_TESTS:= ${srcdir} TESTNAMES= \ comment \ cond1 \ + cond2 \ error \ export \ export-all \ Copied: projects/ci20_mips/contrib/bmake/unit-tests/cond2.exp (from r282930, head/contrib/bmake/unit-tests/cond2.exp) ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ projects/ci20_mips/contrib/bmake/unit-tests/cond2.exp Thu May 14 22:21:50 2015 (r282931, copy of r282930, head/contrib/bmake/unit-tests/cond2.exp) @@ -0,0 +1,7 @@ +make: Bad conditional expression ` == "empty"' in == "empty"?oops:ok +make: "cond2.mk" line 13: Malformed conditional ({TEST_TYPO} == "Ok") +TEST_NOT_SET is empty or not defined +make: "cond2.mk" line 20: Malformed conditional (${TEST_NOT_SET} == "empty") +make: Fatal errors encountered -- cannot continue +make: stopped in unit-tests +exit status 1 Copied: projects/ci20_mips/contrib/bmake/unit-tests/cond2.mk (from r282930, head/contrib/bmake/unit-tests/cond2.mk) ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ projects/ci20_mips/contrib/bmake/unit-tests/cond2.mk Thu May 14 22:21:50 2015 (r282931, copy of r282930, head/contrib/bmake/unit-tests/cond2.mk) @@ -0,0 +1,25 @@ +# $Id: cond2.mk,v 1.1.1.1 2015/05/05 21:53:13 sjg Exp $ + +TEST_UNAME_S= NetBSD + +# this should be ok +X:= ${${TEST_UNAME_S} == "NetBSD":?Ok:fail} +.if $X == "Ok" +Y= good +.endif +# expect: Bad conditional expression ` == "empty"' in == "empty"?oops:ok +X:= ${${TEST_NOT_SET} == "empty":?oops:ok} +# expect: Malformed conditional ({TEST_TYPO} == "Ok") +.if {TEST_TYPO} == "Ok" +Y= oops +.endif +.if empty(TEST_NOT_SET) +Y!= echo TEST_NOT_SET is empty or not defined >&2; echo +.endif +# expect: Malformed conditional (${TEST_NOT_SET} == "empty") +.if ${TEST_NOT_SET} == "empty" +Y= oops +.endif + +all: + @echo $@ Modified: projects/ci20_mips/contrib/bmake/var.c ============================================================================== --- projects/ci20_mips/contrib/bmake/var.c Thu May 14 21:39:03 2015 (r282930) +++ projects/ci20_mips/contrib/bmake/var.c Thu May 14 22:21:50 2015 (r282931) @@ -1,4 +1,4 @@ -/* $NetBSD: var.c,v 1.191 2014/09/14 02:32:51 dholland Exp $ */ +/* $NetBSD: var.c,v 1.192 2015/05/05 21:51:09 sjg Exp $ */ /* * Copyright (c) 1988, 1989, 1990, 1993 @@ -69,14 +69,14 @@ */ #ifndef MAKE_NATIVE -static char rcsid[] = "$NetBSD: var.c,v 1.191 2014/09/14 02:32:51 dholland Exp $"; +static char rcsid[] = "$NetBSD: var.c,v 1.192 2015/05/05 21:51:09 sjg Exp $"; #else #include #ifndef lint #if 0 static char sccsid[] = "@(#)var.c 8.3 (Berkeley) 3/19/94"; #else -__RCSID("$NetBSD: var.c,v 1.191 2014/09/14 02:32:51 dholland Exp $"); +__RCSID("$NetBSD: var.c,v 1.192 2015/05/05 21:51:09 sjg Exp $"); #endif #endif /* not lint */ #endif @@ -3261,7 +3261,7 @@ ApplyModifiers(char *nstr, const char *t termc = *--cp; delim = '\0'; - if (Cond_EvalExpression(NULL, v->name, &value, 0) + if (Cond_EvalExpression(NULL, v->name, &value, 0, FALSE) == COND_INVALID) { Error("Bad conditional expression `%s' in %s?%s:%s", v->name, v->name, pattern.lhs, pattern.rhs); Modified: projects/ci20_mips/contrib/elftoolchain/addr2line/addr2line.1 ============================================================================== --- projects/ci20_mips/contrib/elftoolchain/addr2line/addr2line.1 Thu May 14 21:39:03 2015 (r282930) +++ projects/ci20_mips/contrib/elftoolchain/addr2line/addr2line.1 Thu May 14 22:21:50 2015 (r282931) @@ -22,7 +22,7 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $Id: addr2line.1 2066 2011-10-26 15:40:28Z jkoshy $ +.\" $Id: addr2line.1 3195 2015-05-12 17:22:19Z emaste $ .\" .Dd July 25, 2010 .Os @@ -99,7 +99,7 @@ Print a help message. Print a version identifier and exit. .El .Sh OUTPUT FORMAT -If the +If the .Fl f option was not specified, .Nm @@ -156,4 +156,4 @@ its source file and line number use: The .Nm utility was written by -.An "Kai Wang" Aq kaiwang27@users.sourceforge.net . +.An Kai Wang Aq Mt kaiwang27@users.sourceforge.net . Modified: projects/ci20_mips/contrib/elftoolchain/addr2line/addr2line.c ============================================================================== --- projects/ci20_mips/contrib/elftoolchain/addr2line/addr2line.c Thu May 14 21:39:03 2015 (r282930) +++ projects/ci20_mips/contrib/elftoolchain/addr2line/addr2line.c Thu May 14 22:21:50 2015 (r282931) @@ -39,7 +39,7 @@ #include "_elftc.h" -ELFTC_VCSID("$Id: addr2line.c 3174 2015-03-27 17:13:41Z emaste $"); +ELFTC_VCSID("$Id: addr2line.c 3197 2015-05-12 21:01:31Z emaste $"); static struct option longopts[] = { {"target" , required_argument, NULL, 'b'}, @@ -84,6 +84,44 @@ version(void) exit(0); } +/* + * Handle DWARF 4 'offset from' DW_AT_high_pc. Although we don't + * fully support DWARF 4, some compilers (like FreeBSD Clang 3.5.1) + * generate DW_AT_high_pc as an offset from DW_AT_low_pc. + * + * "If the value of the DW_AT_high_pc is of class address, it is the + * relocated address of the first location past the last instruction + * associated with the entity; if it is of class constant, the value + * is an unsigned integer offset which when added to the low PC gives + * the address of the first location past the last instruction + * associated with the entity." + * + * DWARF4 spec, section 2.17.2. + */ +static int +handle_high_pc(Dwarf_Die die, Dwarf_Unsigned lopc, Dwarf_Unsigned *hipc) +{ + Dwarf_Error de; + Dwarf_Half form; + Dwarf_Attribute at; + int ret; + + ret = dwarf_attr(die, DW_AT_high_pc, &at, &de); + if (ret == DW_DLV_ERROR) { + warnx("dwarf_attr failed: %s", dwarf_errmsg(de)); + return (ret); + } + ret = dwarf_whatform(at, &form, &de); + if (ret == DW_DLV_ERROR) { + warnx("dwarf_whatform failed: %s", dwarf_errmsg(de)); + return (ret); + } + if (dwarf_get_form_class(2, 0, 0, form) == DW_FORM_CLASS_CONSTANT) + *hipc += lopc; + + return (DW_DLV_OK); +} + static void search_func(Dwarf_Debug dbg, Dwarf_Die die, Dwarf_Addr addr, const char **rlt_func) @@ -108,6 +146,8 @@ search_func(Dwarf_Debug dbg, Dwarf_Die d if (dwarf_attrval_unsigned(die, DW_AT_low_pc, &lopc, &de) || dwarf_attrval_unsigned(die, DW_AT_high_pc, &hipc, &de)) goto cont_search; + if (handle_high_pc(die, lopc, &hipc) != DW_DLV_OK) + goto cont_search; if (addr < lopc || addr >= hipc) goto cont_search; @@ -202,6 +242,8 @@ translate(Dwarf_Debug dbg, const char* a * Check if the address falls into the PC range of * this CU. */ + if (handle_high_pc(die, lopc, &hipc) != DW_DLV_OK) + continue; if (addr < lopc || addr >= hipc) continue; } Modified: projects/ci20_mips/contrib/elftoolchain/common/native-elf-format ============================================================================== --- projects/ci20_mips/contrib/elftoolchain/common/native-elf-format Thu May 14 21:39:03 2015 (r282930) +++ projects/ci20_mips/contrib/elftoolchain/common/native-elf-format Thu May 14 22:21:50 2015 (r282931) @@ -1,6 +1,6 @@ #!/bin/sh # -# $Id: native-elf-format 3167 2015-02-24 19:10:08Z emaste $ +# $Id: native-elf-format 3186 2015-04-16 22:16:40Z emaste $ # # Find the native ELF format for a host platform by compiling a # test object and examining the resulting object. @@ -33,7 +33,7 @@ $1 ~ "Data:" { $1 ~ "Machine:" { if (match($0, "Intel.*386")) { elfarch = "EM_386"; - } else if (match($0, ".*X86-64")) { + } else if (match($0, ".*[xX]86-64")) { elfarch = "EM_X86_64"; } else { elfarch = "unknown"; Modified: projects/ci20_mips/contrib/elftoolchain/cxxfilt/c++filt.1 ============================================================================== --- projects/ci20_mips/contrib/elftoolchain/cxxfilt/c++filt.1 Thu May 14 21:39:03 2015 (r282930) +++ projects/ci20_mips/contrib/elftoolchain/cxxfilt/c++filt.1 Thu May 14 22:21:50 2015 (r282931) @@ -22,7 +22,7 @@ .\" (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF .\" THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. .\" -.\" $Id: c++filt.1 2175 2011-11-16 05:51:49Z jkoshy $ +.\" $Id: c++filt.1 3195 2015-05-12 17:22:19Z emaste $ .\" .Dd August 24, 2011 .Os @@ -106,4 +106,4 @@ and exit. The .Nm utility was written by -.An "Kai Wang" Aq kaiwang27@users.sourceforge.net . +.An Kai Wang Aq Mt kaiwang27@users.sourceforge.net . Modified: projects/ci20_mips/contrib/elftoolchain/elfcopy/elfcopy.1 ============================================================================== --- projects/ci20_mips/contrib/elftoolchain/elfcopy/elfcopy.1 Thu May 14 21:39:03 2015 (r282930) +++ projects/ci20_mips/contrib/elftoolchain/elfcopy/elfcopy.1 Thu May 14 22:21:50 2015 (r282931) @@ -21,7 +21,7 @@ .\" out of the use of this software, even if advised of the possibility of .\" such damage. .\" -.\" $Id: elfcopy.1 3173 2015-03-27 16:46:13Z emaste $ +.\" $Id: elfcopy.1 3195 2015-05-12 17:22:19Z emaste $ .\" .Dd March 27, 2015 .Os @@ -330,4 +330,4 @@ Do not copy symbols that are not needed .Sh HISTORY .Nm has been implemented by -.An "Kai Wang" Aq kaiwang27@users.sourceforge.net . +.An Kai Wang Aq Mt kaiwang27@users.sourceforge.net . Modified: projects/ci20_mips/contrib/elftoolchain/elfcopy/sections.c ============================================================================== --- projects/ci20_mips/contrib/elftoolchain/elfcopy/sections.c Thu May 14 21:39:03 2015 (r282930) +++ projects/ci20_mips/contrib/elftoolchain/elfcopy/sections.c Thu May 14 22:21:50 2015 (r282931) @@ -34,7 +34,7 @@ #include "elfcopy.h" -ELFTC_VCSID("$Id: sections.c 3174 2015-03-27 17:13:41Z emaste $"); +ELFTC_VCSID("$Id: sections.c 3185 2015-04-11 08:56:34Z kaiwang27 $"); static void add_gnu_debuglink(struct elfcopy *ecp); static uint32_t calc_crc32(const char *p, size_t len, uint32_t crc); @@ -1223,6 +1223,14 @@ update_shdr(struct elfcopy *ecp, int upd osh.sh_info != 0) osh.sh_info = ecp->secndx[osh.sh_info]; + /* + * sh_info of SHT_GROUP section needs to point to the correct + * string in the symbol table. + */ + if (s->type == SHT_GROUP && (ecp->flags & SYMTAB_EXIST) && + (ecp->flags & SYMTAB_INTACT) == 0) + osh.sh_info = ecp->symndx[osh.sh_info]; + if (!gelf_update_shdr(s->os, &osh)) errx(EXIT_FAILURE, "gelf_update_shdr() failed: %s", elf_errmsg(-1)); Modified: projects/ci20_mips/contrib/elftoolchain/elfcopy/segments.c ============================================================================== --- projects/ci20_mips/contrib/elftoolchain/elfcopy/segments.c Thu May 14 21:39:03 2015 (r282930) +++ projects/ci20_mips/contrib/elftoolchain/elfcopy/segments.c Thu May 14 22:21:50 2015 (r282931) @@ -34,7 +34,7 @@ #include "elfcopy.h" -ELFTC_VCSID("$Id: segments.c 3177 2015-03-30 18:19:41Z emaste $"); +ELFTC_VCSID("$Id: segments.c 3196 2015-05-12 17:33:48Z emaste $"); static void insert_to_inseg_list(struct segment *seg, struct section *sec); @@ -442,7 +442,7 @@ copy_phdr(struct elfcopy *ecp) s = seg->v_sec[i]; seg->msz = s->vma + s->sz - seg->addr; if (s->type != SHT_NOBITS) - seg->fsz = seg->msz; + seg->fsz = s->off + s->sz - seg->off; } } Modified: projects/ci20_mips/contrib/elftoolchain/elfcopy/symbols.c ============================================================================== --- projects/ci20_mips/contrib/elftoolchain/elfcopy/symbols.c Thu May 14 21:39:03 2015 (r282930) +++ projects/ci20_mips/contrib/elftoolchain/elfcopy/symbols.c Thu May 14 22:21:50 2015 (r282931) @@ -33,7 +33,7 @@ #include "elfcopy.h" -ELFTC_VCSID("$Id: symbols.c 3174 2015-03-27 17:13:41Z emaste $"); +ELFTC_VCSID("$Id: symbols.c 3191 2015-05-04 17:07:01Z jkoshy $"); /* Symbol table buffer structure. */ struct symbuf { @@ -1090,7 +1090,7 @@ str_hash(const char *s) { uint32_t hash; - for (hash = 2166136261; *s; s++) + for (hash = 2166136261UL; *s; s++) hash = (hash ^ *s) * 16777619; return (hash & (STHASHSIZE - 1)); Modified: projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf.3 ============================================================================== --- projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf.3 Thu May 14 21:39:03 2015 (r282930) +++ projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf.3 Thu May 14 22:21:50 2015 (r282931) @@ -21,7 +21,7 @@ .\" out of the use of this software, even if advised of the possibility of .\" such damage. .\" -.\" $Id: dwarf.3 3130 2014-12-21 20:06:29Z jkoshy $ +.\" $Id: dwarf.3 3195 2015-05-12 17:22:19Z emaste $ .\" .Dd December 21, 2014 .Os @@ -44,7 +44,7 @@ is defined by the DWARF standard, see .Xr dwarf 4 . .Pp The -.Xr DWARF 3 +.Xr DWARF 3 API has two parts: .Bl -bullet .It @@ -349,7 +349,7 @@ Retrieve a debugging information entry g .It Fn dwarf_siblingof , Fn dwarf_siblingof_b Retrieve the sibling descriptor for a debugging information entry. .It Fn dwarf_srclang -Retrive the source language attribute for a debugging information +Retrieve the source language attribute for a debugging information entry. .It Fn dwarf_tag Retrieve the tag for a debugging information entry. @@ -742,12 +742,12 @@ The DWARF standard is defined by The DWARF(3) API originated at Silicon Graphics Inc. .Pp A BSD-licensed implementation of a subset of the API was written by -.An "John Birrell" Aq jb@FreeBSD.org +.An John Birrell Aq Mt jb@FreeBSD.org for the FreeBSD project. The implementation was subsequently revised and completed by -.An "Kai Wang" Aq kaiwang27@users.sourceforge.net . +.An Kai Wang Aq Mt kaiwang27@users.sourceforge.net . .Pp Manual pages for this implementation were written by -.An "Joseph Koshy" Aq jkoshy@users.sourceforge.net +.An Joseph Koshy Aq Mt jkoshy@users.sourceforge.net and -.An "Kai Wang" Aq kaiwang27@users.sourceforge.net . +.An Kai Wang Aq Mt kaiwang27@users.sourceforge.net . Modified: projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_add_line_entry.3 ============================================================================== --- projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_add_line_entry.3 Thu May 14 21:39:03 2015 (r282930) +++ projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_add_line_entry.3 Thu May 14 22:21:50 2015 (r282931) @@ -22,7 +22,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: dwarf_add_line_entry.3 2953 2013-06-30 20:21:38Z kaiwang27 $ +.\" $Id: dwarf_add_line_entry.3 3182 2015-04-10 16:08:10Z emaste $ .\" .Dd June 30, 2013 .Os @@ -66,7 +66,8 @@ Valid source file indices are those retu .Pp Argument .Ar off -specifies a relocatable program address. The ELF symbol to be used +specifies a relocatable program address. +The ELF symbol to be used for relocation is set by a prior call to the function .Xr dwarf_lne_set_address 3 . .Pp Modified: projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_def_macro.3 ============================================================================== --- projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_def_macro.3 Thu May 14 21:39:03 2015 (r282930) +++ projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_def_macro.3 Thu May 14 22:21:50 2015 (r282931) @@ -22,7 +22,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: dwarf_def_macro.3 2122 2011-11-09 15:35:14Z jkoshy $ +.\" $Id: dwarf_def_macro.3 3182 2015-04-10 16:08:10Z emaste $ .\" .Dd November 9, 2011 .Os @@ -72,7 +72,7 @@ Argument .Ar value should point to a NUL-terminated string containing the value of the macro. -If the macro doesn't have a value, argument +If the macro does not have a value, argument .Ar value should be set to NULL. .Pp Modified: projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_expand_frame_instructions.3 ============================================================================== --- projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_expand_frame_instructions.3 Thu May 14 21:39:03 2015 (r282930) +++ projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_expand_frame_instructions.3 Thu May 14 22:21:50 2015 (r282931) @@ -22,14 +22,14 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: dwarf_expand_frame_instructions.3 2122 2011-11-09 15:35:14Z jkoshy $ +.\" $Id: dwarf_expand_frame_instructions.3 3181 2015-04-10 13:22:51Z emaste $ .\" .Dd November 9, 2011 .Os .Dt DWARF_EXPAND_FRAME_INSTRUCTIONS 3 .Sh NAME .Nm dwarf_expand_frame_instructions -.Nd expand frame instructions +.Nd expand frame instructions .Sh LIBRARY .Lb libdwarf .Sh SYNOPSIS Modified: projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_formblock.3 ============================================================================== --- projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_formblock.3 Thu May 14 21:39:03 2015 (r282930) +++ projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_formblock.3 Thu May 14 22:21:50 2015 (r282931) @@ -22,7 +22,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: dwarf_formblock.3 2073 2011-10-27 03:30:47Z jkoshy $ +.\" $Id: dwarf_formblock.3 3182 2015-04-10 16:08:10Z emaste $ .\" .Dd July 23, 2010 .Os @@ -69,7 +69,7 @@ the DWARF(3) library. The application should not attempt to free this memory area. Portable code may indicate that the memory area is to be freed by -by using +using .Xr dwarf_dealloc 3 . .Sh RETURN VALUES Function Modified: projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_formflag.3 ============================================================================== --- projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_formflag.3 Thu May 14 21:39:03 2015 (r282930) +++ projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_formflag.3 Thu May 14 22:21:50 2015 (r282931) @@ -22,7 +22,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: dwarf_formflag.3 2073 2011-10-27 03:30:47Z jkoshy $ +.\" $Id: dwarf_formflag.3 3181 2015-04-10 13:22:51Z emaste $ .\" .Dd June 21, 2010 .Os @@ -58,7 +58,7 @@ or If argument .Ar err is not NULL, it will be used to return an error descriptor in case -of an error. +of an error. .Sh RETURN VALUES Function .Fn dwarf_formflag Modified: projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_formref.3 ============================================================================== --- projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_formref.3 Thu May 14 21:39:03 2015 (r282930) +++ projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_formref.3 Thu May 14 22:21:50 2015 (r282931) @@ -22,7 +22,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: dwarf_formref.3 2073 2011-10-27 03:30:47Z jkoshy $ +.\" $Id: dwarf_formref.3 3181 2015-04-10 13:22:51Z emaste $ .\" .Dd June 21, 2010 .Os @@ -101,7 +101,7 @@ ELF section. If argument .Ar err is not NULL, it will be used to return an error descriptor in case -of an error. +of an error. .Sh RETURN VALUES These functions return .Dv DW_DLV_OK Modified: projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_formsig8.3 ============================================================================== --- projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_formsig8.3 Thu May 14 21:39:03 2015 (r282930) +++ projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_formsig8.3 Thu May 14 22:21:50 2015 (r282931) @@ -22,7 +22,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: dwarf_formsig8.3 2073 2011-10-27 03:30:47Z jkoshy $ +.\" $Id: dwarf_formsig8.3 3181 2015-04-10 13:22:51Z emaste $ .\" .Dd July 24, 2010 .Os @@ -56,7 +56,7 @@ must be If argument .Ar err is not NULL, it will be used to return an error descriptor in case -of an error. +of an error. .Sh RETURN VALUES Function .Fn dwarf_formsig8 Modified: projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_formudata.3 ============================================================================== --- projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_formudata.3 Thu May 14 21:39:03 2015 (r282930) +++ projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_formudata.3 Thu May 14 22:21:50 2015 (r282931) @@ -22,7 +22,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: dwarf_formudata.3 2073 2011-10-27 03:30:47Z jkoshy $ +.\" $Id: dwarf_formudata.3 3181 2015-04-10 13:22:51Z emaste $ .\" .Dd June 21, 2010 .Os @@ -88,7 +88,7 @@ and If argument .Ar err is not NULL, it will be used to return an error descriptor in case -of an error. +of an error. .Sh RETURN VALUES These functions return .Dv DW_DLV_OK Modified: projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_get_fde_info_for_all_regs.3 ============================================================================== --- projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_get_fde_info_for_all_regs.3 Thu May 14 21:39:03 2015 (r282930) +++ projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_get_fde_info_for_all_regs.3 Thu May 14 22:21:50 2015 (r282931) @@ -22,7 +22,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: dwarf_get_fde_info_for_all_regs.3 2071 2011-10-27 03:20:00Z jkoshy $ +.\" $Id: dwarf_get_fde_info_for_all_regs.3 3182 2015-04-10 16:08:10Z emaste $ .\" .Dd June 4, 2011 .Os @@ -90,7 +90,8 @@ typedef struct { For each of the register rules returned, the .Va dw_offset_relevant -field is set to 1 if the register rule has a offset value. The +field is set to 1 if the register rule has a offset value. +The .Va dw_regnum field is set to the register number associated with the regsiter rule. The Modified: projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_get_fde_info_for_reg.3 ============================================================================== --- projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_get_fde_info_for_reg.3 Thu May 14 21:39:03 2015 (r282930) +++ projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_get_fde_info_for_reg.3 Thu May 14 22:21:50 2015 (r282931) @@ -22,7 +22,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: dwarf_get_fde_info_for_reg.3 2071 2011-10-27 03:20:00Z jkoshy $ +.\" $Id: dwarf_get_fde_info_for_reg.3 3181 2015-04-10 13:22:51Z emaste $ .\" .Dd June 4, 2011 .Os @@ -99,7 +99,7 @@ counter address associated with the regi If argument .Ar err is not NULL, it will be used to return an error descriptor in case -of an error. +of an error. .Ss COMPATIBILITY Function .Fn dwarf_get_fde_info_for_reg Modified: projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_get_ranges.3 ============================================================================== --- projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_get_ranges.3 Thu May 14 21:39:03 2015 (r282930) +++ projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_get_ranges.3 Thu May 14 22:21:50 2015 (r282931) @@ -22,7 +22,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: dwarf_get_ranges.3 2122 2011-11-09 15:35:14Z jkoshy $ +.\" $Id: dwarf_get_ranges.3 3182 2015-04-10 16:08:10Z emaste $ .\" .Dd November 9, 2011 .Os @@ -137,7 +137,7 @@ For this type of entry, the field .Va dwr_addr1 is the value of the largest representable address offset, and .Va dwr_addr2 -is a base address for the begining and ending address offsets of +is a base address for the beginning and ending address offsets of subsequent address range entries in the list. .It Dv DW_RANGES_END An end of list mark. Modified: projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_hasattr.3 ============================================================================== --- projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_hasattr.3 Thu May 14 21:39:03 2015 (r282930) +++ projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_hasattr.3 Thu May 14 22:21:50 2015 (r282931) @@ -22,7 +22,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: dwarf_hasattr.3 3142 2015-01-29 23:11:14Z jkoshy $ +.\" $Id: dwarf_hasattr.3 3181 2015-04-10 13:22:51Z emaste $ .\" .Dd April 17, 2010 .Os @@ -64,7 +64,7 @@ If the named attribute is not present, a If argument .Ar err is not NULL, it will be used to return an error descriptor in case -of an error. +of an error. .Sh RETURN VALUES On success, function .Fn dwarf_hasattr Modified: projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_next_cu_header.3 ============================================================================== --- projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_next_cu_header.3 Thu May 14 21:39:03 2015 (r282930) +++ projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_next_cu_header.3 Thu May 14 22:21:50 2015 (r282931) @@ -22,7 +22,7 @@ .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF .\" SUCH DAMAGE. .\" -.\" $Id: dwarf_next_cu_header.3 3128 2014-12-21 20:06:22Z jkoshy $ +.\" $Id: dwarf_next_cu_header.3 3182 2015-04-10 16:08:10Z emaste $ .\" .Dd December 21, 2014 .Os @@ -220,8 +220,7 @@ unit in the section. .Ss Iterating Through Type Units in a Debug Context When a DWARF debug context is allocated using .Xr dwarf_init 3 , -an internal pointer assoicated with the context will point to the -fisrt +an internal pointer associated with the context will point to the first .Dq \&.debug_types section found in the debug object. The first call to function Modified: projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_producer_init.3 ============================================================================== --- projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_producer_init.3 Thu May 14 21:39:03 2015 (r282930) +++ projects/ci20_mips/contrib/elftoolchain/libdwarf/dwarf_producer_init.3 Thu May 14 22:21:50 2015 (r282931) @@ -22,7 +22,7 @@ *** DIFF OUTPUT TRUNCATED AT 1000 LINES ***