about summary refs log tree commit diff
path: root/pkgs/development/tools/misc
diff options
context:
space:
mode:
authorFrederik Rietdijk <fridh@fridh.nl>2019-11-11 12:09:26 +0100
committerFrederik Rietdijk <fridh@fridh.nl>2019-11-11 12:09:26 +0100
commit73b88e17dda6eb6546e0fdcefeb3251f806d88d3 (patch)
tree4ec0603851ec82737ccbc387fe1db1bb63a572fa /pkgs/development/tools/misc
parent539e94030c226562433e5ff96299dffb0641427a (diff)
parentcf27abf534930ecb1657c4a4e7466ed15c4a2076 (diff)
downloadnixlib-73b88e17dda6eb6546e0fdcefeb3251f806d88d3.tar
nixlib-73b88e17dda6eb6546e0fdcefeb3251f806d88d3.tar.gz
nixlib-73b88e17dda6eb6546e0fdcefeb3251f806d88d3.tar.bz2
nixlib-73b88e17dda6eb6546e0fdcefeb3251f806d88d3.tar.lz
nixlib-73b88e17dda6eb6546e0fdcefeb3251f806d88d3.tar.xz
nixlib-73b88e17dda6eb6546e0fdcefeb3251f806d88d3.tar.zst
nixlib-73b88e17dda6eb6546e0fdcefeb3251f806d88d3.zip
Merge staging-next into staging
Diffstat (limited to 'pkgs/development/tools/misc')
-rw-r--r--pkgs/development/tools/misc/argbash/default.nix27
-rw-r--r--pkgs/development/tools/misc/editorconfig-checker/default.nix22
-rw-r--r--pkgs/development/tools/misc/fsatrace/default.nix17
-rw-r--r--pkgs/development/tools/misc/lttng-tools/default.nix4
-rw-r--r--pkgs/development/tools/misc/stm32cubemx/default.nix78
5 files changed, 139 insertions, 9 deletions
diff --git a/pkgs/development/tools/misc/argbash/default.nix b/pkgs/development/tools/misc/argbash/default.nix
new file mode 100644
index 000000000000..b8e3ff4a9dfe
--- /dev/null
+++ b/pkgs/development/tools/misc/argbash/default.nix
@@ -0,0 +1,27 @@
+{ stdenv, fetchFromGitHub, autoconf }:
+
+stdenv.mkDerivation rec {
+  pname = "argbash";
+
+  version = "2.8.1";
+
+  src = fetchFromGitHub {
+    owner = "matejak";
+    repo = "argbash";
+    rev = "${version}";
+    sha256 = "0zara7v3pnwiwkpb0x0g37pxhmim4425q4gba712f6djj115r1mr";
+  };
+
+  sourceRoot = "${src}/resources";
+
+  nativeBuildInputs = [ autoconf ];
+
+  makeFlags = [ "PREFIX=$(out)" ];
+
+  meta = with stdenv.lib; {
+    description = "Bash argument parsing code generator";
+    homepage = "https://argbash.io/";
+    license = licenses.free; # custom license.  See LICENSE in source repo.
+    maintainers = with maintainers; [ rencire ];
+  };
+}
diff --git a/pkgs/development/tools/misc/editorconfig-checker/default.nix b/pkgs/development/tools/misc/editorconfig-checker/default.nix
new file mode 100644
index 000000000000..cbb6a38f67a8
--- /dev/null
+++ b/pkgs/development/tools/misc/editorconfig-checker/default.nix
@@ -0,0 +1,22 @@
+{ buildGoModule, fetchFromGitHub, lib }:
+
+buildGoModule rec {
+  pname = "editorconfig-checker";
+  version = "2.0.2";
+
+  src = fetchFromGitHub {
+    owner = "editorconfig-checker";
+    repo = "editorconfig-checker";
+    rev = "${version}";
+    sha256 = "0v2ml9r8b5admi3sv80wa1pwl9qnz03q2p84vgcmgg2nv1v6yxf3";
+  };
+
+  modSha256 = "09b1v9gyh6827yqlfxxxq3lcqhd5snn3n7gdlbjmga3wyp2x4g2r";
+
+  meta = with lib; {
+    description = "A tool to verify that your files are in harmony with your .editorconfig";
+    homepage = "https://editorconfig-checker.github.io/";
+    license = licenses.mit;
+    maintainers = with maintainers; [ uri-canva ];
+  };
+}
diff --git a/pkgs/development/tools/misc/fsatrace/default.nix b/pkgs/development/tools/misc/fsatrace/default.nix
index 152792dcee25..b8202f94ce9b 100644
--- a/pkgs/development/tools/misc/fsatrace/default.nix
+++ b/pkgs/development/tools/misc/fsatrace/default.nix
@@ -2,23 +2,26 @@
 
 stdenv.mkDerivation rec {
   pname = "fsatrace";
-  version = "0.0.1-160";
+  version = "0.0.1-324";
 
   src = fetchFromGitHub {
     owner = "jacereda";
     repo = "fsatrace";
-    rev = "2bf89d836e0156e68f121b0ffeedade7c9381f77";
-    sha256 = "0bndfmm0y738azwzf6m6xg6gjnrwcqlfjsampk67vga40yylwkbw";
+    rev = "41fbba17da580f81ababb32ec7e6e5fd49f11473";
+    sha256 = "1ihm2v723idd6m0kc1z9v73hmfvh2v0vjs8wvx5w54jaxh3lmj1y";
   };
 
-  preConfigure = ''
-    mkdir -p $out/libexec/${pname}-${version}
-    export makeFlags=INSTALLDIR=$out/libexec/${pname}-${version}
+  installDir = "libexec/${pname}-${version}";
+
+  makeFlags = [ "INSTALLDIR=$(out)/$(installDir)" ];
+
+  preInstall = ''
+    mkdir -p $out/$installDir
   '';
 
   postInstall = ''
     mkdir -p $out/bin
-    ln -s $out/libexec/${pname}-${version}/fsatrace $out/bin/
+    ln -s $out/$installDir/fsatrace $out/bin/fsatrace
   '';
 
   meta = with stdenv.lib; {
diff --git a/pkgs/development/tools/misc/lttng-tools/default.nix b/pkgs/development/tools/misc/lttng-tools/default.nix
index a02bb2c9f2fe..815d5aac4069 100644
--- a/pkgs/development/tools/misc/lttng-tools/default.nix
+++ b/pkgs/development/tools/misc/lttng-tools/default.nix
@@ -2,11 +2,11 @@
 
 stdenv.mkDerivation rec {
   pname = "lttng-tools";
-  version = "2.10.8";
+  version = "2.11.0";
 
   src = fetchurl {
     url = "https://lttng.org/files/lttng-tools/${pname}-${version}.tar.bz2";
-    sha256 = "03dkwvmiqbr7dcnrk8hw8xd9i0vrx6xxz8wal56mfypxz52i2jk6";
+    sha256 = "1g0g7ypxvc7wd5x4d4ixmfgl9yk0lxax3ymm95hcjwxn5p497r6w";
   };
 
   nativeBuildInputs = [ pkgconfig ];
diff --git a/pkgs/development/tools/misc/stm32cubemx/default.nix b/pkgs/development/tools/misc/stm32cubemx/default.nix
new file mode 100644
index 000000000000..53336ab417cd
--- /dev/null
+++ b/pkgs/development/tools/misc/stm32cubemx/default.nix
@@ -0,0 +1,78 @@
+{ stdenv, requireFile, makeDesktopItem, libicns, imagemagick, zstd, jre }:
+
+let
+  version = "5.3.0";
+  desktopItem = makeDesktopItem {
+    name = "stm32CubeMX";
+    exec = "stm32cubemx";
+    desktopName = "STM32CubeMX";
+    categories = "Application;Development;";
+    icon = "stm32cubemx";
+  };
+in
+stdenv.mkDerivation rec {
+  pname = "stm32cubemx";
+  inherit version;
+
+  src = requireFile rec {
+    name = "STM32CubeMX.tar.zst";
+    message = ''
+      Unfortunately, we cannot download file ${name} automatically.
+      Please proceed with the following steps to download and add it to the Nix
+      store yourself:
+
+      1. get en.STM32CubeMX_${builtins.replaceStrings ["."] ["-"] version}.zip
+      2. unzip en.STM32CubeMX_${builtins.replaceStrings ["."] ["-"] version}.zip
+      3. run the setup: java -jar SetupSTM32CubeMX-${version}.exe
+      4. create a tar from created folder: tar --zstd -cf ${name} STM32CubeMX
+      5. add the result to the store: nix-prefetch-url file://\$PWD/${name}
+
+      Notice: The setup will quit with an error about /bin/chmod
+    '';
+    sha256 = "1r5k5wmsvw1w2nfs3nb4gc6pb3j0x6bqljn9jzc4r8y5bxc34rr8";
+  };
+
+  nativeBuildInputs = [ libicns imagemagick zstd ];
+
+  buildCommand = ''
+    mkdir -p $out/{bin,opt,share/applications}
+
+    tar --extract --zstd --file $src --directory $out/opt/
+    chmod +rx $out/opt/STM32CubeMX/STM32CubeMX.exe
+
+    cat << EOF > $out/bin/${pname}
+    #!${stdenv.shell}
+    ${jre}/bin/java -jar $out/opt/STM32CubeMX/STM32CubeMX.exe
+    EOF
+    chmod +x $out/bin/${pname}
+
+    icns2png --extract $out/opt/STM32CubeMX/${pname}.icns
+    ls
+    for size in 16 24 32 48 64 128 256; do
+      mkdir -pv $out/share/icons/hicolor/"$size"x"$size"/apps
+      if [ -e ${pname}_"$size"x"$size"x32.png ]; then
+        mv ${pname}_"$size"x"$size"x32.png \
+          $out/share/icons/hicolor/"$size"x"$size"/apps/${pname}.png
+      else
+        convert -resize "$size"x"$size" ${pname}_256x256x32.png \
+          $out/share/icons/hicolor/"$size"x"$size"/apps/${pname}.png
+      fi
+    done;
+
+    ln -s ${desktopItem}/share/applications/* $out/share/applications
+  '';
+
+  meta = with stdenv.lib; {
+    description = ''
+      A graphical tool that allows a very easy configuration of STM32
+      microcontrollers and microprocessors, as well as the generation of the
+      corresponding initialization C code for the Arm® Cortex®-M core or a
+      partial Linux® Device Tree for Arm® Cortex®-A core), through a
+      step-by-step process.        
+    '';
+    homepage = "https://www.st.com/en/development-tools/stm32cubemx.html";
+    license = licenses.unfree;
+    maintainers = with maintainers; [ wucke13 ];
+    platforms = platforms.all;
+  };
+}