NetBSD Problem Report #60507

From www@netbsd.org  Sun Jul 26 16:41:56 2026
Return-Path: <www@netbsd.org>
Received: from mail.netbsd.org (mail.netbsd.org [199.233.217.200])
	(using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)
	 key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256
	 client-signature RSA-PSS (2048 bits) client-digest SHA256)
	(Client CN "mail.netbsd.org", Issuer "YR2" (not verified))
	by mollari.NetBSD.org (Postfix) with ESMTPS id 645241A923B
	for <gnats-bugs@gnats.NetBSD.org>; Sun, 26 Jul 2026 16:41:56 +0000 (UTC)
Message-Id: <20260726164155.2557C1A923C@mollari.NetBSD.org>
Date: Sun, 26 Jul 2026 16:41:55 +0000 (UTC)
From: thorpej@me.com
Reply-To: thorpej@me.com
To: gnats-bugs@NetBSD.org
Subject: pkgsrc should disable PIC code generation for m68000 / m68010
X-Send-Pr-Version: www-1.0
X-From4GNATS: "thorpej@me.com via gnats" <gnats-admin@NetBSD.org>

>Number:         60507
>Category:       pkg
>Synopsis:       pkgsrc should disable PIC code generation for m68000 / m68010
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    pkg-manager
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Sun Jul 26 16:45:00 +0000 2026
>Originator:     Jason Thorpe
>Release:        11.99.7
>Organization:
Retrogrouches'R'Us
>Environment:
Cross-building packages from:

NetBSD the-ripe-vessel 10.99.10 NetBSD 10.99.10 (GENERIC) #68: Fri Nov 17 14:40:27 PST 2023  thorpej@the-ripe-vessel:/space/src/sys/arch/amd64/compile/GENERIC amd64

>Description:
m68000 / m68010 do not support the addressing modes necessary for PIC code generation in the SVR4 ELF ABI.  For tiny / trivial programs (like conftest.c), it will appear to work, but for anything else you're likely to encounter a fatal relocation overflow for GOT references because the linker runs out of options.

This, pkgsrc should forcefully disable PIC code generation.  For GNU autoconf-using packages, this will work:

+CONFIGURE_ARGS+= --without-pic --disable-shared

>How-To-Repeat:
Try to cross-build sysutils/nabud for hb68010.
>Fix:
Pkgsrc .mk wizardry; I am not sufficiently skilled in the Dark Arts to attempt it.

NetBSD Home
NetBSD PR Database Search

(Contact us) $NetBSD: query-full-pr,v 1.51 2026/08/10 02:28:17 riastradh Exp $
$NetBSD: gnats_config.sh,v 1.10 2026/05/13 22:00:09 riastradh Exp $
Copyright © 1994-2026 The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.