Add lp64d symlink to parent directory on riscv64

On RISCV we typically expect to have /usr/lib64/<ABI> directory. Some
software is strict about it, and some actually fallback to /usr/lib64.

We only support a single ABI, that's lp64d. We have it as a symlink back
to the parent. That means /usr/lib64 and /usr/lib64/lpd64 both point to
the same content.

Signed-off-by: David Abdurachmanov <davidlt@rivosinc.com>
This commit is contained in:
David Abdurachmanov 2024-05-16 16:30:34 +03:00
parent 5cbb39caaa
commit 05be625e2a
Signed by: davidlt
GPG Key ID: 7A5F42FAF91FACC3

View File

@ -1,7 +1,7 @@
Summary: The basic directory layout for a Linux system
Name: filesystem
Version: 3.18
Release: 9%{?dist}
Release: 9.0.riscv64%{?dist}
License: LicenseRef-Fedora-Public-Domain
URL: https://pagure.io/filesystem
Source1: https://pagure.io/filesystem/raw/master/f/lang-exceptions
@ -58,6 +58,9 @@ ln -snf usr/bin bin
ln -snf usr/sbin sbin
ln -snf usr/lib lib
ln -snf usr/%{_lib} %{_lib}
%ifarch riscv64
ln -snf . usr/%{_lib}/lp64d
%endif
ln -snf ../run var/run
ln -snf ../run/lock var/lock
ln -snf usr/bin usr/lib/debug/bin
@ -153,6 +156,9 @@ posix.symlink("usr/%{_lib}", "/usr/lib/debug/%{_lib}")
posix.symlink("../.dwz", "/usr/lib/debug/usr/.dwz")
posix.symlink("usr/sbin", "/usr/lib/debug/sbin")
posix.symlink("usr/%{_lib}", "/%{_lib}")
if "%{_arch}" == "riscv64" then
posix.symlink(".", "/usr/%{_lib}/lp64d")
end
posix.mkdir("/run")
posix.mkdir("/proc")
posix.mkdir("/sys")
@ -241,12 +247,15 @@ end
%ghost /usr/lib/debug/sbin
%attr(555,root,root) /usr/lib/games
%ifarch x86_64 ppc64 sparc64 s390x aarch64 ppc64le mips64 mips64el riscv64
%attr(555,root,root) /usr/%{_lib}
%dir %attr(555,root,root) /usr/%{_lib}
%else
%attr(555,root,root) /usr/lib/bpf
%attr(555,root,root) /usr/lib/X11
%attr(555,root,root) /usr/lib/pm-utils
%endif
%ifarch riscv64
/usr/%{_lib}/lp64d
%endif
/usr/libexec
/usr/local
%attr(555,root,root) /usr/sbin
@ -312,6 +321,9 @@ end
/var/yp
%changelog
* Thu May 16 2024 David Abdurachmanov <davidlt@rivosinc.com> - 3.18-9.0.riscv64
- Add lp64d symlink to parent directory on riscv64
* Wed Mar 13 2024 Orion Poplawski <orion@fedoraproject.org> - 3.18-9
- Add /usr/share/modulefiles for environment modules