NetBSD Problem Report #56248

From john@daisy.zia.io  Tue Jun 15 14:21:15 2021
Return-Path: <john@daisy.zia.io>
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 4FDEB1A921F
	for <gnats-bugs@gnats.NetBSD.org>; Tue, 15 Jun 2021 14:21:15 +0000 (UTC)
Message-Id: <202106151421.15FELAU4006684@daisy.zia.io>
Date: Tue, 15 Jun 2021 14:21:10 GMT
From: john@ziaspace.com
Reply-To: john@ziaspace.com
To: gnats-bugs@NetBSD.org
Subject: pkgsrc bootstrap fails on modern Ubuntu
X-Send-Pr-Version: 3.95

>Number:         56248
>Category:       pkg
>Synopsis:       pkgsrc bootstrap fails on modern Ubuntu
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    pkg-manager
>State:          closed
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Tue Jun 15 14:25:00 +0000 2021
>Closed-Date:    Fri Mar 01 19:19:22 +0000 2024
>Last-Modified:  Fri Mar 01 19:19:22 +0000 2024
>Originator:     John Klos
>Release:        Linux UbuntuQemu 5.8.0-55-generic #62~20.04.1-Ubuntu SMP Wed Jun 2 08:55:04 UTC 2021 x86_64 x86_64 x86_64 GNU/Linux
>Organization:

>Environment:


System: Linux UbuntuQemu 5.8.0-55-generic #62~20.04.1-Ubuntu SMP Wed Jun 2 08:55:04 UTC 2021 x86_64 x86_64 x86_64 GNU/Linux
Architecture: x86_64
Machine: x86_64
>Description:
Bootstrapping pkgsrc on Ubuntu Ubuntu 20.04.2 LTS fails with:

./bootstrap --prefix /usr/local --prefer-pkgsrc yes --make-jobs 4
...
=> Replacing config-sub with pkgsrc versions
=> Replacing install-sh with pkgsrc version
checking for x86_64-debian-linux-gcc... cc
checking whether the C compiler works... no
configure: error: in `/usr/pkgsrc/bootstrap/work/wrk/pkgtools/cwrappers/work/cwrappers-20180325':
configure: error: C compiler cannot create executables
See `config.log' for more details
*** Error code 77

Stop.
bmake[1]: stopped in /usr/pkgsrc/pkgtools/cwrappers
*** Error code 1

The relevant part of config.log:

Thread model: posix
gcc version 9.3.0 (Ubuntu 9.3.0-17ubuntu1~20.04) 
configure:2427: $? = 0
configure:2416: cc -V >&5
gcc: error: unrecognized command line option '-V'
gcc: fatal error: no input files
compilation terminated.
configure:2427: $? = 1
configure:2416: cc -qversion >&5
gcc: error: unrecognized command line option '-qversion'; did you mean '--version'?
gcc: fatal error: no input files
compilation terminated.
configure:2427: $? = 1
configure:2447: checking whether the C compiler works
configure:2469: cc -O2 -D_GNU_SOURCE=1 -D_FORTIFY_SOURCE=2 -DHAVE_NBCOMPAT_H=1 -I/usr/pkgsrc/bootstrap/work/wrk/pkgtools/cwrappers/work/libnbcompat -L/usr/pkgsrc/bootstrap/work/wrk/pkgtools/cwrappers/work/libnbcompat -Wl,-R/usr/local/lib conftest.c -lnbcompat >&5
/usr/bin/ld: cannot find -lnbcompat
collect2: error: ld returned 1 exit status

gcc is version 9.3.0:

cc --version
cc (Ubuntu 9.3.0-17ubuntu1~20.04) 9.3.0
Copyright (C) 2019 Free Software Foundation, Inc.

>How-To-Repeat:

>Fix:


>Release-Note:

>Audit-Trail:
From: "Amitai Schleier" <schmonz@schmonz.com>
To: gnats-bugs@netbsd.org
Cc: 
Subject: Re: pkg/56248: pkgsrc bootstrap fails on modern Ubuntu
Date: 23 Jun 2021 15:01:03 -0400

 Whoever addresses this, please see Michael Forney's analysis in 
 http://mail-index.netbsd.org/tech-pkg/2021/05/29/msg024998.html

From: "Maya Rashish" <maya@netbsd.org>
To: gnats-bugs@gnats.NetBSD.org
Cc: 
Subject: PR/56248 CVS commit: pkgsrc/mk/wrapper
Date: Fri, 25 Jun 2021 22:02:06 +0000

 Module Name:	pkgsrc
 Committed By:	maya
 Date:		Fri Jun 25 22:02:06 UTC 2021

 Modified Files:
 	pkgsrc/mk/wrapper: gen-transform.sh

 Log Message:
 switch $echo statements to printf "%s\n".
 dash considers \1 to be octal escape.

 for PR pkg/56248, from Michael Forney's suggestion.
 $echo seems to be used for performance here (was previously cat) and not
 for compatibility with some esoteric system.

 I misunderstood things, and failed to test the last bootstrap diff, breaking
 bootstrap on Ubuntu for a while.


 To generate a diff of this commit:
 cvs rdiff -u -r1.12 -r1.13 pkgsrc/mk/wrapper/gen-transform.sh

 Please note that diffs are not public domain; they are subject to the
 copyright notices on the relevant files.

State-Changed-From-To: open->feedback
State-Changed-By: dholland@NetBSD.org
State-Changed-When: Sun, 27 Jun 2021 19:23:56 +0000
State-Changed-Why:
fixed?


From: "Benny Siegert" <bsiegert@netbsd.org>
To: gnats-bugs@gnats.NetBSD.org
Cc: 
Subject: PR/56248 CVS commit: [pkgsrc-2021Q2] pkgsrc/mk/wrapper
Date: Thu, 8 Jul 2021 08:04:56 +0000

 Module Name:	pkgsrc
 Committed By:	bsiegert
 Date:		Thu Jul  8 08:04:56 UTC 2021

 Modified Files:
 	pkgsrc/mk/wrapper [pkgsrc-2021Q2]: gen-transform.sh

 Log Message:
 Pullup ticket #6482 - requested by maya
 mk: Linux bootstrap fix

 Revisions pulled up:
 - mk/wrapper/gen-transform.sh                                   1.13

 ---
    Module Name:    pkgsrc
    Committed By:   maya
    Date:           Fri Jun 25 22:02:06 UTC 2021

    Modified Files:
            pkgsrc/mk/wrapper: gen-transform.sh

    Log Message:
    switch $echo statements to printf "%s\n".
    dash considers \1 to be octal escape.

    for PR pkg/56248, from Michael Forney's suggestion.
    $echo seems to be used for performance here (was previously cat) and not
    for compatibility with some esoteric system.

    I misunderstood things, and failed to test the last bootstrap diff, breaking
    bootstrap on Ubuntu for a while.


 To generate a diff of this commit:
 cvs rdiff -u -r1.12 -r1.12.24.1 pkgsrc/mk/wrapper/gen-transform.sh

 Please note that diffs are not public domain; they are subject to the
 copyright notices on the relevant files.

State-Changed-From-To: feedback->closed
State-Changed-By: bsiegert@NetBSD.org
State-Changed-When: Fri, 01 Mar 2024 19:19:22 +0000
State-Changed-Why:
Feedback timeout, assuming fixed


>Unformatted:

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-2024 The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.