gnu: 389-ds-base: Use gexp.
* gnu/packages/openldap.scm (389-ds-base)[arguments]: Use gexp; remove one obsolete substitution.
parent
597685054b
commit
b5bb44b260
|
@ -260,96 +260,93 @@ servers from Python programs.")
|
||||||
"1sdvfbjfg0091f47562gw3gdc2vgvvhyhdi21lrpwnw9lqc8xdxk"))))
|
"1sdvfbjfg0091f47562gw3gdc2vgvvhyhdi21lrpwnw9lqc8xdxk"))))
|
||||||
(build-system gnu-build-system)
|
(build-system gnu-build-system)
|
||||||
(arguments
|
(arguments
|
||||||
`(#:modules ((srfi srfi-1)
|
(list
|
||||||
|
#:modules '((srfi srfi-1)
|
||||||
(guix build gnu-build-system)
|
(guix build gnu-build-system)
|
||||||
((guix build python-build-system)
|
((guix build python-build-system)
|
||||||
#:select (add-installed-pythonpath python-version))
|
#:select (add-installed-pythonpath python-version))
|
||||||
(guix build utils))
|
(guix build utils))
|
||||||
#:imported-modules ((guix build python-build-system)
|
#:imported-modules `((guix build python-build-system)
|
||||||
,@%gnu-build-system-modules)
|
,@%gnu-build-system-modules)
|
||||||
#:configure-flags
|
#:configure-flags
|
||||||
(list (string-append "--with-db="
|
#~(list (string-append "--with-db="
|
||||||
(assoc-ref %build-inputs "bdb"))
|
#$(this-package-input "bdb"))
|
||||||
(string-append "--with-netsnmp="
|
(string-append "--with-netsnmp="
|
||||||
(assoc-ref %build-inputs "net-snmp"))
|
#$(this-package-input "net-snmp"))
|
||||||
(string-append "--with-selinux="
|
(string-append "--with-selinux="
|
||||||
(assoc-ref %build-inputs "libselinux"))
|
#$(this-package-input "libselinux"))
|
||||||
"--localstatedir=/var"
|
"--localstatedir=/var"
|
||||||
"--with-instconfigdir=/etc/dirsrv")
|
"--with-instconfigdir=/etc/dirsrv")
|
||||||
#:phases
|
#:phases
|
||||||
(modify-phases %standard-phases
|
#~(modify-phases %standard-phases
|
||||||
(add-after 'unpack 'fix-references
|
(add-after 'unpack 'fix-references
|
||||||
(lambda _
|
(lambda _
|
||||||
(substitute* "ldap/servers/plugins/sync/sync_persist.c"
|
(substitute* "ldap/servers/plugins/sync/sync_persist.c"
|
||||||
(("nspr4") "nspr"))
|
(("nspr4") "nspr"))
|
||||||
(substitute* "src/lib389/lib389/utils.py"
|
(substitute* "src/lib389/lib389/utils.py"
|
||||||
(("'/sbin/ip'")
|
(("'/sbin/ip'")
|
||||||
(string-append "'" (which "ip") "'")))
|
(string-append "'" (which "ip") "'")))
|
||||||
(substitute* "src/lib389/lib389/nss_ssl.py"
|
(substitute* "src/lib389/lib389/nss_ssl.py"
|
||||||
(("'/usr/bin/certutil'")
|
(("'/usr/bin/certutil'")
|
||||||
(string-append "'" (which "certutil") "'"))
|
(string-append "'" (which "certutil") "'"))
|
||||||
(("'/usr/bin/openssl'")
|
(("'/usr/bin/openssl'")
|
||||||
(string-append "'" (which "openssl") "'")))))
|
(string-append "'" (which "openssl") "'")))))
|
||||||
(add-after 'unpack 'overwrite-default-locations
|
(add-after 'unpack 'overwrite-default-locations
|
||||||
(lambda* (#:key outputs #:allow-other-keys)
|
(lambda _
|
||||||
(let ((out (assoc-ref outputs "out")))
|
(substitute* "src/lib389/lib389/paths.py"
|
||||||
(substitute* "src/lib389/lib389/paths.py"
|
(("/usr/share/dirsrv/inf/defaults.inf")
|
||||||
(("/usr/share/dirsrv/inf/defaults.inf")
|
(string-append #$output "/share/dirsrv/inf/defaults.inf")))
|
||||||
(string-append out "/share/dirsrv/inf/defaults.inf")))
|
;; This directory can only be specified relative to sysconfdir. This
|
||||||
;; This directory can only be specified relative to sysconfdir. This
|
;; is used to determine where to look for installed directory
|
||||||
;; is used to determine where to look for installed directory
|
;; servers, so in the absence of a search path it needs to be global.
|
||||||
;; servers, so in the absence of a search path it needs to be global.
|
(substitute* "ldap/admin/src/defaults.inf.in"
|
||||||
(substitute* "ldap/admin/src/defaults.inf.in"
|
(("^initconfig_dir =.*")
|
||||||
(("^initconfig_dir =.*")
|
"initconfig_dir = /etc/dirsrv/registry\n"))
|
||||||
"initconfig_dir = /etc/dirsrv/registry\n"))
|
;; This is used to determine where to write certificate files
|
||||||
;; This is used to determine where to write certificate files
|
;; when installing new directory server instances.
|
||||||
;; when installing new directory server instances.
|
(substitute* "src/lib389/lib389/instance/setup.py"
|
||||||
(substitute* "src/lib389/lib389/instance/setup.py"
|
(("etc_dirsrv_path = .*")
|
||||||
(("etc_dirsrv_path = .*")
|
"etc_dirsrv_path = '/etc/dirsrv/'\n"))))
|
||||||
"etc_dirsrv_path = '/etc/dirsrv/'\n")))))
|
(add-after 'unpack 'fix-install-location-of-python-tools
|
||||||
(add-after 'unpack 'fix-install-location-of-python-tools
|
(lambda* (#:key inputs outputs #:allow-other-keys)
|
||||||
(lambda* (#:key inputs outputs #:allow-other-keys)
|
(let ((pythondir (string-append
|
||||||
(let* ((out (assoc-ref outputs "out"))
|
#$output "/lib/python"
|
||||||
(pythondir (string-append
|
(python-version #$(this-package-input "python"))
|
||||||
out "/lib/python"
|
|
||||||
(python-version (assoc-ref inputs "python"))
|
|
||||||
"/site-packages/")))
|
"/site-packages/")))
|
||||||
;; Install directory must be on PYTHONPATH.
|
;; Install directory must be on PYTHONPATH.
|
||||||
(add-installed-pythonpath inputs outputs)
|
(add-installed-pythonpath inputs outputs)
|
||||||
;; Install directory must exist.
|
;; Install directory must exist.
|
||||||
(mkdir-p pythondir)
|
(mkdir-p pythondir)
|
||||||
(substitute* "src/lib389/setup.py"
|
(setenv "INSTALL_PREFIX" #$output)
|
||||||
(("/usr") out))
|
(substitute* "Makefile.am"
|
||||||
(substitute* "Makefile.am"
|
(("setup.py install --skip-build" m)
|
||||||
(("setup.py install --skip-build" m)
|
(string-append
|
||||||
(string-append
|
m " --prefix=" #$output
|
||||||
m " --prefix=" out
|
" --root=/ --single-version-externally-managed"))))))
|
||||||
" --root=/ --single-version-externally-managed"))))))
|
(add-after 'build 'build-python-tools
|
||||||
(add-after 'build 'build-python-tools
|
(lambda* (#:key make-flags #:allow-other-keys)
|
||||||
(lambda* (#:key make-flags #:allow-other-keys)
|
;; Set DETERMINISTIC_BUILD to override the embedded mtime in pyc
|
||||||
;; Set DETERMINISTIC_BUILD to override the embedded mtime in pyc
|
;; files.
|
||||||
;; files.
|
(setenv "DETERMINISTIC_BUILD" "1")
|
||||||
(setenv "DETERMINISTIC_BUILD" "1")
|
;; Use deterministic hashes for strings, bytes, and datetime
|
||||||
;; Use deterministic hashes for strings, bytes, and datetime
|
;; objects.
|
||||||
;; objects.
|
(setenv "PYTHONHASHSEED" "0")
|
||||||
(setenv "PYTHONHASHSEED" "0")
|
(apply invoke "make" "lib389" make-flags)))
|
||||||
(apply invoke "make" "lib389" make-flags)))
|
(add-after 'install 'install-python-tools
|
||||||
(add-after 'install 'install-python-tools
|
(lambda* (#:key make-flags #:allow-other-keys)
|
||||||
(lambda* (#:key make-flags #:allow-other-keys)
|
(apply invoke "make" "lib389-install" make-flags)))
|
||||||
(apply invoke "make" "lib389-install" make-flags)))
|
(add-after 'install-python-tools 'wrap-python-tools
|
||||||
(add-after 'install-python-tools 'wrap-python-tools
|
(lambda* (#:key outputs #:allow-other-keys)
|
||||||
(lambda* (#:key outputs #:allow-other-keys)
|
(let ((pythonpath (getenv "GUIX_PYTHONPATH")))
|
||||||
(let* ((out (assoc-ref outputs "out"))
|
(for-each (lambda (file)
|
||||||
(pythonpath (getenv "GUIX_PYTHONPATH")))
|
(wrap-program (string-append #$output file)
|
||||||
(for-each (lambda (file)
|
`("GUIX_PYTHONPATH" ":" prefix (,pythonpath))))
|
||||||
(wrap-program (string-append out file)
|
'("/sbin/dsconf"
|
||||||
`("GUIX_PYTHONPATH" ":" prefix (,pythonpath))))
|
"/sbin/dscreate"
|
||||||
'("/sbin/dsconf"
|
"/sbin/dsctl"
|
||||||
"/sbin/dscreate"
|
"/sbin/dsidm"
|
||||||
"/sbin/dsctl"
|
"/bin/ds-logpipe.py"
|
||||||
"/sbin/dsidm"
|
"/bin/ds-replcheck"))))))))
|
||||||
"/bin/ds-logpipe.py"
|
|
||||||
"/bin/ds-replcheck"))))))))
|
|
||||||
(inputs
|
(inputs
|
||||||
(list bdb
|
(list bdb
|
||||||
cracklib
|
cracklib
|
||||||
|
|
Reference in New Issue