Compare commits
No commits in common. "82b0e8f4eef684cd7c3d6ef11d9bc6d2c991792b" and "a002c1476dfb2977d91f6de677873c1050f0a09c" have entirely different histories.
82b0e8f4ee
...
a002c1476d
2 changed files with 4 additions and 141 deletions
|
@ -45,10 +45,11 @@
|
||||||
htop
|
htop
|
||||||
ncmpcpp
|
ncmpcpp
|
||||||
usbutils # lsusb etc.
|
usbutils # lsusb etc.
|
||||||
file exiftool binwalk
|
file
|
||||||
|
binwalk
|
||||||
shellcheck
|
shellcheck
|
||||||
|
|
||||||
#wine
|
wine
|
||||||
wineWowPackages.stable
|
wineWowPackages.stable
|
||||||
winePackages.fonts
|
winePackages.fonts
|
||||||
pavucontrol
|
pavucontrol
|
||||||
|
@ -81,8 +82,7 @@
|
||||||
tdesktop
|
tdesktop
|
||||||
horizon-eda
|
horizon-eda
|
||||||
kicad-small
|
kicad-small
|
||||||
# cura
|
cura
|
||||||
(pkgs.callPackage ../packages/cura-appimage.nix {})
|
|
||||||
pulseview
|
pulseview
|
||||||
nextcloud-client
|
nextcloud-client
|
||||||
];
|
];
|
||||||
|
@ -93,8 +93,6 @@
|
||||||
system.extraDependencies = with pkgs; [
|
system.extraDependencies = with pkgs; [
|
||||||
# For various development environments
|
# For various development environments
|
||||||
gcc-arm-embedded
|
gcc-arm-embedded
|
||||||
pkgsCross.arm-embedded.buildPackages.gcc
|
|
||||||
pkgsCross.riscv32-embedded.buildPackages.gcc
|
|
||||||
gnumake
|
gnumake
|
||||||
];
|
];
|
||||||
|
|
||||||
|
@ -192,10 +190,6 @@
|
||||||
size = 16 * 1024;
|
size = 16 * 1024;
|
||||||
}];
|
}];
|
||||||
|
|
||||||
environment.variables = {
|
|
||||||
FREETYPE_PROPERTIES = "cff:no-stem-darkening=0 autofitter:no-stem-darkening=0 type1:no-stem-darkening=0 t1cid:no-stem-darkening=0";
|
|
||||||
};
|
|
||||||
|
|
||||||
# This value determines the NixOS release from which the default
|
# This value determines the NixOS release from which the default
|
||||||
# settings for stateful data, like file locations and database versions
|
# settings for stateful data, like file locations and database versions
|
||||||
# on your system were taken. It‘s perfectly fine and recommended to leave
|
# on your system were taken. It‘s perfectly fine and recommended to leave
|
||||||
|
|
|
@ -1,131 +0,0 @@
|
||||||
{
|
|
||||||
lib,
|
|
||||||
stdenv,
|
|
||||||
stdenvNoCC,
|
|
||||||
fetchurl,
|
|
||||||
writeScriptBin,
|
|
||||||
appimageTools,
|
|
||||||
copyDesktopItems,
|
|
||||||
makeDesktopItem,
|
|
||||||
nix-update-script,
|
|
||||||
wrapGAppsHook3,
|
|
||||||
}:
|
|
||||||
|
|
||||||
stdenvNoCC.mkDerivation rec {
|
|
||||||
pname = "cura-appimage";
|
|
||||||
version = "5.9.0";
|
|
||||||
|
|
||||||
# Give some good names so the intermediate packages are easy
|
|
||||||
# to recognise by name in the Nix store.
|
|
||||||
appimageBinName = "cura-appimage-tools-output";
|
|
||||||
wrapperScriptName = "${pname}-wrapper-script";
|
|
||||||
|
|
||||||
src = fetchurl {
|
|
||||||
url = "https://github.com/Ultimaker/Cura/releases/download/${version}/Ultimaker-Cura-${version}-linux-X64.AppImage";
|
|
||||||
hash = "sha256-STtVeM4Zs+PVSRO3cI0LxnjRDhOxSlttZF+2RIXnAp4=";
|
|
||||||
};
|
|
||||||
|
|
||||||
appimageContents = appimageTools.extract {
|
|
||||||
inherit pname version src;
|
|
||||||
};
|
|
||||||
|
|
||||||
curaAppimageToolsWrapped = appimageTools.wrapType2 {
|
|
||||||
inherit src;
|
|
||||||
# For `appimageTools.wrapType2`, `pname` determines the binary's name in `bin/`.
|
|
||||||
pname = appimageBinName;
|
|
||||||
inherit version;
|
|
||||||
extraPkgs = _: [ ];
|
|
||||||
};
|
|
||||||
|
|
||||||
# The `QT_QPA_PLATFORM=xcb` fixes Wayland support, see https://github.com/NixOS/nixpkgs/issues/186570#issuecomment-2526277637
|
|
||||||
# The `GTK_USE_PORTAL=1` fixes file dialog issues under Gnome, see https://github.com/NixOS/nixpkgs/pull/372614#issuecomment-2585663161
|
|
||||||
script = writeScriptBin wrapperScriptName ''
|
|
||||||
#!${stdenv.shell}
|
|
||||||
# AppImage version of Cura loses current working directory and treats all paths relateive to $HOME.
|
|
||||||
# So we convert each of the files passed as argument to an absolute path.
|
|
||||||
# This fixes use cases like `cd /path/to/my/files; cura mymodel.stl anothermodel.stl`.
|
|
||||||
|
|
||||||
args=()
|
|
||||||
for a in "$@"; do
|
|
||||||
if [ -e "$a" ]; then
|
|
||||||
a="$(realpath "$a")"
|
|
||||||
fi
|
|
||||||
args+=("$a")
|
|
||||||
done
|
|
||||||
QT_QPA_PLATFORM=xcb GTK_USE_PORTAL=1 exec "${curaAppimageToolsWrapped}/bin/${appimageBinName}" "''${args[@]}"
|
|
||||||
'';
|
|
||||||
|
|
||||||
dontUnpack = true;
|
|
||||||
|
|
||||||
nativeBuildInputs = [
|
|
||||||
copyDesktopItems
|
|
||||||
wrapGAppsHook3
|
|
||||||
];
|
|
||||||
desktopItems = [
|
|
||||||
# Based on upstream.
|
|
||||||
# https://github.com/Ultimaker/Cura/blob/382b98e8b0c910fdf8b1509557ae8afab38f1817/packaging/AppImage/cura.desktop.jinja
|
|
||||||
(makeDesktopItem {
|
|
||||||
name = "cura";
|
|
||||||
desktopName = "UltiMaker Cura";
|
|
||||||
genericName = "3D Printing Software";
|
|
||||||
comment = meta.longDescription;
|
|
||||||
exec = "cura";
|
|
||||||
icon = "cura-icon";
|
|
||||||
terminal = false;
|
|
||||||
type = "Application";
|
|
||||||
mimeTypes = [
|
|
||||||
"model/stl"
|
|
||||||
"application/vnd.ms-3mfdocument"
|
|
||||||
"application/prs.wavefront-obj"
|
|
||||||
"image/bmp"
|
|
||||||
"image/gif"
|
|
||||||
"image/jpeg"
|
|
||||||
"image/png"
|
|
||||||
"text/x-gcode"
|
|
||||||
"application/x-amf"
|
|
||||||
"application/x-ply"
|
|
||||||
"application/x-ctm"
|
|
||||||
"model/vnd.collada+xml"
|
|
||||||
"model/gltf-binary"
|
|
||||||
"model/gltf+json"
|
|
||||||
"model/vnd.collada+xml+zip"
|
|
||||||
];
|
|
||||||
categories = [ "Graphics" ];
|
|
||||||
keywords = [
|
|
||||||
"3D"
|
|
||||||
"Printing"
|
|
||||||
];
|
|
||||||
})
|
|
||||||
];
|
|
||||||
|
|
||||||
installPhase = ''
|
|
||||||
runHook preInstall
|
|
||||||
|
|
||||||
mkdir -p $out/bin
|
|
||||||
cp ${script}/bin/${wrapperScriptName} $out/bin/cura
|
|
||||||
|
|
||||||
mkdir -p $out/share/applications $out/share/icons/hicolor/128x128/apps
|
|
||||||
install -Dm644 ${appimageContents}/usr/share/icons/hicolor/128x128/apps/cura-icon.png $out/share/icons/hicolor/128x128/apps/cura-icon.png
|
|
||||||
|
|
||||||
runHook postInstall
|
|
||||||
'';
|
|
||||||
|
|
||||||
passthru.updateScript = nix-update-script { extraArgs = [ "--version-regex=([56789].+)" ]; };
|
|
||||||
|
|
||||||
meta = {
|
|
||||||
description = "3D printing software";
|
|
||||||
homepage = "https://github.com/ultimaker/cura";
|
|
||||||
changelog = "https://github.com/Ultimaker/Cura/releases/tag/${version}";
|
|
||||||
longDescription = ''
|
|
||||||
Cura converts 3D models into paths for a 3D printer. It prepares your print for maximum accuracy, minimum printing time and good reliability with many extra features that make your print come out great.
|
|
||||||
'';
|
|
||||||
license = lib.licenses.lgpl3Plus;
|
|
||||||
platforms = [ "x86_64-linux" ];
|
|
||||||
mainProgram = "cura";
|
|
||||||
maintainers = with lib.maintainers; [
|
|
||||||
pbek
|
|
||||||
nh2
|
|
||||||
fliegendewurst
|
|
||||||
];
|
|
||||||
};
|
|
||||||
}
|
|
Loading…
Add table
Add a link
Reference in a new issue