iced-template: remove commonArgs

these are mostly useful for crane,
and were only acting as unnecessary complexity here
This commit is contained in:
electria 2026-08-22 17:56:48 -07:00
commit 9b308d6b54
Signed by: electria
SSH key fingerprint: SHA256:8LlB3ucPbBHqozqkhsNbaV5oG3SlzzqUj8FZDL6IPQs

View file

@ -33,24 +33,6 @@
wayland
];
commonArgs = {
# all that's needed for artifacts and checks
nativeBuildInputs = with pkgs; [
# pkg-config
];
buildInputs = with pkgs; [
];
strictDeps = true;
__structuredAttrs = true;
src = lib.sourceFilesBySuffices ./. [
"Cargo.toml"
"Cargo.lock"
".rs"
];
};
crate =
let
desktopItem = pkgs.makeDesktopItem {
@ -59,30 +41,35 @@
exec = name;
};
in
pkgs.rustPlatform.buildRustPackage (
commonArgs
// {
pkgs.rustPlatform.buildRustPackage rec {
inherit name;
cargoLock.lockFile = "${commonArgs.src}/Cargo.lock";
nativeBuildInputs = commonArgs.nativeBuildInputs ++ [
pkgs.autoPatchelfHook
src = lib.sourceFilesBySuffices ./. [
"Cargo.toml"
"Cargo.lock"
".rs"
];
cargoLock.lockFile = "${src}/Cargo.lock";
buildInputs = commonArgs.buildInputs ++ [
pkgs.libgcc
nativeBuildInputs = with pkgs; [
autoPatchelfHook
];
buildInputs = with pkgs; [
libgcc
];
runtimeDependencies = dlDeps;
doCheck = false;
postFixup = ''
mkdir -p "$out/share/applications"
ln -s "${desktopItem}"/share/applications/* "$out/share/applications/"
'';
}
);
doCheck = false;
strictDeps = true;
__structuredAttrs = true;
};
in
{
packages.default = crate;