From nobody Fri Nov 10 21:13:54 2023 X-Original-To: pkg@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4SRs4y4gwPz50T4P for ; Fri, 10 Nov 2023 21:13:54 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4SRs4y0Lhqz3HBq for ; Fri, 10 Nov 2023 21:13:54 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1699650834; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=yhotsJT69STsM27P0X/q+t4QQ8BNpDIdSktCwV12WLY=; b=k5dVy8K1EQ43OJr56Cun1MsrzqJNPxXrlDu2UDgRJv1ZEB2XM277XdH5kQ9aA1AqsVVxpC dFeAvAvAVi7X+sQZ3EADaAEmp70INP5kzqtn967JaryXc3o4L2AIDd4F7KhilTz/bv0JsW Ty1JU2zocMJDguP8bbGzYRldrwyykneTAkJMSi3bz//RlkxHp/LxR38ns9APyzCiOQgGal 3vg713DyPoI0vycMjzo1Npk6P5hMvUb120f+bkLo6jYv8km/6MUiADul5hIfFP4uMy5VKw v1VSWVoFbXBZCsY5R/kVa0iMi9yg01FieO7KB12Igi8U0MBPuc+mKtH7NGdnhg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1699650834; a=rsa-sha256; cv=none; b=kkW9mcU7Py3Qz/mnb15YuH4f1KJzk3YJWdZqetvurqhG2vjJV2at5NodVgpYG87nMz5I9j dW0kkIESKXCP1kElUetAYeTncQ3FRgppNPHTam8US+YPUpjDiH1IqRFSDyOwl+YKFz2Phu 0vY6xob0By6u6rxhWMDrt+UzjKDjZFeJ+BVpj3w/9mlcviwzkOVsoVZv5Ap4gIbEhwxYj9 bvK4I733r6kkODlblKeafWGyfFxEyWapJBJJ/VlUwczyEFufd2CfNn40prr22MQi+fDe/B rYJJRQdOVmfhfNQ8wm7Naahc8xVDKl0bMvE6zBe6B2XKWOwrAjIY9nLheqOoFw== Received: from kenobi.freebsd.org (kenobi.freebsd.org [IPv6:2610:1c1:1:606c::50:1d]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4SRs4x6Y3Qz1Cpm for ; Fri, 10 Nov 2023 21:13:53 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from kenobi.freebsd.org ([127.0.1.5]) by kenobi.freebsd.org (8.15.2/8.15.2) with ESMTP id 3AALDrUp047311 for ; Fri, 10 Nov 2023 21:13:53 GMT (envelope-from bugzilla-noreply@freebsd.org) Received: (from www@localhost) by kenobi.freebsd.org (8.15.2/8.15.2/Submit) id 3AALDrJS047310 for pkg@FreeBSD.org; Fri, 10 Nov 2023 21:13:53 GMT (envelope-from bugzilla-noreply@freebsd.org) X-Authentication-Warning: kenobi.freebsd.org: www set sender to bugzilla-noreply@freebsd.org using -f Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="UTF-8" From: bugzilla-noreply@freebsd.org To: pkg@FreeBSD.org Subject: maintainer-feedback requested: [Bug 275018] ports-mgmt/pkg: building with PIE and RELRO is broken when CFLAGS are set Date: Fri, 10 Nov 2023 21:13:54 +0000 X-Bugzilla-Type: request X-Bugzilla-Product: Ports & Packages X-Bugzilla-Component: Individual Port(s) X-Bugzilla-Version: Latest X-Bugzilla-Keywords: X-Bugzilla-Severity: Affects Only Me X-Bugzilla-Who: X-Bugzilla-Status: New X-Bugzilla-Resolution: X-Bugzilla-Priority: --- X-Bugzilla-Assigned-To: pkg@FreeBSD.org X-Bugzilla-Flags: maintainer-feedback? Message-ID: In-Reply-To: References: X-Bugzilla-URL: https://bugs.freebsd.org/bugzilla/ Auto-Submitted: auto-generated List-Id: Binary package management and package tools discussion List-Archive: https://lists.freebsd.org/archives/freebsd-pkg List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-freebsd-pkg@freebsd.org MIME-Version: 1.0 Bugzilla Automation has asked freebsd-pkg (Nobody) for maintainer-feedback: Bug 275018: ports-mgmt/pkg: building with PIE and RELRO is broken when CFLA= GS are set https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D275018 --- Description --- Since WITH_PIE and WITH_RELRO were introduced to ports, it was impossible to build ports-mgmt/pkg when CFLAGS were also set. To reproduce try to build ports-mgmt/pkg with these settings in make.conf: CFLAGS=3D-O2 -pipe -fno-strict-aliasing=20 WITH_PIE=3DYES=20 WITH_RELRO=3DYES it looks like setting CFLAGS is killing -fPIC at some point which results i= n: ld: error: relocation R_X86_64_32 cannot be used against local symbol; recompile with -fPIC I initially believed it was only a flaw, but I was encouraged to submit a PR about it.