NetBSD Problem Report #50275

From www@NetBSD.org  Thu Sep 24 06:32:37 2015
Return-Path: <www@NetBSD.org>
Received: from mail.netbsd.org (mail.netbsd.org [149.20.53.66])
	(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 3FD3EA666A
	for <gnats-bugs@gnats.NetBSD.org>; Thu, 24 Sep 2015 06:32:37 +0000 (UTC)
Message-Id: <20150924063235.E1E32A668E@mollari.NetBSD.org>
Date: Thu, 24 Sep 2015 06:32:35 +0000 (UTC)
From: david.sainty@gmail.com
Reply-To: david.sainty@gmail.com
To: gnats-bugs@NetBSD.org
Subject: Bootstrapping shlock fails if cwrappers and locking are enabled
X-Send-Pr-Version: www-1.0

>Number:         50275
>Category:       pkg
>Synopsis:       Bootstrapping shlock fails if cwrappers and locking are enabled
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    joerg
>State:          closed
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Thu Sep 24 06:35:00 +0000 2015
>Closed-Date:    Wed Jan 04 15:03:26 +0000 2017
>Last-Modified:  Wed Jan 04 15:03:26 +0000 2017
>Originator:     David Sainty
>Release:        Pkgsrc current
>Organization:
>Environment:
Linux laptop 3.0.0-31-generic-pae #49-Ubuntu SMP Tue Feb 19 20:24:31 UTC 2013 i686 i686 i386 GNU/Linux

>Description:
If you happen to set USE_CWRAPPERS=yes and PKGSRC_LOCKTYPE=sleep in mk.conf on a blank slate Pkgsrc on a system with no native shlock (E.g. Linux), trouble ensues.

Any attempt to install will ask you to install shlock.  But shlock wants cwrappers.  But cwrappers needs shlock.

>How-To-Repeat:
Add to mk.conf:

USE_CWRAPPERS=yes
PKGSRC_LOCKTYPE=sleep

% pkg_delete shlock
% pkg_delete cwrappers
% cd pkgtools/cwrappers
% make install
ERROR: [locking.mk] shlock is not installed.
ERROR: [locking.mk] Please "(cd ../../pkgtools/shlock && /pkg/pkgrootR1/bin/bmake install)".
*** Error code 1

% cd ../shlock
% make install
===> Installing dependencies for shlock-20080529
=> Build dependency cwrappers>=20150314: NOT found
=> Verifying reinstall for ../../pkgtools/cwrappers
ERROR: [locking.mk] shlock is not installed.
ERROR: [locking.mk] Please "(cd ../../pkgtools/shlock && /pkg/pkgrootR1/bin/bmake install)".
*** Error code 1

>Fix:
This could be fixed either by adding PKGSRC_LOCKTYPE=none to cwrappers (like shlock does, but it risks race problems), or something like USE_CWRAPPERS=no to shlock (could be ok...).

This might be a little too niche to address in the freeze.  Anyone getting into this trouble probably knows how to get out :)

>Release-Note:

>Audit-Trail:

Responsible-Changed-From-To: pkg-manager->joerg
Responsible-Changed-By: bsiegert@NetBSD.org
Responsible-Changed-When: Mon, 28 Dec 2015 12:58:58 +0000
Responsible-Changed-Why:
Joerg, should this be fixed in cwrappers?


From: "Joerg Sonnenberger" <joerg@netbsd.org>
To: gnats-bugs@gnats.NetBSD.org
Cc: 
Subject: PR/50275 CVS commit: pkgsrc/pkgtools/cwrappers
Date: Fri, 25 Nov 2016 22:46:40 +0000

 Module Name:	pkgsrc
 Committed By:	joerg
 Date:		Fri Nov 25 22:46:40 UTC 2016

 Modified Files:
 	pkgsrc/pkgtools/cwrappers: Makefile

 Log Message:
 PR pkg/50275: Explicitly disable the locking type here. If shlock is not
 a platform tool, it will introduce cyclic dependencies otherwise, e.g.
 via sysutils/checkperms.


 To generate a diff of this commit:
 cvs rdiff -u -r1.16 -r1.17 pkgsrc/pkgtools/cwrappers/Makefile

 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 Nov 2016 04:10:26 +0000
State-Changed-Why:
Fixed?


State-Changed-From-To: feedback->closed
State-Changed-By: wiz@NetBSD.org
State-Changed-When: Wed, 04 Jan 2017 15:03:26 +0000
State-Changed-Why:
one month feedback timeout, believed fixed.


>Unformatted:

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.