2020-09-10 19:38:25 +01:00
|
|
|
{ stdenv, fetchFromGitHub, fetchurl, glib, gtk-engine-murrine, gtk_engines, inkscape, optipng, sassc, which }:
|
2019-01-02 22:23:49 +00:00
|
|
|
|
|
|
|
stdenv.mkDerivation rec {
|
|
|
|
pname = "mojave-gtk-theme";
|
2020-11-30 22:33:30 +00:00
|
|
|
version = "2020-11-29";
|
2019-01-02 22:23:49 +00:00
|
|
|
|
2019-12-13 12:57:14 +00:00
|
|
|
srcs = [
|
|
|
|
(fetchFromGitHub {
|
|
|
|
owner = "vinceliuice";
|
|
|
|
repo = pname;
|
|
|
|
rev = version;
|
2020-11-30 22:33:30 +00:00
|
|
|
sha256 = "07lcg28y0scpii29j85343kmcga4wyaayjpx9a118z838mnvb757";
|
2019-12-13 12:57:14 +00:00
|
|
|
})
|
|
|
|
(fetchurl {
|
|
|
|
url = "https://github.com/vinceliuice/Mojave-gtk-theme/raw/11741a99d96953daf9c27e44c94ae50a7247c0ed/macOS_Mojave_Wallpapers.tar.xz";
|
|
|
|
sha256 = "18zzkwm1kqzsdaj8swf0xby1n65gxnyslpw4lnxcx1rphip0rwf7";
|
|
|
|
})
|
|
|
|
];
|
|
|
|
|
|
|
|
sourceRoot = "source";
|
2019-01-02 22:23:49 +00:00
|
|
|
|
2020-09-10 19:38:25 +01:00
|
|
|
nativeBuildInputs = [ glib inkscape optipng sassc which ];
|
2020-03-19 11:51:48 +00:00
|
|
|
|
2019-01-02 22:23:49 +00:00
|
|
|
buildInputs = [ gtk_engines ];
|
|
|
|
|
|
|
|
propagatedUserEnvPkgs = [ gtk-engine-murrine ];
|
|
|
|
|
2020-03-19 11:51:48 +00:00
|
|
|
postPatch = ''
|
2019-01-02 22:23:49 +00:00
|
|
|
patchShebangs .
|
2020-03-19 11:51:48 +00:00
|
|
|
|
|
|
|
for f in render-assets.sh \
|
|
|
|
src/assets/gtk-2.0/render-assets.sh \
|
|
|
|
src/assets/gtk-3.0/common-assets/render-assets.sh \
|
|
|
|
src/assets/gtk-3.0/windows-assets/render-assets.sh \
|
|
|
|
src/assets/metacity-1/render-assets.sh \
|
|
|
|
src/assets/xfwm4/render-assets.sh
|
|
|
|
do
|
|
|
|
substituteInPlace $f \
|
2020-09-10 19:38:25 +01:00
|
|
|
--replace /usr/bin/inkscape ${inkscape}/bin/inkscape \
|
2020-03-19 11:51:48 +00:00
|
|
|
--replace /usr/bin/optipng ${optipng}/bin/optipng
|
|
|
|
done
|
|
|
|
|
|
|
|
# Shut up inkscape's warnings
|
|
|
|
export HOME="$NIX_BUILD_ROOT"
|
|
|
|
'';
|
|
|
|
|
|
|
|
installPhase = ''
|
2019-01-02 22:23:49 +00:00
|
|
|
name= ./install.sh -d $out/share/themes
|
2019-12-13 12:57:14 +00:00
|
|
|
install -D -t $out/share/wallpapers ../"macOS Mojave Wallpapers"/*
|
2019-01-02 22:23:49 +00:00
|
|
|
'';
|
|
|
|
|
|
|
|
meta = with stdenv.lib; {
|
|
|
|
description = "Mac OSX Mojave like theme for GTK based desktop environments";
|
2020-04-01 02:11:51 +01:00
|
|
|
homepage = "https://github.com/vinceliuice/Mojave-gtk-theme";
|
2019-01-02 22:23:49 +00:00
|
|
|
license = licenses.gpl3;
|
|
|
|
platforms = platforms.unix;
|
|
|
|
maintainers = [ maintainers.romildo ];
|
|
|
|
};
|
|
|
|
}
|