Rpmrebuild...file not found errors

Hi

Tumbleweed 20251127
rpmrebuild 2.18-1.3
rpm 4.20.1-6.1
iscan-2.30.4-2.x86_64.rpm

I’ve just changed over to Tumbleweed, having been previously on Leap 15.5 (and many versions before on this 2007 PC) and I’m having problems using rpmrebuild on an Epson scanner rpm. I just wanted to edit the spec file as I want to tweak the dependency for libxml2 to libxml2-16.

rpmrebuild -enp iscan-2.30.4-2.x86.rpm

starts okay and files are created in ~/.tmp/rpmrebuild.$$/work/root

When it asks “Do you want to continue ? (y/N)” and I respond “y”, it opens up a text editor and I’m able to edit the file. However when I save that file and it moves to the next stage, I get a load of file not found errors, starting with:

error: File not found: ~/rpmbuild/BUILD/iscan-2.30.4-build/BUILDROOT/etc/sane.d/epkowa.conf

along with two dozen others and the directory in .tmp is deleted.

Now I’m sure it’s something simple, but I haven’t figured it out yet. Either the files aren’t being created in the first place to delete or rpmbuild is looking in the wrong place for them.

I went as far as downloading and running a live USB stick with Fedora 43 and had no trouble with exactly the same commands and process once I installed rpm and rpmrebuild. Any pointers to what I am (or the program) is doing wrong?

Thanks in advance.

in your %files section, rpmbuild most likely has %{_sysconfdir}/sane.d/epkowa.conf or something similar listed, which must not be getting put into %{buildroot}%{_sysconfdir}/sane.d/ during your %install

You’ll need to figure out what’s happening there. One of the easier, but less efficient ways to do it is to comment out the line in your %files section, and rerun the build, and it will tell you that you have installed but unpackaged files.

(e.g. %dnl %{_sysconfdir}/sane.d/epkowa.conf)