From owner-freebsd-pkg@freebsd.org Sun Nov 6 19:31:52 2016 Return-Path: Delivered-To: freebsd-pkg@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id E9C5DC34B04 for ; Sun, 6 Nov 2016 19:31:52 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from mailman.ysv.freebsd.org (mailman.ysv.freebsd.org [IPv6:2001:1900:2254:206a::50:5]) by mx1.freebsd.org (Postfix) with ESMTP id D2E6BF6B for ; Sun, 6 Nov 2016 19:31:52 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: by mailman.ysv.freebsd.org (Postfix) id CF792C34B03; Sun, 6 Nov 2016 19:31:52 +0000 (UTC) Delivered-To: pkg@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:1900:2254:206a::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id CF297C34B02 for ; Sun, 6 Nov 2016 19:31:52 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) 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 BEAD0F6A for ; Sun, 6 Nov 2016 19:31:52 +0000 (UTC) (envelope-from bugzilla-noreply@freebsd.org) Received: from bugs.freebsd.org ([127.0.1.118]) by kenobi.freebsd.org (8.15.2/8.15.2) with ESMTP id uA6JVq7g084411 for ; Sun, 6 Nov 2016 19:31:52 GMT (envelope-from bugzilla-noreply@freebsd.org) From: bugzilla-noreply@freebsd.org To: pkg@FreeBSD.org Subject: [Bug 213255] ports-mgmt/pkg: hardlinks aren't installed by make install (fake-pkg) Date: Sun, 06 Nov 2016 19:31:52 +0000 X-Bugzilla-Reason: AssignedTo X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: Ports & Packages X-Bugzilla-Component: Individual Port(s) X-Bugzilla-Version: Latest X-Bugzilla-Keywords: X-Bugzilla-Severity: Affects Only Me X-Bugzilla-Who: tijl@FreeBSD.org X-Bugzilla-Status: New X-Bugzilla-Resolution: X-Bugzilla-Priority: --- X-Bugzilla-Assigned-To: pkg@FreeBSD.org X-Bugzilla-Flags: maintainer-feedback? X-Bugzilla-Changed-Fields: attachments.created Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: https://bugs.freebsd.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-BeenThere: freebsd-pkg@freebsd.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Binary package management and package tools discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 06 Nov 2016 19:31:53 -0000 https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D213255 --- Comment #1 from Tijl Coosemans --- Created attachment 176698 --> https://bugs.freebsd.org/bugzilla/attachment.cgi?id=3D176698&action= =3Dedit patch So this turned out to be caused by /compat being a symlink to usr/compat on= my system and it's a bug in libarchive. It can be reproduced with tar like th= is: % mkdir dir2 % ln -s dir2 dir % touch dir/file % ln dir/file dir/file2 % tar cf dir.tar dir/file dir/file2 % rm dir/* % tar xf dir.tar -P dir/file2: Can't create 'dir/file2' tar: Error exit delayed from previous errors. tijl@kalimero:~/tmp/test% ls -l dir/ total 0 -rw-r--r-- 1 tijl wheel 0 6 Nov 20:05 file With -P extraction through a symlink (dir->dir2) should work, but fails for hardlinks. The attached patch fixes this. In archive_write_disk_posix.c the function create_filesystem_object() calls check_symlinks_fsobj() in the case of hardlinks, but not in the case of symlinks or regular files. The patch rem= oves this call. check_symlinks_fsobj() is still called elsewhere in the same fi= le and the 'tar xf' command above without -P still fails on both archive entri= es. --=20 You are receiving this mail because: You are the assignee for the bug.=