19 stdenv.mkDerivation (finalAttrs: {
23 src = fetchFromGitHub {
26 rev = "v${finalAttrs.version}";
27 fetchSubmodules = true;
28 hash = "sha256-Fl8YV7yBW9dmcpcHCDVvkAzICTopNb4zKziDkR6NEwU=";
34 ] ++ lib.optionals stdenv.isLinux [
44 ] ++ lib.optionals stdenv.isLinux [
45 libffi # needed for wayland
56 (lib.cmakeBool "PLATFORM_DESKTOP" true)
57 (lib.cmakeBool "INSTALL" true)
58 (lib.cmakeBool "GLFW_BUILD_WAYLAND" stdenv.isLinux)
59 (lib.cmakeBool "GLFW_BUILD_X11" stdenv.isLinux)
60 # Otherwise cpr cmake will try to download zlib
61 (lib.cmakeBool "CPR_FORCE_USE_SYSTEM_CURL" true)
65 description = "Third-party Bilibili client with a switch-like UI";
66 homepage = "https://xfangfang.github.io/wiliwili";
67 # https://github.com/xfangfang/wiliwili/discussions/355
68 license = lib.licenses.gpl3Only;
69 mainProgram = "wiliwili";
70 maintainers = with lib.maintainers; [ aleksana ];
71 platforms = with lib.platforms; unix ++ windows;
72 # Testing on darwin was blocked due to broken swift
73 # buildInputs should still need some tweaking, but can't be sure
74 badPlatforms = lib.platforms.darwin;