1 ;;; GNU Guix --- Functional package management for GNU
2 ;;; Copyright © 2013 Nikita Karetnikov <nikita@karetnikov.org>
3 ;;; Copyright © 2016 Efraim Flashner <efraim@flashner.co.il>
4 ;;; Copyright © 2016 Nicolas Goaziou <mail@nicolasgoaziou.fr>
5 ;;; Copyright © 2016 Ludovic Courtès <ludo@gnu.org>
6 ;;; Copyright © 2018 Tobias Geerinckx-Rice <me@tobias.gr>
8 ;;; This file is part of GNU Guix.
10 ;;; GNU Guix is free software; you can redistribute it and/or modify it
11 ;;; under the terms of the GNU General Public License as published by
12 ;;; the Free Software Foundation; either version 3 of the License, or (at
13 ;;; your option) any later version.
15 ;;; GNU Guix is distributed in the hope that it will be useful, but
16 ;;; WITHOUT ANY WARRANTY; without even the implied warranty of
17 ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 ;;; GNU General Public License for more details.
20 ;;; You should have received a copy of the GNU General Public License
21 ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
23 (define-module (gnu packages smalltalk)
24 #:use-module ((guix licenses) #:prefix license:)
25 #:use-module (guix packages)
26 #:use-module (guix download)
27 #:use-module (guix build-system cmake)
28 #:use-module (guix build-system gnu)
29 #:use-module (gnu packages)
30 #:use-module (gnu packages assembly)
31 #:use-module (gnu packages audio)
32 #:use-module (gnu packages autotools)
33 #:use-module (gnu packages base)
34 #:use-module (gnu packages compression)
35 #:use-module (gnu packages fontutils)
36 #:use-module (gnu packages gl)
37 #:use-module (gnu packages glib)
38 #:use-module (gnu packages libffi)
39 #:use-module (gnu packages libsigsegv)
40 #:use-module (gnu packages linux)
41 #:use-module (gnu packages multiprecision)
42 #:use-module (gnu packages pkg-config)
43 #:use-module (gnu packages pulseaudio)
44 #:use-module (gnu packages xorg))
46 (define-public smalltalk
53 ;; XXX: Revert to mirror://gnu with the next release of Smalltalk.
54 (uri (string-append "https://alpha.gnu.org/gnu/smalltalk/smalltalk-"
58 "1zb2h5cbz1cwybqjl24lflw359lwj7sjvvhwb4x6miypzhwq4qh0"))
59 ;; XXX: To be removed with the next release of Smalltalk.
60 (patches (search-patches "smalltalk-multiplication-overflow.patch"))))
61 (build-system gnu-build-system)
63 `(("pkg-config" ,pkg-config)
64 ;; XXX: To be removed with the next release of Smalltalk.
65 ("autoconf" ,autoconf)
66 ("automake" ,automake)
67 ("libtool" ,libtool)))
68 ;; TODO: These optional dependencies raise the closure size to ~1 GiB
69 ;; from the current ~100 MiB, although some of them might be very
70 ;; useful for end users:
73 ;; - gobject-introspection
83 ("libsigsegv" ,libsigsegv)
84 ("lightning" ,lightning)
88 (modify-phases %standard-phases
89 ;; XXX: To be removed with the next release of Smalltalk.
90 ;; The overflow patch modifies configure.ac, therefore remove
91 ;; old configure script and enforce an autoreconf.
92 (add-before 'bootstrap 'remove-unpatched-configure
94 (delete-file "configure")
96 ;; XXX: To be removed with the next release of Smalltalk.
97 ;; We don't want to regenerate the info files.
98 (add-after 'build 'keep-generated-info-manual
100 (for-each (lambda (file)
101 (invoke "touch" file))
102 (find-files "doc" "\\.info"))
104 (add-before 'configure 'fix-libc
106 (let ((libc (assoc-ref %build-inputs "libc")))
107 (substitute* "libc.la.in"
108 (("@LIBC_SO_NAME@") "libc.so")
109 (("@LIBC_SO_DIR@") (string-append libc "/lib"))))
111 (home-page "http://smalltalk.gnu.org/")
112 (synopsis "Smalltalk environment")
114 "GNU Smalltalk is a free implementation of the Smalltalk language. It
115 implements the ANSI standard for the language and also includes extra classes
116 such as ones for networking and GUI programming.")
117 (license license:gpl2+)))
119 (define-public squeak-vm
122 (version "4.10.2.2614")
126 (uri (string-append "http://squeakvm.org/unix/release/"
127 "Squeak-" version "-src.tar.gz"))
129 (base32 "0bpwbnpy2sb4gylchfx50sha70z36bwgdxraym4vrr93l8pd3dix"))
130 (modules '((guix build utils)))
132 ;; Make builds bit-reproducible.
134 (substitute* "unix/cmake/verstamp"
136 "vm_date = \"1970-01-01\";\n")
138 "ux_version = \"GNU\";\n"))
139 (substitute* "unix/vm/config.cmake"
140 (("\\(VM_BUILD_STRING.*")
141 "(VM_BUILD_STRING \\\"Built with GNU Guix\\\")"))
144 `(("alsa-lib" ,alsa-lib)
146 ("freetype" ,freetype)
148 ("libxrender" ,libxrender)
150 ("pulseaudio" ,pulseaudio)))
152 `(("pkg-config" ,pkg-config)))
153 (build-system cmake-build-system)
155 `(#:tests? #f ;no check target
157 (modify-phases %standard-phases
158 (add-after 'unpack 'remove-hardcoded-PATH
160 ;; Remove hard-coded FHS PATH entries.
161 (substitute* '("unix/cmake/squeak.in"
162 "unix/cmake/squeak.sh.in")
165 (add-before 'configure 'enter-build-directory
171 (lambda* (#:key outputs #:allow-other-keys)
172 (let ((out (assoc-ref outputs "out")))
173 (invoke "../unix/cmake/configure"
174 (string-append "--prefix=" out)
177 (synopsis "Smalltalk programming language and environment")
178 (description "Squeak is a full-featured implementation of the Smalltalk
179 programming language and environment based on (and largely compatible with)
180 the original Smalltalk-80 system. Squeak has very powerful 2- and 3-D
181 graphics, sound, video, MIDI, animation and other multimedia capabilities. It
182 also includes a customisable framework for creating dynamic HTTP servers and
183 interactively extensible Web sites.")
184 (home-page "http://squeakvm.org/")
185 (license license:x11)))