mirror of
https://github.com/mx42/nix_spacetimedb.git
synced 2026-01-14 13:49:54 +01:00
Initial commit
This commit is contained in:
7
default.nix
Executable file
7
default.nix
Executable file
@@ -0,0 +1,7 @@
|
|||||||
|
let
|
||||||
|
nixpkgs = fetchTarball "https://github.com/NixOS/nixpkgs/tarball/nixos-24.05";
|
||||||
|
pkgs = import nixpkgs { config = {}; overlays = []; };
|
||||||
|
in
|
||||||
|
{
|
||||||
|
spacetimedb = pkgs.callPackage ./spacetimedb.nix {};
|
||||||
|
}
|
||||||
1
result
Symbolic link
1
result
Symbolic link
@@ -0,0 +1 @@
|
|||||||
|
/nix/store/fqyql58pnwqnq0zs1x3k2ns784mgw1yz-spacetimedb-1.0.1
|
||||||
35
spacetimedb.nix
Executable file
35
spacetimedb.nix
Executable file
@@ -0,0 +1,35 @@
|
|||||||
|
{
|
||||||
|
stdenv,
|
||||||
|
lib,
|
||||||
|
fetchurl,
|
||||||
|
autoPatchelfHook,
|
||||||
|
libgcc,
|
||||||
|
}:
|
||||||
|
|
||||||
|
stdenv.mkDerivation {
|
||||||
|
pname = "spacetimedb";
|
||||||
|
version = "1.0.1";
|
||||||
|
src = fetchurl {
|
||||||
|
url = "https://github.com/clockworklabs/SpacetimeDB/releases/download/v1.0.1/spacetime-x86_64-unknown-linux-gnu.tar.gz";
|
||||||
|
hash = "sha256-dHxb9hNbQwfww9CJUp6IE4etxro9qvFQGyHOhJMYkV0=";
|
||||||
|
};
|
||||||
|
|
||||||
|
nativeBuildInputs = [ autoPatchelfHook ];
|
||||||
|
|
||||||
|
buildInputs = [
|
||||||
|
libgcc
|
||||||
|
stdenv.cc.cc.lib
|
||||||
|
];
|
||||||
|
|
||||||
|
unpackPhase = ''
|
||||||
|
runHook preUnpack
|
||||||
|
mkdir -p $out/bin
|
||||||
|
tar -xvf $src -C $out/bin
|
||||||
|
runHook postUnpack
|
||||||
|
'';
|
||||||
|
|
||||||
|
installPhase = ''
|
||||||
|
runHook preInstall
|
||||||
|
runHook postInstall
|
||||||
|
'';
|
||||||
|
}
|
||||||
Reference in New Issue
Block a user