11/40 test-button-content FAIL 2.98s killed by signal 5 SIGTRAP >>> PYTHONDONTWRITEBYTECODE=yes MALLOC_PERTURB_=214 GTK_A11Y=none GSETTINGS_BACKEND=memory G_TEST_SRCDIR=/private/tmp/nix-build-libadwaita-1.3.2.drv-0/source/tests G_TEST_BUILDDIR=/private/tmp/nix-build-libadwaita-1.3.2.drv-0/source/build/tests G_DEBUG=gc-friendly,fatal-warnings MALLOC_CHECK_=2 /private/tmp/nix-build-libadwaita-1.3.2.drv-0/source/build/tests/test-button-content ✀ stdout: TAP version 13 # random seed: R02Se84baf70152144b0bb2dbf23cf179bf4 # GLib-GIO-DEBUG: _g_io_module_get_default: Found default implementation local (GLocalVfs) for ‘gio-vfs’ # GLib-GIO-DEBUG: _g_io_module_get_default: Found default implementation memory (GMemorySettingsBackend) for ‘gsettings-backend’ 1..5 # Start of Adwaita tests # Start of ButtonContent tests ok 1 /Adwaita/ButtonContent/icon_name ok 2 /Adwaita/ButtonContent/label ok 3 /Adwaita/ButtonContent/use_underline not ok /Adwaita/ButtonContent/style_class_button - Gdk-FATAL-CRITICAL: gdk_macos_monitor_get_workarea: assertion 'GDK_IS_MACOS_MONITOR (self)' failed Bail out! stderr: 2023-04-25 08:39:33.359 test-button-content[73233:738156655] XType: Using static font registry.
120 lines
2.8 KiB
Nix
120 lines
2.8 KiB
Nix
{ lib
|
|
, stdenv
|
|
, fetchFromGitLab
|
|
, gi-docgen
|
|
, meson
|
|
, ninja
|
|
, pkg-config
|
|
, sassc
|
|
, vala
|
|
, gobject-introspection
|
|
, fribidi
|
|
, glib
|
|
, gtk4
|
|
, gnome
|
|
, gsettings-desktop-schemas
|
|
, xvfb-run
|
|
, AppKit
|
|
, Foundation
|
|
}:
|
|
|
|
stdenv.mkDerivation rec {
|
|
pname = "libadwaita";
|
|
version = "1.3.2";
|
|
|
|
outputs = [ "out" "dev" "devdoc" ];
|
|
outputBin = "devdoc"; # demo app
|
|
|
|
src = fetchFromGitLab {
|
|
domain = "gitlab.gnome.org";
|
|
owner = "GNOME";
|
|
repo = "libadwaita";
|
|
rev = version;
|
|
hash = "sha256-9Qha8xN3lC/t5dQNYPbgMX6HAKgEk80pyycrd5MGYLo=";
|
|
};
|
|
|
|
depsBuildBuild = [
|
|
pkg-config
|
|
];
|
|
|
|
nativeBuildInputs = [
|
|
gi-docgen
|
|
meson
|
|
ninja
|
|
pkg-config
|
|
sassc
|
|
vala
|
|
gobject-introspection
|
|
];
|
|
|
|
mesonFlags = [
|
|
"-Dgtk_doc=true"
|
|
] ++ lib.optionals (!doCheck) [
|
|
"-Dtests=false"
|
|
];
|
|
|
|
buildInputs = [
|
|
fribidi
|
|
] ++ lib.optionals stdenv.isDarwin [
|
|
AppKit
|
|
Foundation
|
|
];
|
|
|
|
propagatedBuildInputs = [
|
|
gtk4
|
|
];
|
|
|
|
nativeCheckInputs = [
|
|
gnome.adwaita-icon-theme
|
|
] ++ lib.optionals (!stdenv.isDarwin) [
|
|
xvfb-run
|
|
];
|
|
|
|
# Tests had to be disabled on Darwin because test-button-content fails
|
|
#
|
|
# not ok /Adwaita/ButtonContent/style_class_button - Gdk-FATAL-CRITICAL:
|
|
# gdk_macos_monitor_get_workarea: assertion 'GDK_IS_MACOS_MONITOR (self)' failed
|
|
doCheck = !stdenv.isDarwin;
|
|
|
|
checkPhase = ''
|
|
runHook preCheck
|
|
|
|
testEnvironment=(
|
|
# Disable portal since we cannot run it in tests.
|
|
ADW_DISABLE_PORTAL=1
|
|
|
|
# AdwSettings needs to be initialized from “org.gnome.desktop.interface” GSettings schema when portal is not used for color scheme.
|
|
# It will not actually be used since the “color-scheme” key will only have been introduced in GNOME 42, falling back to detecting theme name.
|
|
# See adw_settings_constructed function in https://gitlab.gnome.org/GNOME/libadwaita/commit/60ec69f0a5d49cad8a6d79e4ecefd06dc6e3db12
|
|
"XDG_DATA_DIRS=${glib.getSchemaDataDirPath gsettings-desktop-schemas}"
|
|
|
|
# Tests need a cache directory
|
|
"HOME=$TMPDIR"
|
|
)
|
|
env "''${testEnvironment[@]}" ${lib.optionalString (!stdenv.isDarwin) "xvfb-run"} \
|
|
meson test --print-errorlogs
|
|
|
|
runHook postCheck
|
|
'';
|
|
|
|
postFixup = ''
|
|
# Cannot be in postInstall, otherwise _multioutDocs hook in preFixup will move right back.
|
|
moveToOutput "share/doc" "$devdoc"
|
|
'';
|
|
|
|
passthru = {
|
|
updateScript = gnome.updateScript {
|
|
packageName = pname;
|
|
};
|
|
};
|
|
|
|
meta = with lib; {
|
|
changelog = "https://gitlab.gnome.org/GNOME/libadwaita/-/blob/${src.rev}/NEWS";
|
|
description = "Library to help with developing UI for mobile devices using GTK/GNOME";
|
|
homepage = "https://gitlab.gnome.org/GNOME/libadwaita";
|
|
license = licenses.lgpl21Plus;
|
|
maintainers = teams.gnome.members ++ (with maintainers; [ dotlambda ]);
|
|
platforms = platforms.unix;
|
|
};
|
|
}
|