I am trying to figure out an issue that I have with installing an RPM file on openSUSE which I build on Windows (using Cygwin/rpmbuild).

When I try to install the RPM on Linux I get an error saying

package <package>.rpm is intended for a different operating system

The RPM is build by calling

rpmbuild --nodeps --target=i386 --buildroot="$BUILDDIR" -bb $ROOTPATH/tmp.spec

I can force the installation by installing it with --ignoreos, but if there is a way to avoid it. I've been rummaging through the rpm macros file in Cygwin, but I've not been able to find the correct setting. Any ideas?


Literally 5 seconds after I've posted the question, I found the answer. The rpmbuild command is incorrect; if I execute

rpmbuild --nodeps --target=i386-linux --buildroot="$BUILDDIR" -bb $ROOTPATH/tmp.spec

everything works correctly and I can install the resulting RPM on Linux.


Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.