guix-patches
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[bug#56806] [PATCH 0/9] Add the Haxe language and tools.


From: John Kehayias
Subject: [bug#56806] [PATCH 0/9] Add the Haxe language and tools.
Date: Thu, 28 Jul 2022 04:06:27 +0000

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. Here is a breakdown of what the patches do:

Patch 1-4: Add needed OCaml dependencies. I relied on the importer and fixed up 
the builds, descriptions, licenses, etc. I haven't packaged any OCaml before 
(or know anything about it), but everything appeared to work and I followed our 
existing packages.

Patch 5 & 6: Add 2 small libraries, minimp3 and mikktspace.

Minimp3 is a single header library, though also included the extended version 
(so, 2 headers). The repo has a lot of other files for what looks like tests, 
but wasn't sure how to easily run them with all the files and scripts and a 
lack of instructions. I left that as a TODO for the future.

Mikktspace is a header and C file. There is no makefile or instructions, so 
upon discussion on #guix I built a shared library manually. It works for what I 
needed and means Hashlink can be completely unbundled.

Patch 7-9: Add Neko (language/VM used to build Haxe), the Haxe toolkit, and the 
Haxe VM Hashlink.

Haxe: this builds the compiler and library manager, haxelib. Perhaps these 
could be separated, but it seemed to make more sense to keep them together as 
intended by upstream. haxelib-src is a bare origin to use rather than Haxe's 
haxelib submodule. There was also a manual change so that the default location 
haxelib will suggest for libraries is user writeable: ~/.haxe/lib (rather than 
/usr/lib/haxe/lib).

Hashlink: unbundled the included libraries with Guix packages. I left a comment 
about there being a CMake build that seemed perhaps incomplete (there is bug 
reports on confusion of how to build with CMake) and is also where the tests 
seemed to be. I could get the CMake build to build, but it didn't build 
everything needed and didn't seem to be fully linked. The tests may also need 
network access as they want to call haxelib (typically would download haxe 
libraries). Tests disabled until future updates can sort this out.

I've run guix lint on all and have built and used Haxe and Hashlink. Everything 
seems to run well, it can download Haxe libraries to then build, the Hashlink 
VM works to run e.g. SDL graphics code; even building to JS with Haxe works 
just fine. I used [3] as an example of a non-trivial Haxe package, using the 
Heaps.io game engine [4]; everything worked without modification.

I put Neko (since it is used to build Haxe) and the Haxe packages in a new 
module (gnu packages haxe). Perhaps in the future someone may want a 
haxe-build-system to manage libraries with Guix, but so far everything works 
well with how Haxe wants it to.

Hope everything looks good, let me know any needed changes.

John

[0] https://haxe.org/

[1] https://nekovm.org/

[2] https://hashlink.haxe.org/

[3] https://github.com/deepnight/gameBase

[4] https://heaps.io/





reply via email to

[Prev in Thread] Current Thread [Next in Thread]