* [bug#56806] [PATCH 1/9] gnu: Add ocaml-luv.
2022-07-28 4:06 [bug#56806] [PATCH 0/9] Add the Haxe language and tools John Kehayias via Guix-patches via
@ 2022-07-28 4:08 ` John Kehayias via Guix-patches via
2022-07-28 4:09 ` [bug#56806] [PATCH 2/9] gnu: Add ocaml-ptmap John Kehayias via Guix-patches via
` (8 subsequent siblings)
9 siblings, 0 replies; 12+ messages in thread
From: John Kehayias via Guix-patches via @ 2022-07-28 4:08 UTC (permalink / raw)
To: 56806@debbugs.gnu.org
[-- Attachment #1: Type: text/plain, Size: 13 bytes --]
Empty Message
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: 0001-gnu-Add-ocaml-luv.patch --]
[-- Type: text/x-patch; name=0001-gnu-Add-ocaml-luv.patch, Size: 2889 bytes --]
From d96390019a22b1b01b5845f971e46523a42848e5 Mon Sep 17 00:00:00 2001
From: John Kehayias <john.kehayias@protonmail.com>
Date: Wed, 27 Jul 2022 23:31:26 -0400
Subject: [PATCH 1/9] gnu: Add ocaml-luv.
* gnu/packages/ocaml.scm (ocaml-luv): New variable.
---
gnu/packages/ocaml.scm | 43 ++++++++++++++++++++++++++++++++++++++++++
1 file changed, 43 insertions(+)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index ff24861eb0..895b99320e 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -25,6 +25,7 @@
;;; Copyright © 2021 Maxime Devos <maximedevos@telenet.be>
;;; Copyright © 2021 Sarah Morgensen <iskarian@mgsn.dev>
;;; Copyright © 2022 Maxim Cournoyer <maxim.cournoyer@gmail.com>
+;;; Copyright © 2022 John Kehayias <john.kehayias@protonmail.com>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -2624,6 +2625,48 @@ (define-public ocaml-lwt
locks or other synchronization primitives.")
(license license:lgpl2.1)))
+(define-public ocaml-luv
+ (package
+ (name "ocaml-luv")
+ (version "0.5.11")
+ (source (origin
+ (method url-fetch)
+ (uri (string-append "https://github.com/aantron/luv/releases/download/"
+ version "/luv-" version ".tar.gz"))
+ (sha256
+ (base32
+ "0hrsi8n2l31bcwgj847df4chjgqb9lmwkaky8fvvi15k25rz9v6c"))
+ (modules '((guix build utils)))
+ (snippet
+ '(begin
+ ;; Remove bundled configure and libuv.
+ (delete-file-recursively "src/c/vendor")
+ #t))))
+ (build-system dune-build-system)
+ (arguments
+ (list #:phases
+ #~(modify-phases %standard-phases
+ (add-before 'build 'use-system-libuv
+ (lambda _
+ (setenv "LUV_USE_SYSTEM_LIBUV" "yes")))
+ (replace 'check
+ (lambda* (#:key tests? #:allow-other-keys)
+ (when tests?
+ (invoke "dune" "runtest" "--no-buffer" "--force")))))))
+ (inputs (list libuv))
+ (propagated-inputs (list ocaml-ctypes ocaml-result ocaml-odoc))
+ (native-inputs (list ocaml-base ocaml-alcotest))
+ (home-page "https://github.com/aantron/luv")
+ (synopsis "Binding to libuv: cross-platform asynchronous I/O")
+ (description
+ "Luv is a binding to libuv, the cross-platform C library that does
+asynchronous I/O in Node.js and runs its main loop. Besides asynchronous I/O,
+libuv also supports multiprocessing and multithreading. Multiple event loops
+can be run in different threads. libuv also exposes a lot of other
+functionality, amounting to a full OS API, and an alternative to the standard
+module Unix.")
+ (license license:expat)))
+
(define-public ocaml-lwt-react
(package
(inherit ocaml-lwt)
--
2.37.1
^ permalink raw reply related [flat|nested] 12+ messages in thread
* [bug#56806] [PATCH 2/9] gnu: Add ocaml-ptmap.
2022-07-28 4:06 [bug#56806] [PATCH 0/9] Add the Haxe language and tools John Kehayias via Guix-patches via
2022-07-28 4:08 ` [bug#56806] [PATCH 1/9] gnu: Add ocaml-luv John Kehayias via Guix-patches via
@ 2022-07-28 4:09 ` John Kehayias via Guix-patches via
2022-07-28 4:09 ` [bug#56806] [PATCH 3/9] gnu: Add ocaml-sha John Kehayias via Guix-patches via
` (7 subsequent siblings)
9 siblings, 0 replies; 12+ messages in thread
From: John Kehayias via Guix-patches via @ 2022-07-28 4:09 UTC (permalink / raw)
To: 56806@debbugs.gnu.org
[-- Attachment #1: Type: text/plain, Size: 13 bytes --]
Empty Message
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: 0002-gnu-Add-ocaml-ptmap.patch --]
[-- Type: text/x-patch; name=0002-gnu-Add-ocaml-ptmap.patch, Size: 1810 bytes --]
From 8f67088861460984d5ed1147c58d66d0658528be Mon Sep 17 00:00:00 2001
From: John Kehayias <john.kehayias@protonmail.com>
Date: Wed, 27 Jul 2022 23:31:45 -0400
Subject: [PATCH 2/9] gnu: Add ocaml-ptmap.
* gnu/packages/ocaml.scm (ocaml-ptmap): New variable.
---
gnu/packages/ocaml.scm | 28 ++++++++++++++++++++++++++++
1 file changed, 28 insertions(+)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index 895b99320e..da7086ab2b 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -4407,6 +4407,34 @@ (define-public ocaml4.07-utop
("ocaml-zed" ,ocaml-zed)))
(properties '()))))
+(define-public ocaml-ptmap
+ (package
+ (name "ocaml-ptmap")
+ (version "2.0.5")
+ (source (origin
+ (method url-fetch)
+ (uri
+ (string-append "https://github.com/backtracking/ptmap/releases/download/"
+ version "/ptmap-" version ".tbz"))
+ (sha256
+ (base32
+ "1apk61fc1y1g7x3m3c91fnskvxp6i0vk5nxwvipj56k7x2pzilgb"))))
+ (build-system dune-build-system)
+ (arguments
+ (list #:phases
+ #~(modify-phases %standard-phases
+ (replace 'check
+ (lambda* (#:key tests? #:allow-other-keys)
+ (when tests?
+ (invoke "dune" "runtest")))))))
+ (propagated-inputs (list ocaml-stdlib-shims ocaml-seq))
+ (home-page "https://github.com/backtracking/ptmap")
+ (synopsis "Maps of integers implemented as Patricia trees")
+ (description
+ "An implementation inspired by Okasaki & Gill's paper 'Fast Mergeable
+Integer Maps.'")
+ (license license:lgpl2.1))) ; with linking exception
+
(define-public ocaml-integers
(package
(name "ocaml-integers")
--
2.37.1
^ permalink raw reply related [flat|nested] 12+ messages in thread
* [bug#56806] [PATCH 3/9] gnu: Add ocaml-sha.
2022-07-28 4:06 [bug#56806] [PATCH 0/9] Add the Haxe language and tools John Kehayias via Guix-patches via
2022-07-28 4:08 ` [bug#56806] [PATCH 1/9] gnu: Add ocaml-luv John Kehayias via Guix-patches via
2022-07-28 4:09 ` [bug#56806] [PATCH 2/9] gnu: Add ocaml-ptmap John Kehayias via Guix-patches via
@ 2022-07-28 4:09 ` John Kehayias via Guix-patches via
2022-07-28 4:10 ` [bug#56806] [PATCH 4/9] gnu: Add ocaml-xml-light John Kehayias via Guix-patches via
` (6 subsequent siblings)
9 siblings, 0 replies; 12+ messages in thread
From: John Kehayias via Guix-patches via @ 2022-07-28 4:09 UTC (permalink / raw)
To: 56806@debbugs.gnu.org
[-- Attachment #1: Type: text/plain, Size: 13 bytes --]
Empty Message
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: 0003-gnu-Add-ocaml-sha.patch --]
[-- Type: text/x-patch; name=0003-gnu-Add-ocaml-sha.patch, Size: 1698 bytes --]
From 268e976b4410be89e8e655704732e42a74f6a654 Mon Sep 17 00:00:00 2001
From: John Kehayias <john.kehayias@protonmail.com>
Date: Wed, 27 Jul 2022 23:31:57 -0400
Subject: [PATCH 3/9] gnu: Add ocaml-sha.
* gnu/packages/ocaml.scm (ocaml-sha): New variable.
---
gnu/packages/ocaml.scm | 22 ++++++++++++++++++++++
1 file changed, 22 insertions(+)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index da7086ab2b..8620d2bde3 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -5930,6 +5930,28 @@ (define-public ocaml-octavius
(description "Octavius is a library to parse the `ocamldoc` comment syntax.")
(license license:isc)))
+(define-public ocaml-sha
+ (package
+ (name "ocaml-sha")
+ (version "1.15.2")
+ (source (origin
+ (method url-fetch)
+ (uri (string-append "https://github.com/djs55/ocaml-sha/releases/download/"
+ version "/sha-" version ".tbz"))
+ (sha256
+ (base32
+ "1dzzhchknnbrpp5s81iqbvmqp4s0l75yrq8snj70ch3wkarmgg9z"))))
+ (build-system dune-build-system)
+ (propagated-inputs (list ocaml-stdlib-shims ocaml-odoc))
+ (native-inputs (list ocaml-ounit2))
+ (home-page "https://github.com/djs55/ocaml-sha")
+ (synopsis "OCaml binding to the SHA cryptographic functions")
+ (description
+ "This is the binding for SHA interface code in OCaml, offering the same
+interface as the MD5 digest included in the OCaml standard library. It
+currently provides SHA1, SHA256 and SHA512 hash functions.")
+ (license license:isc)))
+
(define-public ocaml-ppx-hash
(package
(name "ocaml-ppx-hash")
--
2.37.1
^ permalink raw reply related [flat|nested] 12+ messages in thread
* [bug#56806] [PATCH 4/9] gnu: Add ocaml-xml-light.
2022-07-28 4:06 [bug#56806] [PATCH 0/9] Add the Haxe language and tools John Kehayias via Guix-patches via
` (2 preceding siblings ...)
2022-07-28 4:09 ` [bug#56806] [PATCH 3/9] gnu: Add ocaml-sha John Kehayias via Guix-patches via
@ 2022-07-28 4:10 ` John Kehayias via Guix-patches via
2022-07-28 4:10 ` [bug#56806] [PATCH 5/9] gnu: Add mikktspace John Kehayias via Guix-patches via
` (5 subsequent siblings)
9 siblings, 0 replies; 12+ messages in thread
From: John Kehayias via Guix-patches via @ 2022-07-28 4:10 UTC (permalink / raw)
To: 56806@debbugs.gnu.org
[-- Attachment #1: Type: text/plain, Size: 13 bytes --]
Empty Message
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: 0004-gnu-Add-ocaml-xml-light.patch --]
[-- Type: text/x-patch; name=0004-gnu-Add-ocaml-xml-light.patch, Size: 2425 bytes --]
From 2733ca5c0a423155a9db5f6dfbda678463f39647 Mon Sep 17 00:00:00 2001
From: John Kehayias <john.kehayias@protonmail.com>
Date: Wed, 27 Jul 2022 23:32:04 -0400
Subject: [PATCH 4/9] gnu: Add ocaml-xml-light.
* gnu/packages/ocaml.scm (ocaml-xml-light): New variable.
---
gnu/packages/ocaml.scm | 39 +++++++++++++++++++++++++++++++++++++++
1 file changed, 39 insertions(+)
diff --git a/gnu/packages/ocaml.scm b/gnu/packages/ocaml.scm
index 8620d2bde3..3df81e498b 100644
--- a/gnu/packages/ocaml.scm
+++ b/gnu/packages/ocaml.scm
@@ -2812,6 +2812,45 @@ (define-public ocaml-bos
run command line programs.")
(license license:isc)))
+(define-public ocaml-xml-light
+ (package
+ (name "ocaml-xml-light")
+ (version "2.4")
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/ncannasse/xml-light")
+ (commit version)))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "089ywjz84y4p5iln94y54vh03b5fm2zrl2dld1398dyrby96dp6s"))))
+ (build-system ocaml-build-system)
+ (arguments
+ (list #:tests? #f ; There are no tests.
+ #:phases
+ #~(modify-phases %standard-phases
+ (add-after 'unpack 'prefix
+ (lambda _
+ (substitute* "Makefile"
+ (("`\\$\\(OCAMLC\\) -where`")
+ (string-append #$output "/lib/ocaml/site-lib/xml-light")))))
+ (delete 'configure) ; no configure
+ (add-before 'install 'mkdir
+ (lambda _
+ (mkdir-p (string-append #$output "/lib/ocaml/site-lib/xml-light"))))
+ (replace 'install
+ (lambda _
+ (invoke "make" "install_ocamlfind"))))))
+ (home-page "https://github.com/ncannasse/xml-light")
+ (synopsis "Xml-Light is a minimal XML parser & printer for OCaml")
+ (description
+ "Xml-Light provides functions to parse an XML document into an OCaml data
+structure, work with it, and print it back to an XML document. It also
+supports DTD parsing and checking, and is entirely written in OCaml, hence it
+does not require additional C libraries.")
+ (license license:lgpl2.1+))) ; with linking exception
+
(define-public ocaml-xmlm
(package
(name "ocaml-xmlm")
--
2.37.1
^ permalink raw reply related [flat|nested] 12+ messages in thread
* [bug#56806] [PATCH 5/9] gnu: Add mikktspace.
2022-07-28 4:06 [bug#56806] [PATCH 0/9] Add the Haxe language and tools John Kehayias via Guix-patches via
` (3 preceding siblings ...)
2022-07-28 4:10 ` [bug#56806] [PATCH 4/9] gnu: Add ocaml-xml-light John Kehayias via Guix-patches via
@ 2022-07-28 4:10 ` John Kehayias via Guix-patches via
2022-07-28 4:10 ` [bug#56806] [PATCH 6/9] gnu: Add minimp3 John Kehayias via Guix-patches via
` (4 subsequent siblings)
9 siblings, 0 replies; 12+ messages in thread
From: John Kehayias via Guix-patches via @ 2022-07-28 4:10 UTC (permalink / raw)
To: 56806@debbugs.gnu.org
[-- Attachment #1: Type: text/plain, Size: 13 bytes --]
Empty Message
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: 0005-gnu-Add-mikktspace.patch --]
[-- Type: text/x-patch; name=0005-gnu-Add-mikktspace.patch, Size: 2442 bytes --]
From 441a3faaa94688ff01313644d7ee0bd83cf067e9 Mon Sep 17 00:00:00 2001
From: John Kehayias <john.kehayias@protonmail.com>
Date: Wed, 27 Jul 2022 23:32:42 -0400
Subject: [PATCH 5/9] gnu: Add mikktspace.
* gnu/packages/graphics.scm (mikktspace): New variable.
---
gnu/packages/graphics.scm | 39 +++++++++++++++++++++++++++++++++++++++
1 file changed, 39 insertions(+)
diff --git a/gnu/packages/graphics.scm b/gnu/packages/graphics.scm
index c193be1efb..1acec5ea76 100644
--- a/gnu/packages/graphics.scm
+++ b/gnu/packages/graphics.scm
@@ -584,6 +584,45 @@ (define-public assimp
more.")
(license license:bsd-3)))
+(define-public mikktspace
+ ;; The latest commit is used as there is no release.
+ (let ((commit "3e895b49d05ea07e4c2133156cfa94369e19e409")
+ (revision "0"))
+ (package
+ (name "mikktspace")
+ (version (git-version "0.0.0" revision commit))
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/mmikk/MikkTSpace")
+ (commit commit)))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "1rjh9zflx51hdhnfadal87v4hhkrbprkv692hjkg9wkxx0ch39zi"))))
+ (build-system gnu-build-system)
+ (arguments
+ (list #:tests? #f
+ #:phases
+ #~(modify-phases %standard-phases
+ (delete 'configure)
+ (replace 'build
+ (lambda* (#:key make-flags parallel-build? #:allow-other-keys)
+ (invoke #$(cc-for-target) "mikktspace.c" "-O2" "-g" "-fPIC"
+ "-shared" "-o" "libmikktspace.so")))
+ (replace 'install
+ (lambda _
+ (install-file "mikktspace.h"
+ (string-append #$output "/include"))
+ (install-file "libmikktspace.so"
+ (string-append #$output "/lib")))))))
+ (home-page "http://www.mikktspace.com/")
+ (synopsis "Library for a common standard for tangent spaces")
+ (description
+ "This package provides a common standard tangent space library used in
+baking tools to produce normal maps.")
+ (license license:zlib))))
+
(define-public openshadinglanguage
(package
(name "openshadinglanguage")
--
2.37.1
^ permalink raw reply related [flat|nested] 12+ messages in thread
* [bug#56806] [PATCH 6/9] gnu: Add minimp3.
2022-07-28 4:06 [bug#56806] [PATCH 0/9] Add the Haxe language and tools John Kehayias via Guix-patches via
` (4 preceding siblings ...)
2022-07-28 4:10 ` [bug#56806] [PATCH 5/9] gnu: Add mikktspace John Kehayias via Guix-patches via
@ 2022-07-28 4:10 ` John Kehayias via Guix-patches via
2022-07-28 4:10 ` [bug#56806] [PATCH 7/9] gnu: Add neko John Kehayias via Guix-patches via
` (3 subsequent siblings)
9 siblings, 0 replies; 12+ messages in thread
From: John Kehayias via Guix-patches via @ 2022-07-28 4:10 UTC (permalink / raw)
To: 56806@debbugs.gnu.org
[-- Attachment #1: Type: text/plain, Size: 13 bytes --]
Empty Message
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: 0006-gnu-Add-minimp3.patch --]
[-- Type: text/x-patch; name=0006-gnu-Add-minimp3.patch, Size: 2544 bytes --]
From 5b653ede7baa7afdf2a6ea226fbf4b130af61d0b Mon Sep 17 00:00:00 2001
From: John Kehayias <john.kehayias@protonmail.com>
Date: Wed, 27 Jul 2022 23:32:54 -0400
Subject: [PATCH 6/9] gnu: Add minimp3.
* gnu/packages/mp3.scm (minimp3): New variable.
---
gnu/packages/mp3.scm | 31 +++++++++++++++++++++++++++++++
1 file changed, 31 insertions(+)
diff --git a/gnu/packages/mp3.scm b/gnu/packages/mp3.scm
index 4a8bdad711..275468d343 100644
--- a/gnu/packages/mp3.scm
+++ b/gnu/packages/mp3.scm
@@ -10,6 +10,7 @@
;;; Copyright © 2020 Michael Rohleder <mike@rohleder.de>
;;; Copyright © 2021 Simon Streit <simon@netpanic.org>
;;; Copyright © 2021 Guillaume Le Vaillant <glv@posteo.net>
+;;; Copyright © 2022 John Kehayias <john.kehayias@protonmail.com>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -54,6 +55,7 @@ (define-module (gnu packages mp3)
#:use-module (guix download)
#:use-module (guix git-download)
#:use-module (guix utils)
+ #:use-module (guix build-system copy)
#:use-module (guix build-system gnu)
#:use-module (guix build-system python)
#:use-module (guix build-system cmake))
@@ -247,6 +249,35 @@ (define-public taglib
;; Dual-licensed: user may choose between LGPLv2.1 or MPLv1.1.
(license (list license:lgpl2.1 license:mpl1.1))))
+(define-public minimp3
+ ;; The latest commit is used as there is no release.
+ (let ((commit "afb604c06bc8beb145fecd42c0ceb5bda8795144")
+ (revision "0"))
+ (package
+ (name "minimp3")
+ (version (git-version "0.0.0" revision commit))
+ (source (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/lieff/minimp3")
+ (commit commit)))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32
+ "0brgrbij8swhp7lac21xnnrr5l0371lkr5vz6h9x0dbz1qq2xhsj"))))
+ ;; TODO: minimp3 has many more files for at least tests with scripts to
+ ;; run them, although it is unclear how to easily package them.
+ (build-system copy-build-system)
+ (arguments
+ '(#:install-plan
+ '(("minimp3.h" "include/")
+ ("minimp3_ex.h" "include/"))))
+ (home-page "https://github.com/lieff/minimp3")
+ (synopsis "Minimalistic MP3 decoder header library")
+ (description
+ "Minimp3 is a header-only MP3 decoder library.")
+ (license license:cc0))))
+
(define-public mp3info
(package
(name "mp3info")
--
2.37.1
^ permalink raw reply related [flat|nested] 12+ messages in thread
* [bug#56806] [PATCH 7/9] gnu: Add neko.
2022-07-28 4:06 [bug#56806] [PATCH 0/9] Add the Haxe language and tools John Kehayias via Guix-patches via
` (5 preceding siblings ...)
2022-07-28 4:10 ` [bug#56806] [PATCH 6/9] gnu: Add minimp3 John Kehayias via Guix-patches via
@ 2022-07-28 4:10 ` John Kehayias via Guix-patches via
2022-07-28 4:11 ` [bug#56806] [PATCH 8/9] gnu: Add haxe John Kehayias via Guix-patches via
` (2 subsequent siblings)
9 siblings, 0 replies; 12+ messages in thread
From: John Kehayias via Guix-patches via @ 2022-07-28 4:10 UTC (permalink / raw)
To: 56806@debbugs.gnu.org
[-- Attachment #1: Type: text/plain, Size: 13 bytes --]
Empty Message
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: 0007-gnu-Add-neko.patch --]
[-- Type: text/x-patch; name=0007-gnu-Add-neko.patch, Size: 5701 bytes --]
From 1d5b7fc835c4bb4953597eee1c96c5ecf366f48c Mon Sep 17 00:00:00 2001
From: John Kehayias <john.kehayias@protonmail.com>
Date: Wed, 27 Jul 2022 23:34:42 -0400
Subject: [PATCH 7/9] gnu: Add neko.
* gnu/packages/haxe.scm: New module.
(neko): New variable.
* gnu/local.mk (GNU_SYSTEM_MODULES): Add new module.
---
gnu/local.mk | 2 +
gnu/packages/haxe.scm | 107 ++++++++++++++++++++++++++++++++++++++++++
2 files changed, 109 insertions(+)
create mode 100644 gnu/packages/haxe.scm
diff --git a/gnu/local.mk b/gnu/local.mk
index 0c4edf6e56..c837b2520a 100644
--- a/gnu/local.mk
+++ b/gnu/local.mk
@@ -50,6 +50,7 @@
# Copyright © 2022 Daniel Meißner <daniel.meissner-i4k@ruhr-uni-bochum.de>
# Copyright © 2022 Remco van 't Veer <remco@remworks.net>
# Copyright © 2022 Artyom V. Poptsov <poptsov.artyom@gmail.com>
+# Copyright © 2022 John Kehayias <john.kehayias@protonmail.com>
#
# This file is part of GNU Guix.
#
@@ -301,6 +302,7 @@ GNU_SYSTEM_MODULES = \
%D%/packages/haskell-crypto.scm \
%D%/packages/haskell-web.scm \
%D%/packages/haskell-xyz.scm \
+ %D%/packages/haxe.scm \
%D%/packages/heads.scm \
%D%/packages/hexedit.scm \
%D%/packages/hugs.scm \
diff --git a/gnu/packages/haxe.scm b/gnu/packages/haxe.scm
new file mode 100644
index 0000000000..6d8d9caca1
--- /dev/null
+++ b/gnu/packages/haxe.scm
@@ -0,0 +1,107 @@
+;;; GNU Guix --- Functional package management for GNU
+;;; Copyright © 2022 John Kehayias <john.kehayias@protonmail.com>
+;;;
+;;; This file is part of GNU Guix.
+;;;
+;;; GNU Guix is free software; you can redistribute it and/or modify it
+;;; under the terms of the GNU General Public License as published by
+;;; the Free Software Foundation; either version 3 of the License, or (at
+;;; your option) any later version.
+;;;
+;;; GNU Guix is distributed in the hope that it will be useful, but
+;;; WITHOUT ANY WARRANTY; without even the implied warranty of
+;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+;;; GNU General Public License for more details.
+;;;
+;;; You should have received a copy of the GNU General Public License
+;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
+
+(define-module (gnu packages haxe)
+ #:use-module (gnu packages)
+ #:use-module (gnu packages apr)
+ #:use-module (gnu packages audio)
+ #:use-module (gnu packages bdw-gc)
+ #:use-module (gnu packages compression)
+ #:use-module (gnu packages databases)
+ #:use-module (gnu packages gl)
+ #:use-module (gnu packages graphics)
+ #:use-module (gnu packages gtk)
+ #:use-module (gnu packages image)
+ #:use-module (gnu packages libevent)
+ #:use-module (gnu packages mp3)
+ #:use-module (gnu packages ocaml)
+ #:use-module (gnu packages pcre)
+ #:use-module (gnu packages perl)
+ #:use-module (gnu packages pkg-config)
+ #:use-module (gnu packages sdl)
+ #:use-module (gnu packages sqlite)
+ #:use-module (gnu packages tls)
+ #:use-module (gnu packages version-control)
+ #:use-module (gnu packages web)
+ #:use-module (gnu packages xiph)
+ #:use-module (guix build-system cmake)
+ #:use-module (guix build-system gnu)
+ #:use-module (guix build-system dune)
+ #:use-module (guix download)
+ #:use-module (guix gexp)
+ #:use-module (guix git-download)
+ #:use-module ((guix licenses) #:prefix license:)
+ #:use-module (guix packages)
+ #:use-module (guix utils))
+
+(define-public neko
+ (package
+ (name "neko")
+ (version "2.3.0")
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/HaxeFoundation/neko")
+ (commit (string-append
+ "v"
+ (string-map (lambda (x) (if (char=? x #\.) #\- x)) version)))))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32 "1xgw646pghsjjbzd8qlaq17vq96swlrazpivrvyrhdj36vb3sci3"))))
+ (build-system cmake-build-system)
+ (arguments
+ (list #:phases
+ #~(modify-phases %standard-phases
+ (add-after 'unpack 'prefix
+ (lambda _
+ (substitute* "CMakeLists.txt"
+ (("\\\\\\$ORIGIN")
+ (string-append #$output "/lib"))))))))
+ (inputs (list apr
+ apr-util
+ gtk+-2
+ httpd
+ libgc
+ mbedtls-apache
+ mysql
+ openssl
+ pcre
+ sqlite
+ zlib))
+ (native-inputs (list git pkg-config)) ; git for source_archive and applying patch
+ (home-page "https://nekovm.org/")
+ (synopsis "High-level dynamically typed programming language and virtual
+machine")
+ (description
+ "The Neko programming language is a high-level dynamically typed
+programming language. It can be used as an embedded scripting language. It
+has been designed to provide a common runtime for several different languages.
+You can easily extend the language with C libraries. You can also write
+generators from your own language to Neko and then use the Neko Runtime to
+compile, run, and access existing libraries.
+
+Neko has a compiler and a virtual machine. The Virtual Machine is both very
+lightweight and well optimized, so it can run very quickly. The VM can be
+easily embedded into any application and your libraries can be accessed using
+the C foreign function interface.
+
+You can use the compiler as standalone command line executable separate from
+the VM, or as a Neko library to perform compile-and-run funtions for
+interactive languages.")
+ (license license:expat)))
--
2.37.1
^ permalink raw reply related [flat|nested] 12+ messages in thread
* [bug#56806] [PATCH 8/9] gnu: Add haxe.
2022-07-28 4:06 [bug#56806] [PATCH 0/9] Add the Haxe language and tools John Kehayias via Guix-patches via
` (6 preceding siblings ...)
2022-07-28 4:10 ` [bug#56806] [PATCH 7/9] gnu: Add neko John Kehayias via Guix-patches via
@ 2022-07-28 4:11 ` John Kehayias via Guix-patches via
2022-07-28 4:11 ` [bug#56806] [PATCH 9/9] gnu: Add hashlink John Kehayias via Guix-patches via
2022-08-03 6:53 ` bug#56806: [PATCH 0/9] Add the Haxe language and tools 宋文武 via Guix-patches via
9 siblings, 0 replies; 12+ messages in thread
From: John Kehayias via Guix-patches via @ 2022-07-28 4:11 UTC (permalink / raw)
To: 56806@debbugs.gnu.org
[-- Attachment #1: Type: text/plain, Size: 13 bytes --]
Empty Message
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: 0008-gnu-Add-haxe.patch --]
[-- Type: text/x-patch; name=0008-gnu-Add-haxe.patch, Size: 4182 bytes --]
From 0f26e1d05ffa9c108e026cc68dfeef25ec76a239 Mon Sep 17 00:00:00 2001
From: John Kehayias <john.kehayias@protonmail.com>
Date: Wed, 27 Jul 2022 23:43:32 -0400
Subject: [PATCH 8/9] gnu: Add haxe.
* gnu/packages/haxe.scm (haxelib-src): New variable.
(haxe): New variable.
---
| 84 +++++++++++++++++++++++++++++++++++++++++++
1 file changed, 84 insertions(+)
--git a/gnu/packages/haxe.scm b/gnu/packages/haxe.scm
index 6d8d9caca1..95de4c5e4b 100644
--- a/gnu/packages/haxe.scm
+++ b/gnu/packages/haxe.scm
@@ -105,3 +105,87 @@ (define-public neko
the VM, or as a Neko library to perform compile-and-run funtions for
interactive languages.")
(license license:expat)))
+
+(define haxelib-src
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/HaxeFoundation/haxelib")
+ ;; This should match the haxelib submodule in haxe.
+ (commit "4b27f91d8a4ff279d9903091680fee2c93a0d574")
+ ;; This repo includes some Haxe libs as well.
+ (recursive? #t)))
+ (sha256
+ (base32
+ "0mwrm6gxgclwziiprfiswmjbz6z3dnvdwl8gq3gaym18pvx4p3ny"))))
+
+(define-public haxe
+ (package
+ (name "haxe")
+ (version "4.2.5")
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/HaxeFoundation/haxe")
+ (commit version)))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32 "0pl8vpyb7gl2yqjg85yc4zxq9c3ipvw4yrrpliaxs25ynrj3l51n"))))
+ (build-system dune-build-system)
+ (arguments
+ (list #:phases
+ #~(modify-phases %standard-phases
+ ;; Needs the haxelib sources for haxelib client
+ (add-after 'unpack 'copy-haxelib-src
+ (lambda _
+ (copy-recursively #$haxelib-src
+ "extra/haxelib_src")))
+ ;; Change the default directory for the haxelib package
+ ;; manager to be something writeable for a user.
+ (add-after 'copy-haxelib-src 'change-default-dir
+ (lambda _
+ (substitute* "extra/haxelib_src/src/haxelib/client/Main.hx"
+ (("'/usr/lib/haxe/\\$REPNAME'")
+ "Path.addTrailingSlash( getHomePath() ) + '.haxe/$REPNAME'"))))
+ (add-after 'unpack 'prefix
+ (lambda _
+ (substitute* "Makefile"
+ (("/usr/local")
+ (string-append #$output)))))
+ ;; Haxe uses a straight forward make, dune runtest, and make
+ ;; install process.
+ (replace 'build
+ (lambda* (#:key make-flags parallel-build? #:allow-other-keys)
+ (invoke "make" "-j" (if parallel-build?
+ (number->string (parallel-job-count))
+ "1"))))
+ (replace 'check
+ (lambda* (#:key tests? #:allow-other-keys)
+ (when tests?
+ (invoke "dune" "runtest"))))
+ (replace 'install
+ (lambda _
+ (invoke "make" "install"))))))
+ (inputs (list libuv
+ mbedtls-apache
+ neko
+ ocaml-extlib
+ ocaml-luv
+ ocaml-ptmap
+ ocaml-sedlex
+ ocaml-sha
+ ocaml-xml-light
+ pcre
+ zlib))
+ (native-inputs (list ocaml-findlib camlp5))
+ (home-page "https://haxe.org/")
+ (synopsis "Multi-target universal programming language")
+ (description
+ "Haxe is a toolkit based on a modern, high level, static-typed
+programming language, a cross-compiler, a complete cross-platform standard
+library and ways to access each platform's native capabilities. This package
+includes the compiler and library manager.")
+ (license (list license:gpl2+ ; the compiler itself
+ license:expat)))) ; the standard library
+
--
2.37.1
^ permalink raw reply related [flat|nested] 12+ messages in thread
* [bug#56806] [PATCH 9/9] gnu: Add hashlink.
2022-07-28 4:06 [bug#56806] [PATCH 0/9] Add the Haxe language and tools John Kehayias via Guix-patches via
` (7 preceding siblings ...)
2022-07-28 4:11 ` [bug#56806] [PATCH 8/9] gnu: Add haxe John Kehayias via Guix-patches via
@ 2022-07-28 4:11 ` John Kehayias via Guix-patches via
2022-08-03 6:53 ` bug#56806: [PATCH 0/9] Add the Haxe language and tools 宋文武 via Guix-patches via
9 siblings, 0 replies; 12+ messages in thread
From: John Kehayias via Guix-patches via @ 2022-07-28 4:11 UTC (permalink / raw)
To: 56806@debbugs.gnu.org
[-- Attachment #1: Type: text/plain, Size: 13 bytes --]
Empty Message
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: 0009-gnu-Add-hashlink.patch --]
[-- Type: text/x-patch; name=0009-gnu-Add-hashlink.patch, Size: 4758 bytes --]
From fa69682cc2051d5058322228cc45e6e5a3ecfc55 Mon Sep 17 00:00:00 2001
From: John Kehayias <john.kehayias@protonmail.com>
Date: Wed, 27 Jul 2022 23:45:22 -0400
Subject: [PATCH 9/9] gnu: Add hashlink.
* gnu/packages/haxe.scm (hashlink): New variable.
---
gnu/packages/haxe.scm | 93 +++++++++++++++++++++++++++++++++++++++++++
1 file changed, 93 insertions(+)
diff --git a/gnu/packages/haxe.scm b/gnu/packages/haxe.scm
index 95de4c5e4b..6876dbdc6f 100644
--- a/gnu/packages/haxe.scm
+++ b/gnu/packages/haxe.scm
@@ -189,3 +189,96 @@ (define-public haxe
(license (list license:gpl2+ ; the compiler itself
license:expat)))) ; the standard library
+(define-public hashlink
+ (package
+ (name "hashlink")
+ (version "1.12")
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/HaxeFoundation/hashlink")
+ (commit version)))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32 "0i5f1mxpgjcdirx60kxrw0r0y15qh3j16a6fj8mzkq3k7j2hc982"))
+ (modules '((guix build utils)))
+ (snippet
+ '(begin
+ ;; Remove bundled libraries (mainly used for Windows build).
+ (delete-file-recursively "include")
+ #t))))
+ (build-system gnu-build-system)
+ (arguments
+ ;; Looks like there are tests with CMake, but there is confusion if this
+ ;; is a supported way to build on Linux. See, e.g.
+ ;; https://github.com/HaxeFoundation/hashlink/issues/397. Also, the
+ ;; CMake build requires running the library manager haxelib in the build
+ ;; process for the tests, likely requiring network access.
+ ;; TODO: Use cmake-build-system instead and enable tests?
+ (list #:tests? #f
+ #:make-flags
+ ;; The built hdll libraries need help finding libhl.so.
+ #~(list (string-append "LIBFLAGS=-Wl,-rpath=" #$output "/lib"))
+ #:phases
+ #~(modify-phases %standard-phases
+ ;; Don't try to build the (removed) bundled libraries pcre,
+ ;; minimp3, and mikktspace. Provide the approriate paths and
+ ;; linking options.
+ (add-after 'unpack 'use-system-libs
+ (lambda _
+ (substitute* "Makefile"
+ (("\\$\\{PCRE\\}") "")
+ (("-lpthread") "-lpthread -lpcre16")
+ (("include/minimp3")
+ (string-append #$(this-package-input "minimp3") "/include"))
+ (("include/mikktspace ")
+ (string-append #$(this-package-input "mikktspace") "/include "))
+ (("include/mikktspace/mikktspace.o") "")
+ (("-lpng") "-lpng -lmikktspace"))))
+ (replace 'configure
+ (lambda* _
+ (setenv "CC" #$(cc-for-target))
+ (setenv "PREFIX" #$output)))
+ (replace 'build
+ (lambda* (#:key make-flags parallel-build? #:allow-other-keys)
+ (apply invoke "make" "-j" (if parallel-build?
+ (number->string (parallel-job-count))
+ "1")
+ make-flags))))))
+ (inputs (list glu
+ haxe
+ libjpeg-turbo
+ libpng
+ libuv
+ libvorbis
+ mbedtls-apache
+ mikktspace
+ minimp3
+ openal
+ pcre
+ sdl2
+ sqlite
+ zlib))
+ (native-inputs (list pkg-config))
+ (home-page "https://hashlink.haxe.org/")
+ (synopsis "Virtual machine for the Haxe language")
+ (description
+ "HashLink (HL) is a virtual machine for the Haxe language. It can run
+bytecode produced by the Haxe compiler, or converted to C by HL. The HashLink runtime
+includes the following features:
+@itemize
+@item Fully compatible with the Haxe specification
+@item Support file I/O, regular expressions, network, etc.
+@item Unicode strings by default
+@item Mark-and-not-sweep Garbage Collector
+@item x86 and x86-64 HL/C compilation
+@item x86 and x86-64 HL/JIT compilation
+@end itemize
+
+While the standard HL runtime provides support for Haxe standard library,
+HashLink also provides several libraries that can optionally be used to build
+HL-specific applications. This includes the FMT library for compression and
+image support and SDL for mouse, keyboard, and game controller support,
+OpenGL, and more.")
+ (license license:expat)))
--
2.37.1
^ permalink raw reply related [flat|nested] 12+ messages in thread
* bug#56806: [PATCH 0/9] Add the Haxe language and tools.
2022-07-28 4:06 [bug#56806] [PATCH 0/9] Add the Haxe language and tools John Kehayias via Guix-patches via
` (8 preceding siblings ...)
2022-07-28 4:11 ` [bug#56806] [PATCH 9/9] gnu: Add hashlink John Kehayias via Guix-patches via
@ 2022-08-03 6:53 ` 宋文武 via Guix-patches via
2022-08-03 18:04 ` [bug#56806] " John Kehayias via Guix-patches via
9 siblings, 1 reply; 12+ messages in thread
From: 宋文武 via Guix-patches via @ 2022-08-03 6:53 UTC (permalink / raw)
To: John Kehayias; +Cc: 56806-done
John Kehayias <john.kehayias@protonmail.com> writes:
> Hi Guix,
>
> Incoming is a patch series to add the Haxe [0] language and tools,
> including the language/VM Neko [1] that it is built with and the Haxe
> VM Hashlink [2]. It starts with OCaml that these are built on top of,
> and includes some other needed packages.
> [...]
Look great to me, pushed, thank you!
I only removed 'XML-Light' from the synopsis of ocaml-xml-light.
^ permalink raw reply [flat|nested] 12+ messages in thread