mirror of
https://github.com/privatevoid-net/nix-super.git
synced 2024-11-22 14:06:16 +02:00
nix-perl: Add deps, use mkMesonDerivation
This commit is contained in:
parent
4c014e238b
commit
efd5f50f5e
1 changed files with 21 additions and 13 deletions
|
@ -1,5 +1,6 @@
|
|||
{ lib
|
||||
, stdenv
|
||||
, mkMesonDerivation
|
||||
, perl
|
||||
, perlPackages
|
||||
, meson
|
||||
|
@ -8,19 +9,23 @@
|
|||
, nix-store
|
||||
, darwin
|
||||
, versionSuffix ? ""
|
||||
, curl
|
||||
, bzip2
|
||||
, libsodium
|
||||
}:
|
||||
|
||||
let
|
||||
inherit (lib) fileset;
|
||||
in
|
||||
|
||||
perl.pkgs.toPerlModule (stdenv.mkDerivation (finalAttrs: {
|
||||
perl.pkgs.toPerlModule (mkMesonDerivation (finalAttrs: {
|
||||
pname = "nix-perl";
|
||||
version = lib.fileContents ./.version + versionSuffix;
|
||||
|
||||
src = fileset.toSource {
|
||||
root = ./.;
|
||||
workDir = ./.;
|
||||
fileset = fileset.unions ([
|
||||
./.version
|
||||
../../.version
|
||||
./MANIFEST
|
||||
./lib
|
||||
./meson.build
|
||||
|
@ -29,17 +34,19 @@ perl.pkgs.toPerlModule (stdenv.mkDerivation (finalAttrs: {
|
|||
./.yath.rc.in
|
||||
./t
|
||||
]);
|
||||
};
|
||||
|
||||
nativeBuildInputs = [
|
||||
meson
|
||||
ninja
|
||||
pkg-config
|
||||
perl
|
||||
curl
|
||||
];
|
||||
|
||||
buildInputs = [
|
||||
nix-store
|
||||
bzip2
|
||||
libsodium
|
||||
];
|
||||
|
||||
# `perlPackages.Test2Harness` is marked broken for Darwin
|
||||
|
@ -52,6 +59,7 @@ perl.pkgs.toPerlModule (stdenv.mkDerivation (finalAttrs: {
|
|||
preConfigure =
|
||||
# "Inline" .version so its not a symlink, and includes the suffix
|
||||
''
|
||||
chmod u+w .version
|
||||
echo ${finalAttrs.version} > .version
|
||||
'';
|
||||
|
||||
|
|
Loading…
Reference in a new issue