[Rpm-maint] [rpm-software-management/rpm] RFE: Allow slicing sources list (Issue #2180)

Maxwell G notifications at github.com
Sat Sep 10 21:34:22 UTC 2022


Sometimes, I want to copy all of the sources into the working build directory except the first one. For example, if I have

```
Source0: %{name}-%{version}.tar.gz
Source1: %{name}.service
Source2: %{name}.sysconfig
Source3: %{name}-sysusers.conf
Source4: %{name}.1
```

I could do `cp -a %{sources} .`, but that would also copy the source tarball, which I don't want. Could you consider implementing a simple way to "slice" the sources list so I can run `cp -a sliced_sources_implementation .` and copy every Source except the first? Other ranges should be supported as well, e.g. if a package has multiple source tarballs or some other special case.

In these type of cases, I'd normally directly install these files with `install -Dp %{SOURCEn} %{buildroot}%{_foodir}/bar`, but I would prefer to be able to copy them into the build directory and refer to them by name in `%install`. This feature would eliminate the need manual source numbering (which I find cumbersome) and make specfiles more readable. It would mainly benefit packages that have more than a couple Sources.

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

Message ID: <rpm-software-management/rpm/issues/2180 at github.com>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.rpm.org/pipermail/rpm-maint/attachments/20220910/ea7a4297/attachment.html>


More information about the Rpm-maint mailing list