Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I am trying to build an rpm using the rpmbuild tool. I have source code which build binaries around 30 GB. This software for which I am making the rpm has dozens of executables. When I copy only the binaries of a single executable (Eg. init) my rpm builds successfully. But when I dump the entire build to the rpm, rpmbuild does everything but gives a seg fault in the end.

Here is my spec file:

# This is a sample spec file for wget

%define _topdir     /root/mywget
%define name            source 
%define release     1
%define version     1.12
%define _builddir     /root/mywget/BUILD/glenlivet
%define _buildrootdir /root/mywget/BUILDROOT
%define _buildroot /root/mywget/BUILDROOT
%define _sourcedir    /root/mywget/SOURCES

BuildRoot:  %{_buildroot}
Summary:        GNU source
License:        GPL
Name:           %{name}
Version:        %{version}
Release:        %{release}
Source:         %{name}-%{version}.tar.gz
Prefix:         /usr
Group:          Development/Tools

%description
The GNU sample program downloads files from the Internet using the command-line.

%prep
%setup -q -n glenlivet

%build
cd %{_builddir}
make all

%install
rm -rf %{_buildrootdir}
mkdir -p %{_buildrootdir}/bin
cp -p -r %{_builddir}/build/obj-x64/* %{_buildrootdir}/bin/

%files
%defattr(-,root,root)
/bin/*

If I only copy some of the binaries (let say one utility and its dependent binaries) it works fine. But when I try to copy the entire build, I get a seg fault. I get the seg fault after rpmbuild has executed these sections:

%prep
%build
%install

rpmbuild also processes my source file.

Processing files: source-1.12-1
Finding Provides: 
Finding Requires:
Finding Supplements:
Provides:......
Requires:......
Checking for unpackaged file(s):/ usr/lib/rpm/check-files /root/mywget/BUILDROOT
Checking for unpackaged file(s):/ usr/lib/rpm/check-files /root/mywget/BUILDROOT
Segmentation fault

Any clue what wrong is going on or where does rpmbuild fails? Thanks in advance

share|improve this question

1 Answer 1

RPM versions up to 4.4.x have a 2GB package size cap because it requires 64-bit integer type support in headers. Starting with 4.6, this package size cap is removed. There is still a 4GB limit on individual files within packages due to cpio format limitations.

Reference Link

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.