From ae31cfbc3de561ce1b2b960ebcc9a91223f35fc9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C3=89rico=20Rolim?= Date: Thu, 11 Feb 2021 03:11:18 -0300 Subject: [PATCH] srcpkgs/: move packages checking XBPS_CHECK_PKGS to use make_check. --- srcpkgs/R/template | 7 +++---- srcpkgs/efl/template | 7 +++---- srcpkgs/ell/template | 7 +++---- srcpkgs/elogind/template | 9 ++------- srcpkgs/ghdl/template | 4 +--- srcpkgs/igt-gpu-tools/template | 2 ++ srcpkgs/nautilus/template | 11 +++-------- srcpkgs/openvswitch/template | 9 ++------- srcpkgs/squid/template | 6 ++---- srcpkgs/wine/template | 7 +++---- 10 files changed, 24 insertions(+), 45 deletions(-) diff --git a/srcpkgs/R/template b/srcpkgs/R/template index 1ac1b9667a2..e40cefabcd4 100644 --- a/srcpkgs/R/template +++ b/srcpkgs/R/template @@ -26,6 +26,7 @@ distfiles="https://cran.r-project.org/src/base/R-4/${pkgname}-${version}.tar.gz" checksum=09983a8a78d5fb6bc45d27b1c55f9ba5265f78fa54a55c13ae691f87c5bb9e0d nocross=yes shlib_provides="libR.so" +make_check=extended build_options="openblas" @@ -42,10 +43,8 @@ pre_configure() { export R_PDFVIEWER=/usr/bin/xdg-open } -do_check() { - if [ "${XBPS_CHECK_PKGS}" = full ]; then - ( TEST_MC_CORES=${XBPS_MAKEJOBS} make check ) - fi +pre_check() { + export TEST_MC_CORES=${XBPS_MAKEJOBS} } post_install() { diff --git a/srcpkgs/efl/template b/srcpkgs/efl/template index efb3019a969..da39b6a38bb 100644 --- a/srcpkgs/efl/template +++ b/srcpkgs/efl/template @@ -55,6 +55,7 @@ homepage="https://enlightenment.org" changelog="https://git.enlightenment.org/core/efl.git/plain/NEWS" distfiles="https://download.enlightenment.org/rel/libs/efl/efl-${version}.tar.xz" checksum=351ca0211ca000234527a503585f039f985607ec9439e34b49d8b8bbf35a7e6b +make_check=extended if [ "$XBPS_CHECK_PKGS" ]; then configure_args+=" -Dbuild-tests=true" @@ -107,10 +108,8 @@ case "$XBPS_TARGET_MACHINE" in esac do_check() { - if [ "$XBPS_CHECK_PKGS" = full ]; then - # FIXME: tests fail in weird places - xvfb-run dbus-run-session ninja -C build test - fi + # FIXME: tests fail in weird places + xvfb-run dbus-run-session ninja -C build test } post_install() { diff --git a/srcpkgs/ell/template b/srcpkgs/ell/template index a221184180e..19634a337aa 100644 --- a/srcpkgs/ell/template +++ b/srcpkgs/ell/template @@ -13,12 +13,11 @@ license="GPL-2.0-only" homepage="https://01.org/ell" distfiles="${KERNEL_SITE}/libs/${pkgname}/${pkgname}-${version}.tar.xz" checksum=2f99e743a235b1c834b19112e4e0283d02da93b863899381466cde47bf159cf6 +# tests depend on kernel features +make_check=extended do_check() { - if [ "$XBPS_CHECK_PKGS" = full]; then - # tests depend on kernel features - dbus-run-session make check - fi + dbus-run-session make check } ell-devel_package() { diff --git a/srcpkgs/elogind/template b/srcpkgs/elogind/template index 228a35ad87f..d4bfe499bc5 100644 --- a/srcpkgs/elogind/template +++ b/srcpkgs/elogind/template @@ -19,6 +19,8 @@ homepage="https://github.com/elogind/elogind" distfiles="https://github.com/${pkgname}/${pkgname}/archive/v${version}.tar.gz" checksum=dd2fcf22a89a078cad22e633d2f14a4cc9f4a9c8bae25c0e39fc4aec3e273bc9 conf_files="/etc/elogind/*.conf" +# tests fail differently due to containerization and kernel features +make_check=extended if [ "$XBPS_TARGET_LIBC" = "musl" ]; then configure_args+=" -Dutmp=false" @@ -38,13 +40,6 @@ pre_check() { echo 'dummy-file' > /etc/os-release } -do_check() { - if [ "$XBPS_CHECK_PKGS" = full ]; then - # tests fail differently due to containerization and kernel features - make check - fi -} - post_check() { rm -f /etc/machine-id /etc/os-release } diff --git a/srcpkgs/ghdl/template b/srcpkgs/ghdl/template index 4229ca3d563..1a1540e8fc5 100644 --- a/srcpkgs/ghdl/template +++ b/srcpkgs/ghdl/template @@ -19,6 +19,7 @@ distfiles="https://github.com/ghdl/ghdl/archive/v${version}.tar.gz" checksum=3008616201cc3b0b596872e4ad59d8bc36e6ee3ff798bdce066828fbdad041e4 nocross=yes patch_args="-Np1" +make_check=extended build_options="llvm mcode" build_options_default="llvm" @@ -107,9 +108,6 @@ do_check() { # this indicates a bug in the testsuite : && return 0 - # the testsuite is big and long even when it runs - [ "$XBPS_CHECK_PKGS" != full ] && return 0 - # need a temporary installation for testsuite run so that ghdl1 is found for variant in ${build_options_default}; do cd ${wrksrc}/build_${variant} diff --git a/srcpkgs/igt-gpu-tools/template b/srcpkgs/igt-gpu-tools/template index 46f941f50a8..2588c2ddff5 100644 --- a/srcpkgs/igt-gpu-tools/template +++ b/srcpkgs/igt-gpu-tools/template @@ -15,6 +15,8 @@ license="MIT" homepage="https://gitlab.freedesktop.org/drm/igt-gpu-tools" distfiles="${XORG_SITE}/app/${pkgname}-${version}.tar.xz" checksum=40454d8f0484ea2477862007398a08eef78a6c252c4defce1c934548593fdd11 +# tests don't behave in containers +make_check=extended lib32disabled=yes archs="i686* x86_64*" diff --git a/srcpkgs/nautilus/template b/srcpkgs/nautilus/template index 67fac293ac2..e6d843249a6 100644 --- a/srcpkgs/nautilus/template +++ b/srcpkgs/nautilus/template @@ -18,6 +18,9 @@ license="GPL-2.0-or-later, LGPL-2.1-or-later" homepage="https://wiki.gnome.org/Nautilus" distfiles="${GNOME_SITE}/${pkgname}/${version::4}/${pkgname}-${version}.tar.xz" checksum=d09ceb54c274e50084c8757a73cd247fee5bde02a0b0d13733b0006d1a4196a6 +# tests timeout: +# 11/11 test-nautilus-search-engine-tracker TIMEOUT 480.00s +make_check=extended if [ "$CROSS_BUILD" ]; then # tests try to use tracker-sandbox from the wrong path, because of some confusion with libdir: @@ -28,14 +31,6 @@ fi build_options="gir" build_options_default="gir" -do_check() { - if [ "$XBPS_CHECK_PKGS" = full ]; then - # tests timeout: - # 11/11 test-nautilus-search-engine-tracker TIMEOUT 480.00s - ninja -C builddir test - fi -} - libnautilus_package() { short_desc+=" - shared libraries" pkg_install() { diff --git a/srcpkgs/openvswitch/template b/srcpkgs/openvswitch/template index 65f816ea9a2..e158dd8b0a5 100644 --- a/srcpkgs/openvswitch/template +++ b/srcpkgs/openvswitch/template @@ -18,13 +18,8 @@ checksum=65f420f954e250d895fb2db22a132e1cb560bc5e2b9051e834511348108e597a python_version=3 _completiondir="/usr/share/bash-completion/completions" make_install_args+=" completiondir=${_completiondir}" - -do_check() { - if [ "$XBPS_CHECK_PKGS" = full ]; then - # test can hang in containers - make check ${makejobs} - fi -} +# test can hang in containers +make_check=extended post_install() { for cmd in ovs-appctl ovs-vsctl; do diff --git a/srcpkgs/squid/template b/srcpkgs/squid/template index 319ac86c9aa..24a9833cc44 100644 --- a/srcpkgs/squid/template +++ b/srcpkgs/squid/template @@ -67,16 +67,14 @@ homepage="http://www.squid-cache.org/" distfiles="http://www.squid-cache.org/Versions/v4/squid-${version}.tar.xz" checksum=f1097daa6434897c159bc100978b51347c0339041610845d0afa128151729ffc system_accounts="squid" +# squid-conf-tests requires a squid user in the system +make_check=no if [ "$XBPS_TARGET_NO_ATOMIC8" ]; then makedepends+=" libatomic-devel" LDFLAGS+=" -latomic" fi -do_check() { - : # squid-conf-tests requires a squid user in the system -} - post_install() { chmod u+s \ ${DESTDIR}/usr/libexec/squid/basic_ncsa_auth \ diff --git a/srcpkgs/wine/template b/srcpkgs/wine/template index b80e73bbdc9..fff56aa1202 100644 --- a/srcpkgs/wine/template +++ b/srcpkgs/wine/template @@ -48,6 +48,7 @@ makedepends="gettext-devel lcms2-devel zlib-devel ncurses-devel depends="libXi libXinerama libXcomposite libXcursor libOSMesa desktop-file-utils hicolor-icon-theme liberation-fonts-ttf gnutls wine-common>=${version}_${revision} libwine>=${version}_${revision}" +make_check=extended case $XBPS_TARGET_MACHINE in x86_64*) configure_args+=" --enable-win64 --libdir=/usr/lib" @@ -85,10 +86,8 @@ pre_build() { } do_check() { - if [ "$XBPS_CHECK_PKGS" = full ]; then - msg_warn "This testsuite might hang indefinitely\n" - make check - fi + msg_warn "This testsuite might hang indefinitely\n" + make check } post_install() {