uboot: (firmwareOdroidC2/C4) don't invoke patch tool, use patches = [] instead
https://github.com/NixOS/nixpkgs/blob/master/pkgs/stdenv/generic/setup.sh#L948 this can do it nicely. Signed-off-by: Anton Arapov <anton@deadbeef.mx>
This commit is contained in:
commit
56de2bcd43
30691 changed files with 3076956 additions and 0 deletions
46
pkgs/os-specific/linux/pam_mount/default.nix
Normal file
46
pkgs/os-specific/linux/pam_mount/default.nix
Normal file
|
|
@ -0,0 +1,46 @@
|
|||
{ lib, stdenv, fetchurl, autoreconfHook, pkg-config, libtool, pam, libHX, libxml2, pcre, perl, openssl, cryptsetup, util-linux }:
|
||||
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "pam_mount";
|
||||
version = "2.17";
|
||||
|
||||
src = fetchurl {
|
||||
url = "mirror://sourceforge/pam-mount/pam_mount/${pname}-${version}.tar.xz";
|
||||
sha256 = "1q2n6a2ah6nghdn8i6ad2wj247njwb5nx48cggxknaa6lqxylidy";
|
||||
};
|
||||
|
||||
patches = [
|
||||
./insert_utillinux_path_hooks.patch
|
||||
];
|
||||
|
||||
postPatch = ''
|
||||
substituteInPlace src/mtcrypt.c \
|
||||
--replace @@NIX_UTILLINUX@@ ${util-linux}/bin
|
||||
'';
|
||||
|
||||
nativeBuildInputs = [ autoreconfHook libtool pkg-config ];
|
||||
|
||||
buildInputs = [ pam libHX util-linux libxml2 pcre perl openssl cryptsetup ];
|
||||
|
||||
enableParallelBuilding = true;
|
||||
|
||||
configureFlags = [
|
||||
"--prefix=${placeholder "out"}"
|
||||
"--localstatedir=${placeholder "out"}/var"
|
||||
"--sbindir=${placeholder "out"}/bin"
|
||||
"--sysconfdir=${placeholder "out"}/etc"
|
||||
"--with-slibdir=${placeholder "out"}/lib"
|
||||
];
|
||||
|
||||
postInstall = ''
|
||||
rm -r $out/var
|
||||
'';
|
||||
|
||||
meta = with lib; {
|
||||
description = "PAM module to mount volumes for a user session";
|
||||
homepage = "https://pam-mount.sourceforge.net/";
|
||||
license = with licenses; [ gpl2 gpl3 lgpl21 lgpl3 ];
|
||||
maintainers = with maintainers; [ tstrobel ];
|
||||
platforms = platforms.linux;
|
||||
};
|
||||
}
|
||||
|
|
@ -0,0 +1,30 @@
|
|||
diff -uNr pam_mount-2.15_old/src/mtcrypt.c pam_mount-2.15/src/mtcrypt.c
|
||||
--- pam_mount-2.15_old/src/mtcrypt.c 2015-07-04 16:00:12.917943336 +0200
|
||||
+++ pam_mount-2.15/src/mtcrypt.c 2015-07-04 16:03:45.685302493 +0200
|
||||
@@ -534,7 +534,7 @@
|
||||
|
||||
/* candidate for replacement by some libmount calls, I guess. */
|
||||
argk = 0;
|
||||
- mount_args[argk++] = "mount";
|
||||
+ mount_args[argk++] = "@@NIX_UTILLINUX@@/mount";
|
||||
if (opt->fstype != NULL) {
|
||||
mount_args[argk++] = "-t";
|
||||
mount_args[argk++] = opt->fstype;
|
||||
@@ -668,7 +668,7 @@
|
||||
|
||||
if (!opt->no_update)
|
||||
pmt_smtab_remove(mntpt, SMTABF_MOUNTPOINT);
|
||||
- rmt_args[argk++] = "mount";
|
||||
+ rmt_args[argk++] = "@@NIX_UTILLINUX@@/mount";
|
||||
rmt_args[argk++] = "-o";
|
||||
rmt_args[argk++] = opt->extra_opts;
|
||||
rmt_args[argk++] = mntpt;
|
||||
@@ -749,7 +749,7 @@
|
||||
pmt_smtab_remove(mountpoint, SMTABF_MOUNTPOINT);
|
||||
pmt_cmtab_remove(mountpoint);
|
||||
|
||||
- umount_args[argk++] = "umount";
|
||||
+ umount_args[argk++] = "@@NIX_UTILLINUX@@/umount";
|
||||
umount_args[argk++] = "-i";
|
||||
umount_args[argk++] = mountpoint;
|
||||
umount_args[argk] = NULL;
|
||||
Loading…
Add table
Add a link
Reference in a new issue