[PATCH] gnu: gcl: Update snapshot.

  • Done
  • quality assurance status badge
Details
2 participants
  • Kei Kebreau
  • Ludovic Courtès
Owner
unassigned
Submitted by
Kei Kebreau
Severity
normal

Debbugs page

Kei Kebreau wrote 7 years ago
(address . guix-patches@gnu.org)(name . Kei Kebreau)(address . kkebreau@posteo.net)
20171122190619.3505-1-kkebreau@posteo.net
* gnu/packages/lisp.scm (gcl): Update to 2.6.12-1.5956140.
[arguments]: Remove CFLAGS from make-flags; adjust pre-conf phase.
[native-inputs]: Add which.
---
gnu/packages/lisp.scm | 152 +++++++++++++++++++++++++++-----------------------
1 file changed, 81 insertions(+), 71 deletions(-)

Toggle diff (169 lines)
diff --git a/gnu/packages/lisp.scm b/gnu/packages/lisp.scm
index e5b8ad356..cbb6c0097 100644
--- a/gnu/packages/lisp.scm
+++ b/gnu/packages/lisp.scm
@@ -76,81 +76,91 @@
,lisp))))
(define-public gcl
- (package
- (name "gcl")
- (version "2.6.12")
- (source
- (origin
- (method url-fetch)
- (uri (string-append "mirror://gnu/" name "/" name "-" version ".tar.gz"))
- (sha256
- (base32 "1s4hs2qbjqmn9h88l4xvsifq5c3dlc5s74lyb61rdi5grhdlkf4f"))))
- (build-system gnu-build-system)
- (arguments
- `(#:parallel-build? #f ; The build system seems not to be thread safe.
- #:tests? #f ; There does not seem to be make check or anything similar.
- #:configure-flags '("--enable-ansi") ; required for use by the maxima package
- #:make-flags (list
- "CFLAGS=-fgnu89-inline" ; removes inline function warnings
- (string-append "GCC=" (assoc-ref %build-inputs "gcc")
- "/bin/gcc"))
- #:phases (modify-phases %standard-phases
- (add-before 'configure 'pre-conf
- (lambda _
- (substitute*
- (append
- '("pcl/impl/kcl/makefile.akcl"
- "add-defs"
- "unixport/makefile.dos"
- "add-defs.bat"
- "gcl-tk/makefile.prev"
- "add-defs1")
- (find-files "h" "\\.defs"))
- (("SHELL=/bin/bash")
- (string-append "SHELL=" (which "bash")))
- (("SHELL=/bin/sh")
- (string-append "SHELL=" (which "sh"))))
- (substitute* "h/linux.defs"
- (("#CC") "CC")
- (("-fwritable-strings") "")
- (("-Werror") ""))
- #t))
- (add-after 'install 'wrap
- (lambda* (#:key inputs outputs #:allow-other-keys)
- (let* ((gcl (assoc-ref outputs "out"))
- (input-path (lambda (lib path)
- (string-append
- (assoc-ref inputs lib) path)))
- (binaries '("binutils")))
- ;; GCC and the GNU binutils are necessary for GCL to be
- ;; able to compile Lisp functions and programs (this is
- ;; a standard feature in Common Lisp). While the
- ;; the location of GCC is specified in the make-flags,
- ;; the GNU binutils must be available in GCL's $PATH.
- (wrap-program (string-append gcl "/bin/gcl")
- `("PATH" prefix ,(map (lambda (binary)
- (input-path binary "/bin"))
- binaries))))
- #t))
- ;; drop strip phase to make maxima build, see
- ;; https://www.ma.utexas.edu/pipermail/maxima/2008/009769.html
- (delete 'strip))))
- (inputs
- `(("gmp" ,gmp)
- ("readline" ,readline)))
- (native-inputs
- `(("gcc" ,gcc-4.9)
- ("m4" ,m4)
- ("texinfo" ,texinfo)
- ("texlive" ,texlive)))
- (home-page "https://www.gnu.org/software/gcl/")
- (synopsis "A Common Lisp implementation")
- (description "GCL is an implementation of the Common Lisp language. It
+ (let ((commit "5956140b1083e2302a59d7ce2054b0b7c2cbb417")
+ (revision "1")) ;Guix package revision
+ (package
+ (name "gcl")
+ (version (string-append "2.6.12-" revision "."
+ (string-take commit 7)))
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://git.savannah.gnu.org/r/gcl.git")
+ (commit commit)))
+ (file-name (string-append "gcl-" version "-checkout"))
+ (sha256
+ (base32 "0mwclf2879mh3d9xqkqhghf58lwy7srsnsq9x0f1cc6j302sy4hb"))))
+ (build-system gnu-build-system)
+ (arguments
+ `(#:parallel-build? #f ; The build system seems not to be thread safe.
+ #:tests? #f ; There does not seem to be make check or anything similar.
+ #:configure-flags '("--enable-ansi") ; required for use by the maxima package
+ #:make-flags (list
+ (string-append "GCC=" (assoc-ref %build-inputs "gcc")
+ "/bin/gcc"))
+ #:phases
+ (modify-phases %standard-phases
+ (add-before 'configure 'pre-conf
+ (lambda _
+ (chdir "gcl")
+ (substitute*
+ (append
+ '("pcl/impl/kcl/makefile.akcl"
+ "add-defs"
+ "unixport/makefile.dos"
+ "add-defs.bat"
+ "gcl-tk/makefile.prev"
+ "add-defs1")
+ (find-files "h" "\\.defs"))
+ (("SHELL=/bin/bash")
+ (string-append "SHELL=" (which "bash")))
+ (("SHELL=/bin/sh")
+ (string-append "SHELL=" (which "sh"))))
+ (substitute* "h/linux.defs"
+ (("#CC") "CC")
+ (("-fwritable-strings") "")
+ (("-Werror") ""))
+ #t))
+ (add-after 'install 'wrap
+ (lambda* (#:key inputs outputs #:allow-other-keys)
+ (let* ((gcl (assoc-ref outputs "out"))
+ (input-path (lambda (lib path)
+ (string-append
+ (assoc-ref inputs lib) path)))
+ (binaries '("binutils")))
+ ;; GCC and the GNU binutils are necessary for GCL to be
+ ;; able to compile Lisp functions and programs (this is
+ ;; a standard feature in Common Lisp). While the
+ ;; the location of GCC is specified in the make-flags,
+ ;; the GNU binutils must be available in GCL's $PATH.
+ (wrap-program (string-append gcl "/bin/gcl")
+ `("PATH" prefix ,(map (lambda (binary)
+ (input-path binary "/bin"))
+ binaries))))
+ #t))
+ ;; drop strip phase to make maxima build, see
+ ;; https://www.ma.utexas.edu/pipermail/maxima/2008/009769.html
+ (delete 'strip))))
+ (inputs
+ `(("gmp" ,gmp)
+ ("readline" ,readline)))
+ (native-inputs
+ `(("gcc" ,gcc-4.9)
+ ("m4" ,m4)
+ ("texinfo" ,texinfo)
+ ("texlive" ,texlive)
+ ;; The which binary is needed by lsp/gcl_directory.lsp to properly
+ ;; define the Lisp procedure named "which".
+ ("which" ,which)))
+ (home-page "https://www.gnu.org/software/gcl/")
+ (synopsis "A 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
object code modules directly into its lisp core. It also features a
stratified garbage collection strategy, a source-level debugger and a built-in
interface to the Tk widget system.")
- (license license:lgpl2.0+)))
+ (license license:lgpl2.0+))))
(define-public ecl
(package
--
2.15.0
Ludovic Courtès wrote 7 years ago
(name . Kei Kebreau)(address . kkebreau@posteo.net)(address . 29403@debbugs.gnu.org)
87fu95vwfx.fsf@gnu.org
Hi!

Kei Kebreau <kkebreau@posteo.net> skribis:

Toggle quote (4 lines)
> * gnu/packages/lisp.scm (gcl): Update to 2.6.12-1.5956140.
> [arguments]: Remove CFLAGS from make-flags; adjust pre-conf phase.
> [native-inputs]: Add which.

Could you include a rationale for using a development snapshot?
Normally we’d stick to upstream releases, unless there’s a good reason.

Thanks,
Ludo’.
Kei Kebreau wrote 7 years ago
(name . Ludovic Courtès)(address . ludo@gnu.org)(address . 29403@debbugs.gnu.org)
87fu94kdpk.fsf@posteo.net
ludo@gnu.org (Ludovic Courtès) writes:

Toggle quote (14 lines)
> Hi!
>
> Kei Kebreau <kkebreau@posteo.net> skribis:
>
>> * gnu/packages/lisp.scm (gcl): Update to 2.6.12-1.5956140.
>> [arguments]: Remove CFLAGS from make-flags; adjust pre-conf phase.
>> [native-inputs]: Add which.
>
> Could you include a rationale for using a development snapshot?
> Normally we’d stick to upstream releases, unless there’s a good reason.
>
> Thanks,
> Ludo’.

The short story is that there is an issue with GCL's garbage collection
when it gets built on hydra.gnu.org. In the process of investigating
this issue, I noticed that Camm Maguire, GCL maintainer, uses these
development snapshots in the package he oversees for Debian. This
specific snapshot is the latest one and is shipped in Debian unstable,
but even stable uses a fairly recent GCL development snapshot. These
snapshots are mainly small bug fixes and optimizations from the look of
the GCL commit history.

If you think this update is permissible, how does the following commit
message read:

* gnu/packages/lisp.scm (gcl): Update to 2.6.12-1.5956140.
[arguments]: Remove CFLAGS from make-flags; adjust pre-conf phase.
[native-inputs]: Add which.

This update includes small upstream bug fixes and optimizations.

Thank you,
Kei
-----BEGIN PGP SIGNATURE-----

iQIzBAEBCAAdFiEEg7ZwOtzKO2lLzi2m5qXuPBlGeg0FAloXHpgACgkQ5qXuPBlG
eg0i0g/8C0zALyWZswZvJykEaGSppddz4oySD4aXpAh8q38cM7ETc6tf8ciTWAwa
kfK72D5OYZn1hxg2rapp61c9/kHvJZqN78MVXkh6OsUf7jT8agk+JUssOrHw07rO
hTbKG2yE/dWKqrfRdwv9Mfji53wCvqXZ7i7Ujfg0icsgDxgt6qY2ldsR2jdyJwdu
lEIBzWciYOyxRlRz4tQPgKWxR+xIgDT6prDEkdJz/r1Xl4ybqpywNlB7AxeL8ooG
i+QJwnyumS2iWjQJTjKhpTIYMCuI7BGkk0MKeSiE/7FlqFzlLLLAoRWZ2El3p63o
h1bN/c0aqmmJtXn9v1w3k33fq+kuJvKEXwLXRf5grmQhkWKPu8NcpSlpMCVa83uH
jIXfu4qbMzhzQ5agnoZ5x3V0GO5Nol13B6Eeti51jrNIg1MaH6aj+MOAJs0m6ynh
FEZf5lySXBj5viAtacce32YVM3PFifx46oiw97e99HQ24j3L+eJrz7/yfliiA6Z8
ruMilb1PyIX4fmh+y6cFD5QWZCxQ7Y1xXowPyD/7esoGOlfi0dgByvyURHPBzVV3
SYoZ+bivIlvvyeU5/OqmnRahAM2j7V+sdrV6sNkFKx8jbJJwTBXo/zcyKFu1kMx5
/5lEtn5TmSTBlamaVug4n5Ik1p0XeKkCNhtc+ugugNU9fYm7+Oo=
=W/EA
-----END PGP SIGNATURE-----

Ludovic Courtès wrote 7 years ago
(name . Kei Kebreau)(address . kkebreau@posteo.net)(address . 29403@debbugs.gnu.org)
874lpkpt1c.fsf@gnu.org
Kei Kebreau <kkebreau@posteo.net> skribis:

Toggle quote (15 lines)
>> Kei Kebreau <kkebreau@posteo.net> skribis:
>>
>>> * gnu/packages/lisp.scm (gcl): Update to 2.6.12-1.5956140.
>>> [arguments]: Remove CFLAGS from make-flags; adjust pre-conf phase.
>>> [native-inputs]: Add which.
>>
>> Could you include a rationale for using a development snapshot?
>> Normally we’d stick to upstream releases, unless there’s a good reason.
>>
>> Thanks,
>> Ludo’.
>
> The short story is that there is an issue with GCL's garbage collection
> when it gets built on hydra.gnu.org.

Do you mean that substitutes disappeared? (I just tried and got
substitutes from berlin.guixsd.org.)

Toggle quote (7 lines)
> In the process of investigating this issue, I noticed that Camm
> Maguire, GCL maintainer, uses these development snapshots in the
> package he oversees for Debian. This specific snapshot is the latest
> one and is shipped in Debian unstable, but even stable uses a fairly
> recent GCL development snapshot. These snapshots are mainly small bug
> fixes and optimizations from the look of the GCL commit history.

OK, that certainly justifies this patch.

Nevertheless, we should also kindly invite them to publish these as
formal releases rather than giving Debian a special treatment.

Toggle quote (9 lines)
> If you think this update is permissible, how does the following commit
> message read:
>
> * gnu/packages/lisp.scm (gcl): Update to 2.6.12-1.5956140.
> [arguments]: Remove CFLAGS from make-flags; adjust pre-conf phase.
> [native-inputs]: Add which.
>
> This update includes small upstream bug fixes and optimizations.

Sounds good, yes.

Thanks for explaining!

Ludo’.
Kei Kebreau wrote 7 years ago
(name . Ludovic Courtès)(address . ludo@gnu.org)(address . 29403-done@debbugs.gnu.org)
87bmjrjvva.fsf@posteo.net
ludo@gnu.org (Ludovic Courtès) writes:

Toggle quote (21 lines)
> Kei Kebreau <kkebreau@posteo.net> skribis:
>
>>> Kei Kebreau <kkebreau@posteo.net> skribis:
>>>
>>>> * gnu/packages/lisp.scm (gcl): Update to 2.6.12-1.5956140.
>>>> [arguments]: Remove CFLAGS from make-flags; adjust pre-conf phase.
>>>> [native-inputs]: Add which.
>>>
>>> Could you include a rationale for using a development snapshot?
>>> Normally we’d stick to upstream releases, unless there’s a good reason.
>>>
>>> Thanks,
>>> Ludo’.
>>
>> The short story is that there is an issue with GCL's garbage collection
>> when it gets built on hydra.gnu.org.
>
> Do you mean that substitutes disappeared? (I just tried and got
> substitutes from berlin.guixsd.org.)
>

Sorry for not being clearer. I meant that the stratified garbage
collection that GCL uses seems to have a non-reproducible memory
protection issue right now.

Toggle quote (13 lines)
>> In the process of investigating this issue, I noticed that Camm
>> Maguire, GCL maintainer, uses these development snapshots in the
>> package he oversees for Debian. This specific snapshot is the latest
>> one and is shipped in Debian unstable, but even stable uses a fairly
>> recent GCL development snapshot. These snapshots are mainly small bug
>> fixes and optimizations from the look of the GCL commit history.
>
> OK, that certainly justifies this patch.
>
> Nevertheless, we should also kindly invite them to publish these as
> formal releases rather than giving Debian a special treatment.
>

I'll send a message to the GCL mailing list.

Toggle quote (15 lines)
>> If you think this update is permissible, how does the following commit
>> message read:
>>
>> * gnu/packages/lisp.scm (gcl): Update to 2.6.12-1.5956140.
>> [arguments]: Remove CFLAGS from make-flags; adjust pre-conf phase.
>> [native-inputs]: Add which.
>>
>> This update includes small upstream bug fixes and optimizations.
>
> Sounds good, yes.
>
> Thanks for explaining!
>
> Ludo’.

Pushed to master as dd0134fcb707452e1c343d66af6088c0be38a285. I also
managed to avoid adding "which" as a build dependency by substituting
paths to gcc, ld and objdump in GCL's top loop. Thanks for the review!
-----BEGIN PGP SIGNATURE-----

iQIzBAEBCAAdFiEEg7ZwOtzKO2lLzi2m5qXuPBlGeg0FAloYeOoACgkQ5qXuPBlG
eg0nexAAgHwHTk2ufEuX8x0Ce8jYZ2HQScKFjljKxvp8yo3lXLFGMAaYjot5x8Lj
L/Q31xGUCjCfi6wf63pEdfZfo4Y1kPzUstHIFxh76zYSjM8VX3cJco3/X2/A7cqQ
UKVFvdIIgf0tRLivSFWSvz5g5ZKE1fK0TIeF7Qrj4DKtf4JP5vazYmLffyYcMpel
Ofm2OgO3zxFDkS5JRWIjy1dDlSZLbF9chyKQDOwrK/FhICi97Uyg1dEX110QsEPZ
yXDyFT5t7qX5T5EKoupUPKWVJ7xp4NHISR1Co9cxbsEkBMLq2TR2LFFphyQQBIKL
iTwNmJyhlSzTKAh+PCtipIjMU85HdmTXk1lZZhHvBb0NTSyEIJXZWNTge2QLquGR
ENVWS2OF7nNtfVnS1IJVNHg+vraOyF0xEmiDH+O3DezCZt+P28KVwcYyaHgR8wQr
dsYtwPWgi5dUNT9wCfGGNkBJAnxu5NZBIx26+PGO3RK79tDLzYRH2Po0O88GSgZ9
rPZEThWbDtH+KsEOJIXFzpmcn71V5yzn7OID4DY8HXXOm0uG1Gl7IIpE9cUz2QJ+
WnSqHbACf0cqsPONc27H2ioWFGrxN7kQdkP+882ttr945czu2zYlQF5Z8eQhG47y
0t1v7RFKZ6FOLeMeMMBM79HD2PJVvSL2qxzpIueJAg0Zs06YgoE=
=1YyW
-----END PGP SIGNATURE-----

Closed
?
Your comment

This issue is archived.

To comment on this conversation send an email to 29403@debbugs.gnu.org

To respond to this issue using the mumi CLI, first switch to it
mumi current 29403
Then, you may apply the latest patchset in this issue (with sign off)
mumi am -- -s
Or, compose a reply to this issue
mumi compose
Or, send patches to this issue
mumi send-email *.patch
You may also tag this issue. See list of standard tags. For example, to set the confirmed and easy tags
mumi command -t +confirmed -t +easy
Or, remove the moreinfo tag and set the help tag
mumi command -t -moreinfo -t +help