* [Buildroot] [PATCH v2 1/8] package/qbe: new host package
2026-07-20 15:02 [Buildroot] [PATCH v2 0/8] support Hare language Francois Perrad
@ 2026-07-20 15:02 ` Francois Perrad
2026-07-20 16:06 ` Baruch Siach via buildroot
2026-07-20 15:02 ` [Buildroot] [PATCH v2 2/8] package/scdoc: " Francois Perrad
` (6 subsequent siblings)
7 siblings, 1 reply; 12+ messages in thread
From: Francois Perrad @ 2026-07-20 15:02 UTC (permalink / raw)
To: buildroot; +Cc: Francois Perrad
dependency for host-hare
Signed-off-by: Francois Perrad <francois.perrad@gadz.org>
---
DEVELOPERS | 1 +
package/qbe/qbe.hash | 5 +++++
package/qbe/qbe.mk | 22 ++++++++++++++++++++++
3 files changed, 28 insertions(+)
create mode 100644 package/qbe/qbe.hash
create mode 100644 package/qbe/qbe.mk
diff --git a/DEVELOPERS b/DEVELOPERS
index 3530d515a..23c95db6f 100644
--- a/DEVELOPERS
+++ b/DEVELOPERS
@@ -1177,6 +1177,7 @@ F: package/coxpcall/
F: package/dado/
F: package/ficl/
F: package/janet/
+F: package/qbe/
F: package/libtomcrypt/
F: package/libtommath/
F: package/linenoise/
diff --git a/package/qbe/qbe.hash b/package/qbe/qbe.hash
new file mode 100644
index 000000000..2250c493a
--- /dev/null
+++ b/package/qbe/qbe.hash
@@ -0,0 +1,5 @@
+# Hashes from: https://c9x.me/compile/releases.html
+sha256 a6d50eb952525a234bf76ba151861f73b7a382ac952d985f2b9af1df5368225d qbe-1.2.tar.xz
+
+# Locally computed
+sha256 2b026a9038be00b1102da922775ffea4857ea755f63694efc36dcbcbdebf23d6 LICENSE
diff --git a/package/qbe/qbe.mk b/package/qbe/qbe.mk
new file mode 100644
index 000000000..a6e3e4d57
--- /dev/null
+++ b/package/qbe/qbe.mk
@@ -0,0 +1,22 @@
+################################################################################
+#
+# qbe
+#
+################################################################################
+
+QBE_VERSION = 1.2
+QBE_SITE = https://c9x.me/compile/release
+QBE_SOURCE = qbe-$(QBE_VERSION).tar.xz
+QBE_LICENSE = MIT
+QBE_LICENSE_FILES = LICENSE
+
+define HOST_QBE_BUILD_CMDS
+ $(HOST_MAKE_ENV) $(MAKE) -C $(@D)
+endef
+
+define HOST_QBE_INSTALL_CMDS
+ $(HOST_MAKE_ENV) $(MAKE) -C $(@D) \
+ PREFIX=/usr DESTDIR="$(HOST_DIR)" install
+endef
+
+$(eval $(host-generic-package))
--
2.43.0
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
^ permalink raw reply related [flat|nested] 12+ messages in thread* Re: [Buildroot] [PATCH v2 1/8] package/qbe: new host package
2026-07-20 15:02 ` [Buildroot] [PATCH v2 1/8] package/qbe: new host package Francois Perrad
@ 2026-07-20 16:06 ` Baruch Siach via buildroot
2026-07-20 20:43 ` François PERRAD
0 siblings, 1 reply; 12+ messages in thread
From: Baruch Siach via buildroot @ 2026-07-20 16:06 UTC (permalink / raw)
To: Francois Perrad; +Cc: buildroot, Francois Perrad
Hi Francois,
On Mon, Jul 20 2026, Francois Perrad wrote:
> dependency for host-hare
[...]
> diff --git a/package/qbe/qbe.mk b/package/qbe/qbe.mk
> new file mode 100644
> index 000000000..a6e3e4d57
> --- /dev/null
> +++ b/package/qbe/qbe.mk
> @@ -0,0 +1,22 @@
> +################################################################################
> +#
> +# qbe
> +#
> +################################################################################
> +
> +QBE_VERSION = 1.2
Any reason to prefer 1.2 over the latest 1.3 version?
baruch
> +QBE_SITE = https://c9x.me/compile/release
> +QBE_SOURCE = qbe-$(QBE_VERSION).tar.xz
> +QBE_LICENSE = MIT
> +QBE_LICENSE_FILES = LICENSE
> +
> +define HOST_QBE_BUILD_CMDS
> + $(HOST_MAKE_ENV) $(MAKE) -C $(@D)
> +endef
> +
> +define HOST_QBE_INSTALL_CMDS
> + $(HOST_MAKE_ENV) $(MAKE) -C $(@D) \
> + PREFIX=/usr DESTDIR="$(HOST_DIR)" install
> +endef
> +
> +$(eval $(host-generic-package))
--
~. .~ Tk Open Systems
=}------------------------------------------------ooO--U--Ooo------------{=
- baruch@tkos.co.il - tel: +972.52.368.4656, http://www.tkos.co.il -
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
^ permalink raw reply [flat|nested] 12+ messages in thread* Re: [Buildroot] [PATCH v2 1/8] package/qbe: new host package
2026-07-20 16:06 ` Baruch Siach via buildroot
@ 2026-07-20 20:43 ` François PERRAD
0 siblings, 0 replies; 12+ messages in thread
From: François PERRAD @ 2026-07-20 20:43 UTC (permalink / raw)
To: Baruch Siach; +Cc: buildroot
[-- Attachment #1.1: Type: text/plain, Size: 1512 bytes --]
Le lun. 20 juil. 2026 à 18:06, Baruch Siach <baruch@tkos.co.il> a écrit :
> Hi Francois,
>
> On Mon, Jul 20 2026, Francois Perrad wrote:
> > dependency for host-hare
>
> [...]
>
> > diff --git a/package/qbe/qbe.mk b/package/qbe/qbe.mk
> > new file mode 100644
> > index 000000000..a6e3e4d57
> > --- /dev/null
> > +++ b/package/qbe/qbe.mk
> > @@ -0,0 +1,22 @@
> >
> +################################################################################
> > +#
> > +# qbe
> > +#
> >
> +################################################################################
> > +
> > +QBE_VERSION = 1.2
>
> Any reason to prefer 1.2 over the latest 1.3 version?
>
> baruch
>
>
Hare 0.26.0 was developed & tested with QBE 1.2.
QBE 1.3 will wait for the next Hare release.
François
> > +QBE_SITE = https://c9x.me/compile/release
> > +QBE_SOURCE = qbe-$(QBE_VERSION).tar.xz
> > +QBE_LICENSE = MIT
> > +QBE_LICENSE_FILES = LICENSE
> > +
> > +define HOST_QBE_BUILD_CMDS
> > + $(HOST_MAKE_ENV) $(MAKE) -C $(@D)
> > +endef
> > +
> > +define HOST_QBE_INSTALL_CMDS
> > + $(HOST_MAKE_ENV) $(MAKE) -C $(@D) \
> > + PREFIX=/usr DESTDIR="$(HOST_DIR)" install
> > +endef
> > +
> > +$(eval $(host-generic-package))
>
> --
> ~. .~ Tk Open
> Systems
> =}------------------------------------------------ooO--U--Ooo------------{=
> - baruch@tkos.co.il - tel: +972.52.368.4656, http://www.tkos.co.il -
>
[-- Attachment #1.2: Type: text/html, Size: 2650 bytes --]
[-- Attachment #2: Type: text/plain, Size: 150 bytes --]
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Buildroot] [PATCH v2 2/8] package/scdoc: new host package
2026-07-20 15:02 [Buildroot] [PATCH v2 0/8] support Hare language Francois Perrad
2026-07-20 15:02 ` [Buildroot] [PATCH v2 1/8] package/qbe: new host package Francois Perrad
@ 2026-07-20 15:02 ` Francois Perrad
2026-07-20 15:02 ` [Buildroot] [PATCH v2 3/8] package/harec: " Francois Perrad
` (5 subsequent siblings)
7 siblings, 0 replies; 12+ messages in thread
From: Francois Perrad @ 2026-07-20 15:02 UTC (permalink / raw)
To: buildroot; +Cc: Francois Perrad
dependency for host-hare
Signed-off-by: Francois Perrad <francois.perrad@gadz.org>
---
DEVELOPERS | 1 +
package/scdoc/scdoc.hash | 3 +++
package/scdoc/scdoc.mk | 22 ++++++++++++++++++++++
3 files changed, 26 insertions(+)
create mode 100644 package/scdoc/scdoc.hash
create mode 100644 package/scdoc/scdoc.mk
diff --git a/DEVELOPERS b/DEVELOPERS
index 23c95db6f..442fe4e6a 100644
--- a/DEVELOPERS
+++ b/DEVELOPERS
@@ -1197,6 +1197,7 @@ F: package/pkg-perl.mk
F: package/pkg-luarocks.mk
F: package/quickjs/
F: package/rings/
+F: package/scdoc/
F: package/wsapi/
F: package/wsapi-fcgi/
F: package/wsapi-xavante/
diff --git a/package/scdoc/scdoc.hash b/package/scdoc/scdoc.hash
new file mode 100644
index 000000000..8917b4038
--- /dev/null
+++ b/package/scdoc/scdoc.hash
@@ -0,0 +1,3 @@
+# Locally computed
+sha256 e1a9c2000f855123a1a50c8f897073e0ee95fc41787431efe3864c2f1c2e7092 1.11.4.tar.gz
+sha256 ad227c56bf22c9fa35be3d383789d065698904b61161f6a8339b91bde5a3e48b COPYING
diff --git a/package/scdoc/scdoc.mk b/package/scdoc/scdoc.mk
new file mode 100644
index 000000000..80ee9ce76
--- /dev/null
+++ b/package/scdoc/scdoc.mk
@@ -0,0 +1,22 @@
+################################################################################
+#
+# scdoc
+#
+################################################################################
+
+SCDOC_VERSION = 1.11.4
+SCDOC_SITE = https://git.sr.ht/~sircmpwn/scdoc/archive
+SCDOC_SOURCE = $(SCDOC_VERSION).tar.gz
+SCDOC_LICENSE = MIT
+SCDOC_LICENSE_FILES = COPYING
+
+define HOST_SCDOC_BUILD_CMDS
+ $(HOST_MAKE_ENV) $(MAKE) -C $(@D) all
+endef
+
+define HOST_SCDOC_INSTALL_CMDS
+ $(HOST_MAKE_ENV) $(MAKE) -C $(@D) \
+ PREFIX=/usr DESTDIR="$(HOST_DIR)" install
+endef
+
+$(eval $(host-generic-package))
--
2.43.0
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
^ permalink raw reply related [flat|nested] 12+ messages in thread* [Buildroot] [PATCH v2 3/8] package/harec: new host package
2026-07-20 15:02 [Buildroot] [PATCH v2 0/8] support Hare language Francois Perrad
2026-07-20 15:02 ` [Buildroot] [PATCH v2 1/8] package/qbe: new host package Francois Perrad
2026-07-20 15:02 ` [Buildroot] [PATCH v2 2/8] package/scdoc: " Francois Perrad
@ 2026-07-20 15:02 ` Francois Perrad
2026-07-20 15:02 ` [Buildroot] [PATCH v2 4/8] package/hare: " Francois Perrad
` (4 subsequent siblings)
7 siblings, 0 replies; 12+ messages in thread
From: Francois Perrad @ 2026-07-20 15:02 UTC (permalink / raw)
To: buildroot; +Cc: Francois Perrad
dependency for host-hare
Signed-off-by: Francois Perrad <francois.perrad@gadz.org>
---
DEVELOPERS | 1 +
package/harec/harec.hash | 3 +++
package/harec/harec.mk | 26 ++++++++++++++++++++++++++
3 files changed, 30 insertions(+)
create mode 100644 package/harec/harec.hash
create mode 100644 package/harec/harec.mk
diff --git a/DEVELOPERS b/DEVELOPERS
index 442fe4e6a..0b99456a9 100644
--- a/DEVELOPERS
+++ b/DEVELOPERS
@@ -1176,6 +1176,7 @@ F: package/copas/
F: package/coxpcall/
F: package/dado/
F: package/ficl/
+F: package/harec/
F: package/janet/
F: package/qbe/
F: package/libtomcrypt/
diff --git a/package/harec/harec.hash b/package/harec/harec.hash
new file mode 100644
index 000000000..0c3679bfc
--- /dev/null
+++ b/package/harec/harec.hash
@@ -0,0 +1,3 @@
+# Locally computed
+sha256 5581bc16dcf22969c7d33b0f2a9535ba37d4cf1bb39dec252e98ff2781175629 0.26.0.tar.gz
+sha256 3972dc9744f6499f0f9b2dbf76696f2ae7ad8af9b23dde66d6af86c9dfb36986 COPYING
diff --git a/package/harec/harec.mk b/package/harec/harec.mk
new file mode 100644
index 000000000..df1096680
--- /dev/null
+++ b/package/harec/harec.mk
@@ -0,0 +1,26 @@
+################################################################################
+#
+# harec
+#
+################################################################################
+
+HAREC_VERSION = 0.26.0
+HAREC_SITE = https://git.sr.ht/~sircmpwn/harec/archive
+HAREC_SOURCE = $(HAREC_VERSION).tar.gz
+HAREC_LICENSE = GPL-3.0
+HAREC_LICENSE_FILES = COPYING
+
+define HOST_HAREC_CONFIGURE_CMDS
+ cp $(@D)/configs/linux.mk $(@D)/config.mk
+endef
+
+define HOST_HAREC_BUILD_CMDS
+ $(HOST_MAKE_ENV) $(MAKE) -C $(@D) ARCH=$(HOSTARCH) all
+endef
+
+define HOST_HAREC_INSTALL_CMDS
+ $(HOST_MAKE_ENV) $(MAKE) -C $(@D) \
+ PREFIX=/usr DESTDIR="$(HOST_DIR)" install
+endef
+
+$(eval $(host-generic-package))
--
2.43.0
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
^ permalink raw reply related [flat|nested] 12+ messages in thread* [Buildroot] [PATCH v2 4/8] package/hare: new host package
2026-07-20 15:02 [Buildroot] [PATCH v2 0/8] support Hare language Francois Perrad
` (2 preceding siblings ...)
2026-07-20 15:02 ` [Buildroot] [PATCH v2 3/8] package/harec: " Francois Perrad
@ 2026-07-20 15:02 ` Francois Perrad
2026-07-20 16:02 ` Baruch Siach via buildroot
2026-07-20 15:02 ` [Buildroot] [PATCH v2 5/8] package/pkg-hare.mk: new infrastructure Francois Perrad
` (3 subsequent siblings)
7 siblings, 1 reply; 12+ messages in thread
From: Francois Perrad @ 2026-07-20 15:02 UTC (permalink / raw)
To: buildroot; +Cc: Francois Perrad
Signed-off-by: Francois Perrad <francois.perrad@gadz.org>
---
DEVELOPERS | 2 +-
package/Config.in.host | 1 +
package/hare/Config.in.host | 14 +++++++++
package/hare/hare.hash | 3 ++
package/hare/hare.mk | 57 +++++++++++++++++++++++++++++++++++++
5 files changed, 76 insertions(+), 1 deletion(-)
create mode 100644 package/hare/Config.in.host
create mode 100644 package/hare/hare.hash
create mode 100644 package/hare/hare.mk
diff --git a/DEVELOPERS b/DEVELOPERS
index 0b99456a9..89232ff71 100644
--- a/DEVELOPERS
+++ b/DEVELOPERS
@@ -1176,7 +1176,7 @@ F: package/copas/
F: package/coxpcall/
F: package/dado/
F: package/ficl/
-F: package/harec/
+F: package/hare*
F: package/janet/
F: package/qbe/
F: package/libtomcrypt/
diff --git a/package/Config.in.host b/package/Config.in.host
index df57cc0c1..595caf9e7 100644
--- a/package/Config.in.host
+++ b/package/Config.in.host
@@ -54,6 +54,7 @@ menu "Host utilities"
source "package/gobject-introspection/Config.in.host"
source "package/google-breakpad/Config.in.host"
source "package/gptfdisk/Config.in.host"
+ source "package/hare/Config.in.host"
source "package/imagemagick/Config.in.host"
source "package/imx-mkimage/Config.in.host"
source "package/imx-usb-loader/Config.in.host"
diff --git a/package/hare/Config.in.host b/package/hare/Config.in.host
new file mode 100644
index 000000000..a6c53b376
--- /dev/null
+++ b/package/hare/Config.in.host
@@ -0,0 +1,14 @@
+
+config BR2_PACKAGE_HOST_HARE_TARGET_ARCH_SUPPORTS
+ bool
+ default y if BR2_aarch64
+ default y if BR2_RISCV_64
+ default y if BR2_x86_64
+
+config BR2_PACKAGE_HOST_HARE
+ bool "host hare"
+ depends on BR2_PACKAGE_HOST_HARE_TARGET_ARCH_SUPPORTS
+ help
+ The Hare programming language
+
+ https://harelang.org/
diff --git a/package/hare/hare.hash b/package/hare/hare.hash
new file mode 100644
index 000000000..98aadd890
--- /dev/null
+++ b/package/hare/hare.hash
@@ -0,0 +1,3 @@
+# Locally computed
+sha256 f76704920a2f457be4d2d6290dc10dcfb7319c1d1990f2305491644383466905 0.26.0.1.tar.gz
+sha256 be782a711236b742d7231a4a9a15ca781013e61dead0d6908105fbc2cb38a317 COPYING
diff --git a/package/hare/hare.mk b/package/hare/hare.mk
new file mode 100644
index 000000000..d408b03d6
--- /dev/null
+++ b/package/hare/hare.mk
@@ -0,0 +1,57 @@
+################################################################################
+#
+# hare
+#
+################################################################################
+
+HARE_VERSION = 0.26.0.1
+HARE_SITE = https://git.sr.ht/~sircmpwn/hare/archive
+HARE_SOURCE = $(HARE_VERSION).tar.gz
+HARE_LICENSE = MPL-2.0
+HARE_LICENSE_FILES = COPYING
+
+HOST_HARE_DEPENDENCIES = host-harec host-qbe host-scdoc
+
+HOST_HARE_CONF_OPTS = \
+ ARCH=$(HOSTARCH) \
+ DESTDIR="$(HOST_DIR)" \
+ PREFIX=/usr \
+ HAREC="$(HOST_DIR)/usr/bin/harec" \
+ QBE="$(HOST_DIR)/usr/bin/qbe" \
+ SCDOC="$(HOST_DIR)/usr/bin/scdoc" \
+ HAREPATH="$(HOST_DIR)/usr/src/hare/stdlib"
+
+ifeq ($(BR2_aarch64),y)
+HOST_HARE_CONF_OPTS += \
+ AARCH64_AS=$(TARGET_AS) \
+ AARCH64_CC=$(TARGET_CC) \
+ AARCH64_LD=$(TARGET_LD)
+endif
+
+ifeq ($(BR2_RISCV_64),y)
+HOST_HARE_CONF_OPTS += \
+ RISCV64_AS=$(TARGET_AS) \
+ RISCV64_CC=$(TARGET_CC) \
+ RISCV64_LD=$(TARGET_LD)
+endif
+
+ifeq ($(BR2_x86_64),y)
+HOST_HARE_CONF_OPTS += \
+ X86_64_AS=$(TARGET_AS) \
+ X86_64_CC=$(TARGET_CC) \
+ X86_64_LD=$(TARGET_LD)
+endif
+
+define HOST_HARE_CONFIGURE_CMDS
+ cp $(@D)/configs/linux.mk $(@D)/config.mk
+endef
+
+define HOST_HARE_BUILD_CMDS
+ $(HOST_MAKE_ENV) $(MAKE) -C $(@D) $(HOST_HARE_CONF_OPTS) all
+endef
+
+define HOST_HARE_INSTALL_CMDS
+ $(HOST_MAKE_ENV) $(MAKE) -C $(@D) $(HOST_HARE_CONF_OPTS) install
+endef
+
+$(eval $(host-generic-package))
--
2.43.0
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
^ permalink raw reply related [flat|nested] 12+ messages in thread* Re: [Buildroot] [PATCH v2 4/8] package/hare: new host package
2026-07-20 15:02 ` [Buildroot] [PATCH v2 4/8] package/hare: " Francois Perrad
@ 2026-07-20 16:02 ` Baruch Siach via buildroot
0 siblings, 0 replies; 12+ messages in thread
From: Baruch Siach via buildroot @ 2026-07-20 16:02 UTC (permalink / raw)
To: Francois Perrad; +Cc: buildroot, Francois Perrad
Hi Francois,
On Mon, Jul 20 2026, Francois Perrad wrote:
> +ifeq ($(BR2_aarch64),y)
> +HOST_HARE_CONF_OPTS += \
> + AARCH64_AS=$(TARGET_AS) \
> + AARCH64_CC=$(TARGET_CC) \
> + AARCH64_LD=$(TARGET_LD)
> +endif
> +
> +ifeq ($(BR2_RISCV_64),y)
> +HOST_HARE_CONF_OPTS += \
> + RISCV64_AS=$(TARGET_AS) \
> + RISCV64_CC=$(TARGET_CC) \
> + RISCV64_LD=$(TARGET_LD)
> +endif
> +
> +ifeq ($(BR2_x86_64),y)
> +HOST_HARE_CONF_OPTS += \
> + X86_64_AS=$(TARGET_AS) \
> + X86_64_CC=$(TARGET_CC) \
> + X86_64_LD=$(TARGET_LD)
> +endif
I think you can reduce code duplication with something like this
(untested):
ifeq ($(BR2_aarch64),y)
HOST_HARE_TARGET_ARCH = AARCH64
else ifeq ($(BR2_RISCV_64),y)
HOST_HARE_TARGET_ARCH = RISCV64
else ifeq ($(BR2_x86_64),y)
HOST_HARE_TARGET_ARCH = X86_64
endif
HOST_HARE_CONF_OPTS += \
$(HOST_HARE_TARGET_ARCH)_AS=$(TARGET_AS) \
$(HOST_HARE_TARGET_ARCH)_CC=$(TARGET_CC) \
$(HOST_HARE_TARGET_ARCH)_LD=$(TARGET_LD)
Alternatively, instead of HOST_HARE_TARGET_ARCH, you can use a blind
config symbol similar to BR2_PACKAGE_FLUENT_BIT_WASM_ARCH.
baruch
> +
> +define HOST_HARE_CONFIGURE_CMDS
> + cp $(@D)/configs/linux.mk $(@D)/config.mk
> +endef
> +
> +define HOST_HARE_BUILD_CMDS
> + $(HOST_MAKE_ENV) $(MAKE) -C $(@D) $(HOST_HARE_CONF_OPTS) all
> +endef
> +
> +define HOST_HARE_INSTALL_CMDS
> + $(HOST_MAKE_ENV) $(MAKE) -C $(@D) $(HOST_HARE_CONF_OPTS) install
> +endef
> +
> +$(eval $(host-generic-package))
--
~. .~ Tk Open Systems
=}------------------------------------------------ooO--U--Ooo------------{=
- baruch@tkos.co.il - tel: +972.52.368.4656, http://www.tkos.co.il -
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
^ permalink raw reply [flat|nested] 12+ messages in thread
* [Buildroot] [PATCH v2 5/8] package/pkg-hare.mk: new infrastructure
2026-07-20 15:02 [Buildroot] [PATCH v2 0/8] support Hare language Francois Perrad
` (3 preceding siblings ...)
2026-07-20 15:02 ` [Buildroot] [PATCH v2 4/8] package/hare: " Francois Perrad
@ 2026-07-20 15:02 ` Francois Perrad
2026-07-20 15:02 ` [Buildroot] [PATCH v2 6/8] package/hare-ev: new package Francois Perrad
` (2 subsequent siblings)
7 siblings, 0 replies; 12+ messages in thread
From: Francois Perrad @ 2026-07-20 15:02 UTC (permalink / raw)
To: buildroot; +Cc: Francois Perrad
Signed-off-by: Francois Perrad <francois.perrad@gadz.org>
---
DEVELOPERS | 1 +
docs/manual/adding-packages-hare.adoc | 87 ++++++++++++++++++++++++
docs/manual/adding-packages.adoc | 2 +
package/Makefile.in | 1 +
package/pkg-hare.mk | 95 +++++++++++++++++++++++++++
5 files changed, 186 insertions(+)
create mode 100644 docs/manual/adding-packages-hare.adoc
create mode 100644 package/pkg-hare.mk
diff --git a/DEVELOPERS b/DEVELOPERS
index 89232ff71..ac7345e04 100644
--- a/DEVELOPERS
+++ b/DEVELOPERS
@@ -1194,6 +1194,7 @@ F: package/lzlib/
F: package/moarvm/
F: package/opendoas/
F: package/perl*
+F: package/pkg-hare.mk
F: package/pkg-perl.mk
F: package/pkg-luarocks.mk
F: package/quickjs/
diff --git a/docs/manual/adding-packages-hare.adoc b/docs/manual/adding-packages-hare.adoc
new file mode 100644
index 000000000..b52d953b2
--- /dev/null
+++ b/docs/manual/adding-packages-hare.adoc
@@ -0,0 +1,87 @@
+// -*- mode:doc; -*-
+// vim: set syntax=asciidoc:
+
+=== Infrastructure for Hare packages
+
+[[hare-package-tutorial]]
+
+==== +hare-package+ tutorial
+
+The +Config.in+ file of Hare-based package 'hare-foo' should contain:
+
+----
+01: config BR2_PACKAGE_HARE_FOO
+02: bool "hare-foo"
+03: depends on BR2_PACKAGE_HOST_HARE_TARGET_ARCH_SUPPORTS
+04: select BR2_PACKAGE_HOST_HARE
+05: help
+06: This is a comment that explains what foo is.
+07:
+08: https://foosoftware.org/foo/
+----
+
+And the +.mk+ file for this package should contain:
+
+----
+01: ################################################################################
+02: #
+03: # hare-foo
+04: #
+05: ################################################################################
+06:
+07: HARE_FOO_VERSION = 0.42.0
+08: HARE_FOO_SITE = https://git.sr.ht/~sircmpwn/hare-foo
+09: HARE_FOO_SITE_METHOD = git
+10: HARE_FOO_LICENSE = MPL-2.0
+11: HARE_FOO_LICENSE_FILES = COPYING
+12: HARE_FOO_INSTALL_STAGING = YES
+13:
+14: $(eval $(hare-package))
+----
+
+The Makefile starts with the definition of the standard variables for
+package declaration (lines 7 to 12).
+
+Finally, on line 14, we invoke the +hare-package+
+macro that generates all the Makefile rules that actually allows the
+package to be built.
+
+[[hare-package-reference]]
+
+==== +hare-package+ reference
+
+As a policy, packages that provide Hare modules should all be
+named +hare-<something>+ in Buildroot.
+
+In their +Config.in+ file, packages using the +hare-package+
+infrastructure should depend on +BR2_PACKAGE_HOST_HARE_TARGET_ARCH_SUPPORTS+
+because Buildroot will automatically add a dependency on +host-hare+
+to such packages.
+
+The main macro of the Hare package infrastructure is +hare-package+:
+like +generic-package+ it works by defining a number of variables providing
+metadata information about the package, and then calling the +hare-package+
+macro.
+
+Just like the generic infrastructure, the Hare infrastructure works
+by defining a number of variables before calling the +hare-package+
+macro.
+
+All the package metadata information variables that exist in the
+xref:generic-package-reference[generic package infrastructure] also
+exist in the Hare infrastructure.
+
+This infrastructure expects that the upstream package follows the
+https://harelang.org/documentation/usage/project-structure.html#makefiles[project structure conventions],
+because the upstream +Makefile+ is called.
+
+When the package contains Hare modules (ie. libraries),
+there are not compiled by this BR package,
+there are just installed in +$(STAGING_DIR)/usr/src/hare/third-party+,
+for a future use.
+
+When the package produces one or more executables,
+all Hare sources (from this package, from dependent modules,
+from the Hare stdlib) are compiled and statically linked.
+If a binding to a native library is used,
+the link requires the static library, not the shared one.
diff --git a/docs/manual/adding-packages.adoc b/docs/manual/adding-packages.adoc
index 10acae0b1..2c66d88f3 100644
--- a/docs/manual/adding-packages.adoc
+++ b/docs/manual/adding-packages.adoc
@@ -43,6 +43,8 @@ include::adding-packages-golang.adoc[]
include::adding-packages-qmake.adoc[]
+include::adding-packages-hare.adoc[]
+
include::adding-packages-kernel-module.adoc[]
include::adding-packages-asciidoc.adoc[]
diff --git a/package/Makefile.in b/package/Makefile.in
index 5ebb5f9ba..eac28b3a9 100644
--- a/package/Makefile.in
+++ b/package/Makefile.in
@@ -474,3 +474,4 @@ include package/pkg-golang.mk
include package/pkg-meson.mk
include package/pkg-qmake.mk
include package/pkg-cargo.mk
+include package/pkg-hare.mk
diff --git a/package/pkg-hare.mk b/package/pkg-hare.mk
new file mode 100644
index 000000000..e1c1415d0
--- /dev/null
+++ b/package/pkg-hare.mk
@@ -0,0 +1,95 @@
+################################################################################
+# Hare package infrastructure
+# see https://harelang.org/
+#
+# This file implements an infrastructure that eases development of
+# package .mk files for Hare packages.
+#
+# See the Buildroot documentation for details on the usage of this
+# infrastructure
+#
+# In terms of implementation, this Hare infrastructure requires
+# the .mk file to only specify metadata information about the
+# package: name, version, etc.
+#
+################################################################################
+
+HARE_RUN_CMD = PATH=$(BR_PATH) HAREPATH="$(HOST_DIR)/usr/src/hare/stdlib:$(STAGING_DIR)/usr/src/hare/third-party" $(HOST_DIR)/bin/hare
+HARE_ARCH_OPT = -a $(ARCH)
+HARE_LIBDIR_OPT = -L $(STAGING_DIR)/usr/lib
+
+################################################################################
+# inner-hare-package -- defines how the configuration, compilation and
+# installation of a Hare package should be done, implements a few hooks to
+# tune the build process and calls the generic package infrastructure to
+# generate the necessary make targets
+#
+# argument 1 is the lowercase package name
+# argument 2 is the uppercase package name, including a HOST_ prefix
+# for host packages
+# argument 3 is the uppercase package name, without the HOST_ prefix
+# for host packages
+# argument 4 is the type (target or host)
+################################################################################
+
+define inner-hare-package
+
+$(2)_DEPENDENCIES += host-hare
+
+#
+# Build step. Only define it if not already defined by the package .mk
+# file.
+#
+ifndef $(2)_BUILD_CMDS
+# in perfect world, all project follows the conventions described in https://harelang.org/documentation/usage/project-structure.html#makefiles
+# but in real world, the target "all" is not always the default one
+define $(2)_BUILD_CMDS
+ if grep "^all:" $$($(2)_SRCDIR)Makefile > /dev/null; then \
+ $(MAKE) -C $$($(2)_SRCDIR) HARE="$$(HARE_RUN_CMD)" HAREFLAGS="$$(HARE_ARCH_OPT) $$(HARE_LIBDIR_OPT)" all; \
+ else \
+ $(MAKE) -C $$($(2)_SRCDIR) HARE="$$(HARE_RUN_CMD)" HAREFLAGS="$$(HARE_ARCH_OPT) $$(HARE_LIBDIR_OPT)"; \
+ fi
+endef
+endif
+
+#
+# Staging installation step. Only define it if not already defined by
+# the package .mk file.
+#
+ifndef $(2)_INSTALL_STAGING_CMDS
+define $(2)_INSTALL_STAGING_CMDS
+ $(MAKE) -C $$($(2)_SRCDIR) PREFIX=/usr DESTDIR="$$(STAGING_DIR)" install
+endef
+endif
+
+#
+# Target installation step. Only define it if not already defined by
+# the package .mk file.
+#
+ifndef $(2)_INSTALL_TARGET_CMDS
+define $(2)_INSTALL_TARGET_CMDS
+ $(MAKE) -C $$($(2)_SRCDIR) PREFIX=/usr DESTDIR="$$(TARGET_DIR)" install
+endef
+endif
+
+# Call the generic package infrastructure to generate the necessary
+# make targets
+$(call inner-generic-package,$(1),$(2),$(3),$(4))
+
+endef
+
+################################################################################
+# hare-package -- the target generator macro for Hare packages
+################################################################################
+
+hare-package = $(call inner-hare-package,$(pkgname),$(call UPPERCASE,$(pkgname)),$(call UPPERCASE,$(pkgname)),target)
+
+################################################################################
+# Cleanup target /usr/src/hare
+################################################################################
+
+define HARE_FINALIZE_TARGET
+ rm -rf $(TARGET_DIR)/usr/src/hare
+endef
+
+TARGET_FINALIZE_HOOKS += HARE_FINALIZE_TARGET
--
2.43.0
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
^ permalink raw reply related [flat|nested] 12+ messages in thread* [Buildroot] [PATCH v2 6/8] package/hare-ev: new package
2026-07-20 15:02 [Buildroot] [PATCH v2 0/8] support Hare language Francois Perrad
` (4 preceding siblings ...)
2026-07-20 15:02 ` [Buildroot] [PATCH v2 5/8] package/pkg-hare.mk: new infrastructure Francois Perrad
@ 2026-07-20 15:02 ` Francois Perrad
2026-07-20 15:02 ` [Buildroot] [PATCH v2 7/8] package/hare-xml: " Francois Perrad
2026-07-20 15:02 ` [Buildroot] [PATCH v2 8/8] package/hare-dbus: " Francois Perrad
7 siblings, 0 replies; 12+ messages in thread
From: Francois Perrad @ 2026-07-20 15:02 UTC (permalink / raw)
To: buildroot; +Cc: Francois Perrad
Signed-off-by: Francois Perrad <francois.perrad@gadz.org>
---
package/Config.in | 1 +
package/hare-ev/Config.in | 8 ++++++++
package/hare-ev/hare-ev.hash | 3 +++
package/hare-ev/hare-ev.mk | 14 ++++++++++++++
4 files changed, 26 insertions(+)
create mode 100644 package/hare-ev/Config.in
create mode 100644 package/hare-ev/hare-ev.hash
create mode 100644 package/hare-ev/hare-ev.mk
diff --git a/package/Config.in b/package/Config.in
index 630662477..5cdf0c13d 100644
--- a/package/Config.in
+++ b/package/Config.in
@@ -2168,6 +2168,7 @@ menu "Other"
source "package/gsl/Config.in"
source "package/gtest/Config.in"
source "package/gumbo-parser/Config.in"
+ source "package/hare-ev/Config.in"
source "package/highway/Config.in"
source "package/jemalloc/Config.in"
source "package/lapack/Config.in"
diff --git a/package/hare-ev/Config.in b/package/hare-ev/Config.in
new file mode 100644
index 000000000..5a65e1fbc
--- /dev/null
+++ b/package/hare-ev/Config.in
@@ -0,0 +1,8 @@
+config BR2_PACKAGE_HARE_EV
+ bool "hare-ev"
+ depends on BR2_PACKAGE_HOST_HARE_TARGET_ARCH_SUPPORTS
+ select BR2_PACKAGE_HOST_HARE
+ help
+ This package provides an event loop for Hare programs.
+
+ https://git.sr.ht/~sircmpwn/hare-ev
diff --git a/package/hare-ev/hare-ev.hash b/package/hare-ev/hare-ev.hash
new file mode 100644
index 000000000..beb0c6f4d
--- /dev/null
+++ b/package/hare-ev/hare-ev.hash
@@ -0,0 +1,3 @@
+# Locally computed
+sha256 c80dc647f3a227259c05dab3b42b4cdfee44c68acd8e7cf31245807a8fa79188 hare-ev-0.26.0.0-git4.tar.gz
+sha256 be782a711236b742d7231a4a9a15ca781013e61dead0d6908105fbc2cb38a317 COPYING
diff --git a/package/hare-ev/hare-ev.mk b/package/hare-ev/hare-ev.mk
new file mode 100644
index 000000000..0f374f3a3
--- /dev/null
+++ b/package/hare-ev/hare-ev.mk
@@ -0,0 +1,14 @@
+################################################################################
+#
+# hare-ev
+#
+################################################################################
+
+HARE_EV_VERSION = 0.26.0.0
+HARE_EV_SITE_METHOD = git
+HARE_EV_SITE = https://git.sr.ht/~sircmpwn/hare-ev
+HARE_EV_LICENSE = MPL-2.0
+HARE_EV_LICENSE_FILES = COPYING
+HARE_EV_INSTALL_STAGING = YES
+
+$(eval $(hare-package))
--
2.43.0
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
^ permalink raw reply related [flat|nested] 12+ messages in thread* [Buildroot] [PATCH v2 7/8] package/hare-xml: new package
2026-07-20 15:02 [Buildroot] [PATCH v2 0/8] support Hare language Francois Perrad
` (5 preceding siblings ...)
2026-07-20 15:02 ` [Buildroot] [PATCH v2 6/8] package/hare-ev: new package Francois Perrad
@ 2026-07-20 15:02 ` Francois Perrad
2026-07-20 15:02 ` [Buildroot] [PATCH v2 8/8] package/hare-dbus: " Francois Perrad
7 siblings, 0 replies; 12+ messages in thread
From: Francois Perrad @ 2026-07-20 15:02 UTC (permalink / raw)
To: buildroot; +Cc: Francois Perrad
Signed-off-by: Francois Perrad <francois.perrad@gadz.org>
---
package/Config.in | 1 +
package/hare-xml/Config.in | 8 ++++++++
package/hare-xml/hare-xml.hash | 3 +++
package/hare-xml/hare-xml.mk | 14 ++++++++++++++
4 files changed, 26 insertions(+)
create mode 100644 package/hare-xml/Config.in
create mode 100644 package/hare-xml/hare-xml.hash
create mode 100644 package/hare-xml/hare-xml.mk
diff --git a/package/Config.in b/package/Config.in
index 5cdf0c13d..1d0dac96c 100644
--- a/package/Config.in
+++ b/package/Config.in
@@ -1883,6 +1883,7 @@ menu "JSON/XML"
source "package/benejson/Config.in"
source "package/cjson/Config.in"
source "package/expat/Config.in"
+ source "package/hare-xml/Config.in"
source "package/jansson/Config.in"
source "package/jose/Config.in"
source "package/jsmn/Config.in"
diff --git a/package/hare-xml/Config.in b/package/hare-xml/Config.in
new file mode 100644
index 000000000..469a9907a
--- /dev/null
+++ b/package/hare-xml/Config.in
@@ -0,0 +1,8 @@
+config BR2_PACKAGE_HARE_XML
+ bool "hare-xml"
+ depends on BR2_PACKAGE_HOST_HARE_TARGET_ARCH_SUPPORTS
+ select BR2_PACKAGE_HOST_HARE
+ help
+ This package provides XML support for Hare.
+
+ https://git.sr.ht/~sircmpwn/hare-xml
diff --git a/package/hare-xml/hare-xml.hash b/package/hare-xml/hare-xml.hash
new file mode 100644
index 000000000..25c1f3c1d
--- /dev/null
+++ b/package/hare-xml/hare-xml.hash
@@ -0,0 +1,3 @@
+# Locally computed
+sha256 56703cc20f70878a02f37967385e9af3659733b31c91c5f34cf819d235a20a28 hare-xml-0.25.2.0-git4.tar.gz
+sha256 be782a711236b742d7231a4a9a15ca781013e61dead0d6908105fbc2cb38a317 COPYING
diff --git a/package/hare-xml/hare-xml.mk b/package/hare-xml/hare-xml.mk
new file mode 100644
index 000000000..be30fd934
--- /dev/null
+++ b/package/hare-xml/hare-xml.mk
@@ -0,0 +1,14 @@
+################################################################################
+#
+# hare-xml
+#
+################################################################################
+
+HARE_XML_VERSION = 0.25.2.0
+HARE_XML_SITE_METHOD = git
+HARE_XML_SITE = https://git.sr.ht/~sircmpwn/hare-xml
+HARE_XML_LICENSE = MPL-2.0
+HARE_XML_LICENSE_FILES = COPYING
+HARE_XML_INSTALL_STAGING = YES
+
+$(eval $(hare-package))
--
2.43.0
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
^ permalink raw reply related [flat|nested] 12+ messages in thread* [Buildroot] [PATCH v2 8/8] package/hare-dbus: new package
2026-07-20 15:02 [Buildroot] [PATCH v2 0/8] support Hare language Francois Perrad
` (6 preceding siblings ...)
2026-07-20 15:02 ` [Buildroot] [PATCH v2 7/8] package/hare-xml: " Francois Perrad
@ 2026-07-20 15:02 ` Francois Perrad
7 siblings, 0 replies; 12+ messages in thread
From: Francois Perrad @ 2026-07-20 15:02 UTC (permalink / raw)
To: buildroot; +Cc: Francois Perrad
Signed-off-by: Francois Perrad <francois.perrad@gadz.org>
---
package/Config.in | 1 +
package/hare-dbus/0001-fix-Makefile.patch | 26 +++++++++++++++++++++++
package/hare-dbus/Config.in | 10 +++++++++
package/hare-dbus/hare-dbus.hash | 3 +++
package/hare-dbus/hare-dbus.mk | 15 +++++++++++++
5 files changed, 55 insertions(+)
create mode 100644 package/hare-dbus/0001-fix-Makefile.patch
create mode 100644 package/hare-dbus/Config.in
create mode 100644 package/hare-dbus/hare-dbus.hash
create mode 100644 package/hare-dbus/hare-dbus.mk
diff --git a/package/Config.in b/package/Config.in
index 1d0dac96c..aa8818ce7 100644
--- a/package/Config.in
+++ b/package/Config.in
@@ -511,6 +511,7 @@ endmenu
source "package/gpsd/Config.in"
source "package/gptfdisk/Config.in"
source "package/gvfs/Config.in"
+ source "package/hare-dbus/Config.in"
source "package/hddtemp/Config.in"
source "package/hdparm/Config.in"
source "package/hwdata/Config.in"
diff --git a/package/hare-dbus/0001-fix-Makefile.patch b/package/hare-dbus/0001-fix-Makefile.patch
new file mode 100644
index 000000000..1250d89b0
--- /dev/null
+++ b/package/hare-dbus/0001-fix-Makefile.patch
@@ -0,0 +1,26 @@
+From 93abfa5970937253ae73bc8bcd9e243d890484a9 Mon Sep 17 00:00:00 2001
+From: Francois Perrad <francois.perrad@gadz.org>
+Date: Fri, 15 May 2026 11:56:39 +0200
+Subject: [PATCH] fix Makefile
+
+Signed-off-by: Francois Perrad <francois.perrad@gadz.org>
+---
+ Makefile | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/Makefile b/Makefile
+index a738e6a..8c4fe78 100644
+--- a/Makefile
++++ b/Makefile
+@@ -18,7 +18,7 @@ dbus-introspector:
+ dbus-scanner:
+ $(HARE) build $(HAREFLAGS) cmd/dbus-scanner/
+
+-install: build
++install:
+ install -Dm755 dbus-introspector ${DESTDIR}${BINDIR}/dbus-introspector
+ install -Dm755 dbus-scanner ${DESTDIR}${BINDIR}/dbus-scanner
+ install -Dm644 dbus/protocol/*.ha -t $(DESTDIR)$(THIRDPARTYDIR)/dbus/protocol
+--
+2.43.0
+
diff --git a/package/hare-dbus/Config.in b/package/hare-dbus/Config.in
new file mode 100644
index 000000000..63f332cbf
--- /dev/null
+++ b/package/hare-dbus/Config.in
@@ -0,0 +1,10 @@
+config BR2_PACKAGE_HARE_DBUS
+ bool "hare-dbus"
+ depends on BR2_PACKAGE_HOST_HARE_TARGET_ARCH_SUPPORTS
+ select BR2_PACKAGE_HOST_HARE
+ select BR2_PACKAGE_HARE_EV
+ select BR2_PACKAGE_HARE_XML
+ help
+ D-Bus client implementation for Hare.
+
+ https://git.sr.ht/~whynothugo/hare-dbus
diff --git a/package/hare-dbus/hare-dbus.hash b/package/hare-dbus/hare-dbus.hash
new file mode 100644
index 000000000..e8abc40e4
--- /dev/null
+++ b/package/hare-dbus/hare-dbus.hash
@@ -0,0 +1,3 @@
+# Locally computed
+sha256 67a3041126f7745e667d570904504a58475ca398acdd679b548d9e0e513092f8 hare-dbus-e9a89f8bc5ce783fa25f0eb67d7d8932db90bcc2-git4.tar.gz
+sha256 7c77ea8fa77851b9ee52d715ec6a3c5f15604bdab5148dd13dbd1dd345752017 LICENCE
diff --git a/package/hare-dbus/hare-dbus.mk b/package/hare-dbus/hare-dbus.mk
new file mode 100644
index 000000000..93d2a688f
--- /dev/null
+++ b/package/hare-dbus/hare-dbus.mk
@@ -0,0 +1,15 @@
+################################################################################
+#
+# hare-dbus
+#
+################################################################################
+
+HARE_DBUS_VERSION = e9a89f8bc5ce783fa25f0eb67d7d8932db90bcc2
+HARE_DBUS_SITE_METHOD = git
+HARE_DBUS_SITE = https://git.sr.ht/~whynothugo/hare-dbus
+HARE_DBUS_LICENSE = MIT
+HARE_DBUS_LICENSE_FILES = LICENCE
+HARE_DBUS_INSTALL_STAGING = YES
+HARE_DBUS_DEPENDENCIES = hare-ev hare-xml
+
+$(eval $(hare-package))
--
2.43.0
_______________________________________________
buildroot mailing list
buildroot@buildroot.org
https://lists.buildroot.org/mailman/listinfo/buildroot
^ permalink raw reply related [flat|nested] 12+ messages in thread