mirror of
https://codeberg.org/guix/guix.git
synced 2025-10-02 02:15:12 +00:00
gnu: gcl: Update to 2.6.14.
* gnu/packages/lisp.scm (gcl): Update to 2.6.14.
This commit is contained in:
parent
dfc5d6628f
commit
d5e41d7166
1 changed files with 114 additions and 107 deletions
|
@ -139,117 +139,124 @@ Definition Facility.")
|
||||||
(license license:expat)))
|
(license license:expat)))
|
||||||
|
|
||||||
(define-public gcl
|
(define-public gcl
|
||||||
(let ((commit "ff7ef981765cc0efdb4b1db27c292f5c11a72753")
|
(package
|
||||||
(revision "3")) ;Guix package revision
|
(name "gcl")
|
||||||
(package
|
(version "2.6.14")
|
||||||
(name "gcl")
|
(source
|
||||||
(version (git-version "2.6.12" revision commit))
|
(origin
|
||||||
(source
|
(method git-fetch)
|
||||||
(origin
|
(uri (git-reference
|
||||||
(method git-fetch)
|
(url "https://git.savannah.gnu.org/r/gcl.git")
|
||||||
(uri (git-reference
|
(commit (string-append "Version_"
|
||||||
(url "https://git.savannah.gnu.org/r/gcl.git")
|
(string-map (lambda (c)
|
||||||
(commit commit)))
|
(if (char=? c #\.) #\_ c))
|
||||||
(file-name (git-file-name name version))
|
version)))))
|
||||||
(sha256
|
(file-name (git-file-name name version))
|
||||||
(base32 "0z64fxxcaial2i1s1hms8r095dm1ff3wd8ivwdx894a3yln9c0an"))))
|
(sha256
|
||||||
(build-system gnu-build-system)
|
(base32 "1b9m02rfnyflsr8n57v7llxz5m3mi7ip3ypwdww4pdhbgh0lzyg7"))))
|
||||||
(arguments
|
(build-system gnu-build-system)
|
||||||
`(#:parallel-build? #f ; The build system seems not to be thread safe.
|
(arguments
|
||||||
#:test-target "ansi-tests/test_results"
|
(list
|
||||||
#:configure-flags ,#~(list
|
#:parallel-build? #f ; The build system seems not to be thread safe.
|
||||||
"--enable-ansi" ; required by the maxima package
|
#:test-target "ansi-tests/test_results"
|
||||||
(string-append "CFLAGS=-I"
|
#:configure-flags #~(list
|
||||||
#$(this-package-input "libtirpc")
|
"--enable-ansi" ; required by the maxima package
|
||||||
"/include/tirpc")
|
(string-append "CFLAGS=-I"
|
||||||
(string-append "LDFLAGS=-L"
|
#$(this-package-input "libtirpc")
|
||||||
#$(this-package-input "libtirpc")
|
"/include/tirpc")
|
||||||
"/lib")
|
(string-append "LDFLAGS=-L"
|
||||||
"LIBS=-ltirpc")
|
#$(this-package-input "libtirpc")
|
||||||
#:make-flags ,#~(let ((gcc (search-input-file %build-inputs "/bin/gcc")))
|
"/lib")
|
||||||
(list (string-append "GCL_CC=" gcc)
|
"LIBS=-ltirpc")
|
||||||
(string-append "CC=" gcc)))
|
#:make-flags #~(let ((gcc (search-input-file %build-inputs "/bin/gcc")))
|
||||||
#:phases
|
(list (string-append "GCL_CC=" gcc)
|
||||||
(modify-phases %standard-phases
|
(string-append "CC=" gcc)))
|
||||||
(add-after 'unpack 'realpath-workaround
|
#:phases
|
||||||
;; Calls to the realpath function can set errno even if the return
|
#~(modify-phases %standard-phases
|
||||||
;; value of the function indicates that there is no error, which
|
(add-after 'unpack 'realpath-workaround
|
||||||
;; make massert consider that there was an error.
|
;; Calls to the realpath function can set errno even if the return
|
||||||
(lambda _
|
;; value of the function indicates that there is no error, which
|
||||||
(substitute* "gcl/o/main.c"
|
;; make massert consider that there was an error.
|
||||||
(("massert\\(realpath\\(s,o\\)\\);" all)
|
(lambda _
|
||||||
"massert((realpath(s, o) != NULL) && ((errno = 0) == 0));"))))
|
(substitute* "gcl/o/main.c"
|
||||||
(add-after 'unpack 'fix-makefile
|
(("massert\\(realpath\\(s,o\\)\\);" all)
|
||||||
;; The "final" target doesn't exist.
|
"massert((realpath(s, o) != NULL) && ((errno = 0) == 0));"))))
|
||||||
(lambda _
|
(add-after 'unpack 'fix-missing-enum
|
||||||
(substitute* "gcl/makefile"
|
(lambda _
|
||||||
(("\\$\\(MAKE\\) -C \\$\\(PORTDIR\\) final")
|
;; The 'disassembler_style' enum is not defined anywhere,
|
||||||
"$(MAKE) -C $(PORTDIR)"))))
|
;; and the parameter is not used...
|
||||||
(add-before 'configure 'pre-conf
|
(substitute* "gcl/o/main.c"
|
||||||
(lambda* (#:key inputs #:allow-other-keys)
|
(("my_fprintf_styled\\(void \\*v,enum disassembler_style,")
|
||||||
(chdir "gcl")
|
"my_fprintf_styled(void *v,int disassembler_style,"))))
|
||||||
(substitute*
|
(add-after 'unpack 'fix-makefile
|
||||||
(append
|
;; The "final" target doesn't exist.
|
||||||
'("pcl/impl/kcl/makefile.akcl"
|
(lambda _
|
||||||
"add-defs"
|
(substitute* "gcl/makefile"
|
||||||
"unixport/makefile.dos"
|
(("\\$\\(MAKE\\) -C \\$\\(PORTDIR\\) final")
|
||||||
"add-defs.bat"
|
"$(MAKE) -C $(PORTDIR)"))))
|
||||||
"gcl-tk/makefile.prev"
|
(add-before 'configure 'pre-conf
|
||||||
"add-defs1")
|
(lambda* (#:key inputs #:allow-other-keys)
|
||||||
(find-files "h" "\\.defs"))
|
(chdir "gcl")
|
||||||
(("SHELL=/bin/bash")
|
(substitute*
|
||||||
(string-append "SHELL=" (which "bash")))
|
(append
|
||||||
(("SHELL=/bin/sh")
|
'("pcl/impl/kcl/makefile.akcl"
|
||||||
(string-append "SHELL=" (which "sh"))))
|
"add-defs"
|
||||||
(substitute* "h/linux.defs"
|
"unixport/makefile.dos"
|
||||||
(("#CC") "CC")
|
"add-defs.bat"
|
||||||
(("-fwritable-strings") "")
|
"gcl-tk/makefile.prev"
|
||||||
(("-Werror") ""))
|
"add-defs1")
|
||||||
(substitute* "lsp/gcl_top.lsp"
|
(find-files "h" "\\.defs"))
|
||||||
(("\"cc\"")
|
(("SHELL=/bin/bash")
|
||||||
(string-append "\"" (assoc-ref %build-inputs "gcc")
|
(string-append "SHELL=" (which "bash")))
|
||||||
"/bin/gcc\""))
|
(("SHELL=/bin/sh")
|
||||||
(("\\(or \\(get-path \\*cc\\*\\) \\*cc\\*\\)") "*cc*")
|
(string-append "SHELL=" (which "sh"))))
|
||||||
(("\"ld\"")
|
(substitute* "h/linux.defs"
|
||||||
(string-append "\"" (assoc-ref %build-inputs "binutils")
|
(("#CC") "CC")
|
||||||
"/bin/ld\""))
|
(("-fwritable-strings") "")
|
||||||
(("\\(or \\(get-path \\*ld\\*\\) \\*ld\\*\\)") "*ld*")
|
(("-Werror") ""))
|
||||||
(("\\(get-path \"objdump --source \"\\)")
|
(substitute* "lsp/gcl_top.lsp"
|
||||||
(string-append "\"" (assoc-ref %build-inputs "binutils")
|
(("\"cc\"")
|
||||||
"/bin/objdump --source \"")))
|
(string-append "\"" (assoc-ref %build-inputs "gcc")
|
||||||
#t))
|
"/bin/gcc\""))
|
||||||
(add-after 'install 'wrap
|
(("\\(or \\(get-path \\*cc\\*\\) \\*cc\\*\\)") "*cc*")
|
||||||
(lambda* (#:key inputs outputs #:allow-other-keys)
|
(("\"ld\"")
|
||||||
(let* ((gcl (assoc-ref outputs "out"))
|
(string-append "\"" (assoc-ref %build-inputs "binutils")
|
||||||
(input-path (lambda (lib path)
|
"/bin/ld\""))
|
||||||
(string-append
|
(("\\(or \\(get-path \\*ld\\*\\) \\*ld\\*\\)") "*ld*")
|
||||||
(assoc-ref inputs lib) path)))
|
(("\\(get-path \"objdump --source \"\\)")
|
||||||
(binaries '("binutils")))
|
(string-append "\"" (assoc-ref %build-inputs "binutils")
|
||||||
;; GCC and the GNU binutils are necessary for GCL to be
|
"/bin/objdump --source \"")))))
|
||||||
;; able to compile Lisp functions and programs (this is
|
(add-after 'install 'wrap
|
||||||
;; a standard feature in Common Lisp). While the
|
(lambda* (#:key inputs outputs #:allow-other-keys)
|
||||||
;; the location of GCC is specified in the make-flags,
|
(let* ((gcl #$output)
|
||||||
;; the GNU binutils must be available in GCL's $PATH.
|
(input-path (lambda (lib path)
|
||||||
(wrap-program (string-append gcl "/bin/gcl")
|
(string-append
|
||||||
`("PATH" prefix ,(map (lambda (binary)
|
(assoc-ref inputs lib) path)))
|
||||||
(input-path binary "/bin"))
|
(binaries '("binutils")))
|
||||||
binaries))))
|
;; GCC and the GNU binutils are necessary for GCL to be
|
||||||
#t))
|
;; able to compile Lisp functions and programs (this is
|
||||||
;; drop strip phase to make maxima build, see
|
;; a standard feature in Common Lisp). While the
|
||||||
;; https://www.ma.utexas.edu/pipermail/maxima/2008/009769.html
|
;; the location of GCC is specified in the make-flags,
|
||||||
(delete 'strip))))
|
;; the GNU binutils must be available in GCL's $PATH.
|
||||||
(inputs
|
(wrap-program (string-append gcl "/bin/gcl")
|
||||||
(list bash-minimal gmp libtirpc readline))
|
`("PATH" prefix ,(map (lambda (binary)
|
||||||
(native-inputs
|
(input-path binary "/bin"))
|
||||||
(list m4 texinfo))
|
binaries))))))
|
||||||
(home-page "https://www.gnu.org/software/gcl/")
|
;; drop strip phase to make maxima build, see
|
||||||
(synopsis "Common Lisp implementation")
|
;; https://www.ma.utexas.edu/pipermail/maxima/2008/009769.html
|
||||||
(description "GCL is an implementation of the Common Lisp language. It
|
(delete 'strip))))
|
||||||
|
(inputs
|
||||||
|
(list bash-minimal gmp libtirpc readline))
|
||||||
|
(native-inputs
|
||||||
|
(list m4 texinfo))
|
||||||
|
(home-page "https://www.gnu.org/software/gcl/")
|
||||||
|
(synopsis "Common Lisp implementation")
|
||||||
|
(description "GCL is an implementation of the Common Lisp language. It
|
||||||
features the ability to compile to native object code and to load native
|
features the ability to compile to native object code and to load native
|
||||||
object code modules directly into its lisp core. It also features a
|
object code modules directly into its lisp core. It also features a
|
||||||
stratified garbage collection strategy, a source-level debugger and a built-in
|
stratified garbage collection strategy, a source-level debugger and a built-in
|
||||||
interface to the Tk widget system.")
|
interface to the Tk widget system.")
|
||||||
(license license:lgpl2.0+))))
|
(license license:lgpl2.0+)))
|
||||||
|
|
||||||
(define-public ecl
|
(define-public ecl
|
||||||
(package
|
(package
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue