test
Rev openSUSE:Tools/406 Md5 06eb2b0e65dd58a20ff66b81eebaa5eb 2020-02-03 09:48:14 adrianSuSE None
This commit is contained in:
parent
ec2c6e65f1
commit
71cdf2da04
12
build.spec
12
build.spec
@ -50,11 +50,13 @@ BuildRequires: tar
|
||||
%if 0%{?fedora}
|
||||
Requires: perl-MD5
|
||||
Requires: perl-TimeDate
|
||||
BuildRequires: perl-TimeDate
|
||||
%endif
|
||||
Conflicts: bsdtar < 2.5.5
|
||||
%if 0%{?suse_version} > 1000
|
||||
# None of them are actually required for core features.
|
||||
# Perl helper scripts use them.
|
||||
BuildRequires: perl(Date::Parse)
|
||||
Recommends: perl(Date::Language)
|
||||
Recommends: perl(Date::Parse)
|
||||
Recommends: perl(LWP::UserAgent)
|
||||
@ -199,12 +201,16 @@ test -e baselibs_global.conf || exit 1
|
||||
|
||||
%check
|
||||
for i in build build-* ; do bash -n $i || exit 1 ; done
|
||||
|
||||
# expect unit tests
|
||||
LANG=C prove -I. -v t/*.t
|
||||
|
||||
if [ `whoami` != "root" ]; then
|
||||
echo "WARNING: Not building as root, tests did not run!"
|
||||
echo "WARNING: Not building as root, build test did not run!"
|
||||
exit 0
|
||||
fi
|
||||
if [ ! -f "%{buildroot}/usr/lib/build/configs/default.conf" ]; then
|
||||
echo "WARNING: No default config, tests did not run!"
|
||||
echo "WARNING: No default config, build test did not run!"
|
||||
exit 0
|
||||
fi
|
||||
# get back the default.conf link
|
||||
@ -213,6 +219,8 @@ cp -av %{buildroot}/usr/lib/build/configs/default.conf configs/
|
||||
export BUILD_IGNORE_2ND_STAGE=1
|
||||
# use our own build code
|
||||
export BUILD_DIR=$PWD
|
||||
|
||||
# simple chroot build test
|
||||
cd test
|
||||
# target is autodetected
|
||||
%if 0%{?sles_version}
|
||||
|
Loading…
Reference in New Issue
Block a user