aboutsummaryrefslogtreecommitdiff
path: root/gnu/packages/acl.scm
blob: da6dead3c2c238931aa02b0fa87805508375fd88 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
;;; GNU Guix --- Functional package management for GNU
;;; Copyright © 2012 Nikita Karetnikov <nikita@karetnikov.org>
;;; Copyright © 2014, 2018 Mark H Weaver <mhw@netris.org>
;;; Copyright © 2014 Andreas Enge <andreas@enge.fr>
;;; Copyright © 2017 Efraim Flashner <efraim@flashner.co.il>
;;; Copyright © 2018 Ricardo Wurmus <rekado@elephly.net>
;;; Copyright © 2019 Marius Bakke <mbakke@fastmail.com>
;;; Copyright © 2020 Jan (janneke) Nieuwenhuizen <janneke@gnu.org>
;;; Copyright © 2021 Lars-Dominik Braun <ldb@leibniz-psychology.org>
;;;
;;; This file is part of GNU Guix.
;;;
;;; GNU Guix is free software; you can redistribute it and/or modify it
;;; under the terms of the GNU General Public License as published by
;;; the Free Software Foundation; either version 3 of the License, or (at
;;; your option) any later version.
;;;
;;; GNU Guix is distributed in the hope that it will be useful, but
;;; WITHOUT ANY WARRANTY; without even the implied warranty of
;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
;;; GNU General Public License for more details.
;;;
;;; You should have received a copy of the GNU General Public License
;;; along with GNU Guix.  If not, see <http://www.gnu.org/licenses/>.

(define-module (gnu packages acl)
  #:use-module (guix licenses)
  #:use-module (gnu packages attr)
  #:use-module (gnu packages base)
  #:use-module (gnu packages check)
  #:use-module (gnu packages hurd)
  #:use-module (gnu packages gettext)
  #:use-module (gnu packages perl)
  #:use-module (guix packages)
  #:use-module (guix download)
  #:use-module (gnu packages)
  #:use-module (guix build-system gnu)
  #:use-module (guix build-system python))

(define-public acl
  (package
    (name "acl")
    (version "2.3.1")
    (source
     (origin
      (method url-fetch)
      (uri (string-append "mirror://savannah/acl/acl-"
                          version ".tar.gz"))
      (sha256
       (base32
        "1bqi7hj0xkpivwg7lx5cv3yvs9ks1i6azvpgbvfpzcq1i736233n"))))
    (build-system gnu-build-system)
    (arguments
     `(#:modules ((ice-9 ftw)
                  ,@%gnu-build-system-modules)
       #:configure-flags '("--disable-static")
       #:tests? ,(not (or (%current-target-system)
                          (hurd-target?)))
       #:phases
       (modify-phases %standard-phases
         ;; XXX After repacking the sources the timestamps are reset to the
         ;; epoch, which leads to a failure in gzipping the CHANGES file.
         (add-after 'unpack 'ensure-no-mtimes-pre-1980
           (lambda _
             (let ((early-1980 315619200)) ; 1980-01-02 UTC
               (ftw "." (lambda (file stat flag)
                          (unless (<= early-1980 (stat:mtime stat))
                            (utime file early-1980 early-1980))
                          #t))
               #t)))
         (add-after 'build 'patch-exec-bin-sh
           (lambda _
             (substitute* "test/run"
               (("/bin/sh") (which "sh")))
             #t))
         (add-before 'check 'patch-tests
           (lambda _
             ;; The coreutils do not have an ACL bit to remove from their
             ;; output, so the sed expression that removes the bit is disabled.
             (substitute* "test/sbits-restore.test"
                          (("\\| sed.*'") ""))
             ;; These tests require the existence of a user named "bin", but
             ;; this user does not exist within Guix's build environment.
             (substitute* "Makefile.in"
               ((".*test/misc\\.test.*") "")
               ((".*test/cp\\.test.*") "")
               ((".*test/setfacl-X\\.test.*") ""))
             #t)))))
    (inputs (list attr))
    (native-inputs
     `(("gettext" ,gettext-minimal)
       ("perl" ,perl)))
    (home-page "https://savannah.nongnu.org/projects/acl")
    (synopsis
     "Library and tools for manipulating access control lists")
    (description
     "Library and tools for manipulating access control lists.")
    (license (list gpl2+ lgpl2.1+))))

(define-public python-pylibacl
  (package
    (name "python-pylibacl")
    (version "0.6.0")
    (source
      (origin
        (method url-fetch)
        (uri (pypi-uri "pylibacl" version))
        (sha256
          (base32
            "1zyrk2m20p5b6bdwxhrwib273i6i71zyr5hzssbxfqis5qra9848"))))
    (build-system python-build-system)
    (arguments
     `(#:phases
       (modify-phases %standard-phases
         (add-after 'unpack 'disable-tests
           (lambda* (#:key outputs inputs #:allow-other-keys)
             ;; These tests operate on real files, but our tmpfs does not support
             ;; ACLs.
             (substitute* "tests/test_acls.py"
               (("( *)def test_applyto(_extended(_mixed)?)?" match indent)
                (string-append indent "@pytest.mark.skip(reason=\"guix\")\n"
                               match)))))
         (replace 'check
           (lambda* (#:key inputs outputs tests? #:allow-other-keys)
             (when tests?
               (add-installed-pythonpath inputs outputs)
               (invoke "pytest" "tests")))))))
    (inputs (list acl))
    (native-inputs (list python-pytest))
    (home-page "https://pylibacl.k1024.org/")
    (synopsis "POSIX.1e @acronym{ACLs, access control lists} for Python")
    (description
     "This Python extension module manipulates the POSIX.1e @acronym{ACLs,
Access Control Lists} available on many file systems.  These allow more
fine-grained access control than traditional user/group permissions.")
    (license lgpl2.1+)))
pported?): Remove. (clone*): Inline code that was dependent on AUTH-SUPPORTED?. (update-cached-checkout): Likewise. (resolve-reference): Remove check for 'object-lookup-prefix' and use it unconditionally. (load-git-submodules): Remove. (update-submodules): Use 'repository-submodules', 'submodule-lookup', etc. unconditionally. (update-cached-checkout): Use 'repository-close!' unconditionally. * m4/guix.m4 (GUIX_CHECK_GUILE_GIT): New macro. * configure.ac: Use it and error out when it fails. * doc/guix.texi (Requirements): Bump to Guile-Git 0.3.0. 2020-10-05build: Use a 'guile' executable that doesn't warn about locales.Ludovic Courtès This gets rid of: guile: warning: failed to install locale when running the 'guix' command on a foreign distro where 'GUIX_LOCPATH' isn't set. * Makefile.am (pkglibexec_PROGRAMS, guile_SOURCES, guile_LDADD) (guile_CFLAGS): New variables. (install-exec-hook): New target. (AUX_FILES): Remove 'guile-launcher.c'. * configure.ac: Use 'GUILE_FLAGS'. 2020-08-29build: Remove references to the 'nix-hash' program.Ludovic Courtès * configure.ac: Remove check for 'nix-hash'. * tests/base32.scm (%nix-hash, %have-nix-hash?): Remove. ("sha256 & bytevector->nix-base32-string"): Remove test. * build-aux/pre-inst-env.in: Do not set 'NIX_HASH' environment variable. 2020-08-29build: Remove check for Guile 2.2.1 bug.Ludovic Courtès This check is unnecessary since e688c2df3924423b67892cc9939ca099c729d1cb. * m4/guix.m4 (GUIX_ASSERT_SYNTAX_OBJECT_EQUAL): Remove. * configure.ac: Remove user. 2020-08-24Use "guile-zlib" and "guile-lzlib" instead of (guix config).Mathieu Othacehe * Makefile.am (MODULES): Remove guix/zlib.scm and guix/lzlib.scm, (SCM_TESTS): remove tests/zlib.scm, tests/lzlib.scm. * build-aux/build-self.scm (make-config.scm): Remove unused %libz variable. * configure.ac: Remove LIBZ and LIBLZ variables and check instead for Guile-zlib and Guile-lzlib. * doc/guix.texi ("Requirements"): Remove zlib requirement and add Guile-zlib and Guile-lzlib instead. * gnu/packages/package-management.scm (guix)[native-inputs]: Add "guile-zlib" and "guile-lzlib", [inputs]: remove "zlib" and "lzlib", [propagated-inputs]: ditto, [arguments]: add "guile-zlib" and "guile-lzlib" to Guile load path. * guix/config.scm.in (%libz, %liblz): Remove them. * guix/lzlib.scm: Remove it. * guix/man-db.scm: Use (zlib) instead of (guix zlib). * guix/profiles.scm (manual-database): Do not stub (guix config) in imported modules list, instead add "guile-zlib" to the extension list. * guix/scripts/publish.scm: Use (zlib) instead of (guix zlib) and (lzlib) instead of (guix lzlib), (string->compression-type, effective-compression): do not check for zlib and lzlib availability. * guix/scripts/substitute.scm (%compression-methods): Do not check for lzlib availability. * guix/self.scm (specification->package): Add "guile-zlib" and "guile-lzlib" and remove "zlib" and "lzlib", (compiled-guix): remove "zlib" and "lzlib" arguments and add guile-zlib and guile-lzlib to the dependencies, also do not pass "zlib" and "lzlib" to "make-config.scm" procedure, (make-config.scm): remove "zlib" and "lzlib" arguments as well as %libz and %liblz variables. * guix/utils.scm (lzip-port): Use (lzlib) instead of (guix lzlib) and do not check for lzlib availability. * guix/zlib.scm: Remove it. * m4/guix.m4 (GUIX_LIBZ_LIBDIR, GUIX_LIBLZ_FILE_NAME): Remove them. * tests/lzlib.scm: Use (zlib) instead of (guix zlib) and (lzlib) instead of (guix lzlib), and do not check for zlib and lzlib availability. * tests/publish.scm: Ditto. * tests/substitute.scm: Do not check for lzlib availability. * tests/utils.scm: Ditto. * tests/zlib.scm: Remove it. 2020-06-16etc: Add committer script.Ricardo Wurmus * etc/committer.scm.in: New file. * configure.ac: Configure it. 2020-05-28maint: Check whether Guile-Gcrypt is recent enough.Ludovic Courtès Suggested by Danny Milosavljevic <dannym@scratchpost.org> in <https://bugs.gnu.org/41494>. * m4/guix.m4 (GUIX_CHECK_GUILE_GCRYPT): New macro. * configure.ac: Use it. 2020-05-14etc: indent-code.el: Use the --quick option.Maxim Cournoyer This prevents Emacs from loading the autoload definitions found in its profile, which needlessly clutters the output. It also prevents Geiser (if installed) from blocking the script and asking the user to input the Scheme implementation to use. The trick for passing multiple arguments to Emacs is to use what is called a "sesquicolon" (see https://www.emacswiki.org/emacs/EmacsScripts). * etc/indent-code.el.in: Rename to... * etc/indent-code.el: ...this. Adapt the shebang to use a sesquicolon, and pass the --quick option to Emacs. Since this line is interpreted by the shell, simply use Emacs from the PATH instead of from a hard coded location. (main): New procedure, used as the entry point. * configure.ac: Remove the warning about Emacs. Emacs can now be installed any time by the user if they want to use the script. * .gitignore: No longer ignore changes to etc/indent-code.el. 2020-04-23build: Don't build man pages when cross-compiling.Ludovic Courtès * configure.ac: Define 'CROSS_COMPILING' Automake conditional. * doc/local.mk (dist_man1_MANS): Wrap in "if !CROSS_COMPILING". 2020-03-11build: Require Guile 2.2.3 or later.Ludovic Courtès * configure.ac: For 2.2.x, require 2.2.3 or later. 2020-01-17build: Allow builds with Guile 3.0.Ludovic Courtès * configure.ac: Add "3.0" in 'GUILE_PKG' invocation. * doc/guix.texi (Requirements): Mention 3.0.x. 2019-11-09build: Warn about etc/indent-code.el when Emacs is absent.zimoun * configure.ac: Warn when 'emacs' is not found, and emit 'etc/indent-code.el' otherwise. Signed-off-by: Ludovic Courtès <ludo@gnu.org>