NetBSD Problem Report #51562

From eric@woodstock.cirr.com  Wed Oct 19 15:51:01 2016
Return-Path: <eric@woodstock.cirr.com>
Received: from mail.netbsd.org (mail.netbsd.org [199.233.217.200])
	(using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits))
	(Client CN "mail.netbsd.org", Issuer "Postmaster NetBSD.org" (verified OK))
	by mollari.NetBSD.org (Postfix) with ESMTPS id E4F4C7A289
	for <gnats-bugs@gnats.NetBSD.org>; Wed, 19 Oct 2016 15:51:01 +0000 (UTC)
Message-Id: <20161019155052.DCDDC7FA14@woodstock.cirr.com>
Date: Wed, 19 Oct 2016 10:50:52 -0500 (CDT)
From: eric@cirr.com
Reply-To: eric@cirr.com
To: gnats-bugs@NetBSD.org
Subject: textproc/p5-Test-YAML does not package when PKG_DEVELOPER=yes
X-Send-Pr-Version: 3.95

>Number:         51562
>Category:       pkg
>Synopsis:       textproc/p5-Test-YAML does not package when PKG_DEVELOPER=yes
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    pkg-manager
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Wed Oct 19 15:55:00 +0000 2016
>Last-Modified:  Wed Oct 19 16:50:00 +0000 2016
>Originator:     eric@cirr.com
>Release:        NetBSD 7.0_STABLE
>Organization:
CIRR.COM
>Environment:
System: NetBSD woodstock 7.0_STABLE NetBSD 7.0_STABLE (GENERIC.201610161240Z) amd64
Architecture: x86_64
Machine: amd64
>Description:
	When attempting to build/install textproc/p5-Test-YAML with
	PKG_DEVELOPER=yes, the package will not be generated, as
	a path to the work directory version of bash is included
	in the final output scripts.

script(1) output from an attempt at packaging:

    Script started on Wed Oct 19 10:45:02 2016
    woodstock-> make PKG_DEVELOPER=yes package
    => Bootstrap dependency digest>=20010302: found digest-20160304
    => Checksum SHA1 OK for Test-YAML-1.06.tar.gz
    => Checksum RMD160 OK for Test-YAML-1.06.tar.gz
    => Checksum SHA512 OK for Test-YAML-1.06.tar.gz
    ===> Installing dependencies for p5-Test-YAML-1.06nb1
    => Tool dependency checkperms>=1.1: found checkperms-1.11nb1
    => Full dependency p5-Test-Base>=0.86: found p5-Test-Base-0.88nb2
    => Full dependency bash-[0-9]*: found bash-4.4
    => Full dependency perl<5.26.0: found perl-5.24.0
    => Full dependency perl>=5.24.0: found perl-5.24.0
    ===> Overriding tools for p5-Test-YAML-1.06nb1
    ===> Extracting for p5-Test-YAML-1.06nb1
    ===> Patching for p5-Test-YAML-1.06nb1
    ===> Creating toolchain wrappers for p5-Test-YAML-1.06nb1
    ===> Configuring for p5-Test-YAML-1.06nb1
    => Replacing bash interpreter in bin/test-yaml.
    => Checking for portability problems in extracted files
    Checking if your kit is complete...
    Looks good
    Generating a Unix-style Makefile
    Writing Makefile for Test::YAML
    Writing MYMETA.yml and MYMETA.json
    ===> Building for p5-Test-YAML-1.06nb1
    cp lib/Test/YAML.pod blib/lib/Test/YAML.pod
    cp lib/Test/YAML.pm blib/lib/Test/YAML.pm
    cp bin/test-yaml blib/script/test-yaml
    "/usr/pkg/bin/perl5.24.0" -MExtUtils::MY -e 'MY->fixin(shift)' -- blib/script/test-yaml
    Manifying 1 pod document
    => Unwrapping files-to-be-installed.
    ===> Installing for p5-Test-YAML-1.06nb1
    => Generating pre-install file lists
    Manifying 1 pod document
    Installing /scratch/pkg/obj/textproc/p5-Test-YAML/work/.destdir/usr/pkg/lib/perl5/vendor_perl/5.24.0/Test/YAML.pod
    Installing /scratch/pkg/obj/textproc/p5-Test-YAML/work/.destdir/usr/pkg/lib/perl5/vendor_perl/5.24.0/Test/YAML.pm
    Installing /scratch/pkg/obj/textproc/p5-Test-YAML/work/.destdir/usr/pkg/lib/perl5/vendor_perl/man/man3/Test::YAML.3
    Installing /scratch/pkg/obj/textproc/p5-Test-YAML/work/.destdir/usr/pkg/lib/perl5/vendor_perl/bin/test-yaml
    Appending installation info to /scratch/pkg/obj/textproc/p5-Test-YAML/work/.destdir/usr/pkg/lib/perl5/5.24.0/x86_64-netbsd-thread-multi/perllocal.pod
    => Automatic manual page handling
    => Generating post-install file lists
    => Checking file-check results for p5-Test-YAML-1.06nb1
    => Checking for non-existent script interpreters in p5-Test-YAML-1.06nb1
    => Checking file permissions in p5-Test-YAML-1.06nb1
    warning: /scratch/pkg: group-writable directory.
    0 errors and 1 warnings.
    => Checking for missing run-time search paths in p5-Test-YAML-1.06nb1
    => Checking for work-directory references in p5-Test-YAML-1.06nb1
    ERROR: /usr/pkg/lib/perl5/vendor_perl/bin/test-yaml:	#!/scratch/pkg/obj/textproc/p5-Test-YAML/work/.tools/bin/bash
    ERROR: *** The above files still have references to the build directory.
    ERROR:     This is possibly an error that should be fixed by unwrapping
    ERROR:     the files or adding missing tools to the package makefile!
    *** Error code 1

    Stop.
    make[1]: stopped in /usr/pkgsrc/textproc/p5-Test-YAML
    *** Error code 1

    Stop.
    make: stopped in /usr/pkgsrc/textproc/p5-Test-YAML
    woodstock-> exit

    Script done on Wed Oct 19 10:46:33 2016

>How-To-Repeat:
	cd /usr/pkgsrc/textproc/p5-Test-YAML;
	make PKG_DEVELOPER=yes package
>Fix:
	Unknown.  The issue appears to be with the call to MM->fixit()
	that is executed as part of the installation process.

>Audit-Trail:
From: Leonardo Taccari <leot@NetBSD.org>
To: gnats-bugs@NetBSD.org
Cc: 
Subject: Re: pkg/51562: textproc/p5-Test-YAML does not package when PKG_DEVELOPER=yes
Date: Wed, 19 Oct 2016 18:28:35 +0200

 Hello eric,

 eric@cirr.com writes:
 > [...]
 > >Description:
 > 	When attempting to build/install textproc/p5-Test-YAML with
 > 	PKG_DEVELOPER=3Dyes, the package will not be generated, as
 > 	a path to the work directory version of bash is included
 > 	in the final output scripts.
 > =

 > script(1) output from an attempt at packaging:
 > =

 >     Script started on Wed Oct 19 10:45:02 2016
 >     woodstock-> make PKG_DEVELOPER=3Dyes package
 > [...]
 >     =3D> Checking for missing run-time search paths in p5-Test-YAML-1.06=
 nb1
 >     =3D> Checking for work-directory references in p5-Test-YAML-1.06nb1
 >     ERROR: /usr/pkg/lib/perl5/vendor_perl/bin/test-yaml:	#!/scratch/pkg/=
 obj/textproc/p5-Test-YAML/work/.tools/bin/bash
 >     ERROR: *** The above files still have references to the build direct=
 ory.
 >     ERROR:     This is possibly an error that should be fixed by unwrapp=
 ing
 >     ERROR:     the files or adding missing tools to the package makefile=
 !
 >     *** Error code 1
 > =

 >     Stop.
 >     make[1]: stopped in /usr/pkgsrc/textproc/p5-Test-YAML
 >     *** Error code 1
 > =

 >     Stop.
 >     make: stopped in /usr/pkgsrc/textproc/p5-Test-YAML
 >     woodstock-> exit
 > =

 >     Script done on Wed Oct 19 10:46:33 2016
 > =

 > >How-To-Repeat:
 > 	cd /usr/pkgsrc/textproc/p5-Test-YAML;
 > 	make PKG_DEVELOPER=3Dyes package
 > >Fix:
 > 	Unknown.  The issue appears to be with the call to MM->fixit()
 > 	that is executed as part of the installation process.
 > =

 Last time that I've looked at this problem (several months ago, so
 sorry if my mind can be a bit foggy about that!) this happens
 because REPLACE_BASH correctly change the shebang but then
 ExtUtils::MakeMaker rechange it.

 The following patch is a possible workaround but it's a bit dirty
 IMHO:

  http://netbsd.org/~leot/pkgsrc-patches/p5-test-yaml-bash-kludge

From: eric@cirr.com (Eric Schnoebelen)
To: gnats-bugs@NetBSD.org
Cc: pkg-manager@netbsd.org, gnats-admin@netbsd.org, pkgsrc-bugs@netbsd.org
Subject: Re: pkg/51562: textproc/p5-Test-YAML does not package when PKG_DEVELOPER=yes
Date: Wed, 19 Oct 2016 11:48:29 -0500

 Leonardo Taccari writes:
 - The following reply was made to PR pkg/51562; it has been noted by GNATS.
 - 
 - From: Leonardo Taccari <leot@NetBSD.org>
 - To: gnats-bugs@NetBSD.org
 - Cc: 
 - Subject: Re: pkg/51562: textproc/p5-Test-YAML does not package when PKG_DEV
 - ELOPER=yes
 - Date: Wed, 19 Oct 2016 18:28:35 +0200
 - 
 -  Hello eric,
 -  
 -  eric@cirr.com writes:
 -  > [...]
 -  > >Description:
 -  > 	When attempting to build/install textproc/p5-Test-YAML with
 -  > 	PKG_DEVELOPER=3Dyes, the package will not be generated, as
 -  > 	a path to the work directory version of bash is included

 [..]

 -  Last time that I've looked at this problem (several months ago, so
 -  sorry if my mind can be a bit foggy about that!) this happens
 -  because REPLACE_BASH correctly change the shebang but then
 -  ExtUtils::MakeMaker rechange it.

 That fits with my quick analysis as well.  I wasn't able to
 (quickly) figure out a good, sane fix, so I submitted the PR.

 -  The following patch is a possible workaround but it's a bit dirty
 -  IMHO:
 -  
 -   http://netbsd.org/~leot/pkgsrc-patches/p5-test-yaml-bash-kludge

 I suspect there is a way that we can get ExtUtils::MakeMaker to
 do the right thing, but I'm not sufficently well versed in it's
 configuration/calling conventions to figure out how.

 --
 Eric Schnoebelen		eric@cirr.com		http://www.cirr.com
 	I like pigs.  Dogs look up to us.  Cats look down on us.  Pigs 
 		  treat us as equals.  -- Winston Churchill

NetBSD Home
NetBSD PR Database Search

(Contact us) $NetBSD: query-full-pr,v 1.39 2013/11/01 18:47:49 spz Exp $
$NetBSD: gnats_config.sh,v 1.8 2006/05/07 09:23:38 tsutsui Exp $
Copyright © 1994-2014 The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.