From owner-freebsd-bugs@freebsd.org Fri Aug 11 03:13:43 2017 Return-Path: Delivered-To: freebsd-bugs@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 245F4D7D69C for ; Fri, 11 Aug 2017 03:13:43 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org (kenobi.freebsd.org [IPv6:2001:1900:2254:206a::16:76]) (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 EBB1C81B06 for ; Fri, 11 Aug 2017 03:13:42 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from bugs.freebsd.org ([127.0.1.118]) by kenobi.freebsd.org (8.15.2/8.15.2) with ESMTP id v7B3Dgcp077159 for ; Fri, 11 Aug 2017 03:13:42 GMT (envelope-from bugzilla-noreply@freebsd.org) From: bugzilla-noreply@freebsd.org To: freebsd-bugs@FreeBSD.org Subject: [Bug 221107] -r322109 and -r322210 (so clang 5) TARGET_ARCH=powerpc agp.kld or agp.kld gets: R_PPC_PLTREL24 reloc against local symbol; could not read symbols: Bad value Date: Fri, 11 Aug 2017 03:13:43 +0000 X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: Base System X-Bugzilla-Component: kern X-Bugzilla-Version: CURRENT X-Bugzilla-Keywords: X-Bugzilla-Severity: Affects Only Me X-Bugzilla-Who: markmi@dsl-only.net X-Bugzilla-Status: New X-Bugzilla-Resolution: X-Bugzilla-Priority: --- X-Bugzilla-Assigned-To: freebsd-bugs@FreeBSD.org X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: https://bugs.freebsd.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-BeenThere: freebsd-bugs@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Fri, 11 Aug 2017 03:13:43 -0000 https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D221107 --- Comment #7 from Mark Millard --- For reference for how aha.kld and agp.kld are produced: # Meta data file /usr/obj/powerpcvtsc_clang/powerpc.powerpc/usr/src/sys/GENERICvtsc-NODBG/mo= dules/usr/src/sys/modules/aha/aha.kld.meta CMD ld -m elf32ppc_fbsd -d -warn-common -r -d -o aha.kld aha.o aha_isa.o CMD ctfmerge -L VERSION -g -o aha.kld aha.o aha_isa.o CMD :> export_syms CMD awk -f /usr/src/sys/conf/kmod_syms.awk aha.kld export_syms | xargs -J% objcopy % aha.kld CWD /usr/obj/powerpcvtsc_clang/powerpc.powerpc/usr/src/sys/GENERICvtsc-NODBG/mo= dules/usr/src/sys/modules/aha TARGET aha.kld # Meta data file /usr/obj/powerpcvtsc_clang/powerpc.powerpc/usr/src/sys/GENERICvtsc-NODBG/mo= dules/usr/src/sys/modules/agp/agp.kld.meta CMD ld -m elf32ppc_fbsd -d -warn-common -r -d -o agp.kld agp.o agp_if.o agp_apple.o CMD ctfmerge -L VERSION -g -o agp.kld agp.o agp_if.o agp_apple.o CMD echo agp_find_device agp_state agp_acquir= e=20=20=20 agp_release agp_enable agp_alloc_memory= =20=20=20=20=20=20 agp_free_memory agp_bin d_memory agp_unbind_memory agp_memory_info > export_s= yms CMD awk -f /usr/src/sys/conf/kmod_syms.awk agp.kld export_syms | xargs -J% objcopy % agp.kld CWD /usr/obj/powerpcvtsc_clang/powerpc.powerpc/usr/src/sys/GENERICvtsc-NODBG/mo= dules/usr/src/sys/modules/agp TARGET agp.kld It looks like (via kmod_syms.awk) objcopy is explicitly turning various R_PPC_PLTREL24 examples into LOCAL symbols. May be before clang 5 these were not R_PPC_PLTREL24 ? They are now and the conversion to LOCAL while keeping R_PPC_PLTREL24 is rejected by: ppc_elf_check_relocs which in turn stops ld from producing the matching .full files. And that in turn stops the buildkernel . --=20 You are receiving this mail because: You are the assignee for the bug.=