forked from mirrors/nixpkgs
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
53 lines
1.5 KiB
Nix
53 lines
1.5 KiB
Nix
{ lib, stdenv, fetchFromGitHub, perlPackages, makeWrapper }:
|
|
|
|
stdenv.mkDerivation rec {
|
|
pname = "realTimeConfigQuickScan";
|
|
version = "unstable-2020-07-23";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "raboof";
|
|
repo = pname;
|
|
rev = "4697ba093d43d512b74a73b89531cb8c5adaa274";
|
|
sha256 = "16kanzp5i353x972zjkwgi3m8z90wc58613mlfzb0n01djdnm6k5";
|
|
};
|
|
|
|
buildInputs = [ perlPackages.perl makeWrapper ];
|
|
|
|
dontBuild = true;
|
|
|
|
installPhase = ''
|
|
runHook preInstall
|
|
mkdir -p $out/bin
|
|
mkdir -p $out/share/$pname
|
|
mkdir -p $out/share/doc/$pname
|
|
# Install Script Files:
|
|
# *.pm files
|
|
for i in *.pm; do
|
|
install -Dm 755 "$i" "$out/share/$pname/$i"
|
|
done
|
|
# Install doc files:
|
|
install -D COPYING "$out/share/doc/$pname/COPYING"
|
|
install -D README.md "$out/share/doc/$pname/README.md"
|
|
# Install Executable scripts:
|
|
install -Dm 755 realTimeConfigQuickScan.pl "$out/bin/realTimeConfigQuickScan"
|
|
install -Dm 755 QuickScan.pl "$out/bin/QuickScan"
|
|
runHook postInstall
|
|
'';
|
|
|
|
postFixup = ''
|
|
wrapProgram $out/bin/realTimeConfigQuickScan \
|
|
--set PERL5LIB "$out/share/$pname"
|
|
wrapProgram $out/bin/QuickScan \
|
|
--set PERL5LIB "$out/share/$pname:${with perlPackages; makePerlPath [ Tk ]}"
|
|
'';
|
|
|
|
meta = with lib; {
|
|
description = "Linux configuration checker for systems to be used for real-time audio";
|
|
homepage = "https://github.com/raboof/realtimeconfigquickscan";
|
|
license = licenses.gpl2Plus;
|
|
maintainers = with maintainers; [ magnetophon ];
|
|
platforms = platforms.linux ;
|
|
};
|
|
}
|
|
|