From owner-freebsd-ports-bugs@FreeBSD.ORG Tue Nov 4 05:44:06 2014 Return-Path: Delivered-To: freebsd-ports-bugs@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by hub.freebsd.org (Postfix) with ESMTPS id 900544FA for ; Tue, 4 Nov 2014 05:44:06 +0000 (UTC) Received: from kenobi.freebsd.org (kenobi.freebsd.org [IPv6:2001:1900:2254:206a::16:76]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 721BA226 for ; Tue, 4 Nov 2014 05:44:06 +0000 (UTC) Received: from bugs.freebsd.org ([127.0.1.118]) by kenobi.freebsd.org (8.14.9/8.14.9) with ESMTP id sA45i6dl023275 for ; Tue, 4 Nov 2014 05:44:06 GMT (envelope-from bugzilla-noreply@freebsd.org) From: bugzilla-noreply@freebsd.org To: freebsd-ports-bugs@FreeBSD.org Subject: [Bug 194800] New: ports-mgmt/portupgrade: broken after moving ports folder to another place Date: Tue, 04 Nov 2014 05:44:06 +0000 X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: new X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: Ports Tree X-Bugzilla-Component: Individual Port(s) X-Bugzilla-Version: Latest X-Bugzilla-Keywords: X-Bugzilla-Severity: Affects Only Me X-Bugzilla-Who: d.akiyakov@gmail.com X-Bugzilla-Status: Needs Triage X-Bugzilla-Priority: --- X-Bugzilla-Assigned-To: bdrewery@FreeBSD.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: maintainer-feedback? X-Bugzilla-Changed-Fields: bug_id short_desc product version rep_platform op_sys bug_status bug_severity priority component assigned_to reporter flagtypes.name Message-ID: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit X-Bugzilla-URL: https://bugs.freebsd.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-BeenThere: freebsd-ports-bugs@freebsd.org X-Mailman-Version: 2.1.18-1 Precedence: list List-Id: Ports bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 04 Nov 2014 05:44:06 -0000 https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=194800 Bug ID: 194800 Summary: ports-mgmt/portupgrade: broken after moving ports folder to another place Product: Ports Tree Version: Latest Hardware: amd64 OS: Any Status: Needs Triage Severity: Affects Only Me Priority: --- Component: Individual Port(s) Assignee: bdrewery@FreeBSD.org Reporter: d.akiyakov@gmail.com Assignee: bdrewery@FreeBSD.org Flags: maintainer-feedback?(bdrewery@FreeBSD.org) Hello, I moved ports folder to another place, for example to /home/data/ports. After that I added few lines to /usr/local/etc/pkgtools.conf ENV['PORTSDIR'] ||= '/home/data/ports' Also, I try to add the following line to /etc/make.conf PORTSDIR=/home/data/ports Portupgrade worked with /home/data/ports till /usr/ports was in system, but when I delete /usr/ports, I received the following output: ira@sunlark:/home/data % portupgrade cd: /usr/ports: No such file or directory /usr/local/lib/ruby/site_ruby/2.0/pkgtools/portsdb.rb:237:in `join': no implicit conversion of nil into String (TypeError) from /usr/local/lib/ruby/site_ruby/2.0/pkgtools/portsdb.rb:237:in `index_file' from /usr/local/lib/ruby/site_ruby/2.0/pkgtools/portsdb.rb:247:in `db_dir=' from /usr/local/lib/ruby/site_ruby/2.0/pkgtools/portsdb.rb:167:in `setup' from /usr/local/lib/ruby/site_ruby/2.0/pkgtools/pkgtools.rb:242:in `init_pkgtools_global' from /usr/local/sbin/portupgrade:530:in `block in main' from /usr/local/lib/ruby/2.0/optparse.rb:885:in `initialize' from /usr/local/sbin/portupgrade:237:in `new' from /usr/local/sbin/portupgrade:237:in `main' from /usr/local/sbin/portupgrade:2376:in `
' To resolve this problem, I edit /usr/local/lib/ruby/site_ruby/2.0/pkgtools/portsdb.rb line 214: - @ports_dir = new_ports_dir || ENV['PORTSDIR'] || '/usr/ports' + @ports_dir = new_ports_dir || ENV['PORTSDIR'] || '/home/data/ports' it helps for me. ira@sunlark:/home/data % uname -a FreeBSD sunlark.localhost 10.1-PRERELEASE FreeBSD 10.1-PRERELEASE #4 r273447: Wed Oct 22 09:40:49 NOVT 2014 ira@sunlark.localhost:/usr/obj/usr/src/sys/CORE amd64 --- Comment #1 from Bugzilla Automation --- Auto-assigned to maintainer bdrewery@FreeBSD.org -- You are receiving this mail because: You are the assignee for the bug.