NetBSD Problem Report #52854
From www@NetBSD.org Sat Dec 23 14:51:19 2017
Return-Path: <www@NetBSD.org>
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 "mail.NetBSD.org CA" (not verified))
by mollari.NetBSD.org (Postfix) with ESMTPS id E36657A188
for <gnats-bugs@gnats.NetBSD.org>; Sat, 23 Dec 2017 14:51:18 +0000 (UTC)
Message-Id: <20171223145113.721577A1EC@mollari.NetBSD.org>
Date: Sat, 23 Dec 2017 14:51:13 +0000 (UTC)
From: miwarin@gmail.com
Reply-To: miwarin@gmail.com
To: gnats-bugs@NetBSD.org
Subject: port2pkg: Unescaped left brace in regex is illegal here in regex
X-Send-Pr-Version: www-1.0
>Number: 52854
>Category: pkg
>Synopsis: port2pkg: Unescaped left brace in regex is illegal here in regex
>Confidential: no
>Severity: serious
>Priority: medium
>Responsible: pkg-manager
>State: open
>Class: sw-bug
>Submitter-Id: net
>Arrival-Date: Sat Dec 23 14:55:00 +0000 2017
>Originator: Susumu Miwa
>Release: 20171211
>Organization:
area51.gr.jp
>Environment:
NetBSD emi.area51.gr.jp 8.99.9 NetBSD 8.99.9 (MYKERNEL) #0: Tue Dec 12 01:34:43 JST 2017 root@emi.area51.gr.jp:/usr/obj/sys/arch/amd64/compile/MYKERNEL amd64
>Description:
perl has to escape brace.
% sudo port2pkg /home/rin/work/ports/devel/sonarqube /usr/pkgsrc/devel/sonarqube
Unescaped left brace in regex is illegal here in regex; marked by <-- HERE in m/\${ <-- HERE PORTNAME}/ at /usr/pkg/bin/port2pkg line 129
>How-To-Repeat:
above.
>Fix:
% diff -u port2pkg.pl.src port2pkg.pl
--- port2pkg.pl.src 2017-12-23 23:41:09.344519055 +0900
+++ port2pkg.pl 2017-12-23 23:42:56.804580798 +0900
@@ -126,8 +126,8 @@
}
if (defined($distname)) {
- $distname =~ s/\${PORTNAME}/$portname/;
- $distname =~ s/\${PORTVERSION}/$portversion/;
+ $distname =~ s/\$\{PORTNAME\}/$portname/;
+ $distname =~ s/\$\{PORTVERSION\}/$portversion/;
if ($distname ne "$portname-$portversion") {
$pkgname = "$portname-$portversion";
(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.