mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-12-17 03:03:37 +00:00
4a7f99d55d
Part of: https://github.com/NixOS/nixpkgs/issues/108938 meta = with stdenv.lib; is a widely used pattern. We want to slowly remove the `stdenv.lib` indirection and encourage people to use `lib` directly. Thus let’s start with the meta field. This used a rewriting script to mostly automatically replace all occurances of this pattern, and add the `lib` argument to the package header if it doesn’t exist yet. The script in its current form is available at https://cs.tvl.fyi/depot@2f807d7f141068d2d60676a89213eaa5353ca6e0/-/blob/users/Profpatsch/nixpkgs-rewriter/default.nix
50 lines
1.3 KiB
Nix
50 lines
1.3 KiB
Nix
{ lib, stdenv, fetchFromGitHub
|
|
, alsaLib, freetype, xorg, curl, libGL, libjack2, gnome3
|
|
, pkgconfig, makeWrapper
|
|
}:
|
|
|
|
stdenv.mkDerivation rec {
|
|
pname = "helio-workstation";
|
|
version = "3.3";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "helio-fm";
|
|
repo = pname;
|
|
rev = version;
|
|
fetchSubmodules = true;
|
|
sha256 = "sha256-meeNqV1jKUwWc7P3p/LicPsbpzpKKFmQ1wP9DuXc9NY=";
|
|
};
|
|
|
|
buildInputs = [
|
|
alsaLib freetype xorg.libX11 xorg.libXext xorg.libXinerama xorg.libXrandr
|
|
xorg.libXcursor xorg.libXcomposite curl libGL libjack2 gnome3.zenity
|
|
];
|
|
|
|
nativeBuildInputs = [ pkgconfig makeWrapper ];
|
|
|
|
preBuild = ''
|
|
cd Projects/LinuxMakefile
|
|
substituteInPlace Makefile --replace alsa "alsa jack"
|
|
'';
|
|
buildFlags = [ "CONFIG=Release64" ];
|
|
|
|
installPhase = ''
|
|
mkdir -p $out/bin
|
|
install -Dm755 build/Helio $out/bin
|
|
wrapProgram $out/bin/Helio --prefix PATH ":" ${gnome3.zenity}/bin
|
|
|
|
mkdir -p $out/share
|
|
cp -r ../Deployment/Linux/Debian/x64/usr/share/* $out/share
|
|
substituteInPlace $out/share/applications/Helio.desktop \
|
|
--replace "/usr/bin/helio" "$out/bin/Helio"
|
|
'';
|
|
|
|
meta = with lib; {
|
|
description = "One music sequencer for all major platforms, both desktop and mobile";
|
|
homepage = "https://helio.fm/";
|
|
license = licenses.gpl3Only;
|
|
maintainers = [ maintainers.suhr ];
|
|
platforms = [ "x86_64-linux" ];
|
|
};
|
|
}
|