Skip to content

Centos 7 source rpm build fails with /usr/bin ... conflicts with file from package filesystem... #132

@poleguy

Description

@poleguy

On Centos 7, I tried to build and then install the source rpm:

rpmbuild --rebuild rtptools-1.22-1.src.rpm
sudo yum localinstall ~/rpmbuild/RPMS/x86_64/rtptools-1.22-1.x86_64.rpm

But it errors out with:

Transaction check error:
file /usr/bin from install of rtptools-1.22-1.x86_64 conflicts with file from package filesystem-3.2-25.el7.x86_64

I'm not an expert, but I hacked in a fix:
rpm -i rtptools-1.22-1.src.rpm
cd ~/rpmbuild/SPECS/
emacs ~/rpmbuild/SPECS/rtptools-1.22.spec

Change the last few lines to, expicitly list the files that should be installed in /usr/bin:

%files
/usr/bin/multidump
/usr/bin/multiplay
/usr/bin/rtpdump
/usr/bin/rtpplay
/usr/bin/rtpsend
/usr/bin/rtptrans
%{_mandir}
#%{_bindir}

rpmbuild -bp rtptools-1.22.spec
rpmbuild -ba rtptools-1.22.spec

sudo yum localinstall ~/rpmbuild/RPMS/x86_64/rtptools-1.22-1.x86_64.rpm

Thanks to:
https://wiki.centos.org/HowTos/RebuildSRPM
https://stackoverflow.com/questions/38401664/rpmbuild-simple-copy-of-files
https://bugs.launchpad.net/galera/+bug/1199000
https://www.aelius.com/njh/posts/0002

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions