Compare commits
3 commits
be4c446e1d
...
4dc6a6a61a
Author | SHA1 | Date | |
---|---|---|---|
Artemis Tosini | 4dc6a6a61a | ||
Artemis Tosini | 4ff4e7b859 | ||
Artemis Tosini | 99c062b6af |
|
@ -2,11 +2,11 @@
|
||||||
"nodes": {
|
"nodes": {
|
||||||
"nixpkgs": {
|
"nixpkgs": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1711532879,
|
"lastModified": 1717459389,
|
||||||
"narHash": "sha256-VUvOxVoxBokiZETZdZU97MnJpeKa19KqSOPlC84QB9Y=",
|
"narHash": "sha256-I8/plBsua4/NZ5bKgj+z7/ThiWuud1YFwLsn1QQ5PgE=",
|
||||||
"owner": "nixos",
|
"owner": "nixos",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"rev": "2230a20f2b5a14f2db3d7f13a2dc3c22517e790b",
|
"rev": "3b01abcc24846ae49957b30f4345bab4b3f1d14b",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
|
114
flake.nix
114
flake.nix
|
@ -6,8 +6,14 @@
|
||||||
utils.url = "github:numtide/flake-utils";
|
utils.url = "github:numtide/flake-utils";
|
||||||
};
|
};
|
||||||
|
|
||||||
outputs = { self, nixpkgs, utils }:
|
outputs =
|
||||||
utils.lib.eachDefaultSystem (system:
|
{
|
||||||
|
self,
|
||||||
|
nixpkgs,
|
||||||
|
utils,
|
||||||
|
}:
|
||||||
|
utils.lib.eachDefaultSystem (
|
||||||
|
system:
|
||||||
let
|
let
|
||||||
pkgs = import nixpkgs {
|
pkgs = import nixpkgs {
|
||||||
inherit system;
|
inherit system;
|
||||||
|
@ -15,62 +21,68 @@
|
||||||
};
|
};
|
||||||
inherit (pkgs) lib;
|
inherit (pkgs) lib;
|
||||||
names = builtins.attrNames (self.overlays.default pkgs pkgs);
|
names = builtins.attrNames (self.overlays.default pkgs pkgs);
|
||||||
in {
|
in
|
||||||
|
{
|
||||||
devShells = {
|
devShells = {
|
||||||
plotter = pkgs.callPackage ./shells/plotter { };
|
plotter = pkgs.callPackage ./shells/plotter { };
|
||||||
ryujinx = pkgs.callPackage ./shells/ryujinx { };
|
ryujinx = pkgs.callPackage ./shells/ryujinx { };
|
||||||
zephyr = pkgs.callPackage ./shells/zephyr { };
|
zephyr = pkgs.callPackage ./shells/zephyr { };
|
||||||
};
|
};
|
||||||
|
|
||||||
formatter = pkgs.nixfmt;
|
formatter = pkgs.nixfmt-rfc-style;
|
||||||
packages = builtins.listToAttrs (lib.concatMap (name:
|
packages = builtins.listToAttrs (
|
||||||
let pkg = pkgs.${name};
|
lib.concatMap (
|
||||||
in lib.optional (builtins.typeOf pkg == "set") {
|
name:
|
||||||
inherit name;
|
let
|
||||||
value = if lib.isDerivation pkg then
|
pkg = pkgs.${name};
|
||||||
pkg
|
in
|
||||||
else
|
lib.optional (builtins.typeOf pkg == "set") {
|
||||||
pkg // {
|
inherit name;
|
||||||
type = "derivation";
|
value =
|
||||||
name = "dummy-attrset";
|
if lib.isDerivation pkg then
|
||||||
};
|
pkg
|
||||||
}) names);
|
else
|
||||||
}) // {
|
pkg
|
||||||
overlays.default = final: prev: {
|
// {
|
||||||
attic = final.callPackage ./packages/attic { };
|
type = "derivation";
|
||||||
attic-client = final.attic.override { clientOnly = true; };
|
name = "dummy-attrset";
|
||||||
cups-dymo-patched = final.callPackage ./packages/cups-dymo { };
|
};
|
||||||
hactoolnet = final.callPackage ./packages/hactoolnet { };
|
}
|
||||||
ipsw = final.callPackage ./packages/ipsw { };
|
) names
|
||||||
jlink = final.callPackage ./packages/jlink { };
|
);
|
||||||
stlink-tool = final.callPackage ./packages/stlink-tool { };
|
}
|
||||||
zephyrPackages = final.callPackage ./packages/zephyr { };
|
)
|
||||||
|
// {
|
||||||
|
overlays.default = final: prev: {
|
||||||
|
apotris = final.callPackage ./packages/apotris { };
|
||||||
|
attic = final.callPackage ./packages/attic { };
|
||||||
|
attic-client = final.attic.override { clientOnly = true; };
|
||||||
|
cups-dymo-patched = final.callPackage ./packages/cups-dymo { };
|
||||||
|
hactoolnet = final.callPackage ./packages/hactoolnet { };
|
||||||
|
ipsw = final.callPackage ./packages/ipsw { };
|
||||||
|
jlink = final.callPackage ./packages/jlink { };
|
||||||
|
stlink-tool = final.callPackage ./packages/stlink-tool { };
|
||||||
|
zephyrPackages = final.callPackage ./packages/zephyr { };
|
||||||
|
|
||||||
inherit (final.python3.pkgs) axicli vpype;
|
inherit (final.python3.pkgs) axicli vpype;
|
||||||
|
|
||||||
inkscape-extensions = prev.inkscape-extensions // {
|
inkscape-extensions = prev.inkscape-extensions // {
|
||||||
axidraw = final.callPackage ./packages/axidraw/inkscape.nix { };
|
axidraw = final.callPackage ./packages/axidraw/inkscape.nix { };
|
||||||
};
|
|
||||||
|
|
||||||
kernelPatches = prev.kernelPatches
|
|
||||||
// final.callPackage ./packages/kernelPatches { };
|
|
||||||
|
|
||||||
pythonPackagesExtensions = prev.pythonPackagesExtensions ++ [
|
|
||||||
(pythonFinal: pythonPrev:
|
|
||||||
{
|
|
||||||
pnoise = final.callPackage ./packages/pnoise {
|
|
||||||
python3 = pythonFinal;
|
|
||||||
};
|
|
||||||
vpype =
|
|
||||||
final.callPackage ./packages/vpype { python3 = pythonFinal; };
|
|
||||||
vpype-gcode = final.callPackage ./packages/vpype-gcode {
|
|
||||||
python3 = pythonFinal;
|
|
||||||
};
|
|
||||||
} // (final.callPackage ./packages/axidraw/modules.nix {
|
|
||||||
python3 = pythonFinal;
|
|
||||||
}))
|
|
||||||
];
|
|
||||||
};
|
};
|
||||||
};
|
|
||||||
}
|
|
||||||
|
|
||||||
|
kernelPatches = prev.kernelPatches // final.callPackage ./packages/kernelPatches { };
|
||||||
|
|
||||||
|
pythonPackagesExtensions = prev.pythonPackagesExtensions ++ [
|
||||||
|
(
|
||||||
|
pythonFinal: pythonPrev:
|
||||||
|
{
|
||||||
|
pnoise = final.callPackage ./packages/pnoise { python3 = pythonFinal; };
|
||||||
|
vpype = final.callPackage ./packages/vpype { python3 = pythonFinal; };
|
||||||
|
vpype-gcode = final.callPackage ./packages/vpype-gcode { python3 = pythonFinal; };
|
||||||
|
}
|
||||||
|
// (final.callPackage ./packages/axidraw/modules.nix { python3 = pythonFinal; })
|
||||||
|
)
|
||||||
|
];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
78
packages/apotris/default.nix
Normal file
78
packages/apotris/default.nix
Normal file
|
@ -0,0 +1,78 @@
|
||||||
|
{
|
||||||
|
lib,
|
||||||
|
stdenv,
|
||||||
|
fetchFromGitea,
|
||||||
|
cmake,
|
||||||
|
meson,
|
||||||
|
ninja,
|
||||||
|
pkg-config,
|
||||||
|
python3,
|
||||||
|
xxd,
|
||||||
|
|
||||||
|
SDL2,
|
||||||
|
SDL2_mixer,
|
||||||
|
libX11,
|
||||||
|
libXScrnSaver,
|
||||||
|
libXcursor,
|
||||||
|
libXext,
|
||||||
|
libXfixes,
|
||||||
|
libXi,
|
||||||
|
libXrandr,
|
||||||
|
libogg,
|
||||||
|
libopus,
|
||||||
|
zlib,
|
||||||
|
}:
|
||||||
|
|
||||||
|
stdenv.mkDerivation rec {
|
||||||
|
pname = "apotris";
|
||||||
|
version = "4.0.2";
|
||||||
|
|
||||||
|
src = fetchFromGitea {
|
||||||
|
domain = "gitea.com";
|
||||||
|
owner = "akouzoukos";
|
||||||
|
repo = pname;
|
||||||
|
fetchSubmodules = true;
|
||||||
|
rev = "v${version}";
|
||||||
|
hash = "sha256-w9uv7A1UIn82ORyyvT8dxWHUK9chVfJ191bnI53sANU=";
|
||||||
|
};
|
||||||
|
|
||||||
|
patches = [ ./paths.patch ];
|
||||||
|
|
||||||
|
nativeBuildInputs = [
|
||||||
|
meson
|
||||||
|
cmake
|
||||||
|
ninja
|
||||||
|
pkg-config
|
||||||
|
python3
|
||||||
|
xxd
|
||||||
|
];
|
||||||
|
|
||||||
|
buildInputs = [
|
||||||
|
SDL2
|
||||||
|
SDL2_mixer
|
||||||
|
libX11
|
||||||
|
libXScrnSaver
|
||||||
|
libXcursor
|
||||||
|
libXext
|
||||||
|
libXfixes
|
||||||
|
libXi
|
||||||
|
libXrandr
|
||||||
|
libogg
|
||||||
|
libopus
|
||||||
|
zlib
|
||||||
|
];
|
||||||
|
|
||||||
|
postPatch = ''
|
||||||
|
patchShebangs --build tools
|
||||||
|
substituteAllInPlace source/liba_window.cpp
|
||||||
|
'';
|
||||||
|
|
||||||
|
meta = with lib; {
|
||||||
|
description = "Multiplatform open-source block stacking game";
|
||||||
|
mainProgram = "Apotris";
|
||||||
|
homepage = "https://apotris.com";
|
||||||
|
license = licenses.agpl3Only;
|
||||||
|
maintainers = with maintainers; [ artemist ];
|
||||||
|
platforms = platforms.unix;
|
||||||
|
};
|
||||||
|
}
|
52
packages/apotris/paths.patch
Normal file
52
packages/apotris/paths.patch
Normal file
|
@ -0,0 +1,52 @@
|
||||||
|
diff --git a/source/liba_window.cpp b/source/liba_window.cpp
|
||||||
|
index 5c05b92..b3dfacf 100644
|
||||||
|
--- a/source/liba_window.cpp
|
||||||
|
+++ b/source/liba_window.cpp
|
||||||
|
@@ -6,6 +6,7 @@
|
||||||
|
#include <iostream>
|
||||||
|
#include <dirent.h>
|
||||||
|
#include <cstdio>
|
||||||
|
+#include <cstdlib>
|
||||||
|
|
||||||
|
#include "def.h"
|
||||||
|
|
||||||
|
@@ -85,7 +86,7 @@ void windowInit(){
|
||||||
|
|
||||||
|
refreshWindowSize();
|
||||||
|
|
||||||
|
- loadAudio("");
|
||||||
|
+ loadAudio("@out@/");
|
||||||
|
|
||||||
|
nanotime_step_init(&stepper, (uint64_t) (NANOTIME_NSEC_PER_SEC / FPS_TARGET), nanotime_now_max(),nanotime_now,nanotime_sleep);
|
||||||
|
|
||||||
|
@@ -334,9 +335,20 @@ void toggleRendering(bool r){
|
||||||
|
|
||||||
|
void initRumble(){};
|
||||||
|
|
||||||
|
+static std::string savePath() {
|
||||||
|
+ char *home;
|
||||||
|
+ if((home = getenv("XDG_DATA_HOME")) != NULL) {
|
||||||
|
+ return std::string(home) + "/Apotris.sav";
|
||||||
|
+ }
|
||||||
|
+ if((home = getenv("HOME")) != NULL) {
|
||||||
|
+ return std::string(home) + "/.local/share/Apotris.sav";
|
||||||
|
+ }
|
||||||
|
+ return "Apotris.sav";
|
||||||
|
+}
|
||||||
|
+
|
||||||
|
void loadSavefile(){
|
||||||
|
|
||||||
|
- std::ifstream input("Apotris.sav",std::ios::binary | std::ios::in);
|
||||||
|
+ std::ifstream input(savePath(),std::ios::binary | std::ios::in);
|
||||||
|
|
||||||
|
if(savefile == nullptr)
|
||||||
|
savefile = new Save();
|
||||||
|
@@ -355,7 +367,7 @@ void loadSavefile(){
|
||||||
|
|
||||||
|
void saveSavefile(){
|
||||||
|
|
||||||
|
- std::ofstream output("Apotris.sav",std::ios::binary | std::ios::out);
|
||||||
|
+ std::ofstream output(savePath(),std::ios::binary | std::ios::out);
|
||||||
|
|
||||||
|
char * dst = (char * ) savefile;
|
||||||
|
|
|
@ -1,14 +1,28 @@
|
||||||
# Based on original package.nix from zhaofengli
|
# Based on original package.nix from zhaofengli
|
||||||
|
|
||||||
{ lib, stdenv, rustPlatform, fetchFromGitHub, pkg-config, installShellFiles, nix
|
{
|
||||||
, boost, darwin
|
lib,
|
||||||
|
stdenv,
|
||||||
|
rustPlatform,
|
||||||
|
fetchFromGitHub,
|
||||||
|
pkg-config,
|
||||||
|
installShellFiles,
|
||||||
|
nix,
|
||||||
|
boost,
|
||||||
|
darwin,
|
||||||
|
|
||||||
# Only build the client
|
# Only build the client
|
||||||
, clientOnly ? false
|
clientOnly ? false,
|
||||||
|
|
||||||
# Only build certain crates
|
# Only build certain crates
|
||||||
, crates ?
|
crates ?
|
||||||
if clientOnly then [ "attic-client" ] else [ "attic-client" "attic-server" ]
|
if clientOnly then
|
||||||
|
[ "attic-client" ]
|
||||||
|
else
|
||||||
|
[
|
||||||
|
"attic-client"
|
||||||
|
"attic-server"
|
||||||
|
],
|
||||||
}:
|
}:
|
||||||
|
|
||||||
rustPlatform.buildRustPackage {
|
rustPlatform.buildRustPackage {
|
||||||
|
@ -27,32 +41,34 @@ rustPlatform.buildRustPackage {
|
||||||
allowBuiltinFetchGit = true;
|
allowBuiltinFetchGit = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
nativeBuildInputs = [ pkg-config installShellFiles ];
|
nativeBuildInputs = [
|
||||||
|
pkg-config
|
||||||
|
installShellFiles
|
||||||
|
];
|
||||||
|
|
||||||
buildInputs = [ nix boost ] ++ lib.optionals stdenv.isDarwin
|
buildInputs = [
|
||||||
(with darwin.apple_sdk.frameworks; [ SystemConfiguration ]);
|
nix
|
||||||
|
boost
|
||||||
|
] ++ lib.optionals stdenv.isDarwin (with darwin.apple_sdk.frameworks; [ SystemConfiguration ]);
|
||||||
|
|
||||||
cargoBuildFlags = lib.concatMapStrings (c: "-p ${c} ") crates;
|
cargoBuildFlags = lib.concatMapStrings (c: "-p ${c} ") crates;
|
||||||
|
|
||||||
ATTIC_DISTRIBUTOR = "artemist";
|
ATTIC_DISTRIBUTOR = "artemist";
|
||||||
|
|
||||||
# Workaround for https://github.com/NixOS/nixpkgs/issues/166205
|
# Workaround for https://github.com/NixOS/nixpkgs/issues/166205
|
||||||
env = lib.optionalAttrs stdenv.cc.isClang {
|
env = lib.optionalAttrs stdenv.cc.isClang { NIX_LDFLAGS = "-l${stdenv.cc.libcxx.cxxabi.libName}"; };
|
||||||
NIX_LDFLAGS = "-l${stdenv.cc.libcxx.cxxabi.libName}";
|
|
||||||
};
|
|
||||||
|
|
||||||
# Recursive Nix is not stable yet
|
# Recursive Nix is not stable yet
|
||||||
doCheck = false;
|
doCheck = false;
|
||||||
|
|
||||||
postInstall =
|
postInstall = lib.optionalString (stdenv.hostPlatform == stdenv.buildPlatform) ''
|
||||||
lib.optionalString (stdenv.hostPlatform == stdenv.buildPlatform) ''
|
if [[ -f $out/bin/attic ]]; then
|
||||||
if [[ -f $out/bin/attic ]]; then
|
installShellCompletion --cmd attic \
|
||||||
installShellCompletion --cmd attic \
|
--bash <($out/bin/attic gen-completions bash) \
|
||||||
--bash <($out/bin/attic gen-completions bash) \
|
--zsh <($out/bin/attic gen-completions zsh) \
|
||||||
--zsh <($out/bin/attic gen-completions zsh) \
|
--fish <($out/bin/attic gen-completions fish)
|
||||||
--fish <($out/bin/attic gen-completions fish)
|
fi
|
||||||
fi
|
'';
|
||||||
'';
|
|
||||||
|
|
||||||
meta = with lib; {
|
meta = with lib; {
|
||||||
description = "Multi-tenant Nix binary cache system";
|
description = "Multi-tenant Nix binary cache system";
|
||||||
|
|
|
@ -1,12 +1,16 @@
|
||||||
{ stdenv, lib, fetchzip, autoPatchelfHook }:
|
{
|
||||||
|
stdenv,
|
||||||
|
lib,
|
||||||
|
fetchzip,
|
||||||
|
autoPatchelfHook,
|
||||||
|
}:
|
||||||
|
|
||||||
stdenv.mkDerivation rec {
|
stdenv.mkDerivation rec {
|
||||||
pname = "axidraw-inkscape";
|
pname = "axidraw-inkscape";
|
||||||
version = "394";
|
version = "394";
|
||||||
|
|
||||||
src = fetchzip {
|
src = fetchzip {
|
||||||
url =
|
url = "https://cdn.evilmadscientist.com/dl/ad/public/${version}/AxiDraw_${version}_LinX86.zip";
|
||||||
"https://cdn.evilmadscientist.com/dl/ad/public/${version}/AxiDraw_${version}_LinX86.zip";
|
|
||||||
hash = "sha256-LoNi7mR30spELnEYikRuYFvlgUWP3w8KRbQ6Ug108vU=";
|
hash = "sha256-LoNi7mR30spELnEYikRuYFvlgUWP3w8KRbQ6Ug108vU=";
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -23,8 +27,7 @@ stdenv.mkDerivation rec {
|
||||||
|
|
||||||
meta = with lib; {
|
meta = with lib; {
|
||||||
description = "Inkscape extension for managing axidraw";
|
description = "Inkscape extension for managing axidraw";
|
||||||
homepage =
|
homepage = "https://wiki.evilmadscientist.com/Axidraw_Software_Installation";
|
||||||
"https://wiki.evilmadscientist.com/Axidraw_Software_Installation";
|
|
||||||
license = licenses.gpl2Plus;
|
license = licenses.gpl2Plus;
|
||||||
maintainers = with maintainers; [ artemist ];
|
maintainers = with maintainers; [ artemist ];
|
||||||
platforms = [ "x86_64-linux" ];
|
platforms = [ "x86_64-linux" ];
|
||||||
|
|
|
@ -1,22 +1,26 @@
|
||||||
{ python3, fetchPypi, fetchzip, fetchurl }:
|
{
|
||||||
|
python3,
|
||||||
|
fetchPypi,
|
||||||
|
fetchzip,
|
||||||
|
fetchurl,
|
||||||
|
}:
|
||||||
let
|
let
|
||||||
inherit (python3) buildPythonPackage;
|
inherit (python3) buildPythonPackage;
|
||||||
|
|
||||||
axicliVersion = "3.9.0";
|
axicliVersion = "3.9.0";
|
||||||
axicliVer = builtins.replaceStrings [ "." ] [ "" ] axicliVersion;
|
axicliVer = builtins.replaceStrings [ "." ] [ "" ] axicliVersion;
|
||||||
axicliSrc = fetchzip {
|
axicliSrc = fetchzip {
|
||||||
url =
|
url = "https://github.com/evil-mad/axidraw/releases/download/v${axicliVersion}/AxiDraw_API_${axicliVer}.zip";
|
||||||
"https://github.com/evil-mad/axidraw/releases/download/v${axicliVersion}/AxiDraw_API_${axicliVer}.zip";
|
|
||||||
hash = "sha256-RPh00jiiH1RqqKZ10ylFP1J+iBYl5VOmZ8g0vFH8Ibg=";
|
hash = "sha256-RPh00jiiH1RqqKZ10ylFP1J+iBYl5VOmZ8g0vFH8Ibg=";
|
||||||
};
|
};
|
||||||
in {
|
in
|
||||||
|
{
|
||||||
drawsvg = buildPythonPackage {
|
drawsvg = buildPythonPackage {
|
||||||
pname = "drawsvg";
|
pname = "drawsvg";
|
||||||
version = "2.3.0";
|
version = "2.3.0";
|
||||||
format = "wheel";
|
format = "wheel";
|
||||||
src = fetchurl {
|
src = fetchurl {
|
||||||
url =
|
url = "https://files.pythonhosted.org/packages/27/4f/65d72a014026495d8d2847e66bbe542cf899e50f087a50e0abab9c58ef3c/drawsvg-2.3.0-py3-none-any.whl";
|
||||||
"https://files.pythonhosted.org/packages/27/4f/65d72a014026495d8d2847e66bbe542cf899e50f087a50e0abab9c58ef3c/drawsvg-2.3.0-py3-none-any.whl";
|
|
||||||
sha256 = "1gqa5q5b7y38isyw1kgq2lprw5709jv13pic9s6bk80dbm32pbck";
|
sha256 = "1gqa5q5b7y38isyw1kgq2lprw5709jv13pic9s6bk80dbm32pbck";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
@ -39,15 +43,17 @@ in {
|
||||||
hash = "sha256-YxSASXBNXqRyGp7x6jlTU0UYJHJkiKdlEzfDMzUtKXk=";
|
hash = "sha256-YxSASXBNXqRyGp7x6jlTU0UYJHJkiKdlEzfDMzUtKXk=";
|
||||||
};
|
};
|
||||||
doCheck = false;
|
doCheck = false;
|
||||||
propagatedBuildInputs = with python3; [ ink-extensions pyserial ];
|
propagatedBuildInputs = with python3; [
|
||||||
|
ink-extensions
|
||||||
|
pyserial
|
||||||
|
];
|
||||||
};
|
};
|
||||||
|
|
||||||
axidrawinternal = buildPythonPackage {
|
axidrawinternal = buildPythonPackage {
|
||||||
pname = "axidrawinternal";
|
pname = "axidrawinternal";
|
||||||
version = axicliVersion;
|
version = axicliVersion;
|
||||||
format = "wheel";
|
format = "wheel";
|
||||||
src =
|
src = "${axicliSrc}/prebuilt_dependencies/axidrawinternal-${axicliVersion}-py2.py3-none-any.whl";
|
||||||
"${axicliSrc}/prebuilt_dependencies/axidrawinternal-${axicliVersion}-py2.py3-none-any.whl";
|
|
||||||
propagatedBuildInputs = with python3; [
|
propagatedBuildInputs = with python3; [
|
||||||
ink-extensions
|
ink-extensions
|
||||||
requests
|
requests
|
||||||
|
|
|
@ -1,4 +1,13 @@
|
||||||
{ stdenv, lib, fetchFromGitHub, autoconf, automake, boost, cups, ... }:
|
{
|
||||||
|
stdenv,
|
||||||
|
lib,
|
||||||
|
fetchFromGitHub,
|
||||||
|
autoconf,
|
||||||
|
automake,
|
||||||
|
boost,
|
||||||
|
cups,
|
||||||
|
...
|
||||||
|
}:
|
||||||
|
|
||||||
stdenv.mkDerivation {
|
stdenv.mkDerivation {
|
||||||
pname = "cups-dymo";
|
pname = "cups-dymo";
|
||||||
|
@ -11,9 +20,15 @@ stdenv.mkDerivation {
|
||||||
hash = "sha256-IwdTJxCOKyqsl1B5UQqCDpepz04U4VF+G3mqaJTQJ/w=";
|
hash = "sha256-IwdTJxCOKyqsl1B5UQqCDpepz04U4VF+G3mqaJTQJ/w=";
|
||||||
};
|
};
|
||||||
|
|
||||||
nativeBuildInputs = [ autoconf automake ];
|
nativeBuildInputs = [
|
||||||
|
autoconf
|
||||||
|
automake
|
||||||
|
];
|
||||||
|
|
||||||
buildInputs = [ boost cups ];
|
buildInputs = [
|
||||||
|
boost
|
||||||
|
cups
|
||||||
|
];
|
||||||
|
|
||||||
preConfigure = ''
|
preConfigure = ''
|
||||||
touch NEWS AUTHORS INSTALL README ChangeLog
|
touch NEWS AUTHORS INSTALL README ChangeLog
|
||||||
|
|
|
@ -1,4 +1,9 @@
|
||||||
{ lib, buildDotnetModule, dotnetCorePackages, fetchFromGitHub }:
|
{
|
||||||
|
lib,
|
||||||
|
buildDotnetModule,
|
||||||
|
dotnetCorePackages,
|
||||||
|
fetchFromGitHub,
|
||||||
|
}:
|
||||||
|
|
||||||
buildDotnetModule rec {
|
buildDotnetModule rec {
|
||||||
pname = "hactoolnet";
|
pname = "hactoolnet";
|
||||||
|
@ -22,8 +27,7 @@ buildDotnetModule rec {
|
||||||
|
|
||||||
meta = with lib; {
|
meta = with lib; {
|
||||||
homepage = "https://github.com/Thealexbarney/LibHac";
|
homepage = "https://github.com/Thealexbarney/LibHac";
|
||||||
description =
|
description = "Example program for LibHac, which implements parts of Horizon OS";
|
||||||
"Example program for LibHac, which implements parts of Horizon OS";
|
|
||||||
license = licenses.mit;
|
license = licenses.mit;
|
||||||
platforms = platforms.unix;
|
platforms = platforms.unix;
|
||||||
};
|
};
|
||||||
|
|
|
@ -1,7 +1,8 @@
|
||||||
# This file was automatically generated by passthru.fetch-deps.
|
# This file was automatically generated by passthru.fetch-deps.
|
||||||
# Please dont edit it manually, your changes might get overwritten!
|
# Please dont edit it manually, your changes might get overwritten!
|
||||||
|
|
||||||
{ fetchNuGet }: [
|
{ fetchNuGet }:
|
||||||
|
[
|
||||||
(fetchNuGet {
|
(fetchNuGet {
|
||||||
pname = "Microsoft.AspNetCore.App.Ref";
|
pname = "Microsoft.AspNetCore.App.Ref";
|
||||||
version = "7.0.16";
|
version = "7.0.16";
|
||||||
|
|
|
@ -1,4 +1,11 @@
|
||||||
{ lib, buildGo122Module, fetchFromGitHub, unicorn, libusb, pkg-config }:
|
{
|
||||||
|
lib,
|
||||||
|
buildGo122Module,
|
||||||
|
fetchFromGitHub,
|
||||||
|
unicorn,
|
||||||
|
libusb,
|
||||||
|
pkg-config,
|
||||||
|
}:
|
||||||
|
|
||||||
buildGo122Module rec {
|
buildGo122Module rec {
|
||||||
pname = "ipsw";
|
pname = "ipsw";
|
||||||
|
@ -15,14 +22,20 @@ buildGo122Module rec {
|
||||||
patches = [ ./fix-build.patch ];
|
patches = [ ./fix-build.patch ];
|
||||||
|
|
||||||
nativeBuildInputs = [ pkg-config ];
|
nativeBuildInputs = [ pkg-config ];
|
||||||
buildInputs = [ unicorn libusb ];
|
buildInputs = [
|
||||||
|
unicorn
|
||||||
|
libusb
|
||||||
|
];
|
||||||
ldflags = [
|
ldflags = [
|
||||||
"-s"
|
"-s"
|
||||||
"-w"
|
"-w"
|
||||||
"-X github.com/blacktop/ipsw/cmd/ipsw/cmd.AppVersion=${version}"
|
"-X github.com/blacktop/ipsw/cmd/ipsw/cmd.AppVersion=${version}"
|
||||||
"-X github.com/blacktop/ipsw/cmd/ipsw/cmd.AppBuildTime=19700101"
|
"-X github.com/blacktop/ipsw/cmd/ipsw/cmd.AppBuildTime=19700101"
|
||||||
];
|
];
|
||||||
tags = [ "unicorn" "libusb" ];
|
tags = [
|
||||||
|
"unicorn"
|
||||||
|
"libusb"
|
||||||
|
];
|
||||||
doCheck = false;
|
doCheck = false;
|
||||||
|
|
||||||
meta = with lib; {
|
meta = with lib; {
|
||||||
|
|
|
@ -1,10 +1,29 @@
|
||||||
{ stdenv, lib, fetchurl, autoPatchelfHook, fontconfig, freetype, libgcc, libusb
|
{
|
||||||
, libICE, libSM, ncurses5, udev, libX11, libXext, libXcursor, libXfixes
|
stdenv,
|
||||||
, libXrender, libXrandr }:
|
lib,
|
||||||
|
fetchurl,
|
||||||
|
autoPatchelfHook,
|
||||||
|
fontconfig,
|
||||||
|
freetype,
|
||||||
|
libgcc,
|
||||||
|
libusb,
|
||||||
|
libICE,
|
||||||
|
libSM,
|
||||||
|
ncurses5,
|
||||||
|
udev,
|
||||||
|
libX11,
|
||||||
|
libXext,
|
||||||
|
libXcursor,
|
||||||
|
libXfixes,
|
||||||
|
libXrender,
|
||||||
|
libXrandr,
|
||||||
|
}:
|
||||||
let
|
let
|
||||||
conf = (lib.importJSON ./version.json).${stdenv.hostPlatform.system} or (throw
|
conf =
|
||||||
"unsupported system ${stdenv.hostPlatform.system}");
|
(lib.importJSON ./version.json).${stdenv.hostPlatform.system}
|
||||||
in stdenv.mkDerivation rec {
|
or (throw "unsupported system ${stdenv.hostPlatform.system}");
|
||||||
|
in
|
||||||
|
stdenv.mkDerivation rec {
|
||||||
pname = "jlink";
|
pname = "jlink";
|
||||||
version = conf.version;
|
version = conf.version;
|
||||||
|
|
||||||
|
@ -52,7 +71,12 @@ in stdenv.mkDerivation rec {
|
||||||
homepage = "https://www.segger.com/downloads/jlink";
|
homepage = "https://www.segger.com/downloads/jlink";
|
||||||
description = "SEGGER J-Link";
|
description = "SEGGER J-Link";
|
||||||
license = licenses.unfree;
|
license = licenses.unfree;
|
||||||
platforms = [ "x86_64-linux" "i686-linux" "armv7l-linux" "aarch64-linux" ];
|
platforms = [
|
||||||
|
"x86_64-linux"
|
||||||
|
"i686-linux"
|
||||||
|
"armv7l-linux"
|
||||||
|
"aarch64-linux"
|
||||||
|
];
|
||||||
maintainers = with maintainers; [ artemist ];
|
maintainers = with maintainers; [ artemist ];
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,4 +1,5 @@
|
||||||
{ ... }: {
|
{ ... }:
|
||||||
|
{
|
||||||
increase_max_topo = {
|
increase_max_topo = {
|
||||||
name = "increase-max-topo";
|
name = "increase-max-topo";
|
||||||
patch = ./increase-max-topo.patch;
|
patch = ./increase-max-topo.patch;
|
||||||
|
|
|
@ -1,4 +1,8 @@
|
||||||
{ lib, python3, fetchFromGitHub }:
|
{
|
||||||
|
lib,
|
||||||
|
python3,
|
||||||
|
fetchFromGitHub,
|
||||||
|
}:
|
||||||
|
|
||||||
python3.buildPythonPackage rec {
|
python3.buildPythonPackage rec {
|
||||||
pname = "pnoise";
|
pname = "pnoise";
|
||||||
|
|
|
@ -1,4 +1,9 @@
|
||||||
{ stdenv, fetchFromGitHub, pkg-config, libusb1 }:
|
{
|
||||||
|
stdenv,
|
||||||
|
fetchFromGitHub,
|
||||||
|
pkg-config,
|
||||||
|
libusb1,
|
||||||
|
}:
|
||||||
|
|
||||||
stdenv.mkDerivation rec {
|
stdenv.mkDerivation rec {
|
||||||
pname = "stlink-tool";
|
pname = "stlink-tool";
|
||||||
|
|
|
@ -1,4 +1,8 @@
|
||||||
{ lib, python3, fetchFromGitHub }:
|
{
|
||||||
|
lib,
|
||||||
|
python3,
|
||||||
|
fetchFromGitHub,
|
||||||
|
}:
|
||||||
|
|
||||||
python3.buildPythonPackage rec {
|
python3.buildPythonPackage rec {
|
||||||
pname = "vpype";
|
pname = "vpype";
|
||||||
|
@ -12,7 +16,11 @@ python3.buildPythonPackage rec {
|
||||||
hash = "sha256-waSHw4DBgozcBwNTgZwGfvmg0UHaENJIGrCqnMu0ruU=";
|
hash = "sha256-waSHw4DBgozcBwNTgZwGfvmg0UHaENJIGrCqnMu0ruU=";
|
||||||
};
|
};
|
||||||
|
|
||||||
propagatedBuildInputs = with python3; [ click numpy vpype ];
|
propagatedBuildInputs = with python3; [
|
||||||
|
click
|
||||||
|
numpy
|
||||||
|
vpype
|
||||||
|
];
|
||||||
|
|
||||||
meta = with lib; {
|
meta = with lib; {
|
||||||
description = "gcode extension for vpype";
|
description = "gcode extension for vpype";
|
||||||
|
|
|
@ -1,4 +1,9 @@
|
||||||
{ lib, python3, fetchFromGitHub, withViewer ? true }:
|
{
|
||||||
|
lib,
|
||||||
|
python3,
|
||||||
|
fetchFromGitHub,
|
||||||
|
withViewer ? true,
|
||||||
|
}:
|
||||||
|
|
||||||
python3.buildPythonPackage rec {
|
python3.buildPythonPackage rec {
|
||||||
pname = "vpype";
|
pname = "vpype";
|
||||||
|
@ -15,33 +20,36 @@ python3.buildPythonPackage rec {
|
||||||
|
|
||||||
nativeBuildInputs = with python3; [ poetry-core ];
|
nativeBuildInputs = with python3; [ poetry-core ];
|
||||||
|
|
||||||
propagatedBuildInputs = with python3;
|
propagatedBuildInputs =
|
||||||
([
|
with python3;
|
||||||
asteval
|
(
|
||||||
cachetools
|
[
|
||||||
click
|
asteval
|
||||||
multiprocess
|
cachetools
|
||||||
numpy
|
click
|
||||||
pnoise
|
multiprocess
|
||||||
pyphen
|
numpy
|
||||||
scipy
|
pnoise
|
||||||
shapely
|
pyphen
|
||||||
svgelements
|
scipy
|
||||||
svgwrite
|
shapely
|
||||||
tomli
|
svgelements
|
||||||
] ++ lib.optionals withViewer [
|
svgwrite
|
||||||
glcontext
|
tomli
|
||||||
matplotlib
|
]
|
||||||
moderngl
|
++ lib.optionals withViewer [
|
||||||
pillow
|
glcontext
|
||||||
pyside6
|
matplotlib
|
||||||
]);
|
moderngl
|
||||||
|
pillow
|
||||||
|
pyside6
|
||||||
|
]
|
||||||
|
);
|
||||||
|
|
||||||
# No checks since they want OpenGL and a GUI
|
# No checks since they want OpenGL and a GUI
|
||||||
|
|
||||||
meta = with lib; {
|
meta = with lib; {
|
||||||
description =
|
description = "The Swiss-Army-knife command-line tool for plotter vector graphics";
|
||||||
"The Swiss-Army-knife command-line tool for plotter vector graphics";
|
|
||||||
homepage = "https://vpype.readthedocs.io/en/latest/";
|
homepage = "https://vpype.readthedocs.io/en/latest/";
|
||||||
license = with licenses; [ mit ];
|
license = with licenses; [ mit ];
|
||||||
maintainers = with maintainers; [ artemist ];
|
maintainers = with maintainers; [ artemist ];
|
||||||
|
|
|
@ -1,19 +1,27 @@
|
||||||
{ callPackage, stdenv, lib, fetchFromGitHub }:
|
{
|
||||||
|
callPackage,
|
||||||
|
stdenv,
|
||||||
|
lib,
|
||||||
|
fetchFromGitHub,
|
||||||
|
}:
|
||||||
let
|
let
|
||||||
assets = lib.importJSON ./assets.json;
|
assets = lib.importJSON ./assets.json;
|
||||||
modules = lib.importJSON ./modules.json;
|
modules = lib.importJSON ./modules.json;
|
||||||
buildModule = module: callPackage ./module.nix { inherit module; };
|
buildModule = module: callPackage ./module.nix { inherit module; };
|
||||||
in {
|
in
|
||||||
|
{
|
||||||
host-tools = callPackage ./host-tools.nix {
|
host-tools = callPackage ./host-tools.nix {
|
||||||
inherit (assets) version hosts;
|
inherit (assets) version hosts;
|
||||||
sources = assets.host_tools;
|
sources = assets.host_tools;
|
||||||
};
|
};
|
||||||
|
|
||||||
toolchains = lib.mapAttrs (target: sources:
|
toolchains = lib.mapAttrs (
|
||||||
|
target: sources:
|
||||||
callPackage ./toolchain.nix {
|
callPackage ./toolchain.nix {
|
||||||
inherit target sources;
|
inherit target sources;
|
||||||
inherit (assets) version hosts;
|
inherit (assets) version hosts;
|
||||||
}) assets.toolchains;
|
}
|
||||||
|
) assets.toolchains;
|
||||||
|
|
||||||
sdk = callPackage ./sdk.nix {
|
sdk = callPackage ./sdk.nix {
|
||||||
inherit (assets) version hosts;
|
inherit (assets) version hosts;
|
||||||
|
|
|
@ -1,9 +1,21 @@
|
||||||
{ stdenv, fetchurl, hosts, lib, python3, sources, version, which }:
|
{
|
||||||
|
stdenv,
|
||||||
|
fetchurl,
|
||||||
|
hosts,
|
||||||
|
lib,
|
||||||
|
python3,
|
||||||
|
sources,
|
||||||
|
version,
|
||||||
|
which,
|
||||||
|
}:
|
||||||
stdenv.mkDerivation rec {
|
stdenv.mkDerivation rec {
|
||||||
pname = "zephyr-host-tools";
|
pname = "zephyr-host-tools";
|
||||||
inherit version;
|
inherit version;
|
||||||
|
|
||||||
nativeBuildInputs = [ python3 which ];
|
nativeBuildInputs = [
|
||||||
|
python3
|
||||||
|
which
|
||||||
|
];
|
||||||
src = fetchurl (sources."${stdenv.hostPlatform.system}");
|
src = fetchurl (sources."${stdenv.hostPlatform.system}");
|
||||||
|
|
||||||
dontUnpack = true;
|
dontUnpack = true;
|
||||||
|
|
|
@ -1,14 +1,21 @@
|
||||||
{ stdenvNoCC, lib, fetchFromGitHub, symlinkJoin, fetchurl, version ? null
|
{
|
||||||
, module }:
|
stdenvNoCC,
|
||||||
|
lib,
|
||||||
|
fetchFromGitHub,
|
||||||
|
symlinkJoin,
|
||||||
|
fetchurl,
|
||||||
|
version ? null,
|
||||||
|
module,
|
||||||
|
}:
|
||||||
let
|
let
|
||||||
labeledName = label:
|
labeledName =
|
||||||
if version != null then
|
label: if version != null then "${module.name}-${label}-${version}" else "${module.name}-${label}";
|
||||||
"${module.name}-${label}-${version}"
|
fetchBlob =
|
||||||
else
|
blob:
|
||||||
"${module.name}-${label}";
|
let
|
||||||
fetchBlob = blob:
|
blobFile = fetchurl { inherit (blob) url sha256; };
|
||||||
let blobFile = fetchurl { inherit (blob) url sha256; };
|
in
|
||||||
in stdenvNoCC.mkDerivation {
|
stdenvNoCC.mkDerivation {
|
||||||
name = "blob-${blob.path}";
|
name = "blob-${blob.path}";
|
||||||
passAsFile = [ "buildCommand" ];
|
passAsFile = [ "buildCommand" ];
|
||||||
buildCommand = ''
|
buildCommand = ''
|
||||||
|
@ -16,12 +23,21 @@ let
|
||||||
ln -s ${blobFile} $out/${blob.path}
|
ln -s ${blobFile} $out/${blob.path}
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
baseSrc = fetchFromGitHub { inherit (module) owner repo rev name sha256; };
|
baseSrc = fetchFromGitHub {
|
||||||
|
inherit (module)
|
||||||
|
owner
|
||||||
|
repo
|
||||||
|
rev
|
||||||
|
name
|
||||||
|
sha256
|
||||||
|
;
|
||||||
|
};
|
||||||
blobbedSrc = symlinkJoin {
|
blobbedSrc = symlinkJoin {
|
||||||
name = labeledName "with-blobs";
|
name = labeledName "with-blobs";
|
||||||
paths = [ baseSrc ] ++ (map fetchBlob module.blobs);
|
paths = [ baseSrc ] ++ (map fetchBlob module.blobs);
|
||||||
};
|
};
|
||||||
in stdenvNoCC.mkDerivation (finalAttrs: {
|
in
|
||||||
|
stdenvNoCC.mkDerivation (finalAttrs: {
|
||||||
name = labeledName "wrapped";
|
name = labeledName "wrapped";
|
||||||
|
|
||||||
passthru.modulePath = "${finalAttrs.finalPackage.out}/${module.name}";
|
passthru.modulePath = "${finalAttrs.finalPackage.out}/${module.name}";
|
||||||
|
@ -32,4 +48,3 @@ in stdenvNoCC.mkDerivation (finalAttrs: {
|
||||||
ln -s ${blobbedSrc} "$out/${module.name}"
|
ln -s ${blobbedSrc} "$out/${module.name}"
|
||||||
'';
|
'';
|
||||||
})
|
})
|
||||||
|
|
||||||
|
|
|
@ -1,7 +1,17 @@
|
||||||
{ lib, symlinkJoin, fetchurl, zephyrPackages, source, version, hosts
|
{
|
||||||
, toolchains ? [ ] }:
|
lib,
|
||||||
let src = fetchurl source;
|
symlinkJoin,
|
||||||
in symlinkJoin rec {
|
fetchurl,
|
||||||
|
zephyrPackages,
|
||||||
|
source,
|
||||||
|
version,
|
||||||
|
hosts,
|
||||||
|
toolchains ? [ ],
|
||||||
|
}:
|
||||||
|
let
|
||||||
|
src = fetchurl source;
|
||||||
|
in
|
||||||
|
symlinkJoin rec {
|
||||||
pname = "zephyr-sdk";
|
pname = "zephyr-sdk";
|
||||||
inherit version;
|
inherit version;
|
||||||
name = "${pname}-${version}";
|
name = "${pname}-${version}";
|
||||||
|
|
|
@ -1,4 +1,13 @@
|
||||||
{ stdenv, lib, fetchurl, autoPatchelfHook, target, sources, version, hosts }:
|
{
|
||||||
|
stdenv,
|
||||||
|
lib,
|
||||||
|
fetchurl,
|
||||||
|
autoPatchelfHook,
|
||||||
|
target,
|
||||||
|
sources,
|
||||||
|
version,
|
||||||
|
hosts,
|
||||||
|
}:
|
||||||
|
|
||||||
stdenv.mkDerivation {
|
stdenv.mkDerivation {
|
||||||
pname = "zephyr-toolchain-${target}";
|
pname = "zephyr-toolchain-${target}";
|
||||||
|
@ -35,8 +44,7 @@ stdenv.mkDerivation {
|
||||||
|
|
||||||
meta = with lib; {
|
meta = with lib; {
|
||||||
homepage = "https://www.zephyrproject.org/";
|
homepage = "https://www.zephyrproject.org/";
|
||||||
description =
|
description = "Toolchain for building Zephyr for the ${target} architecture";
|
||||||
"Toolchain for building Zephyr for the ${target} architecture";
|
|
||||||
license = licenses.asl20;
|
license = licenses.asl20;
|
||||||
platforms = hosts;
|
platforms = hosts;
|
||||||
maintainers = with maintainers; [ artemist ];
|
maintainers = with maintainers; [ artemist ];
|
||||||
|
|
|
@ -1,24 +1,31 @@
|
||||||
{ lib, mkShell, python3, inkscape-with-extensions, inkscape-extensions, jupyter
|
{
|
||||||
|
lib,
|
||||||
|
mkShell,
|
||||||
|
python3,
|
||||||
|
inkscape-with-extensions,
|
||||||
|
inkscape-extensions,
|
||||||
|
jupyter,
|
||||||
}:
|
}:
|
||||||
mkShell {
|
mkShell {
|
||||||
packages = [
|
packages =
|
||||||
(inkscape-with-extensions.override {
|
[
|
||||||
inkscapeExtensions = with inkscape-extensions; [
|
(inkscape-with-extensions.override {
|
||||||
silhouette
|
inkscapeExtensions = with inkscape-extensions; [
|
||||||
inkcut
|
silhouette
|
||||||
axidraw
|
inkcut
|
||||||
];
|
axidraw
|
||||||
})
|
];
|
||||||
python3
|
})
|
||||||
jupyter
|
python3
|
||||||
] ++ (with python3.pkgs; [
|
jupyter
|
||||||
axicli
|
]
|
||||||
drawsvg
|
++ (with python3.pkgs; [
|
||||||
ipython
|
axicli
|
||||||
pillow
|
drawsvg
|
||||||
requests
|
ipython
|
||||||
vpype
|
pillow
|
||||||
vpype-gcode
|
requests
|
||||||
]);
|
vpype
|
||||||
|
vpype-gcode
|
||||||
|
]);
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,6 +1,28 @@
|
||||||
{ lib, mkShell, dotnetCorePackages, libX11, libgdiplus, SDL2_mixer, openal
|
{
|
||||||
, libsoundio, sndio, pulseaudio, vulkan-loader, ffmpeg, libICE, libSM, libXi
|
lib,
|
||||||
, libXcursor, libXext, libXrandr, fontconfig, glew, libGL, SDL2, udev }:
|
mkShell,
|
||||||
|
dotnetCorePackages,
|
||||||
|
libX11,
|
||||||
|
libgdiplus,
|
||||||
|
SDL2_mixer,
|
||||||
|
openal,
|
||||||
|
libsoundio,
|
||||||
|
sndio,
|
||||||
|
pulseaudio,
|
||||||
|
vulkan-loader,
|
||||||
|
ffmpeg,
|
||||||
|
libICE,
|
||||||
|
libSM,
|
||||||
|
libXi,
|
||||||
|
libXcursor,
|
||||||
|
libXext,
|
||||||
|
libXrandr,
|
||||||
|
fontconfig,
|
||||||
|
glew,
|
||||||
|
libGL,
|
||||||
|
SDL2,
|
||||||
|
udev,
|
||||||
|
}:
|
||||||
|
|
||||||
mkShell {
|
mkShell {
|
||||||
packages = [
|
packages = [
|
||||||
|
|
|
@ -1,34 +1,62 @@
|
||||||
{ lib, mkShell, zephyrPackages, cmake, ninja, gnumake, python3
|
{
|
||||||
, toolchains ? with zephyrPackages.toolchains; [ arm-zephyr-eabi ]
|
lib,
|
||||||
, enableWest ? false, zephyrSrc ? zephyrPackages.src, modules ? [ ]
|
mkShell,
|
||||||
, extraPackages ? [ ], extraAttrs ? { } }:
|
zephyrPackages,
|
||||||
let zephyr-sdk = zephyrPackages.sdk.override { inherit toolchains; };
|
cmake,
|
||||||
in mkShell ({
|
ninja,
|
||||||
packages = [ cmake ninja gnumake python3 ] ++ (with python3.pkgs;
|
gnumake,
|
||||||
[
|
python3,
|
||||||
# requirements-base.txt
|
toolchains ? with zephyrPackages.toolchains; [ arm-zephyr-eabi ],
|
||||||
pyelftools
|
enableWest ? false,
|
||||||
pyyaml
|
zephyrSrc ? zephyrPackages.src,
|
||||||
pykwalify
|
modules ? [ ],
|
||||||
canopen
|
extraPackages ? [ ],
|
||||||
packaging
|
extraAttrs ? { },
|
||||||
progress
|
}:
|
||||||
psutil
|
let
|
||||||
pylink-square
|
zephyr-sdk = zephyrPackages.sdk.override { inherit toolchains; };
|
||||||
pyserial
|
in
|
||||||
requests
|
mkShell (
|
||||||
anytree
|
{
|
||||||
intelhex
|
packages =
|
||||||
] ++ lib.optional enableWest python3.pkgs.west ++ extraPackages);
|
[
|
||||||
|
cmake
|
||||||
|
ninja
|
||||||
|
gnumake
|
||||||
|
python3
|
||||||
|
]
|
||||||
|
++ (
|
||||||
|
with python3.pkgs;
|
||||||
|
[
|
||||||
|
# requirements-base.txt
|
||||||
|
pyelftools
|
||||||
|
pyyaml
|
||||||
|
pykwalify
|
||||||
|
canopen
|
||||||
|
packaging
|
||||||
|
progress
|
||||||
|
psutil
|
||||||
|
pylink-square
|
||||||
|
pyserial
|
||||||
|
requests
|
||||||
|
anytree
|
||||||
|
intelhex
|
||||||
|
]
|
||||||
|
++ lib.optional enableWest python3.pkgs.west
|
||||||
|
++ extraPackages
|
||||||
|
);
|
||||||
|
|
||||||
ZEPHYR_TOOLCHAIN_VARIANT = "zephyr";
|
ZEPHYR_TOOLCHAIN_VARIANT = "zephyr";
|
||||||
ZEPHYR_SDK_INSTALL_DIR = "${zephyr-sdk}";
|
ZEPHYR_SDK_INSTALL_DIR = "${zephyr-sdk}";
|
||||||
} // lib.optionalAttrs (zephyrSrc != null) {
|
}
|
||||||
ZEPHYR_BASE = "${zephyrSrc}";
|
// lib.optionalAttrs (zephyrSrc != null) {
|
||||||
shellHook = ''
|
ZEPHYR_BASE = "${zephyrSrc}";
|
||||||
PATH="${zephyrSrc}/scripts:$PATH"
|
shellHook = ''
|
||||||
'';
|
PATH="${zephyrSrc}/scripts:$PATH"
|
||||||
} // lib.optionalAttrs (modules != [ ]) {
|
'';
|
||||||
ZEPHYR_MODULES =
|
}
|
||||||
lib.concatStringsSep ";" (map (pkg: pkg.passthru.modulePath) modules);
|
// lib.optionalAttrs (modules != [ ]) {
|
||||||
} // extraAttrs)
|
ZEPHYR_MODULES = lib.concatStringsSep ";" (map (pkg: pkg.passthru.modulePath) modules);
|
||||||
|
}
|
||||||
|
// extraAttrs
|
||||||
|
)
|
||||||
|
|
Loading…
Reference in a new issue