Error in rpmbuild

Issues related to applications and software problems and general support
Post Reply
afewgoodman
Posts: 94
Joined: 2019/12/11 03:51:58

Error in rpmbuild

Post by afewgoodman » 2020/05/27 06:38:57

Hi

I am trying to create simple rpm with rpmbuild in CentOS 8.1. I can create rpm file in the CentOS 7.7 without issue, but CentOS 8.1.
I attached rpmbuild.tar which I used in the my home directory.

[bchoi@localhost SPECS]$ rpmbuild --sign -bb hello.spec
+ umask 022
+ cd /home/bchoi/rpmbuild/BUILD
+ cd /home/bchoi/rpmbuild/BUILD
+ rm -rf hello-1.0.0
+ /usr/bin/gzip -dc /home/bchoi/rpmbuild/SOURCES/hello-1.0.0.tar.gz
+ /usr/bin/tar -xof -
+ STATUS=0
+ '[' 0 -ne 0 ']'
+ cd hello-1.0.0
+ /usr/bin/chmod -Rf a+rX,u+w,g-w,o-w .
+ exit 0
+ umask 022
+ cd /home/bchoi/rpmbuild/BUILD
+ cd hello-1.0.0
+ exit 0
+ umask 022
+ cd /home/bchoi/rpmbuild/BUILD
+ '[' /home/bchoi/rpmbuild/BUILDROOT/hello-1.0.0-1.el8.x86_64 '!=' / ']'
+ rm -rf /home/bchoi/rpmbuild/BUILDROOT/hello-1.0.0-1.el8.x86_64
++ dirname /home/bchoi/rpmbuild/BUILDROOT/hello-1.0.0-1.el8.x86_64
+ mkdir -p /home/bchoi/rpmbuild/BUILDROOT
+ mkdir /home/bchoi/rpmbuild/BUILDROOT/hello-1.0.0-1.el8.x86_64
+ cd hello-1.0.0
+ rm -rf /home/bchoi/rpmbuild/BUILDROOT/hello-1.0.0-1.el8.x86_64
+ mkdir -p /home/bchoi/rpmbuild/BUILDROOT/hello-1.0.0-1.el8.x86_64/usr/local/bin
+ cp hello /home/bchoi/rpmbuild/BUILDROOT/hello-1.0.0-1.el8.x86_64/usr/local/bin
+ /usr/lib/rpm/find-debuginfo.sh -j2 --strict-build-id -m -i --build-id-seed 1.0.0-1.el8 --unique-debug-suffix -1.0.0-1.el8.x86_64 --unique-debug-src-base hello-1.0.0-1.el8.x86_64 --run-dwz --dwz-low-mem-die-limit 10000000 --dwz-max-die-limit 110000000 -S debugsourcefiles.list /home/bchoi/rpmbuild/BUILD/hello-1.0.0
+ /usr/lib/rpm/check-buildroot
+ /usr/lib/rpm/redhat/brp-ldconfig
/sbin/ldconfig: Warning: ignoring configuration file that cannot be opened: /etc/ld.so.conf: No such file or directory
+ /usr/lib/rpm/brp-compress
+ /usr/lib/rpm/brp-strip-static-archive /usr/bin/strip
+ /usr/lib/rpm/brp-python-bytecompile 1
+ /usr/lib/rpm/brp-python-hardlink
+ PYTHON3=/usr/libexec/platform-python
+ /usr/lib/rpm/redhat/brp-mangle-shebangs
error: Empty %files file /home/bchoi/rpmbuild/BUILD/hello-1.0.0/debugsourcefiles.list
Empty %files file /home/bchoi/rpmbuild/BUILD/hello-1.0.0/debugsourcefiles.list
rpmsign: no arguments given
[bchoi@localhost rpmbuild]$ pwd
/home/bchoi/rpmbuild
bchoi@localhost rpmbuild]$ tree
.
├── BUILD
│   └── hello-1.0.0
│   ├── debugfiles.list
│   ├── debuglinks.list
│   ├── debugsourcefiles.list
│   ├── debugsources.list
│   ├── elfbins.list
│   └── hello
├── BUILDROOT
│   └── hello-1.0.0-1.el8.x86_64
│   └── usr
│   └── local
│   └── bin
│   └── hello
├── RPMS
├── SOURCES
│   └── hello-1.0.0.tar.gz
├── SPECS
│   └── hello.spec
└── SRPMS

11 directories, 9 files
[bchoi@localhost rpmbuild]$

BR.
Attachments
rpmbuild.tar
(20 KiB) Downloaded 7 times

PryMar56
Posts: 6
Joined: 2020/04/20 14:56:31

Re: Error in rpmbuild

Post by PryMar56 » 2020/05/27 19:56:38

Hello,

the debuginfo shell script is looking for binary files, which there are none. Your output to */bin is a text file.
Maybe try at the top of your *.spec:

%define debug_package %{nil}

Should you use?:
BuildArch: noarch

I'm not sure.
Cheers,
PryMar56

afewgoodman
Posts: 94
Joined: 2019/12/11 03:51:58

Re: Error in rpmbuild

Post by afewgoodman » 2020/05/28 05:17:46

Hi

I resolve this issue by adding:

%global debug_package %{nil}

BR. :D

Post Reply

Return to “CentOS 8 - General Support”