Issue
I am building a RPM package for a c++ application. The compilation and installation succeed. Then the the following command fails /usr/lib/rpm/check-buildroot
with the following error:
Found '/user/dfsdf/rpmbuild/BUILDROOT/vendor-xerces-c-3.1.3-3.1.3-1.x86_64' in installed files; aborting
I haven't found any documentation about this command. What does check-buildroot does?
Solution
Here is a pointer to a copy of the script. Because it is considered an "internal" part of rpmbuild
(in /usr/lib/rpm
, rather than /usr/bin
), there is no manual page for it.
However, it is known to people who troubleshoot problems building rpms.
The script checks for a common problem: when building an rpm, your package compiles and installs into a BUILDROOT
directory. If it is done properly, no trace of that directory name will remain in the final package. Occurrences of the actual installation directory, e.g., /usr/bin
, /usr/lib
, etc., are okay.
Further reading:
- rpmdevtools-5.3-1.el4 RPM for noarch describes the rpmdevtools and gives its changelog.
- pk's Tech Page discusses a change that a developer made based on the
check-buildroot
message. - check-buildroot failure is another example where it was used
- How do I safely remove a path string from a compiled library without corrupting the library? illustrates the real problem: getting good advice.
Answered By - Thomas Dickey Answer Checked By - Marilyn (WPSolving Volunteer)