Compare commits
2 Commits
master
...
new-instal
Author | SHA1 | Date | |
---|---|---|---|
|
a6830d4e91 | ||
|
453ec521da |
|
@ -77,10 +77,10 @@
|
||||||
(,,(string-append (lib) "/libCgGL.so")
|
(,,(string-append (lib) "/libCgGL.so")
|
||||||
("out" "glibc")))
|
("out" "glibc")))
|
||||||
#:install-plan
|
#:install-plan
|
||||||
`(("bin" (".") "bin/")
|
`(("bin" "./")
|
||||||
(,,(lib) (".") "lib/")
|
(,,(lib) "lib")
|
||||||
("include" (".") "include/")
|
("include" "./")
|
||||||
("local" (".") "share/"))
|
("local/" "share/"))
|
||||||
#:phases
|
#:phases
|
||||||
(modify-phases %standard-phases
|
(modify-phases %standard-phases
|
||||||
(replace 'unpack
|
(replace 'unpack
|
||||||
|
|
|
@ -23,6 +23,7 @@
|
||||||
#:use-module (guix search-paths)
|
#:use-module (guix search-paths)
|
||||||
#:use-module (guix build-system)
|
#:use-module (guix build-system)
|
||||||
#:use-module (guix build-system gnu)
|
#:use-module (guix build-system gnu)
|
||||||
|
;; #:use-module (guix build-system copy)
|
||||||
#:use-module (guix packages)
|
#:use-module (guix packages)
|
||||||
#:use-module (ice-9 match)
|
#:use-module (ice-9 match)
|
||||||
#:use-module (srfi srfi-1)
|
#:use-module (srfi srfi-1)
|
||||||
|
@ -37,7 +38,7 @@
|
||||||
;; Commentary:
|
;; Commentary:
|
||||||
;;
|
;;
|
||||||
;; Standard build procedure for binary packages. This is implemented as an
|
;; Standard build procedure for binary packages. This is implemented as an
|
||||||
;; extension of `gnu-build-system'.
|
;; extension of `copy-build-system'.
|
||||||
;;
|
;;
|
||||||
;; Code:
|
;; Code:
|
||||||
|
|
||||||
|
@ -78,7 +79,6 @@
|
||||||
`(("source" ,source))
|
`(("source" ,source))
|
||||||
'())
|
'())
|
||||||
,@inputs
|
,@inputs
|
||||||
|
|
||||||
;; Keep the standard inputs of 'gnu-build-system'.
|
;; Keep the standard inputs of 'gnu-build-system'.
|
||||||
,@(standard-packages)))
|
,@(standard-packages)))
|
||||||
(build-inputs `(("patchelf" ,patchelf)
|
(build-inputs `(("patchelf" ,patchelf)
|
||||||
|
@ -94,7 +94,7 @@
|
||||||
#:key (guile #f)
|
#:key (guile #f)
|
||||||
(outputs '("out"))
|
(outputs '("out"))
|
||||||
(patchelf-plan ''())
|
(patchelf-plan ''())
|
||||||
(install-plan ''(("." (".") "./")))
|
(install-plan ''(("." "./")))
|
||||||
(search-paths '())
|
(search-paths '())
|
||||||
(out-of-source? #t)
|
(out-of-source? #t)
|
||||||
(validate-runpath? #t)
|
(validate-runpath? #t)
|
||||||
|
|
|
@ -18,6 +18,8 @@
|
||||||
|
|
||||||
(define-module (nonguix build binary-build-system)
|
(define-module (nonguix build binary-build-system)
|
||||||
#:use-module ((guix build gnu-build-system) #:prefix gnu:)
|
#:use-module ((guix build gnu-build-system) #:prefix gnu:)
|
||||||
|
#:use-module ((guix build-system copy)) ; TODO: Do we need it?
|
||||||
|
#:use-module ((guix build copy-build-system))
|
||||||
#:use-module (nonguix build utils)
|
#:use-module (nonguix build utils)
|
||||||
#:use-module (guix build utils)
|
#:use-module (guix build utils)
|
||||||
#:use-module (ice-9 match)
|
#:use-module (ice-9 match)
|
||||||
|
@ -30,7 +32,16 @@
|
||||||
;;
|
;;
|
||||||
;; Code:
|
;; Code:
|
||||||
|
|
||||||
(define* (install #:key install-plan outputs #:allow-other-keys)
|
(define (new-install)
|
||||||
|
"Return the copy-build-system `install' procedure."
|
||||||
|
|
||||||
|
;; Do not use `@' to avoid introducing circular dependencies.
|
||||||
|
;; TODO: Does not work?!?
|
||||||
|
;; (let ((module (resolve-interface '(guix build copy-build-system))))
|
||||||
|
;; (module-ref module 'install))
|
||||||
|
(@@ (guix build copy-build-system) install))
|
||||||
|
|
||||||
|
(define* (old-install #:key install-plan outputs #:allow-other-keys)
|
||||||
"Copy files from the \"source\" build input to the \"out\" output according to INSTALL-PLAN.
|
"Copy files from the \"source\" build input to the \"out\" output according to INSTALL-PLAN.
|
||||||
|
|
||||||
An INSTALL-PLAN is made of three elements:
|
An INSTALL-PLAN is made of three elements:
|
||||||
|
@ -70,6 +81,18 @@ represent the target full path, which only makes sense for single files."
|
||||||
(for-each install install-plan)
|
(for-each install install-plan)
|
||||||
#t)
|
#t)
|
||||||
|
|
||||||
|
(define* (install #:key install-plan outputs #:allow-other-keys)
|
||||||
|
(define (install-old-format)
|
||||||
|
(warn "Install-plan format deprecated.
|
||||||
|
Please update to the format of the copy-build-system.")
|
||||||
|
(old-install #:install-plan install-plan #:outputs outputs))
|
||||||
|
(match (car install-plan)
|
||||||
|
((source (. matches) target)
|
||||||
|
(install-old-format))
|
||||||
|
((source #f target)
|
||||||
|
(install-old-format))
|
||||||
|
(_ ((new-install) #:install-plan install-plan #:outputs outputs))))
|
||||||
|
|
||||||
(define* (patchelf #:key inputs outputs patchelf-plan #:allow-other-keys)
|
(define* (patchelf #:key inputs outputs patchelf-plan #:allow-other-keys)
|
||||||
"Set the interpreter and the RPATH of files as per the PATCHELF-PLAN.
|
"Set the interpreter and the RPATH of files as per the PATCHELF-PLAN.
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user