2021-04-05 15:23:46 +00:00
|
|
|
{ lib
|
|
|
|
, mkDerivation
|
2021-05-28 09:39:13 +00:00
|
|
|
, fetchurl
|
2021-04-05 15:23:46 +00:00
|
|
|
, cmake
|
|
|
|
, corrosion
|
|
|
|
, extra-cmake-modules
|
|
|
|
, kconfig
|
|
|
|
, kcoreaddons
|
|
|
|
, kdbusaddons
|
|
|
|
, ki18n
|
|
|
|
, kirigami2
|
|
|
|
, knotifications
|
|
|
|
, kpurpose
|
|
|
|
, kwindowsystem
|
2021-05-28 09:39:13 +00:00
|
|
|
, qtfeedback
|
2021-04-05 15:23:46 +00:00
|
|
|
, qtquickcontrols2
|
|
|
|
, qtwebengine
|
|
|
|
, rustPlatform
|
2021-10-28 06:52:43 +00:00
|
|
|
, srcs
|
|
|
|
|
|
|
|
# These must be updated in tandem with package updates.
|
|
|
|
, cargoShaForVersion ? "21.08"
|
|
|
|
, cargoSha256 ? "1pbvw9hdzn3i97mahdy9y6jnjsmwmjs3lxfz7q6r9r10i8swbkak"
|
2021-04-05 15:23:46 +00:00
|
|
|
}:
|
|
|
|
|
2021-10-28 06:52:43 +00:00
|
|
|
# Guard against incomplete updates.
|
|
|
|
# Values are provided as callPackage inputs to enable easier overrides through overlays.
|
|
|
|
if cargoShaForVersion != srcs.angelfish.version
|
|
|
|
then builtins.throw ''
|
|
|
|
angelfish package update is incomplete.
|
|
|
|
Hash for cargo dependencies is declared for version ${cargoShaForVersion}, but we're building ${srcs.angelfish.version}.
|
|
|
|
Update the cargoSha256 and cargoShaForVersion for angelfish.
|
|
|
|
'' else
|
|
|
|
|
2021-04-05 15:23:46 +00:00
|
|
|
mkDerivation rec {
|
|
|
|
pname = "angelfish";
|
|
|
|
|
|
|
|
cargoDeps = rustPlatform.fetchCargoTarball {
|
2021-10-28 06:52:43 +00:00
|
|
|
src = srcs.angelfish.src;
|
|
|
|
name = "${pname}-${srcs.angelfish.version}";
|
|
|
|
sha256 = cargoSha256;
|
2021-04-05 15:23:46 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
nativeBuildInputs = [
|
|
|
|
cmake
|
|
|
|
corrosion
|
|
|
|
extra-cmake-modules
|
|
|
|
] ++ (with rustPlatform; [
|
|
|
|
cargoSetupHook
|
|
|
|
rust.cargo
|
|
|
|
rust.rustc
|
|
|
|
]);
|
|
|
|
|
|
|
|
cmakeFlags = [
|
|
|
|
"-DRust_CARGO=${rustPlatform.rust.cargo}/bin/cargo"
|
|
|
|
];
|
|
|
|
|
|
|
|
buildInputs = [
|
|
|
|
kconfig
|
|
|
|
kcoreaddons
|
|
|
|
kdbusaddons
|
|
|
|
ki18n
|
|
|
|
kirigami2
|
|
|
|
knotifications
|
|
|
|
kpurpose
|
|
|
|
kwindowsystem
|
2021-05-28 09:39:13 +00:00
|
|
|
qtfeedback
|
2021-04-05 15:23:46 +00:00
|
|
|
qtquickcontrols2
|
|
|
|
qtwebengine
|
|
|
|
];
|
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Web browser for Plasma Mobile";
|
2021-09-23 15:35:13 +00:00
|
|
|
homepage = "https://invent.kde.org/plasma-mobile/angelfish";
|
2021-04-05 15:23:46 +00:00
|
|
|
license = licenses.gpl3Plus;
|
|
|
|
maintainers = with maintainers; [ dotlambda ];
|
|
|
|
};
|
|
|
|
}
|