Description of problem: We have an rpmbuild server which NFS mounts a directory with build artifacts from a separate server farm. We had hoped to use spectool to automatically transfer Source#: files in .SPECS to our SOURCEDIR, which works fine for remote URLs but doesn't do anything useful with absolute paths. Version-Release number of selected component (if applicable): rpmdevtools-8.10-2.fc26.noarch Should be applicable back to >= rpmdevtools 8.0 (2011-02-06) How reproducible: Always Steps to Reproduce: 1. Specify a SOURCE# using a file:// URL or absolute path in package.spec 2. spectool -v -g -S -R package.spec 3. Actual results: Couldn't fetch file:///mnt/foobar/build/package/1.0.0/package-1.0.0.tar.gz: missing URL Expected results: spectool copies the specified file into rpm's %{_sourcedir} Additional info: Recent versions of spectool in rpmdevtools use curl instead of wget and curl natively understands file:// URLs. Suggest either supporting absolute paths directly, or just adding "file" to the allowed list of protocols: > my @protocols = qw/ftp http https file/;
I opted to remove the internal check for specific protocols altogether, everything that looks like it has a protocol is passed to curl now: https://pagure.io/rpmdevtools/c/ecbe7300237b74abfbaa7c429b0e0b78468a89c6
Thank you. Is there any chance this patch could be backported into RHEL? file URLs are a useful feature for those wanting to automate this.
I can't do anything about RHEL rpmdevtools, a separate bug will need to be filed against the RHEL package.