Bug 244439

Summary: ports-mgmt/pkg 1.13.2 does not handle LOCALBASE split to different file systems right
Product: Ports & Packages Reporter: Eugene Grosbein <eugen>
Component: Individual Port(s)Assignee: freebsd-pkg (Nobody) <pkg>
Status: New ---    
Severity: Affects Some People    
Priority: ---    
Version: Latest   
Hardware: Any   
OS: Any   

Description Eugene Grosbein freebsd_committer 2020-02-26 19:30:00 UTC

Suppose we need to install very big port like llvm80 (about 800MB) as dependency for something like samba410 to the system that has no enought space inside /usr/local file system but has plenty of free space at another UFS file system, so we create symlink /usr/local/llvm80 -> /data/llvm80 before installing. Also, we define WRKDIRPREFIX pointing to /data/tmp.

The port builds and stages just fine but installation fails:

===>   Registering installation for llvm80-8.0.1_3 as automatic
Installing llvm80-8.0.1_3...
pkg-static: Fail to create hardlink: /usr/local/llvm80/bin/.pkgtemp.FileCheck.S4KfobBEtZNB:Cross-device link
*** Error code 70

make[5]: stopped in /usr/ports/devel/llvm80
*** Error code 1

It should not fail.
Comment 1 Baptiste Daroussin freebsd_committer 2020-10-01 04:06:24 UTC
This bug should imho be addressed to llvm maintainers and not to pkg as pkg install what it has been asked to installed here a hardlink.

For this situation to be supported, it needs to be a symlink

I fail to see what pkg can/should do here.
That said, I can be convinced otherwise
Comment 2 Eugene Grosbein freebsd_committer 2020-10-01 06:45:36 UTC
I don't see anything in this port insisting on creation of hardlinks, please elaborate.