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
0
votes
0 answers

Creating rpm postinstall script with different behavior for OBS, GBS and target installation

I need to create rpm package, that when installed into OBS environment, GBS environment, and on target device will execute different postinstall scripts. I'm looking for code in spec file like this: %post if ### check for OBS env ### then…
0
votes
0 answers

python-setuptools : How to overwrite files of other package?

The query I have is a simple one :) But I am struggling a bit with the answer Problem Statement :- I have a python package which builds and installs using python-setuptools. I need to include 3 python files into the same package and create an RPM…
mittal
  • 915
  • 10
  • 29
0
votes
2 answers

How to prevent an RPM from being treated as a multilib package

Changing a binary (.so) in an RPM package from 32bit to 64bit seems to result in rpm treating it as a multilib package. The consequence is that the old version of the package is not uninstalled when the new version is installed using "rpm -U". This…
0
votes
1 answer

RPM upgrade does not uninstall previous version of the package installed

I have two builds (Build1 and Build2) of the current version of an rpm package. I use 'rpm -U' (rpm upgrade) to install it. Build1 works as expected, where the previous version is uninstalled after the new version is installed. Build2 does not…
0
votes
1 answer

build two versions of RPMs in one rpm build

what I'm trying to do is to create two RPMs with two versions under one rpmbuild. I'm using the same source code to build those RPMs but the %post section in spec file behaves differently between two versions. I managed to build two RPMs with…
Tommy.Z
  • 14
  • 4
0
votes
1 answer

RPM: include a set of constants

So I already know how to define macros and include these in my main spec file. However, I also want to be able to include a set of constants; something like this: hostnames.spec %define HOST1 host1 %define HOST2 host2 ... main.spec %include…
Daniel Szalay
  • 4,041
  • 12
  • 57
  • 103
0
votes
1 answer

Is it safe to verify the RPM that has just been installed from a %posttrans?

I know this is non-standard, but it's intended to overcome a short term problem with a proprietary distribution. Because there are dependencies that are unique to our deployment systems, we have to compile some libraries from the %post. Because…
Craig
  • 4,268
  • 4
  • 36
  • 53
0
votes
1 answer

Creating an RPM package

I want to create an RPM package that has dependency on R. Question: How to list that in the spec file i.e. install all the R-dependencies and then go through the latest commands ? Also, to install the R, I need to run "rpm -Uvh…
Jason
  • 2,246
  • 6
  • 34
  • 53
0
votes
0 answers

nss-3.14.1-3.fc16.src.rpm build fails with error: test suite returned failure(s)

I am trying to build nss-3.14.1-3.fc16.src.rpm on my fedora-16 with below command: rpmbuild -ba nss.spec and ending up with below error: Tests summary: Passed: 6398 Failed: 9 Failed with core: 0 Unknown status: 0 cd…
0
votes
1 answer

RPM to invoke browser post installation

I am creating an RPM installer for centos 6.5, After installation i want the RPM to invoke the browser and show the installation report. This installation report shows the details of how the installation went. Including errors and warnings that…
Avinash Nair
  • 1,984
  • 2
  • 13
  • 17
0
votes
1 answer

RPM spec files with rpmbuild can have errors

Every time I try to make my own spec file and build it, I get an error like this: many lines on the screen of the build starting... + '[' 0 -ne 0 ']' + cd foobar /var/tmp/rpm-tmp.dN7L6s: line 35: cd: foobar: No such file or directory error: Bad…
Propulsion
  • 503
  • 2
  • 4
  • 14
0
votes
1 answer

RPMs size differs, but their contents look same

I have 2 rpms which are packaged at different times with same content. But there is a slight size difference (less than 10 bytes) between these two rpms. I also tried extracting these rpms to verify its content using command "rpm2cpio ../myrpm.rpm …
Jegan
  • 188
  • 3
  • 15
0
votes
1 answer

How to make a very simple RPM for RedHat

I'm trying to make a very simple RPM installation file for RedHat. This file must only put my binary to /usr/bin and my configuration file to /usr/etc. I don't want to put my sources on the RPM.
nerixm
  • 1
0
votes
1 answer

rpm command giving error while asking for information

I have one package VAB-6.1.0.500-0.x86_64. When I installed this on machine and run command rpm -q VAB, it is showing package VAB not installed . And if i run command rpm -q VAB- it is showing VAB-6.1.0.500-0.x86_64 which is expected ? Why so? Is…
Niraj Nandane
  • 1,318
  • 1
  • 13
  • 24
0
votes
3 answers

rpm spec file skeleton to real spec file

The aim is to have skeleton spec fun.spec.skel file which contains placeholders for Version, Release and that kind of things. For the sake of simplicity I try to make a build target which updates those variables such that I transform the…
drahnr
  • 6,782
  • 5
  • 48
  • 75