LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (https://www.linuxquestions.org/questions/linux-software-2/)
-   -   Rpm build fails (https://www.linuxquestions.org/questions/linux-software-2/rpm-build-fails-769159/)

jerel4565 11-14-2009 02:05 PM

Rpm build fails
 
Hello all,

I have built a rpm but every I run rpmbuild -ba spec I get the following errors.
Code:

Processing files: NetbackupClient-6.5-1
error: File not found: /tmp/NetbackupClient-buildroot/usr/openv
error: File not found: /tmp/NetbackupClient-buildroot/etc/xinetd.d/bpcd
error: File not found: /tmp/NetbackupClient-buildroot/etc/xinetd.d/bpjava-msvc
error: File not found: /tmp/NetbackupClient-buildroot/etc/xinetd.d/vnetd
error: File not found: /tmp/NetbackupClient-buildroot/etc/xinetd.d/vopied
error: File not found: /tmp/NetbackupClient-buildroot/etc/rc.d/rc2.d/S95nbclient
error: File not found: /tmp/NetbackupClient-buildroot/etc/rc.d/rc3.d/S95nbclient
error: File not found: /tmp/NetbackupClient-buildroot/etc/rc.d/rc5.d/S95nbclient
error: File not found: /tmp/NetbackupClient-buildroot/etc/rc.d/rc0.d/K01nbclient
error: File not found: /tmp/NetbackupClient-buildroot/etc/rc.d/rc1.d/K01nbclient
error: File not found: /tmp/NetbackupClient-buildroot/etc/rc.d/rc6.d/K01nbclient
Checking for unpackaged file(s): /usr/lib/rpm/check-files /tmp/NetbackupClient-buildroot


RPM build errors:
    File not found: /tmp/NetbackupClient-buildroot/usr/openv
    File not found: /tmp/NetbackupClient-buildroot/etc/xinetd.d/bpcd
    File not found: /tmp/NetbackupClient-buildroot/etc/xinetd.d/bpjava-msvc
    File not found: /tmp/NetbackupClient-buildroot/etc/xinetd.d/vnetd
    File not found: /tmp/NetbackupClient-buildroot/etc/xinetd.d/vopied
    File not found: /tmp/NetbackupClient-buildroot/etc/rc.d/rc2.d/S95nbclient
    File not found: /tmp/NetbackupClient-buildroot/etc/rc.d/rc3.d/S95nbclient
    File not found: /tmp/NetbackupClient-buildroot/etc/rc.d/rc5.d/S95nbclient
    File not found: /tmp/NetbackupClient-buildroot/etc/rc.d/rc0.d/K01nbclient
    File not found: /tmp/NetbackupClient-buildroot/etc/rc.d/rc1.d/K01nbclient
    File not found: /tmp/NetbackupClient-buildroot/etc/rc.d/rc6.d/K01nbclient

Here is my spec file:
Code:

Summary: Installs NetBackup Client.
Name: NetbackupClient
Version: 6.5
Release: 1
License:
Group: System Environment/Base
Requires: xinetd
Source: http://ip/pub/NetBackup_6.5_CLIENTS2.tar.gz
Prefix: /usr/openv
Packager: me
BuildRoot: /tmp/%{name}-buildroot

%description
This rpm will install the NetBackup Client software.

%prep
%setup -q -n  NB_65_CLIENTS2_20070723

%build

%install
./install

%clean
rm -rf $RPM_BUILD_ROOT

%files
%defattr(-,root,root,-)
%{_prefix}/openv/
%{_sysconfdir}/xinetd.d/bpcd
%{_sysconfdir}/xinetd.d/bpjava-msvc
%{_sysconfdir}/xinetd.d/vnetd
%{_sysconfdir}/xinetd.d/vopied
%{_sysconfdir}/rc.d/rc2.d/S95nbclient
%{_sysconfdir}/rc.d/rc3.d/S95nbclient
%{_sysconfdir}/rc.d/rc5.d/S95nbclient
%{_sysconfdir}/rc.d/rc0.d/K01nbclient
%{_sysconfdir}/rc.d/rc1.d/K01nbclient
%{_sysconfdir}/rc.d/rc6.d/K01nbclient

%post
service xinetd start
service nbclient start


Any help would be greatly appreciated.

unSpawn 11-15-2009 06:25 AM

First of all it's good you included the actual .spec file but since %configure and %install may be configured on the fly to take different values it would be good to also attach the build log.

Quote:

Originally Posted by jerel4565 (Post 3757149)
Code:

Processing files: NetbackupClient-6.5-1
error: File not found: /tmp/NetbackupClient-buildroot/usr/openv
(..)
RPM build errors:
    File not found: /tmp/NetbackupClient-buildroot/etc/rc.d/rc2.d/S95nbclient
(..)


- Here 'bpcd' needs to be "/etc/xinetd.d/bpcd", so maybe you need to explicitly make the .spec's %configure take sysconfigdir as being /etc instead of "(${RPM_BUILDROOT}/)%{_prefix}/openv/".
- Any incorporation of "rc.d/rc?.d/{K,S}.*nbclient" type symbolic links or files in %files can be avoided if /etc/rc.d/init.d/nbclient contains the right chkconfig line. Then a %post using 'chkconfig --add' will populate your SysV initscripts tree with the right symbolic links.
* If you're building RPM's as root user please move to using an unprivileged user account instead.

knudfl 11-15-2009 04:55 PM

Ref # 2 : Setting up 'an unprivileged user account' :

http://www.linuxquestions.org/questi...5.1-766486/#10
> > post # 10

http://www.linuxquestions.org/questi...6/highlight#13
> > post # 13
.....


All times are GMT -5. The time now is 01:02 PM.