Date: Sun, 06 Nov 2016 19:31:52 +0000 From: bugzilla-noreply@freebsd.org To: pkg@FreeBSD.org Subject: [Bug 213255] ports-mgmt/pkg: hardlinks aren't installed by make install (fake-pkg) Message-ID: <bug-213255-32340-a32uVi6K3D@https.bugs.freebsd.org/bugzilla/> In-Reply-To: <bug-213255-32340@https.bugs.freebsd.org/bugzilla/> References: <bug-213255-32340@https.bugs.freebsd.org/bugzilla/>
next in thread | previous in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D213255 --- Comment #1 from Tijl Coosemans <tijl@FreeBSD.org> --- 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.=
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-213255-32340-a32uVi6K3D>