foot: refactor derivation

* Change from fetchzip to fetchFromGitea
* Set `mesonBuildType` instead of supplying the `--build-type=`
  argument in `mesonFlags` as the build type option will be
  repeated.
This commit is contained in:
polykernel 2021-08-08 10:30:42 -04:00
parent c10ded1bb2
commit ba4fcbb33f

View file

@ -1,6 +1,6 @@
{ stdenv { stdenv
, lib , lib
, fetchzip , fetchFromGitea
, fetchurl , fetchurl
, fetchpatch , fetchpatch
, runCommandNoCC , runCommandNoCC
@ -94,8 +94,11 @@ stdenv.mkDerivation rec {
pname = "foot"; pname = "foot";
inherit version; inherit version;
src = fetchzip { src = fetchFromGitea {
url = "https://codeberg.org/dnkl/${pname}/archive/${version}.tar.gz"; domain = "codeberg.org";
owner = "dnkl";
repo = pname;
rev = version;
sha256 = "1k0alz991cslls4926c5gq02pdq0vfw9jfpprh2a1vb59xgikv7h"; sha256 = "1k0alz991cslls4926c5gq02pdq0vfw9jfpprh2a1vb59xgikv7h";
}; };
@ -147,8 +150,9 @@ stdenv.mkDerivation rec {
export AR="${ar}" export AR="${ar}"
''; '';
mesonBuildType = "release";
mesonFlags = [ mesonFlags = [
"--buildtype=release"
"-Db_lto=true" "-Db_lto=true"
"-Dterminfo-install-location=${placeholder "terminfo"}/share/terminfo" "-Dterminfo-install-location=${placeholder "terminfo"}/share/terminfo"
]; ];