Hello guys,
I am trying to make a lando (https://lando.dev) package for NixOS. I am not at all an expert in nix and already tried to google and see how to create new packages from deb.
This is what I cam up with so far:
{ stdenv, dpkg, docker-compose, gcc10, nodejs-14_x, glibc, gcc-unwrapped, autoPatchelfHook, zlib }:
let
# Please keep the version x.y.0.z and do not update to x.y.76.z because the
# source of the latter disappears much faster.
version = "1.0.0";
src = ./lando-stable.deb;
in stdenv.mkDerivation {
name = "lando-${version}";
system = "x86_64-linux";
inherit src;
# Required for compilation
nativeBuildInputs = [
autoPatchelfHook # Automatically setup the loader, and do the magic
dpkg
];
# Required at running time
buildInputs = [
glibc
gcc-unwrapped
docker-compose
zlib
gcc10
nodejs-14_x
];
unpackPhase = "true";
# Extract and copy executable in $out/bin
installPhase = ''
mkdir -p $out
dpkg -x $src $out
chmod 755 $out
'';
meta = with stdenv.lib; {
description = "Lando";
homepage = https://lando.dev;
license = licenses.mit;
maintainers = with stdenv.lib.maintainers; [ ];
platforms = [ "x86_64-linux" ];
};
}
But still, after nix-build I can not run the executable and I can not figure out what the problem is.
I was thinking, maybe it is the dependency for docker-compose?
Any help would be highly appreciated. (If you would like, I posted as well a job, so happy to pay for the solution: https://www.upwork.com/jobs/~0118c7802ba4ea5348)
Thanks in advance,
Alexej