I tried to modify the %install and the installation still failed, but it was 
due to symlink failure.
```
%install
mkdir %{buildroot}/sbin/
touch %{buildroot}/sbin/aaa

%if %{with sbinsymlinks}
mkdir -p %{buildroot}/usr/sbin/
cd %{buildroot}/usr/sbin/
ln -sv ../../sbin/aaa .
%endif
```
```
[root@localhost SPECS]# rpm -ivh 
/root/rpmbuild/RPMS/noarch/test-1.0-1.noarch.rpm --force
Verifying...                          ################################# [100%]
Preparing...                          ################################# [100%]
Updating / installing...
   1:test-1.0-1                       ################################# [100%]
error: unpacking of archive failed on file /usr/sbin/aaa;639a7f70: cpio: 
**symlink failed - No such file or directory**
error: test-1.0-1.noarch: install failed
```

-- 
Reply to this email directly or view it on GitHub:
https://github.com/rpm-software-management/rpm/issues/2273#issuecomment-1352470844
You are receiving this because you are subscribed to this thread.

Message ID: <rpm-software-management/rpm/issues/2273/1352470...@github.com>
_______________________________________________
Rpm-maint mailing list
Rpm-maint@lists.rpm.org
http://lists.rpm.org/mailman/listinfo/rpm-maint

Reply via email to