Build tasktree with carnix
This commit is contained in:
parent
f17a3be347
commit
0c94ccae4d
|
@ -1,4 +1,4 @@
|
|||
# Generated by carnix 0.6.6: carnix -o deps.nix /home/maralorn/code/tasktree/Cargo.lock
|
||||
# Generated by carnix 0.7.2: carnix nix --src .
|
||||
{ lib, buildPlatform, buildRustCrate, fetchgit }:
|
||||
let kernel = buildPlatform.parsed.kernel.name;
|
||||
abi = buildPlatform.parsed.abi.name;
|
||||
|
@ -19,6 +19,7 @@ let kernel = buildPlatform.parsed.kernel.name;
|
|||
in
|
||||
rec {
|
||||
tasktree = f: tasktree_0_1_0 { features = tasktree_0_1_0_features { tasktree_0_1_0 = f; }; };
|
||||
__all = [ (tasktree {}) ];
|
||||
aho_corasick_0_6_3_ = { dependencies?[], buildDependencies?[], features?[] }: buildRustCrate {
|
||||
crateName = "aho-corasick";
|
||||
version = "0.6.3";
|
||||
|
@ -362,7 +363,7 @@ rec {
|
|||
crateName = "tasktree";
|
||||
version = "0.1.0";
|
||||
authors = [ "Malte Brandy <malte.brandy@maralorn.de>" ];
|
||||
src = /home/maralorn/code/tasktree;
|
||||
src = ./.;
|
||||
inherit dependencies buildDependencies features;
|
||||
};
|
||||
thread_local_0_3_4_ = { dependencies?[], buildDependencies?[], features?[] }: buildRustCrate {
|
||||
|
@ -1692,7 +1693,7 @@ rec {
|
|||
gdk_0_5_3.default = (f.gdk_0_5_3.default or false);
|
||||
glib_0_1_3.default = (f.glib_0_1_3.default or false);
|
||||
gtk_0_1_3.default = (f.gtk_0_1_3.default or false);
|
||||
gtk_0_1_3.v3_22 = true;
|
||||
gtk_0_1_3.v3_18 = true;
|
||||
lazy_static_0_2_2.default = true;
|
||||
regex_0_2_2.default = true;
|
||||
serde_0_9_15.default = true;
|
|
@ -1,39 +1,48 @@
|
|||
{ rustPlatform, gnome3, atk, cairo, gdk_pixbuf, glib, pango, makeDesktopItem, fetchFromGitHub }:
|
||||
let
|
||||
desktopItem = makeDesktopItem {
|
||||
name = "Tasktree";
|
||||
exec = "tasktree";
|
||||
icon = "tasktree";
|
||||
comment = "A taskwarrior UI";
|
||||
desktopName = "Tasktree";
|
||||
genericName = "Tasktree";
|
||||
categories = "Office;";
|
||||
};
|
||||
in
|
||||
with rustPlatform; buildRustPackage rec {
|
||||
name = "tasktree";
|
||||
version = "abb312f";
|
||||
src = fetchFromGitHub {
|
||||
rev = version;
|
||||
owner = "maralorn";
|
||||
repo = "tasktree";
|
||||
sha256 = "139xjvi7b62k3075b4md9hdkb1xafhhiyz2yhbb96d73j1gkqs77";
|
||||
};
|
||||
depsSha256 = "14acvigygrrqyvxra2n01vpadc3mcf8981jrggpvwfbz58jrsa7h";
|
||||
cargoSha256 = "14acvigygrrqyvxra2n01vpadc3mcf8981jrggpvwfbz58jrsa7h";
|
||||
{ pkgs, defaultCrateOverrides, makeDesktopItem, atk , pango, gnome3, cairo, gdk_pixbuf, glib, ... }:
|
||||
((pkgs.callPackage ./Cargo.nix {}).tasktree_0_1_0 {}).override {
|
||||
crateOverrides = defaultCrateOverrides // {
|
||||
atk-sys = attr: { buildInputs = [ atk ]; };
|
||||
pango-sys = attr: { buildInputs = [ pango glib ]; };
|
||||
gio = attr: { buildInputs = [ glib ]; };
|
||||
gdk-sys = attr: { buildInputs = [ gdk_pixbuf glib cairo pango ]; };
|
||||
gtk-sys = attr: { buildInputs = [ gdk_pixbuf glib cairo pango atk gnome3.gtk ]; };
|
||||
gdk = attr: { buildInputs = [ cairo gnome3.gtk gdk_pixbuf pango ]; };
|
||||
gtk = attr: { buildInputs = [ cairo atk gnome3.gtk gdk_pixbuf pango ]; };
|
||||
tasktree = attrs:
|
||||
let
|
||||
desktopItem = makeDesktopItem {
|
||||
name = "Tasktree";
|
||||
exec = "tasktree";
|
||||
icon = "tasktree";
|
||||
comment = "A taskwarrior UI";
|
||||
desktopName = "Tasktree";
|
||||
genericName = "Tasktree";
|
||||
categories = "Office;";
|
||||
};
|
||||
in {
|
||||
|
||||
propagatedBuildInputs = [ gnome3.gtk atk cairo gdk_pixbuf glib pango ];
|
||||
postInstall = ''
|
||||
function installIcon () {
|
||||
mkdir -p $out/share/icons/hicolor/$1/apps/
|
||||
cp icons/$1.png $out/share/icons/hicolor/$1/apps/tasktree.png
|
||||
}
|
||||
installIcon "16x16"
|
||||
installIcon "32x32"
|
||||
installIcon "64x64"
|
||||
|
||||
mkdir -p $out/share/applications
|
||||
ln -s ${desktopItem}/share/applications/* $out/share/applications/
|
||||
'';
|
||||
doCheck = false;
|
||||
postInstall = ''
|
||||
mkdir -p $out/share/applications
|
||||
ln -s ${desktopItem}/share/applications/* $out/share/applications/
|
||||
rm $out/lib/link
|
||||
'';
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
|
||||
#propagatedBuildInputs = [ gnome3.gtk atk cairo gdk_pixbuf glib pango ];
|
||||
#postInstall = ''
|
||||
#function installIcon () {
|
||||
#mkdir -p $out/share/icons/hicolor/$1/apps/
|
||||
#cp icons/$1.png $out/share/icons/hicolor/$1/apps/tasktree.png
|
||||
#}
|
||||
#installIcon "16x16"
|
||||
#installIcon "32x32"
|
||||
#installIcon "64x64"
|
||||
|
||||
#mkdir -p $out/share/applications
|
||||
#ln -s ${desktopItem}/share/applications/* $out/share/applications/
|
||||
#'';
|
||||
#doCheck = false;
|
||||
#}
|
||||
|
|
Loading…
Reference in a new issue