diff --git a/pkgs/applications/emulators/blink/default.nix b/pkgs/applications/emulators/blink/default.nix new file mode 100644 index 000000000000..403f5a20cf36 --- /dev/null +++ b/pkgs/applications/emulators/blink/default.nix @@ -0,0 +1,33 @@ +{ stdenv, fetchFromGitHub, lib }: + +stdenv.mkDerivation (finalAttrs: { + pname = "blink"; + version = "1.0.0"; + + src = fetchFromGitHub { + owner = "jart"; + repo = "blink"; + rev = finalAttrs.version; + hash = "sha256-W7yL7Ut3MRygJhFGr+GIj/CK57MkuDTcenft8IvH7jU="; + }; + + # 'make check' requires internet connection + doCheck = true; + checkPhase = '' + make test + ''; + + meta = { + description = "Tiniest x86-64-linux emulator"; + longDescription = '' + blink is a virtual machine that runs x86-64-linux programs on different operating systems and hardware architectures. It's designed to do the same thing as the qemu-x86_64 command, except that + - blink is much smaller in size than qemu-x86_64 + - blink will run your Linux binaries on any POSIX platform, whereas qemu-x86_64 only supports Linux + - blink goes 2x faster than qemu-x86_64 on some benchmarks, such as SSE integer / floating point math. Blink is also faster at running ephemeral programs such as compilers + ''; + + homepage = "https://github.com/jart/blink"; + license = lib.licenses.isc; + maintainers = with lib.maintainers; [ t4ccer ]; + }; +}) diff --git a/pkgs/top-level/aliases.nix b/pkgs/top-level/aliases.nix index b10d82bd3978..3c670a7e851c 100644 --- a/pkgs/top-level/aliases.nix +++ b/pkgs/top-level/aliases.nix @@ -172,7 +172,6 @@ mapAliases ({ bitwarden_rs-vault = vaultwarden-vault; - blink = throw "blink has been removed from nixpkgs, it was unmaintained and required python2 at the time of removal"; # Added 2022-01-12 bs1770gain = throw "bs1770gain has been removed from nixpkgs, as it had no maintainer or reverse dependencies"; # Added 2021-01-02 bsod = throw "bsod has been removed: deleted by upstream"; # Added 2022-01-07 btc1 = throw "btc1 has been removed, it was abandoned by upstream"; # Added 2020-11-03 diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index 73b601bbb8e9..a98d40f7fe66 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -3870,6 +3870,8 @@ with pkgs; bless = callPackage ../applications/editors/bless { }; + blink = callPackage ../applications/emulators/blink { }; + blink1-tool = callPackage ../tools/misc/blink1-tool { }; blis = callPackage ../development/libraries/science/math/blis { };