discrete-scroll: 0.1.1 -> 1.2.1 (#359465)
This commit is contained in:
commit
0ecd14bacb
37
pkgs/by-name/di/discrete-scroll/package.nix
Normal file
37
pkgs/by-name/di/discrete-scroll/package.nix
Normal file
@ -0,0 +1,37 @@
|
||||
{
|
||||
lib,
|
||||
stdenv,
|
||||
fetchFromGitHub,
|
||||
}:
|
||||
|
||||
stdenv.mkDerivation (finalAttrs: {
|
||||
pname = "discrete-scroll";
|
||||
version = "1.2.1";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "emreyolcu";
|
||||
repo = "discrete-scroll";
|
||||
rev = "v${finalAttrs.version}";
|
||||
hash = "sha256-FYYtJUl1tvMu9yMK5VpHmMeM6otDIpoOvSGTjYNPBr0=";
|
||||
};
|
||||
|
||||
buildPhase = ''
|
||||
runHook preBuild
|
||||
$CC -O3 -framework ApplicationServices DiscreteScroll/main.c
|
||||
runHook postBuild
|
||||
'';
|
||||
|
||||
installPhase = ''
|
||||
runHook preInstall
|
||||
install -Dm755 a.out $out/bin/discretescroll
|
||||
runHook postInstall
|
||||
'';
|
||||
|
||||
meta = {
|
||||
description = "Fix for OS X's scroll wheel problem";
|
||||
homepage = "https://github.com/emreyolcu/discrete-scroll";
|
||||
license = lib.licenses.mit;
|
||||
maintainers = with lib.maintainers; [ bb2020 ];
|
||||
platforms = lib.platforms.darwin;
|
||||
};
|
||||
})
|
@ -1,36 +0,0 @@
|
||||
{ stdenv, lib, fetchFromGitHub, Cocoa }:
|
||||
|
||||
## after launching for the first time, grant access for parent application (e.g. Terminal.app)
|
||||
## from 'system preferences >> security & privacy >> accessibility'
|
||||
## and then launch again
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "discrete-scroll";
|
||||
version = "0.1.1";
|
||||
|
||||
src = fetchFromGitHub {
|
||||
owner = "emreyolcu";
|
||||
repo = "discrete-scroll";
|
||||
rev = "v${version}";
|
||||
sha256 = "0aqkp4kkwjlkll91xbqwf8asjww8ylsdgqvdk8d06bwdvg2cgvhg";
|
||||
};
|
||||
|
||||
buildInputs = [ Cocoa ];
|
||||
|
||||
buildPhase = ''
|
||||
cc -std=c99 -O3 -Wall -framework Cocoa -o dc DiscreteScroll/main.m
|
||||
'';
|
||||
|
||||
installPhase = ''
|
||||
mkdir -p $out/bin
|
||||
cp ./dc $out/bin/discretescroll
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
description = "Fix for OS X's scroll wheel problem";
|
||||
homepage = "https://github.com/emreyolcu/discrete-scroll";
|
||||
platforms = platforms.darwin;
|
||||
license = licenses.mit;
|
||||
maintainers = with lib.maintainers; [ bb2020 ];
|
||||
};
|
||||
}
|
@ -59,6 +59,10 @@ mapAliases ({
|
||||
cctools-llvm = pkgs.cctools; # added 2024-07-01
|
||||
cctools-port = pkgs.cctools; # added 2024-07-17
|
||||
|
||||
### D ###
|
||||
|
||||
discrete-scroll = pkgs.discrete-scroll; # added 2024-11-27
|
||||
|
||||
### I ###
|
||||
|
||||
insert_dylib = throw "'darwin.insert_dylib' has been renamed to 'insert-dylib'"; # added 2024-04-04
|
||||
|
@ -239,8 +239,6 @@ impure-cmds // apple-source-packages // apple-source-headers // stubs // {
|
||||
|
||||
ios-deploy = callPackage ../os-specific/darwin/ios-deploy {};
|
||||
|
||||
discrete-scroll = callPackage ../os-specific/darwin/discrete-scroll { };
|
||||
|
||||
# See doc/packages/darwin-builder.section.md
|
||||
linux-builder = lib.makeOverridable ({ modules }:
|
||||
let
|
||||
|
Loading…
Reference in New Issue
Block a user