libk  Artifact [1899f7d930]

Artifact 1899f7d93000176be7136762076a05aadac9a11f539282da0dadacb7b1fdd40c:


{stdenv, m4, yasm, cmark, groff}:

stdenv.mkDerivation {
  name = "libk";
  version = "0.0.0";

  src = stdenv.lib.cleanSource ../.;

  # Need to figure out how split builds work... but that also kinda needs
  # an install script first, so.
  nativeBuildInputs = [ m4 yasm cmark groff ];

  buildPhase = ''
    patchShebangs --build global/build-id.sh global/build-manpage.sh
    env os=lin arch=x86 bits=64 doc_pdf=false library=both \
    bash build.sh
  '';

  installPhase = ''
    env prefix=$prefix bash install.sh
  '';

  meta = with stdenv.lib; {
    description = "A modern replacement for libc";
    homepage = https://c.comint.su/libk;
    changelog = "https://c.comint.su/libk/timeline";
    license = licenses.agpl3;
    # Doesn't actually match w/ supported platforms, but...
    platforms = platforms.unix;
  };
}