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
-1
votes
1 answer

RPM dependency error during build phase of RPM spec file

My purpose is to distribute an already build libmy.so as installable library through RPM. Following is the snippet of the .spec file: %define elX el5 %define arch x86_64 Name: my_rpm Version: 1.0 Requires:
sudeep dasan
  • 81
  • 1
  • 6
-1
votes
1 answer

Spec file: File is packed by rpm, but not getting installed in right destination

Rpm -ql is listing the file but the file is not getting installed in the right location of target machine.
qwerty
  • 85
  • 2
  • 6
-1
votes
1 answer

How to install rpm in opt directory

I have created rpm for one of the package. I want to install that rpm in opt directory but by default it gets installed in root directory. I have tried using Prefix in spec file but it's not working. I have tried rpm -ivh --prefix=/opt as well but…
Chaitali
  • 87
  • 13
-1
votes
1 answer

Spec file for building .tar.gz as .rpm

I'd like to improve the distribution and versioning of a program I've inherited, which is currently distributed as a .tar.gz file, by building a .rpm for RHEL7 that just extracts the contents to /usr/bin/. The tarball is not small, consisting in…
Armaggedon
  • 399
  • 4
  • 14
-1
votes
1 answer

RPM package download to use a specific provider

I want to install package A which has a dependency of Package B, and Package B has 2 providers, When I install package A, can we specify in the spec file which provider to be used to download package B when it’s being installed as a dependency
Connor
  • 33
  • 1
  • 6
-1
votes
2 answers

Creating an rpm package that untars a file

I would like to create a rpm package that does the following: When setup: copies a script across into the rpm untars a file into the rpm When run: runs script.sh runs install file that is extracted into the rpm When the user runs the rpm it…
methuselah
  • 12,766
  • 47
  • 165
  • 315
-1
votes
1 answer

rpmbuild | specfile | %post | to execute a command or script as part of rpm install

How to execute some commands or scripts immediately after rpm installed and has to be run as part rpm install command. I wrote a spec file to take back up of some files within directory and tar them. When I install rpm tar would be copied on file…
Vaseem W
  • 69
  • 1
  • 7
-1
votes
1 answer

Adding Qt Dependencies to spec file in rpmbuild

I'm using Ubuntu 14.04 and I am updating the rpmbuild spec file of an application that now uses Qt. The packages that I need are the following: sudo apt-get build-essential sudo apt-get install mesa-common-dev -y sudo apt-get install…
Ankur Shah
  • 125
  • 12
-1
votes
1 answer

RPM directory that shouldn't get erased on upgrade

I am trying to build a rpm package for my application. And I would like to not remove a owned directory but keep adding files to it on upgrade. I will also like to remove the directory and all it files on uninstall. How do I achieve this?
-1
votes
1 answer

prefix and reloctable rpm package according to an other rpm prefix

I have install sample.rpm in /opt. I want samplw2.rpm find the relocation path of sample.rpm ad install itself in same place. is there any command or macro in spec file which check it befor installation or not?
-1
votes
1 answer

How to write a spec file to build an rpm package?

How can I write a spec file for building an rpm package, if I have only 4 tasks? Place my_file in /usr/local/mydir Place the configuration file in the rsyslog.d Place the logrotate file in logrptate.d Echo "something"…
mr. mistix
  • 11
  • 2
-1
votes
1 answer

rpm: how to allow w/o touching the old package seamless switch between the old and new packages w/ different name

In short, I want to implement seamless switch between the old and new packages with different name. However, I want to achieve this without touching the old package's spec file. Seamless switch includes that the other packages dependent on either…
Stephen
  • 609
  • 6
  • 12
-1
votes
1 answer

Understanding build section in an rpm spec file

In an rpm spec file, I see the following lines: %build ./configure make Can someone explain to me what each of the lines do?
LM10
  • 1,089
  • 4
  • 10
  • 16
-1
votes
2 answers

Replace one rpm pkg with another

Need help with rpm. I need to replace (for example) pkg-number-one with pkg-number-two. Provides in spec: pkg-number. How can I do replace one installed pkg with another? Or I must change something to do this?
-1
votes
1 answer

Rpmbuild permission denied

I am trying to to build an rpm for an application I have made. I have written the spec file and made an additional bash script to copy all the required files automatically into the rpmbuild directory structure i.e…
1 2 3
38
39