NetBSD Problem Report #57101

From www@netbsd.org  Sat Dec 10 15:32:11 2022
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))
	(Client CN "mail.NetBSD.org", Issuer "mail.NetBSD.org CA" (not verified))
	by mollari.NetBSD.org (Postfix) with ESMTPS id 458301A921F
	for <gnats-bugs@gnats.NetBSD.org>; Sat, 10 Dec 2022 15:32:11 +0000 (UTC)
Message-Id: <20221210153210.370861A923A@mollari.NetBSD.org>
Date: Sat, 10 Dec 2022 15:32:10 +0000 (UTC)
From: thorpej@me.com
Reply-To: thorpej@me.com
To: gnats-bugs@NetBSD.org
Subject: cross-arm-none-eabi-gcc-8.3.0nb5 does not work with Raspberry Pi Pico SDK
X-Send-Pr-Version: www-1.0

>Number:         57101
>Category:       pkg
>Synopsis:       cross-arm-none-eabi-gcc-8.3.0nb5 does not work with Raspberry Pi Pico SDK
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    pkg-manager
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Sat Dec 10 15:35:00 +0000 2022
>Originator:     Jason Thorpe
>Release:        pkgsrc-current as of Dec 10, 2022
>Organization:
RISCy Business
>Environment:
NetBSD the-ripe-vessel 9.99.82 NetBSD 9.99.82 (GENERIC) #0: Tue May 18 17:05:45 UTC 2021  mkrepro@mkrepro.NetBSD.org:/usr/src/sys/arch/amd64/compile/GENERIC amd64

>Description:
Linking pico-sdk applications doesn't work due to a duplicate symbol ("_exit") supplied both by newlib and the Pico runtime.  The newlib copy is not elided because something else is pulling in a symbol supplied by the same "syscalls.o" object that contains newlib's "_exit" symbol.  I'm still working on tracking that down.

[  0%] Linking CXX executable blink.elf
/usr/pkg/cross-arm-none-eabi/lib/gcc/arm-none-eabi/8.3.0/../../../../arm-none-eabi/bin/ld: /usr/pkg/cross-arm-none-eabi/lib/gcc/arm-none-eabi/8.3.0/../../../../arm-none-eabi/lib/thumb/libc.a(lib_a-syscalls.o): in function `_exit':
/space/pkgsrc-current/cross/arm-none-eabi-gcc/work/gcc-8.3.0/newlib/libc/sys/arm/syscalls.c:475: multiple definition of `_exit'; CMakeFiles/blink.dir/home/thorpej/Github/raspberrypi/pico-sdk/src/rp2_common/pico_runtime/runtime.c.obj:runtime.c:(.text._exit+0x0): first defined here
collect2: error: ld returned 1 exit status
*** Error code 1

>How-To-Repeat:
Install cmake and cross-arm-none-eabi-gcc packages.

Download the pico-sdk and pico-examples repos from Github, configure them per the SDK instructions, and attempt to build the "blink" example to test your SDK installation.

>Fix:
(Not yet.)

NetBSD Home
NetBSD PR Database Search

(Contact us) $NetBSD: query-full-pr,v 1.47 2022/09/11 19:34:41 kim Exp $
$NetBSD: gnats_config.sh,v 1.9 2014/08/02 14:16:04 spz Exp $
Copyright © 1994-2022 The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.