Commit | Line | Data |
---|---|---|
2614de3c DM |
1 | ;;; GNU Guix --- Functional package management for GNU |
2 | ;;; Copyright © 2016 Danny Milosavljevic <dannym@scratchpost.org> | |
9e39ac41 | 3 | ;;; Copyright © 2016, 2017 Ricardo Wurmus <rekado@elephly.net> |
b84257c0 | 4 | ;;; Copyright © 2016 Hartmut Goebel <h.goebel@crazy-compilers.com> |
3f19b268 | 5 | ;;; Copyright © 2017, 2018, 2019 Efraim Flashner <efraim@flashner.co.il> |
96ec4604 | 6 | ;;; Copyright © 2018, 2019 Tobias Geerinckx-Rice <me@tobias.gr> |
f4167bda | 7 | ;;; Copyright © 2018, 2019, 2020 Nicolas Goaziou <mail@nicolasgoaziou.fr> |
2614de3c DM |
8 | ;;; |
9 | ;;; This file is part of GNU Guix. | |
10 | ;;; | |
11 | ;;; GNU Guix is free software; you can redistribute it and/or modify it | |
12 | ;;; under the terms of the GNU General Public License as published by | |
13 | ;;; the Free Software Foundation; either version 3 of the License, or (at | |
14 | ;;; your option) any later version. | |
15 | ;;; | |
16 | ;;; GNU Guix is distributed in the hope that it will be useful, but | |
17 | ;;; WITHOUT ANY WARRANTY; without even the implied warranty of | |
18 | ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | |
19 | ;;; GNU General Public License for more details. | |
20 | ;;; | |
21 | ;;; You should have received a copy of the GNU General Public License | |
22 | ;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>. | |
23 | ||
24 | (define-module (gnu packages education) | |
25 | #:use-module (ice-9 regex) | |
26 | #:use-module (gnu packages) | |
3cfd12f3 NG |
27 | #:use-module (gnu packages base) |
28 | #:use-module (gnu packages bash) | |
2614de3c | 29 | #:use-module (gnu packages compression) |
230e59da | 30 | #:use-module (gnu packages curl) |
4f963be0 NG |
31 | #:use-module (gnu packages databases) |
32 | #:use-module (gnu packages fonts) | |
3cfd12f3 | 33 | #:use-module (gnu packages freedesktop) |
4f963be0 | 34 | #:use-module (gnu packages game-development) |
2614de3c | 35 | #:use-module (gnu packages gettext) |
0ea179fd RW |
36 | #:use-module (gnu packages glib) |
37 | #:use-module (gnu packages gnome) | |
38 | #:use-module (gnu packages gtk) | |
3cfd12f3 | 39 | #:use-module (gnu packages javascript) |
d2c0a7a2 | 40 | #:use-module (gnu packages kde) |
b27aacbf | 41 | #:use-module (gnu packages kde-frameworks) ; extra-cmake-modules |
2614de3c | 42 | #:use-module (gnu packages perl) |
0ea179fd RW |
43 | #:use-module (gnu packages pkg-config) |
44 | #:use-module (gnu packages python) | |
3cfd12f3 | 45 | #:use-module (gnu packages qt) |
0ea179fd | 46 | #:use-module (gnu packages sdl) |
cd0322a3 | 47 | #:use-module (gnu packages sqlite) |
0ea179fd | 48 | #:use-module (gnu packages texinfo) |
96ec4604 | 49 | #:use-module (gnu packages tls) |
7e48e849 | 50 | #:use-module (gnu packages xorg) |
0ea179fd | 51 | #:use-module (gnu packages xml) |
2614de3c DM |
52 | #:use-module ((guix licenses) #:prefix license:) |
53 | #:use-module (guix packages) | |
54 | #:use-module (guix download) | |
3cfd12f3 | 55 | #:use-module (guix git-download) |
2614de3c DM |
56 | #:use-module (guix svn-download) |
57 | #:use-module (guix utils) | |
2614de3c | 58 | #:use-module (guix build-system cmake) |
3cfd12f3 | 59 | #:use-module (guix build-system gnu) |
3b2cf5c8 | 60 | #:use-module (guix build-system python) |
7d796d80 | 61 | #:use-module (guix build-system qt) |
3cfd12f3 | 62 | #:use-module (guix build-system trivial) |
2614de3c DM |
63 | #:use-module (srfi srfi-1)) |
64 | ||
0ea179fd RW |
65 | (define-public gcompris |
66 | (package | |
67 | (name "gcompris") | |
cdc827b3 | 68 | (version "17.05") |
0ea179fd RW |
69 | (source (origin |
70 | (method url-fetch) | |
71 | (uri (string-append "http://gcompris.net/download/gtk/src/gcompris-" | |
72 | version ".tar.bz2")) | |
73 | (sha256 | |
74 | (base32 | |
cdc827b3 | 75 | "18y483alb4r4vfmh80nnl0pah5gv0b8frcm6l1drb9njn5xlcpgc")))) |
0ea179fd RW |
76 | (build-system gnu-build-system) |
77 | (arguments | |
78 | `(#:configure-flags | |
79 | ;; Use SDL mixer because otherwise GCompris would need an old version | |
80 | ;; of Gstreamer. | |
81 | (list "--enable-sdlmixer" | |
82 | "LDFLAGS=-lgmodule-2.0") | |
83 | #:phases | |
84 | (modify-phases %standard-phases | |
85 | (add-after 'set-paths 'set-sdl-paths | |
86 | (lambda* (#:key inputs #:allow-other-keys) | |
87 | (setenv "CPATH" | |
88 | (string-append (assoc-ref inputs "sdl-mixer") | |
5ba856ab MB |
89 | "/include/SDL:" |
90 | (or (getenv "CPATH") ""))) | |
0ea179fd RW |
91 | #t))))) |
92 | (inputs | |
93 | `(("gtk+" ,gtk+-2) | |
94 | ("librsvg" ,librsvg) | |
95 | ("libxml2" ,libxml2) | |
96 | ("sdl-mixer" ,sdl-mixer) | |
97 | ("sqlite" ,sqlite) | |
98 | ("glib:bin" ,glib) | |
99 | ("python" ,python))) | |
100 | (native-inputs | |
101 | `(("intltool" ,intltool) | |
102 | ("texinfo" ,texinfo) | |
103 | ("texi2html" ,texi2html) | |
104 | ("glib:bin" ,glib "bin") | |
105 | ("pkg-config" ,pkg-config))) | |
106 | (home-page "http://gcompris.net") | |
107 | (synopsis "Educational software suite") | |
108 | (description "GCompris is an educational software suite comprising of | |
109 | numerous activities for children aged 2 to 10. Some of the activities are | |
110 | game orientated, but nonetheless still educational. Below you can find a list | |
111 | of categories with some of the activities available in that category. | |
112 | ||
113 | @enumerate | |
114 | @item computer discovery: keyboard, mouse, different mouse gestures, ... | |
115 | @item arithmetic: table memory, enumeration, double entry table, mirror image, ... | |
116 | @item science: the canal lock, the water cycle, the submarine, electric simulation ... | |
117 | @item geography: place the country on the map | |
118 | @item games: chess, memory, connect 4, oware, sudoku ... | |
119 | @item reading: reading practice | |
120 | @item other: learn to tell time, puzzle of famous paintings, vector drawing, cartoon making, ... | |
121 | @end enumerate | |
122 | ") | |
123 | (license license:gpl3+))) | |
b84257c0 | 124 | |
b27aacbf EF |
125 | (define-public gcompris-qt |
126 | (package | |
127 | (name "gcompris-qt") | |
96ec4604 | 128 | (version "0.96") |
b27aacbf | 129 | (source |
96ec4604 TGR |
130 | (origin |
131 | (method url-fetch) | |
132 | (uri (string-append | |
133 | "https://gcompris.net/download/qt/src/gcompris-qt-" | |
134 | version ".tar.xz")) | |
135 | (sha256 | |
136 | (base32 "06483il59l46ny2w771sg45dgzjwv1ph7vidzzbj0wb8wbk2rg52")))) | |
b27aacbf EF |
137 | (build-system cmake-build-system) |
138 | (arguments | |
5c105203 EF |
139 | `(#:phases |
140 | (modify-phases %standard-phases | |
7e48e849 EF |
141 | (add-before 'check 'start-xorg-server |
142 | (lambda* (#:key inputs #:allow-other-keys) | |
143 | ;; The test suite requires a running X server. | |
144 | (system (string-append (assoc-ref inputs "xorg-server") | |
145 | "/bin/Xvfb :1 &")) | |
146 | (setenv "DISPLAY" ":1") | |
147 | #t)) | |
5c105203 EF |
148 | (add-after 'install 'wrap-executable |
149 | (lambda* (#:key inputs outputs #:allow-other-keys) | |
150 | (let ((out (assoc-ref outputs "out"))) | |
151 | (wrap-program (string-append out "/bin/gcompris-qt") | |
152 | `("QT_PLUGIN_PATH" ":" prefix | |
153 | ,(map (lambda (label) | |
154 | (string-append (assoc-ref inputs label) | |
155 | "/lib/qt5/plugins")) | |
156 | '("qtbase" "qtdeclarative" "qtmultimedia" "qtsvg"))) | |
157 | `("QML2_IMPORT_PATH" ":" prefix | |
158 | ,(map (lambda (label) | |
159 | (string-append (assoc-ref inputs label) | |
160 | "/lib/qt5/qml")) | |
161 | '("qtdeclarative" "qtgraphicaleffects" | |
162 | "qtmultimedia" "qtquickcontrols")))) | |
163 | #t)))) | |
7e48e849 EF |
164 | #:configure-flags (list "-DQML_BOX2D_MODULE=disabled" |
165 | "-DBUILD_TESTING=TRUE"))) | |
b27aacbf EF |
166 | (native-inputs |
167 | `(("extra-cmake-modules" ,extra-cmake-modules) | |
168 | ("gettext" ,gettext-minimal) | |
5c105203 | 169 | ("perl" ,perl) |
7e48e849 | 170 | ("qttools" ,qttools) |
ff337525 | 171 | ("xorg-server" ,xorg-server-for-tests))) |
b27aacbf | 172 | (inputs |
96ec4604 TGR |
173 | `(("openssl" ,openssl) |
174 | ("python-2" ,python-2) | |
5c105203 EF |
175 | ("qtbase" ,qtbase) |
176 | ("qtdeclarative" ,qtdeclarative) | |
177 | ("qtgraphicaleffects" ,qtgraphicaleffects) | |
178 | ("qtmultimedia" ,qtmultimedia) | |
179 | ("qtquickcontrols" ,qtquickcontrols) | |
180 | ("qtsensors" ,qtsensors) | |
181 | ("qtsvg" ,qtsvg) | |
182 | ("qtxmlpatterns" ,qtxmlpatterns))) | |
183 | (home-page "https://gcompris.net/index-en.html") | |
b27aacbf EF |
184 | (synopsis "Educational games for small children") |
185 | (description | |
186 | "Gcompris offers a large collection of educational games for small | |
187 | children, designed to be a unified interface to integrate more educational | |
188 | games. Language-oriented games contain vocabulary, sounds, and voices for | |
189 | many different languages. | |
190 | Currently available boards include: | |
191 | @enumerate | |
192 | @item learning how to use a mouse and keyboard | |
193 | @item learning simple arithmetic | |
194 | @item learning how to read an analog clock | |
195 | @item recognize letters after hearing their names | |
196 | @item reading practice | |
197 | @item small games (memory games, jigsaw puzzles, ...) | |
198 | @end enumerate\n") | |
199 | (license license:gpl3+))) | |
200 | ||
b84257c0 HG |
201 | (define-public tipp10 |
202 | (package | |
203 | (name "tipp10") | |
204 | (version "2.1.0") | |
205 | (source (origin | |
206 | (method url-fetch) | |
207 | ;; guix download is not able to handle the download links on the | |
208 | ;; home-page, which use '<meta http-equiv="refresh" …>' | |
209 | (uri (string-append "mirror://debian/pool/main/" | |
210 | "t/tipp10/tipp10_2.1.0.orig.tar.gz")) | |
211 | (sha256 | |
212 | (base32 | |
213 | "0d387b404j88gsv6kv0rb7wxr23v5g5vl6s5l7602x8pxf7slbbx")) | |
214 | (patches (search-patches "tipp10-fix-compiling.patch" | |
215 | "tipp10-remove-license-code.patch")))) | |
216 | (build-system cmake-build-system) | |
217 | (arguments | |
218 | `(#:tests? #f ; packages has no tests | |
219 | #:phases | |
220 | (modify-phases %standard-phases | |
221 | (add-after 'unpack 'disable-new-version-check | |
7cc98473 RW |
222 | (lambda _ |
223 | ;; Make new version check to default to false. | |
224 | ;; TODO: Remove the checkbox from the dialog and the check itself | |
225 | (substitute* '("widget/settingspages.cpp" "widget/mainwindow.cpp") | |
226 | (("settings.value(\"check_new_version\", true)") | |
227 | "settings.value(\"check_new_version\", false)")) | |
228 | #t)) | |
b84257c0 | 229 | (replace 'configure |
7cc98473 RW |
230 | (lambda* (#:key outputs #:allow-other-keys) |
231 | (let ((out (assoc-ref outputs "out"))) | |
232 | ;; Make program honor $PREFIX | |
233 | (substitute* "tipp10.pro" | |
234 | (("\\.path = /usr/") (string-append ".path = " out "/"))) | |
235 | (substitute* "def/defines.h" | |
236 | (("\"/usr/") (string-append "\"" out "/"))) | |
237 | ;; Recreate Makefile | |
946e5e8a | 238 | (invoke "qmake"))))))) |
b84257c0 HG |
239 | (inputs |
240 | `(("qt4" ,qt-4) | |
241 | ("sqlite" ,sqlite))) | |
242 | (home-page "https://www.tipp10.com/") | |
243 | (synopsis "Touch typing tutor") | |
9e39ac41 RW |
244 | (description "Tipp10 is a touch typing tutor. The ingenious thing about |
245 | the software is its intelligence feature: characters that are mistyped are | |
246 | repeated more frequently. Beginners will find their way around right away so | |
247 | they can start practicing without a hitch. | |
b84257c0 HG |
248 | |
249 | Useful support functions and an extensive progress tracker, topical lessons | |
250 | and the ability to create your own practice lessons make learning to type | |
9e39ac41 | 251 | easy.") |
b84257c0 | 252 | (license license:gpl2))) |
3cfd12f3 NG |
253 | |
254 | (define-public snap | |
255 | (package | |
256 | (name "snap") | |
62ecae83 | 257 | (version "5.4.5") |
3cfd12f3 NG |
258 | (source |
259 | (origin | |
260 | (method git-fetch) | |
261 | (uri (git-reference | |
3a352a44 | 262 | (url "https://github.com/jmoenig/Snap.git") |
458f410b | 263 | (commit (string-append "v" version)))) |
3cfd12f3 NG |
264 | (file-name (git-file-name name version)) |
265 | (sha256 | |
62ecae83 | 266 | (base32 "1z6dbcsgvxxs40p23qysfsk4vzpg8jlrr5pqfnjf8q3kpz1xvzxf")))) |
3cfd12f3 NG |
267 | (build-system trivial-build-system) |
268 | (arguments | |
269 | `(#:modules ((guix build utils)) | |
270 | #:builder | |
271 | (begin | |
272 | (use-modules (guix build utils)) | |
273 | (let* ((source (assoc-ref %build-inputs "source")) | |
274 | (out (assoc-ref %outputs "out")) | |
275 | (share (string-append out "/share/snap"))) | |
276 | (copy-recursively source share) | |
277 | ;; Replace the sole minified file in the package. | |
3a352a44 | 278 | (with-directory-excursion (string-append share "/src") |
3cfd12f3 NG |
279 | (delete-file "FileSaver.min.js") |
280 | (symlink (string-append (assoc-ref %build-inputs "js-filesaver") | |
281 | "/share/javascript/FileSaver.min.js") | |
282 | "FileSaver.min.js")) | |
283 | ;; Create a "snap" executable. | |
284 | (let* ((bin (string-append out "/bin")) | |
285 | (script (string-append bin "/snap")) | |
286 | (snap (string-append share "/snap.html")) | |
287 | (bash (string-append (assoc-ref %build-inputs "bash") | |
288 | "/bin/sh")) | |
289 | (xdg-open (string-append (assoc-ref %build-inputs "xdg-utils") | |
290 | "/bin/xdg-open"))) | |
291 | (mkdir-p bin) | |
292 | (call-with-output-file script | |
293 | (lambda (port) | |
294 | (format port "#!~a\n~a '~a'" bash xdg-open snap))) | |
295 | (chmod script #o555))) | |
296 | #t))) | |
297 | (inputs | |
298 | `(("bash" ,bash-minimal) | |
299 | ("js-filesaver" ,js-filesaver) | |
300 | ("xdg-utils" ,xdg-utils))) | |
301 | (home-page "https://snap.berkeley.edu") | |
302 | (synopsis "Visual, blocks based programming language") | |
303 | (description "Snap! (formerly BYOB) is a visual, drag-and-drop | |
304 | programming language. It is an extended reimplementation of Scratch (a | |
305 | project of the Lifelong Kindergarten Group at the MIT Media Lab) that | |
306 | allows you to Build Your Own Blocks. It also features first class | |
307 | lists, first class procedures, and continuations. These added | |
308 | capabilities make it suitable for a serious introduction to computer | |
309 | science for high school or college students. | |
310 | ||
311 | This package provides a @command{snap} executable calling @command{xdg-open} | |
312 | to open the application in a web browser, for offline usage.") | |
313 | (license license:agpl3+))) | |
3b2cf5c8 NG |
314 | |
315 | (define-public toutenclic | |
316 | (package | |
317 | (name "toutenclic") | |
f5557bde | 318 | (version "7.00") |
3b2cf5c8 NG |
319 | (source |
320 | (origin | |
321 | (method url-fetch) | |
322 | (uri (string-append "http://www.bipede.fr/downloads/logiciels/" | |
f5557bde | 323 | "ToutEnClic-" version "-src.zip")) |
3b2cf5c8 | 324 | (sha256 |
f5557bde | 325 | (base32 "0xg24p925rl5bfqsq3jb2lrkidb0f3kbmay5iyxxmjsn3ra0blyh")))) |
3b2cf5c8 NG |
326 | (build-system python-build-system) |
327 | (arguments | |
632c508c | 328 | `(#:tests? #f ; no tests |
3b2cf5c8 NG |
329 | #:phases |
330 | (modify-phases %standard-phases | |
331 | (delete 'build) | |
332 | (replace 'install | |
333 | (lambda* (#:key outputs #:allow-other-keys) | |
334 | (let* ((out (assoc-ref outputs "out")) | |
335 | (share (string-append out "/share/toutenclic")) | |
336 | (pixmaps (string-append out "/share/pixmaps")) | |
f5557bde | 337 | (doc (string-append out "share/doc/" ,name "-" ,version)) |
3b2cf5c8 | 338 | (bin (string-append out "/bin")) |
f5557bde | 339 | (executable "toutenclic")) |
3b2cf5c8 NG |
340 | ;; Install icon. |
341 | (install-file "toutenclic.png" pixmaps) | |
342 | ;; Move files into "share/" directory. | |
f5557bde NG |
343 | (for-each (lambda (f) (install-file f share)) |
344 | (find-files "." "\\.py$")) | |
345 | ;; Install documentation. | |
346 | (install-file "ToutEnClic.pdf" doc) | |
3b2cf5c8 NG |
347 | ;; Create executable in "bin/". |
348 | (mkdir-p bin) | |
349 | (with-directory-excursion bin | |
f5557bde | 350 | (symlink (string-append share "/" executable ".py") |
3b2cf5c8 NG |
351 | executable))) |
352 | #t)) | |
353 | (add-after 'install 'create-desktop-file | |
354 | (lambda* (#:key outputs #:allow-other-keys) | |
355 | (let* ((out (assoc-ref outputs "out")) | |
356 | (applications (string-append out "/share/applications"))) | |
357 | (mkdir-p applications) | |
358 | (call-with-output-file | |
359 | (string-append applications "/toutenclic.desktop") | |
360 | (lambda (file) | |
361 | (format file | |
362 | "[Desktop Entry]~@ | |
363 | Name=ToutEnClic~@ | |
364 | Comment=For schooling without difference~@ | |
f5557bde NG |
365 | Exec=~a/bin/toutenclic~@ |
366 | TryExec=~@*~a/bin/toutenclic~@ | |
3b2cf5c8 NG |
367 | Terminal=false~@ |
368 | Icon=toutenclic~@ | |
369 | Type=Application~%" | |
370 | out))) | |
371 | #t)))))) | |
372 | (inputs `(("python-pyqt" ,python-pyqt))) | |
373 | (synopsis "School tools for physically disabled children") | |
374 | (description "ToutEnClic is intended to facilitate the schooling | |
375 | of physically disabled children in ordinary schools. It is both | |
376 | a multi-page virtual exercise book and a kit including pencil, | |
377 | scissors, glue, ruler, compass, protractor and square. A virtual | |
378 | keyboard is also available if the child does not have any other | |
379 | specialized device.") | |
380 | (home-page "https://bipede.fr/contrib/") | |
381 | (license license:gpl3))) | |
4f963be0 NG |
382 | |
383 | (define-public childsplay | |
384 | (package | |
385 | (name "childsplay") | |
386 | (version "3.4") | |
387 | (source (origin | |
388 | (method url-fetch) | |
389 | (uri (string-append | |
390 | "mirror://sourceforge/schoolsplay/" | |
391 | "childsplay-" version ".tgz")) | |
392 | (sha256 | |
393 | (base32 | |
394 | "0z7yp2swjnbz51vn2zyfnjn40jq38l5mbh15yafmx1z3vn2z1m77")))) | |
395 | (build-system python-build-system) | |
396 | (arguments | |
397 | `(#:python ,python-2 | |
398 | #:tests? #f | |
399 | #:phases | |
400 | (modify-phases %standard-phases | |
401 | (add-after 'unpack 'unbundle-dejavu-font | |
402 | (lambda* (#:key inputs #:allow-other-keys) | |
403 | (let* ((dejavu-dir | |
404 | (string-append (assoc-ref inputs "font-dejavu") | |
405 | "/share/fonts/truetype")) | |
406 | (dejavu-font | |
407 | (string-append dejavu-dir | |
408 | "/DejaVuSansCondensed-Bold.ttf"))) | |
409 | (substitute* "SPConstants.py" | |
410 | (("^(TTF(BOLD)? = ).*" _ prefix) | |
411 | (string-append prefix "'" dejavu-font "'\n"))) | |
412 | (for-each (lambda (f) (delete-file f)) | |
413 | (find-files "lib/SPData" "DejaVu")) | |
414 | #t))) | |
415 | (delete 'build) | |
416 | (replace 'install | |
417 | (lambda* (#:key outputs #:allow-other-keys) | |
418 | (let* ((out (assoc-ref outputs "out")) | |
419 | (pixmaps (string-append out "/share/pixmaps")) | |
420 | (share (string-append out "/share/childsplay")) | |
421 | (doc (string-append out "/share/doc/" ,name "-",version))) | |
422 | ;; Install icon. | |
423 | (install-file "lib/SPData/themes/childsplay/logo_cp.svg" pixmaps) | |
424 | ;; Install data. | |
425 | (mkdir-p share) | |
426 | (for-each (lambda (f) | |
427 | (copy-recursively f (string-append share "/" f))) | |
428 | '("alphabet-sounds" "lib" "locale" "SPWidgets")) | |
429 | (for-each (lambda (f) (install-file f share)) | |
430 | (find-files "." "\\.(py|dev|db)$")) | |
431 | ;; Install documentation. | |
432 | (mkdir-p doc) | |
433 | (copy-recursively "docs" doc) | |
434 | #t))) | |
435 | (add-after 'install 'create-executable | |
436 | (lambda* (#:key outputs inputs #:allow-other-keys) | |
437 | (let* ((python (string-append (assoc-ref inputs "python") | |
438 | "/bin/python")) | |
439 | (out (assoc-ref outputs "out")) | |
440 | (bin (string-append out "/bin")) | |
441 | (executable (string-append bin "/childsplay"))) | |
442 | (mkdir-p bin) | |
443 | (call-with-output-file executable | |
444 | (lambda (file) | |
445 | (format file | |
446 | "~a ~a" | |
447 | python | |
448 | (string-append out "/share/childsplay/childsplay.py")))) | |
449 | (chmod executable #o555) | |
450 | #t))) | |
451 | (add-after 'install 'create-desktop-file | |
452 | (lambda* (#:key outputs #:allow-other-keys) | |
453 | (let* ((out (assoc-ref outputs "out")) | |
454 | (applications (string-append out "/share/applications"))) | |
455 | (mkdir-p applications) | |
456 | (call-with-output-file | |
457 | (string-append applications "/childsplay.desktop") | |
458 | (lambda (file) | |
459 | (format file | |
460 | "[Desktop Entry]~@ | |
461 | Name=Childsplay~@ | |
462 | Comment=Suite of educational games for young children~@ | |
463 | Comment[ca]=Conjunt de jocs educatius per a xiquets~@ | |
464 | Comment[es]=Conjunto de juegos educativos para niños~@ | |
465 | Comment[de]=Sammlung mit lehrreichen Spielen für kleine Kinder~@ | |
466 | Exec=~a/bin/childsplay.py~@ | |
467 | Terminal=false~@ | |
468 | Icon=logo_cp.svg~@ | |
469 | Type=Application~@ | |
470 | Categories=Application;Game;Education;KidsGame;~@ | |
471 | Keywords=suite;children;games;young;educational;~%" | |
472 | out))) | |
473 | #t)))))) | |
474 | (inputs | |
475 | `(("font-dejavu" ,font-dejavu) | |
476 | ("pygame" ,python2-pygame) | |
477 | ("sqlalchemy" ,python2-sqlalchemy))) | |
478 | (synopsis "Suite of educational games for young children") | |
479 | (description "Childsplay is a collection of educational activities | |
480 | for young children. Childsplay can be used at home, kindergartens and | |
481 | pre-schools. Childsplay is a fun and safe way to let young children | |
482 | use the computer and at the same time teach them a little math, | |
483 | letters of the alphabet, spelling, eye-hand coordination, etc.") | |
484 | (home-page "http://www.schoolsplay.org") | |
485 | (license license:gpl3+))) | |
52e7295f | 486 | |
3450bb81 NG |
487 | (define-public omnitux |
488 | (package | |
489 | (name "omnitux") | |
490 | (version "1.2.1") | |
491 | (source | |
492 | (origin | |
493 | (method url-fetch) | |
494 | (uri (string-append "mirror://sourceforge/omnitux/omnitux/" | |
495 | "v" version "/omnitux-" version ".tar.bz2")) | |
496 | (sha256 | |
497 | (base32 "1wmmmbzmxd0blhn00d4g91xwavnab143a31ca3i8hrqgzh6qz9w6")) | |
498 | (modules '((guix build utils))) | |
499 | (snippet | |
500 | '(begin | |
501 | ;; Remove pre-compiled .pyc files from source. | |
502 | (for-each delete-file (find-files "bin" "\\.pyc$")) | |
503 | #t)))) | |
504 | (build-system python-build-system) | |
505 | (inputs | |
506 | `(("python2-pygame" ,python2-pygame) | |
507 | ("python2-pygtk" ,python2-pygtk))) | |
508 | (arguments | |
509 | `(#:tests? #f ;no test | |
510 | #:python ,python-2 | |
511 | #:phases | |
512 | (modify-phases %standard-phases | |
513 | (delete 'build) ;no setup.py | |
514 | (replace 'install | |
515 | (lambda* (#:key outputs #:allow-other-keys) | |
516 | (let* ((out (assoc-ref outputs "out")) | |
517 | (share (string-append out "/share")) | |
518 | (data (string-append share "/omnitux"))) | |
519 | ;; Install documentation. | |
520 | (let ((doc (string-append share "/doc/" ,name "-" ,version))) | |
521 | (for-each (lambda (f) (install-file f doc)) | |
522 | '("LICENSE.txt" "README.txt"))) | |
523 | ;; Install data. | |
524 | (install-file "omnitux.sh" data) | |
525 | (for-each (lambda (d) | |
526 | (copy-recursively d (string-append data "/" d))) | |
527 | '("bin" "data")) | |
528 | ;; Install the launcher. | |
529 | (let* ((bin (string-append out "/bin")) | |
530 | (script (string-append bin "/omnitux")) | |
531 | (bash (string-append (assoc-ref %build-inputs "bash") | |
532 | "/bin/bash")) | |
533 | (python (string-append (assoc-ref %build-inputs "python") | |
534 | "/bin/python2"))) | |
535 | (mkdir-p bin) | |
536 | (with-output-to-file script | |
537 | (lambda () | |
538 | (format #t "#!~a~%" bash) | |
539 | (format #t | |
540 | "cd ~a; ~a menu.py~%" | |
541 | (string-append data "/bin") | |
542 | python))) | |
543 | (chmod script #o755)) | |
544 | ;; Install icon and desktop file. | |
545 | (let ((pixmaps (string-append share "/pixmaps"))) | |
546 | (install-file "data/default/icons/Omnitux_logo.svg" pixmaps)) | |
547 | (let ((apps (string-append out "/share/applications"))) | |
548 | (mkdir-p apps) | |
549 | (with-output-to-file (string-append apps "/omnitux.desktop") | |
550 | (lambda _ | |
551 | (format #t | |
552 | "[Desktop Entry]~@ | |
553 | Name=Omnitux~@ | |
554 | GenericName=Omnitux | |
555 | Comment=An educational game based on multimedia elements.~@ | |
556 | Comment[fr]=Un jeu ludo-éducatif basé sur des éléments multimédias.~@ | |
557 | Exec=~a/bin/omnitux~@ | |
558 | Type=Application~@ | |
559 | Categories=Game;Education;~@ | |
560 | Terminal=false~@ | |
561 | Icon=Omnitux_logo.svg~@" | |
562 | out)))) | |
563 | #t)))))) | |
564 | (home-page "http://omnitux.sourceforge.net/") | |
565 | (synopsis "Educational activities based on multimedia elements") | |
566 | (description "The project aims to provide various educational | |
567 | activities around multimedia elements (images, sounds, texts). Types | |
568 | of activities include: | |
569 | @itemize | |
570 | @item associations, | |
571 | @item items to place on a map or a schema, | |
572 | @item counting activities, | |
573 | @item puzzles, | |
574 | @item card faces to remember, | |
575 | @item find differences between two pictures, | |
576 | @item ... | |
577 | @end itemize | |
578 | ||
579 | Activities are available in English, French, German, Polish, | |
580 | Portuguese, Spanish and Italian.") | |
581 | ;; Project's license is GPL3+, but multimedia elements are | |
582 | ;; released under various licenses. | |
583 | (license (list license:gpl3+ | |
584 | license:gpl2+ | |
585 | license:cc-by-sa2.0 | |
586 | license:cc-by-sa3.0 | |
587 | license:public-domain)))) | |
588 | ||
52e7295f NG |
589 | (define-public fet |
590 | (package | |
591 | (name "fet") | |
3e4cf41b NG |
592 | (version "5.42.3") |
593 | (source | |
594 | (origin | |
595 | (method url-fetch) | |
596 | (uri (string-append "https://www.lalescu.ro/liviu/fet/download/" | |
597 | "fet-" version ".tar.bz2")) | |
598 | (sha256 | |
599 | (base32 "0z31i8kwd59c3hlq35qll61qhc3x63w330ss92glhp12iy0aja1y")))) | |
52e7295f NG |
600 | (build-system gnu-build-system) |
601 | (arguments | |
602 | `(#:phases | |
603 | (modify-phases %standard-phases | |
604 | (add-after 'unpack 'fix-hardcoded-directories | |
605 | (lambda* (#:key outputs #:allow-other-keys) | |
606 | (substitute* (list "fet.pro" | |
607 | "src/src.pro" | |
608 | "src/src-cl.pro" | |
609 | "src/interface/fet.cpp") | |
610 | (("/usr") (assoc-ref outputs "out"))) | |
611 | #t)) | |
612 | (replace 'configure | |
613 | (lambda _ (invoke "qmake" "fet.pro")))))) | |
614 | (inputs | |
615 | `(("qtbase" ,qtbase))) | |
616 | (home-page "https://www.lalescu.ro/liviu/fet/") | |
617 | (synopsis "Timetabling software") | |
618 | (description "FET is a program for automatically scheduling the | |
619 | timetable of a school, high-school or university. It uses a fast and | |
620 | efficient timetabling algorithm. | |
621 | ||
622 | Usually, FET is able to solve a complicated timetable in maximum 5-20 | |
623 | minutes. For simpler timetables, it may take a shorter time, under | |
624 | 5 minutes (in some cases, a matter of seconds). For extremely | |
625 | difficult timetables, it may take a longer time, a matter of hours.") | |
626 | (license license:agpl3+))) | |
627 | ||
3f19b268 EF |
628 | (define-public klavaro |
629 | (package | |
630 | (name "klavaro") | |
631 | (version "3.09") | |
632 | (source | |
633 | (origin | |
634 | (method url-fetch) | |
635 | (uri (string-append "mirror://sourceforge/klavaro/klavaro-" | |
636 | version ".tar.bz2")) | |
637 | (sha256 | |
638 | (base32 | |
639 | "12gml7h45b1w9s318h0d5wxw92h7pgajn2kh57j0ak9saq0yb0wr")))) | |
640 | (build-system gnu-build-system) | |
641 | (native-inputs | |
642 | `(("intltool" ,intltool) | |
643 | ("pkg-config" ,pkg-config))) | |
644 | (inputs | |
645 | `(("cairo" ,cairo) | |
646 | ("curl" ,curl) | |
647 | ("gtk+" ,gtk+) | |
648 | ("pango" ,pango))) | |
649 | (home-page "https://klavaro.sourceforge.io/en/index.html") | |
650 | (synopsis "Touch typing tutor") | |
651 | (description | |
652 | "Klavaro is a simple tutor to teach correct typing, almost independently of | |
653 | language and very flexible regarding to new or unknown keyboard layouts.") | |
654 | (license license:gpl3+))) | |
d2c0a7a2 EF |
655 | |
656 | (define-public ktouch | |
657 | (package | |
658 | (name "ktouch") | |
15ffff8b | 659 | (version "19.08.3") |
d2c0a7a2 EF |
660 | (source |
661 | (origin | |
662 | (method url-fetch) | |
663 | (uri (string-append "mirror://kde/stable/applications/" | |
664 | version "/src/ktouch-" version ".tar.xz")) | |
665 | (sha256 | |
666 | (base32 | |
15ffff8b | 667 | "0dqxb3xsjc2rwc9779l5fnr4crhq51bc8ln4azbgnnkzldvq6a4a")))) |
7d796d80 | 668 | (build-system qt-build-system) |
d2c0a7a2 | 669 | (arguments |
7d796d80 | 670 | `(#:phases |
50bdf004 | 671 | (modify-phases %standard-phases |
d2c0a7a2 EF |
672 | (add-after 'configure 'patch-makefiles |
673 | (lambda* (#:key inputs #:allow-other-keys) | |
674 | (let ((qtdec (assoc-ref inputs "qtdeclarative"))) | |
675 | (substitute* '("src/CMakeFiles/ktouch_autogen.dir/build.make" | |
676 | "src/CMakeFiles/ktouch.dir/build.make") | |
677 | (("/gnu/store/.*qmlcachegen") | |
678 | (string-append qtdec "/bin/qmlcachegen")))) | |
d2c0a7a2 EF |
679 | #t))))) |
680 | (native-inputs | |
681 | `(("extra-cmake-modules" ,extra-cmake-modules) | |
682 | ("kdoctools" ,kdoctools) | |
683 | ("pkg-config" ,pkg-config))) | |
684 | (inputs | |
685 | `(("kcmutils" ,kcmutils) | |
686 | ("kcompletion" ,kcompletion) | |
687 | ("kconfig" ,kconfig) | |
688 | ("kconfigwidgets" ,kconfigwidgets) | |
689 | ("kcoreaddons" ,kcoreaddons) | |
690 | ("kdeclarative" ,kdeclarative) | |
691 | ("ki18n" ,ki18n) | |
692 | ("kiconthemes" ,kiconthemes) | |
693 | ("kitemviews" ,kitemviews) | |
694 | ("kqtquickcharts" ,kqtquickcharts) | |
695 | ("ktextwidgets" ,ktextwidgets) | |
696 | ("kwidgetsaddons" ,kwidgetsaddons) | |
697 | ("kwindowsystem" ,kwindowsystem) | |
698 | ("kxmlgui" ,kxmlgui) | |
699 | ("libxcb" ,libxcb) | |
700 | ("libxkbfile" ,libxkbfile) | |
701 | ("qtbase" ,qtbase) | |
702 | ("qtdeclarative" ,qtdeclarative) | |
703 | ("qtgraphicaleffects" ,qtgraphicaleffects) | |
704 | ("qtquickcontrols2" ,qtquickcontrols2) | |
705 | ("qtx11extras" ,qtx11extras) | |
706 | ("qtxmlpatterns" ,qtxmlpatterns))) | |
707 | (home-page "https://edu.kde.org/ktouch/") | |
708 | (synopsis "Touch typing tutor") | |
709 | (description | |
710 | "KTouch is an aid for learning how to type with speed and accuracy. It | |
711 | provides a sample text to type and indicates which fingers should be used for | |
712 | each key. A collection of lessons are included for a wide range of different | |
713 | languages and keyboard layouts, and typing statistics are used to dynamically | |
714 | adjust the level of difficulty.") | |
715 | (license license:gpl2))) |