diff --git a/pkgs/tools/misc/plfit/default.nix b/pkgs/by-name/pl/plfit/package.nix similarity index 59% rename from pkgs/tools/misc/plfit/default.nix rename to pkgs/by-name/pl/plfit/package.nix index 8b1726666bcc..a5922d5a75e9 100644 --- a/pkgs/tools/misc/plfit/default.nix +++ b/pkgs/by-name/pl/plfit/package.nix @@ -1,21 +1,22 @@ -{ lib -, stdenv -, fetchFromGitHub -, cmake -, python ? null -, swig -, llvmPackages +{ + cmake, + fetchFromGitHub, + lib, + llvmPackages, + python ? null, + stdenv, + swig, }: stdenv.mkDerivation (finalAttrs: { pname = "plfit"; - version = "0.9.6"; + version = "1.0.0"; src = fetchFromGitHub { owner = "ntamas"; repo = "plfit"; rev = finalAttrs.version; - hash = "sha256-XRl6poEdgPNorFideQmEJHCU+phs4rIhMYa8iAOtL1A="; + hash = "sha256-ur+ai0in7PaoDZcPzuUzQTrZ3nB0H5FDSfPBpl1e9ug="; }; postPatch = lib.optionalString (python != null) '' @@ -24,18 +25,22 @@ stdenv.mkDerivation (finalAttrs: { --replace-fail ' ''${Python3_SITELIB}' ' ${placeholder "out"}/${python.sitePackages}' ''; - nativeBuildInputs = [ - cmake - ] ++ lib.optionals (python != null) [ - python - swig - ]; + nativeBuildInputs = + [ + cmake + ] + ++ lib.optionals (python != null) [ + python + swig + ]; - cmakeFlags = [ - "-DPLFIT_USE_OPENMP=ON" - ] ++ lib.optionals (python != null) [ - "-DPLFIT_COMPILE_PYTHON_MODULE=ON" - ]; + cmakeFlags = + [ + "-DPLFIT_USE_OPENMP=ON" + ] + ++ lib.optionals (python != null) [ + "-DPLFIT_COMPILE_PYTHON_MODULE=ON" + ]; buildInputs = lib.optionals stdenv.cc.isClang [ llvmPackages.openmp @@ -43,11 +48,11 @@ stdenv.mkDerivation (finalAttrs: { doCheck = true; - meta = with lib; { + meta = { description = "Fitting power-law distributions to empirical data"; homepage = "https://github.com/ntamas/plfit"; changelog = "https://github.com/ntamas/plfit/blob/${finalAttrs.src.rev}/CHANGELOG.md"; - license = licenses.gpl2Plus; - maintainers = with maintainers; [ dotlambda ]; + license = lib.licenses.gpl2Plus; + maintainers = with lib.maintainers; [ dotlambda ]; }; }) diff --git a/pkgs/top-level/all-packages.nix b/pkgs/top-level/all-packages.nix index b2063c9ecfdd..e060ad0a3d77 100644 --- a/pkgs/top-level/all-packages.nix +++ b/pkgs/top-level/all-packages.nix @@ -4957,7 +4957,7 @@ with pkgs; beamPackages = beamPackages.extend (self: super: { elixir = elixir_1_17; }); }; - plfit = callPackage ../tools/misc/plfit { + plfit = callPackage ../by-name/pl/plfit/package.nix { python = null; };