Questions tagged [rpm-spec]

The rpm spec file contains the information required by RPM to build a package.

The spec file is at the heart of RPM's packaging building process. Similar in concept to a , it contains information required by RPM to build the package, as well as instructions telling RPM how to build it. The spec file also dictates exactly what files are a part of the package, and where they should be installed.

(From the max-rpm book)

This tag is closely related to and . You should research those tags to see if a similar question exists.

578 questions
3
votes
1 answer

How to require a file not owned by an RPM in a spec file "Requires" line?

I have installed (in CentOS 7) a program called Rational Software Architect (RSA 9.5) which is a rich client platform that acts just like Eclipse, but without actually installing an RPM. RSA came with an installation bash script which pretty much…
msteppe91
  • 143
  • 2
  • 18
3
votes
1 answer

RPM build correctly setting Provides on openSUSE, but not Fedora

I have an RPM specfile for MakeMKV which is uploaded to OBS to build packages for Fedora and openSUSE. The specfile is the same between both distributions, but only openSUSE correctly adds the built libraries to the build packages Provides section,…
Adam Chance
  • 277
  • 1
  • 2
  • 10
3
votes
1 answer

rpm spec Requires wildcard in package name

I'm creating an RPM that has a requirement on another package that has the version number in the middle of the package name. For instance softwarepackage10.1-util-10.1.1.x86_64.rpm. The name would change with the next release, for instance…
retrodev
  • 2,323
  • 6
  • 24
  • 48
3
votes
2 answers

RPM Spec file conditional Requires per distribution AFTER build

I want to build RPM files and I want them to be commonly used and beeing not depending on which distribution is installed. Now I found a requirement which name is different on RHEL and SLES. I found this as possible solution: %if…
Andreas Hubert
  • 381
  • 6
  • 18
3
votes
2 answers

How do i specify a requirement for a minimum version of openssl in rpm spec file?

The rpm spec file for my package looks like this: Requires:mysql-server >= 5.5.30, java >= 1.6, p7zip, openssl >= 1.0.2g I have an RHEL system where the OpenSSL version is this: [ag@rhel1]# openssl OpenSSL> version OpenSSL…
3
votes
1 answer

RPM spec file find installed version

I need to find the previous version of the package (if installed already) when installing rpm. My spec file as follows In POST %post if [ "$1" = "1" ]; then # Perform new install fi elif [ "$1" = "2" ]; then # Perform update # what I need is…
3
votes
1 answer

Relocated path in a postinstall script

I'm working on an RPM package that deploys files to /opt and /etc. In most of the cases it works perfectly, excepted that for a given environment, writing to /etc is not allowed .... So I used Relocations in order to deploy the /etc files in some…
devlearn
  • 1,725
  • 2
  • 17
  • 30
3
votes
2 answers

Sign RPM and DEB packages with SSL certificate

I'm new to SSL certificates and RPM build. I have purchased SSL certificate. I'm interested can I sign RPM package and DEB package with this certificate or this is not possible?
Peter Penzov
  • 1,126
  • 134
  • 430
  • 808
3
votes
2 answers

rpmbuild no such file or directory

I'm just learning making rpm packages for some custom builds of software that gets compiled from source (some legacy stuff needs this, so I'm trying to learn, as some packages can't use the latest versions), but hitting an error (I'm doing this in…
Ian
  • 13,724
  • 4
  • 52
  • 75
3
votes
2 answers

rpmbuild: common ownership of directories

Suppose packages I'm building for myprog1 and myprog2 are to install in /usr/lib/mysystem/myprog1/ and /usr/lib/mysystem/myprog2/ According to some distros' documentation, such in the case of OpenSUSE, both packages must own the shared directory.…
Display Name
  • 2,323
  • 1
  • 26
  • 45
3
votes
1 answer

Variables and escaping in RPM SPEC file macros?

I want to define a macro that will replace some placeholders in makefiles and systemd unit files with the results of RPM variables (macros). However, I don't know if the way expansion works will make the following behave correctly: %define…
Display Name
  • 2,323
  • 1
  • 26
  • 45
3
votes
1 answer

RPM build errors:Bad exit status from /var/tmp/rpm-tmp.32XJLX (%install)

Im trying to create a simple rpm package on centos 6.5.. But i cannot finish it as its giving me errors.. I have already followed these two threads.. Bad exit status from /var/tmp/rpm-tmp.b1DgAt (%build) and Bad exit status from…
Aravinda
  • 495
  • 1
  • 7
  • 17
3
votes
1 answer

Bad exit status from /var/tmp/rpm-tmp.b1DgAt (%build)

I am trying to compile Tizen source code. The compilation tools uses the rpm build environment. While compiling specific package I'm getting an rpm build issue "Bad exit status from /var/tmp/rpm-tmp.b1DgAt (%build)" Here is my build log Building CXX…
prince
  • 1,129
  • 1
  • 15
  • 38
3
votes
2 answers

"Package has no %description:" when packaging an rpm

I am packaging a very simple rpm of a redmine plugin, for internal use, and I am stuck with a "Package has no %description:" error. The .spec has a description and I couldn't find anything relevant on the inet. Here goes my .spec: codeName: …
Bruno9779
  • 1,551
  • 2
  • 14
  • 31
3
votes
1 answer

Unexpected RPM conflict on %config(noreplace) files

I'm creating my own RPM using rpmbuild. My RPM contains config files which should never get overridden, even if the RPM contains a new version of these config files. To archive this, I tagged these with %config(noreplace) /opt/mypackage/etc/* in…
MRalwasser
  • 15,605
  • 15
  • 101
  • 147