uboot: (firmwareOdroidC2/C4) don't invoke patch tool, use patches = [] instead

https://github.com/NixOS/nixpkgs/blob/master/pkgs/stdenv/generic/setup.sh#L948
this can do it nicely.

Signed-off-by: Anton Arapov <anton@deadbeef.mx>
This commit is contained in:
Anton Arapov 2021-04-03 12:58:10 +02:00 committed by Alan Daniels
commit 56de2bcd43
30691 changed files with 3076956 additions and 0 deletions

View file

@ -0,0 +1,38 @@
{ lib, stdenv, fetchurl, makeWrapper, adoptopenjdk-bin, jre }:
stdenv.mkDerivation rec {
pname = "tlaplus";
version = "1.7.2";
src = fetchurl {
url = "https://github.com/tlaplus/tlaplus/releases/download/v${version}/tla2tools.jar";
sha256 = "sha256-+hhUPkTtWXSoW9LGDA3BZiCuEXaA6o5pPSaRmZ7ZCyI=";
};
nativeBuildInputs = [ makeWrapper ];
buildInputs = [ adoptopenjdk-bin ];
dontUnpack = true;
installPhase = ''
mkdir -p $out/share/java $out/bin
cp $src $out/share/java/tla2tools.jar
makeWrapper ${jre}/bin/java $out/bin/tlc \
--add-flags "-XX:+UseParallelGC -cp $out/share/java/tla2tools.jar tlc2.TLC"
makeWrapper ${jre}/bin/java $out/bin/tlasany \
--add-flags "-XX:+UseParallelGC -cp $out/share/java/tla2tools.jar tla2sany.SANY"
makeWrapper ${jre}/bin/java $out/bin/pcal \
--add-flags "-XX:+UseParallelGC -cp $out/share/java/tla2tools.jar pcal.trans"
makeWrapper ${jre}/bin/java $out/bin/tlatex \
--add-flags "-XX:+UseParallelGC -cp $out/share/java/tla2tools.jar tla2tex.TLA"
'';
meta = {
description = "An algorithm specification language with model checking tools";
homepage = "http://lamport.azurewebsites.net/tla/tla.html";
sourceProvenance = with lib.sourceTypes; [ binaryBytecode ];
license = lib.licenses.mit;
platforms = lib.platforms.unix;
maintainers = with lib.maintainers; [ florentc thoughtpolice ];
};
}

View file

@ -0,0 +1,58 @@
{ fetchurl
, lib
, stdenv
, ocaml
, isabelle
, cvc3
, perl
, wget
, which
}:
stdenv.mkDerivation rec {
pname = "tlaps";
version = "1.4.5";
src = fetchurl {
url = "https://tla.msr-inria.inria.fr/tlaps/dist/${version}/tlaps-${version}.tar.gz";
sha256 = "c296998acd14d5b93a8d5be7ee178007ef179957465966576bda26944b1b7fca";
};
buildInputs = [ ocaml isabelle cvc3 perl wget which ];
installPhase = ''
mkdir -pv "$out"
export HOME="$out"
export PATH=$out/bin:$PATH
pushd zenon
./configure --prefix $out
make
make install
popd
pushd isabelle
isabelle build -b Pure
popd
pushd tlapm
./configure --prefix $out
make all
make install
'';
meta = {
description = "Mechanically check TLA+ proofs";
longDescription = ''
TLA+ is a general-purpose formal specification language that is
particularly useful for describing concurrent and distributed
systems. The TLA+ proof language is declarative, hierarchical,
and scalable to large system specifications. It provides a
consistent abstraction over the various backend verifiers.
'';
homepage = "https://tla.msr-inria.inria.fr/tlaps/content/Home.html";
license = lib.licenses.bsd2;
platforms = lib.platforms.unix;
maintainers = with lib.maintainers; [ florentc ];
};
}

View file

@ -0,0 +1,103 @@
{ lib
, fetchzip
, makeShellWrapper
, makeDesktopItem
, stdenv
, gtk3
, libXtst
, glib
, zlib
, wrapGAppsHook
}:
let
desktopItem = makeDesktopItem rec {
name = "TLA+Toolbox";
exec = "tla-toolbox";
icon = "tla-toolbox";
comment = "IDE for TLA+";
desktopName = name;
genericName = comment;
categories = [ "Development" ];
startupWMClass = "TLA+ Toolbox";
};
in
stdenv.mkDerivation rec {
pname = "tla-toolbox";
version = "1.7.1";
src = fetchzip {
url = "https://tla.msr-inria.inria.fr/tlatoolbox/products/TLAToolbox-${version}-linux.gtk.x86_64.zip";
sha256 = "02a2y2mkfab5cczw8g604m61h4xr0apir49zbd1aq6mmgcgngw80";
};
buildInputs = [ gtk3 ];
nativeBuildInputs = [
makeShellWrapper
wrapGAppsHook
];
dontWrapGApps = true;
installPhase = ''
runHook preInstall
mkdir -p "$out/bin"
cp -r "$src" "$out/toolbox"
chmod -R +w "$out/toolbox"
fixupPhase
gappsWrapperArgsHook
patchelf \
--set-interpreter $(cat $NIX_CC/nix-support/dynamic-linker) \
"$out/toolbox/toolbox"
patchelf \
--set-interpreter $(cat $NIX_CC/nix-support/dynamic-linker) \
--set-rpath "${lib.makeLibraryPath [ zlib ]}:$(patchelf --print-rpath $(find "$out/toolbox" -name java))" \
"$(find "$out/toolbox" -name java)"
patchelf \
--set-interpreter $(cat $NIX_CC/nix-support/dynamic-linker) \
"$(find "$out/toolbox" -name jspawnhelper)"
makeShellWrapper $out/toolbox/toolbox $out/bin/tla-toolbox \
--chdir "$out/toolbox" \
--add-flags "-data ~/.tla-toolbox" \
--prefix LD_LIBRARY_PATH : "${lib.makeLibraryPath [ gtk3 libXtst glib zlib ]}" \
"''${gappsWrapperArgs[@]}"
echo -e "\nCreating TLA Toolbox icons..."
pushd "$src"
for icon_in in $(find . -path "./plugins/*/icons/full/etool16/tla_launch_check_wiz_*.png")
do
icon_size=$(echo $icon_in | grep -Po "wiz_\K[0-9]+")
icon_out="$out/share/icons/hicolor/$icon_size""x$icon_size/apps/tla-toolbox.png"
mkdir -p "$(dirname $icon_out)"
cp "$icon_in" "$icon_out"
done
popd
echo -e "\nCreating TLA Toolbox desktop entry..."
cp -r "${desktopItem}/share/applications"* "$out/share/applications"
runHook postInstall
'';
meta = {
homepage = "http://research.microsoft.com/en-us/um/people/lamport/tla/toolbox.html";
description = "IDE for the TLA+ tools";
longDescription = ''
Integrated development environment for the TLA+ tools, based on Eclipse. You can use it
to create and edit your specs, run the PlusCal translator, view the pretty-printed
versions of your modules, run the TLC model checker, and run TLAPS, the TLA+ proof system.
'';
# http://lamport.azurewebsites.net/tla/license.html
license = with lib.licenses; [ mit ];
platforms = [ "x86_64-linux" ];
maintainers = [ ];
};
}