From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 48) id 8A3A9385840B; Fri, 28 Oct 2022 21:23:22 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 8A3A9385840B DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sourceware.org; s=default; t=1666992202; bh=8fVVti59GTqvx3zOn4Kss7VZQaoWL9XuUX+UBK1G53g=; h=From:To:Subject:Date:In-Reply-To:References:From; b=PIQpJG6axcrC2KkCpQgP9eux2pzL+HYlygD4Wedc8O+dYZ5bHR+hTSC4n3GCILVw9 AzRGvEKXr9ZPrS+1NTE67+hwnTW8ZGzFfpFZKdl2YApLvigoePzJ86xamNY0qzv1jC 0tRvlbaYiHhEMUvaoaQHWLXIF1aXZ13SXcw+cQ+M= From: "james.hilliard1 at gmail dot com" To: glibc-bugs@sourceware.org Subject: [Bug libc/29621] librtld.os: in function `__register_frame': libgcc/unwind-dw2-fde.c:136: undefined reference to `malloc' Date: Fri, 28 Oct 2022 21:23:21 +0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: glibc X-Bugzilla-Component: libc X-Bugzilla-Version: 2.36 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: james.hilliard1 at gmail dot com X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Resolution: X-Bugzilla-Priority: P2 X-Bugzilla-Assigned-To: unassigned at sourceware dot org X-Bugzilla-Target-Milestone: --- 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: http://sourceware.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 List-Id: https://sourceware.org/bugzilla/show_bug.cgi?id=3D29621 --- Comment #16 from James Hilliard --- (In reply to Adhemerval Zanella from comment #15) > I am sorry but you will need to figure out yourself what buildroot is doi= ng > that is not expected here, since: >=20 > 1. glibc bootscript (build-many-glibcs.py) can bootstrap both > mipsel-linux-gnu > and mips64el-linux-gnu toolchain. >=20 > 2. Building manually on buildroot does not show the issue.=20 >=20 > If can use the build-many-glibcs.py to check the canonical way to bootstr= ap > glibc. I think I've isolated the issue, the build fails when gcc target libs(CFLAGS_FOR_TARGET and CXXFLAGS_FOR_TARGET) are built with -O0, this al= so explains why it only reproduces when built in the buildroot env since we pa= ss global optimization flags to all packages(and override as needed for packag= es with special requirements). Overriding those to at least -O1 in gcc(similar to how we always override t= o at least -O1 in glibc) appears to fix the glibc build failure. This seems strange, is it expected behavior to require gcc target libs to be built optimized? Why would this only be an issue on a small subset of target architectures? This also doesn't appear to be an issue that happens with uclibc or musl li= bc from what I can tell. --=20 You are receiving this mail because: You are on the CC list for the bug.=