Questions tagged [rpmbuild]

rpmbuild command used to build rpms from rpm SPEC files

rpmbuild is the command used to build rpms from a rpm SPEC file.

854 questions
4
votes
1 answer

Extracting shell scripts from an RPM spec file for static analysis

I want to run ShellCheck on scripts embedded within a spec file that will run where the RPM is deployed. I have .spec snippets like, %setup -q cat > ./example.sh << EOF #!/bin/sh echo "example" EOF As well as hooks, %post #!/bin/sh echo…
artless noise
  • 21,212
  • 6
  • 68
  • 105
4
votes
1 answer

add a new file in existing RPM

I am modifying gnome-shell-3.8.xx.rpm package. I have created several patches for rpm and they are working fine. Now I want to add new source file in rpm but I am not able to find how to do it? For patches I have followed below approach: Download…
user746184
  • 105
  • 1
  • 10
4
votes
1 answer

How do I write an RPM macro which expands into a set of additional macros?

I am packaging an internal product which has dependencies on dozens of second level libraries. Ideally, these libraries would be created and managed as independent packages themselves, but our legacy build system makes this difficult. Instead, we…
Jeff W
  • 414
  • 5
  • 16
4
votes
1 answer

need a little help to create an rpm package for a nodejs app

I've prepared a build box following this instructions, I've search around and did a hello world rpm build, but still not sure what's the best way to go about packaging a bunch of js files (nodejs app). I'd like to : deploy the files to a…
nolimit
  • 814
  • 10
  • 19
4
votes
3 answers

Understanding how rpmbuild works

It seems that the RPM logic is quite different from what I know already and I am having some issues understanding the "RPM logic". For my work, I have to create a documentation on "How-to create a RPM package on Red Hat 5". I'm used to Debian and…
ereOn
  • 53,676
  • 39
  • 161
  • 238
4
votes
2 answers

Revert rpm installation on %post failed

In %post, I am running few tests that will validate the rpm installation. But If tests got failed or post script failed, How can I revert the rpm installation ?
Mohyt
  • 990
  • 2
  • 10
  • 26
4
votes
1 answer

RPM Spec file - how to get rpm package location in %pre script

I am working with RPM package manager for about a month now. Currently I want to use rpm -U to upgrade already existing content from previous RPM execution but I need to know the rpm package location on the file system. The only way I can think of…
even2be
  • 415
  • 1
  • 3
  • 7
4
votes
2 answers

Creating Python RPM

I have been reading about creating an RPM for Python 2.6.4. In this page: http://docs.python.org/distutils/builtdist.html it says you can create an RPM of the current Python using python setup.py bdist_rpm. The question's I have are: Do you have to…
chrisg
  • 40,337
  • 38
  • 86
  • 107
4
votes
1 answer

Getting error while building rpm - File not found by glob:

I am building rpm on RHEL-6/64 bit server. # rpmbuild -bb extras/rpm/neatx.spec RPM build errors: File not found by glob: /root/rpmbuild/BUILDROOT/neatx-0.1-1.el6.x86_64/usr/lib/python2.6/site-packages/neatx/* I do see the same…
user1149518
  • 101
  • 6
  • 13
4
votes
1 answer

Add extra file into the rpm building process

i have the source-code of an application that supports adding python plugins. i have written a python script and want to build a custom rpm that by-default includes my script. So that i do not have to additionally add it after the rpm…
erbdex
  • 1,899
  • 3
  • 22
  • 40
4
votes
2 answers

How to use the same CentOS to build RPMs for different versions?

I'm trying to use the same CentOS instance to get me to build packages for both versions 5 and 6. Until now everything was working OK, but I think an update in the building instance (6) now includes some dependencies that seems they're not available…
rpvilao
  • 1,116
  • 2
  • 14
  • 31
4
votes
2 answers

Conditionally include file in an RPM

How can I conditionally include a file in an .rpm based on a define _foobar being set or not? The define _foobar would contain the absolute path inside the build root. The file is there. According to the documentation, I expected the following to…
0xC0000022L
  • 20,597
  • 9
  • 86
  • 152
4
votes
2 answers

Is it possible to build an rpm package without making a tar.gz archive?

For me making a tar.gz archive is excess, because i export source code from svn. Perhaps it is possible to make rpm archive without automatic unpacking of archive? (Perhaps it is possible just to copy files from source folder to build or something…
avasin
  • 9,186
  • 18
  • 80
  • 127
4
votes
3 answers

rpmbuild failing error: Installed (but unpackaged) file(s) found:

I looked around but none of the answers to this same error message worked in my simple package... I am building the rpm using rpmbuild on Redhat ES 6 and no matter what I have done in my spec file I get the same results. Thank you in advance for…
Todd McGuinness
  • 269
  • 2
  • 5
  • 11
4
votes
1 answer

Cannot change permissions when running rpmbuild

Currently I'm trying to change an spec file extracted from a nagios rpm package to create my own spec file. When trying to build to rpm I'm getting the following error: make[1]: Entering directory /home/mockbuild/rpmbuild/BUILD/nagios-1/base'…
Nicholas
  • 1,189
  • 4
  • 20
  • 40