[PATCH] gnu: Add wasmedge.

  • Open
  • quality assurance status badge
Details
3 participants
  • Ludovic Courtès
  • Sharlatan Hellseher
  • Zheng Junjie
Owner
unassigned
Submitted by
Zheng Junjie
Severity
normal

Debbugs page

Z
Z
Zheng Junjie wrote on 3 Feb 09:26 -0800
(address . guix-patches@gnu.org)
b9abfd65f5c4f23adfc4bc48fe006de523525fd3.1706981201.git.zhengjunjie@iscas.ac.cn
* gnu/packages/web.scm (wasmedge): New variable.

Change-Id: I62a5bbe0e228f0b743bee4d55c4948c61bbfc969
---
gnu/packages/web.scm | 34 ++++++++++++++++++++++++++++++++++
1 file changed, 34 insertions(+)

Toggle diff (63 lines)
diff --git a/gnu/packages/web.scm b/gnu/packages/web.scm
index 1a97dd8dec..194b7ac02a 100644
--- a/gnu/packages/web.scm
+++ b/gnu/packages/web.scm
@@ -66,6 +66,7 @@
;;; Copyright © 2023 Felix Lechner <felix.lechner@lease-up.com>
;;; Copyright © 2023 Evgeny Pisemsky <evgeny@pisemsky.com>
;;; Copyright © 2024 Tomas Volf <~@wolfsden.cz>
+;;; Copyright © 2024 Zheng Junjie <873216071@qq.com>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -165,6 +166,8 @@ (define-module (gnu packages web)
#:use-module (gnu packages lisp-xyz)
#:use-module (gnu packages lsof)
#:use-module (gnu packages lua)
+ #:use-module (gnu packages llvm)
+ #:use-module (gnu packages logging)
#:use-module (gnu packages mail)
#:use-module (gnu packages man)
#:use-module (gnu packages markup)
@@ -1774,6 +1777,37 @@ (define-public wasm-micro-runtime
features.")
(license license:asl2.0)))
+
+(define-public wasmedge
+ (package
+ (name "wasmedge")
+ (version "0.13.5")
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/WasmEdge/WasmEdge")
+ (commit version)))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32 "1l5rr0rma6n17d2khgac79azqjc9sl3r0vljjzc1aw9hhalmm895"))))
+ (build-system cmake-build-system)
+ (native-inputs (list googletest))
+ (inputs (list llvm-17 lld-17 spdlog))
+ (arguments
+ (list
+ ;; TODO: enable test
+ ;; #:configure-flags #~(list "-DWASMEDGE_BUILD_TESTS=ON")
+ #:tests? #f))
+ (home-page "https://wasmedge.org/")
+ (synopsis "High performance WebAssembly Virtual Machine")
+ (description
+ "WasmEdge is a lightweight, high-performance, and extensible
+WebAssembly runtime for cloud native, edge, and decentralized applications.
+It powers serverless apps, embedded functions, microservices, smart contracts,
+and IoT devices.")
+ (license (list license:asl2.0 license:cc0))))
+
(define-public websocketpp
(package
(name "websocketpp")

base-commit: 179bb57d2532ee6b81791e078b0f782cbf88cb84
--
2.41.0
S
S
Sharlatan Hellseher wrote on 19 Feb 11:44 -0800
(address . 68910@debbugs.gnu.org)
CAO+9K5rw1G=hhnUH7sGyV6pofy-nqnepVWOPWMrTJnTvFU=xGw@mail.gmail.com
Hi,

Thank you for the patch.

QA is green.

May you provide more info if you try to enable tests and which
issues you could not resolve?

Thanks,
Oleg
Attachment: file
S
L
L
Ludovic Courtès wrote on 27 Feb 02:22 -0800
control message for bug #68910
(address . control@debbugs.gnu.org)
875xyai4uo.fsf@gnu.org
tags 68910 + moreinfo
quit
Z
Z
Zheng Junjie wrote on 1 Mar 06:04 -0800
[PATCH v2] gnu: Add wasmedge.
(address . 68910@debbugs.gnu.org)
269d25747a9d357c48912fb73dd1197022033c76.1709301898.git.zhengjunjie@iscas.ac.cn
* gnu/packages/web.scm (wasmedge): New variable.

Change-Id: I62a5bbe0e228f0b743bee4d55c4948c61bbfc969
---
gnu/packages/web.scm | 58 ++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 58 insertions(+)

Toggle diff (87 lines)
diff --git a/gnu/packages/web.scm b/gnu/packages/web.scm
index 9ded719e71..fae562d3e8 100644
--- a/gnu/packages/web.scm
+++ b/gnu/packages/web.scm
@@ -66,6 +66,7 @@
;;; Copyright © 2023 Felix Lechner <felix.lechner@lease-up.com>
;;; Copyright © 2023 Evgeny Pisemsky <evgeny@pisemsky.com>
;;; Copyright © 2024 Tomas Volf <~@wolfsden.cz>
+;;; Copyright © 2024 Zheng Junjie <873216071@qq.com>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -171,6 +172,8 @@ (define-module (gnu packages web)
#:use-module (gnu packages lisp-xyz)
#:use-module (gnu packages lsof)
#:use-module (gnu packages lua)
+ #:use-module (gnu packages llvm)
+ #:use-module (gnu packages logging)
#:use-module (gnu packages mail)
#:use-module (gnu packages man)
#:use-module (gnu packages markup)
@@ -1782,6 +1785,61 @@ (define-public wasm-micro-runtime
features.")
(license license:asl2.0)))
+
+(define wasmedge-unittest
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/second-state/WasmEdge-unittest")
+ (commit "wasm-dev-0.13.0")))
+ (file-name
+ (git-file-name "WasmEdge-unittest" "wasm-dev-0.13.0"))
+ (sha256
+ (base32
+ "05nbwci836g0fr7p90v0p94166j7hbxhcw996xv20pywwblf73vl"))))
+
+(define-public wasmedge
+ (package
+ (name "wasmedge")
+ (version "0.13.5")
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/WasmEdge/WasmEdge")
+ (commit version)))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32 "1l5rr0rma6n17d2khgac79azqjc9sl3r0vljjzc1aw9hhalmm895"))))
+ (build-system cmake-build-system)
+ (native-inputs (list googletest simdjson))
+ (inputs (list llvm-17 lld-17 spdlog))
+ (arguments
+ (list
+ #:configure-flags #~(list "-DWASMEDGE_BUILD_TESTS=ON")
+ #:phases
+ #~(modify-phases %standard-phases
+ (add-before 'configure 'unpack-unittest
+ (lambda _
+ (substitute* "test/spec/CMakeLists.txt"
+ (("GIT_REPOSITORY https://github.com/second-state/WasmEdge-unittest")
+ (string-append "URL file://" #$wasmedge-unittest))
+ (("GIT_TAG.*") ""))))
+ (add-before 'configure 'disable-test
+ (lambda _
+ ;; this test require network
+ (substitute* "test/host/socket/CMakeLists.txt"
+ (("add_test\\(wasiSocketTests wasiSocketTests\\)")
+ "")))))))
+ (home-page "https://wasmedge.org/")
+ (synopsis "High performance WebAssembly Virtual Machine")
+ (description
+ "WasmEdge is a lightweight, high-performance, and extensible
+WebAssembly runtime for cloud native, edge, and decentralized applications.
+It powers serverless apps, embedded functions, microservices, smart contracts,
+and IoT devices.")
+ (license (list license:asl2.0 license:cc0))))
+
(define-public websocketpp
(package
(name "websocketpp")

base-commit: aeaa390b71a15335bef03f83bd9dc946fa535398
--
2.41.0
Z
Z
Zheng Junjie wrote on 2 Mar 02:12 -0800
[PATCH] gnu: Add wasmedge.
(address . 68910@debbugs.gnu.org)
47e53db905ed88fb653243b423528b1af0e358de.1709374240.git.zhengjunjie@iscas.ac.cn
* gnu/packages/web.scm (wasmedge): New variable.

Change-Id: I62a5bbe0e228f0b743bee4d55c4948c61bbfc969
---
gnu/packages/web.scm | 64 ++++++++++++++++++++++++++++++++++++++++++++
1 file changed, 64 insertions(+)

Toggle diff (100 lines)
diff --git a/gnu/packages/web.scm b/gnu/packages/web.scm
index 9ded719e71..24947e2ee6 100644
--- a/gnu/packages/web.scm
+++ b/gnu/packages/web.scm
@@ -66,6 +66,7 @@
;;; Copyright © 2023 Felix Lechner <felix.lechner@lease-up.com>
;;; Copyright © 2023 Evgeny Pisemsky <evgeny@pisemsky.com>
;;; Copyright © 2024 Tomas Volf <~@wolfsden.cz>
+;;; Copyright © 2024 Zheng Junjie <873216071@qq.com>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -164,6 +165,7 @@ (define-module (gnu packages web)
#:use-module (gnu packages kerberos)
#:use-module (gnu packages libbsd)
#:use-module (gnu packages libevent)
+ #:use-module (gnu packages libffi)
#:use-module (gnu packages libidn)
#:use-module (gnu packages libunistring)
#:use-module (gnu packages libunwind)
@@ -171,6 +173,8 @@ (define-module (gnu packages web)
#:use-module (gnu packages lisp-xyz)
#:use-module (gnu packages lsof)
#:use-module (gnu packages lua)
+ #:use-module (gnu packages llvm)
+ #:use-module (gnu packages logging)
#:use-module (gnu packages mail)
#:use-module (gnu packages man)
#:use-module (gnu packages markup)
@@ -1782,6 +1786,66 @@ (define-public wasm-micro-runtime
features.")
(license license:asl2.0)))
+
+(define wasmedge-unittest
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/second-state/WasmEdge-unittest")
+ (commit "wasm-dev-0.13.0")))
+ (file-name
+ (git-file-name "WasmEdge-unittest" "wasm-dev-0.13.0"))
+ (sha256
+ (base32
+ "05nbwci836g0fr7p90v0p94166j7hbxhcw996xv20pywwblf73vl"))))
+
+(define-public wasmedge
+ (package
+ (name "wasmedge")
+ (version "0.13.5")
+ (source
+ (origin
+ (method git-fetch)
+ (uri (git-reference
+ (url "https://github.com/WasmEdge/WasmEdge")
+ (commit version)))
+ (file-name (git-file-name name version))
+ (sha256
+ (base32 "1l5rr0rma6n17d2khgac79azqjc9sl3r0vljjzc1aw9hhalmm895"))))
+ (build-system cmake-build-system)
+ (native-inputs (list googletest simdjson pkg-config))
+ (inputs (list llvm-17 lld-17 spdlog libffi))
+ (arguments
+ (list
+ #:configure-flags #~(list "-DWASMEDGE_BUILD_TESTS=ON")
+ #:phases
+ #~(modify-phases %standard-phases
+ (add-after 'unpack 'set-VERSION
+ (lambda _
+ (call-with-output-file "VERSION"
+ (lambda (port)
+ (format port "~a" #$version)))))
+ (add-before 'configure 'unpack-unittest
+ (lambda _
+ (substitute* "test/spec/CMakeLists.txt"
+ (("GIT_REPOSITORY https://github.com/second-state/WasmEdge-unittest")
+ (string-append "URL file://" #$wasmedge-unittest))
+ (("GIT_TAG.*") ""))))
+ (add-before 'configure 'disable-test
+ (lambda _
+ ;; this test require network
+ (substitute* "test/host/socket/CMakeLists.txt"
+ (("add_test\\(wasiSocketTests wasiSocketTests\\)")
+ "")))))))
+ (home-page "https://wasmedge.org/")
+ (synopsis "High performance WebAssembly Virtual Machine")
+ (description
+ "WasmEdge is a lightweight, high-performance, and extensible
+WebAssembly runtime for cloud native, edge, and decentralized applications.
+It powers serverless apps, embedded functions, microservices, smart contracts,
+and IoT devices.")
+ (license (list license:asl2.0 license:cc0))))
+
(define-public websocketpp
(package
(name "websocketpp")

base-commit: aeaa390b71a15335bef03f83bd9dc946fa535398
--
2.41.0
Z
Z
Zheng Junjie wrote on 5 Sep 09:14 -0700
Re: [bug#68910] [PATCH v2] gnu: Add wasmedge.
(name . Zheng Junjie via Guix-patches)(address . guix-patches@gnu.org)(address . 68910@debbugs.gnu.org)
8734me2i37.fsf@iscas.ac.cn
ping
-----BEGIN PGP SIGNATURE-----

iQIzBAEBCgAdFiEEfr6klGDOXiwIdX/bO1qpk+Gi3/AFAmbZ2OwACgkQO1qpk+Gi
3/DWmA/+Ls0JDOZlfd+ivOK0Vn4fhvgWvfuEPaB9jDRZD627BNBFYOxs3/8prRVj
d6ihQ/d1Dy7wJicqi2D7MdMFOdZCvaSrb7/FN7A3iqA3P2EbLPvhSjVLCudFlc00
HLomqKzr+fNl/CrOSZzGHD95iKQdHmIdBlLTiRzeGJV7QEDGL1DozzQ4AR5Z4vBS
RyxbG67zvZYf61+UhWFHMwcVQMp9gB18oXtziYrP6klTLTqFIm/gvyMIgA1ah/P3
ni3jkaNW0k1UzQR+Os5rfuImPf/HBBrh5bdDN18//Z6dCHBM6m2ZceHCRAR3wjjC
bRulAeKsZ+USeNFXltRcPiexc9v68upZ2gHudf67rfhlUQUrk2lG2LAIPWLnYDSp
4Gl8BiItIgf1hAfNtP52Ek/nhb6875t4RWHjanJ6+uZ9/aT5DkvKLDMT9oCr0JpX
vYL3qlhHMHdZlGXmd8nPjfc4LmPgByl4useXTpENHGqR+JC6ciyUBex8ixBlhM6i
xsq2DBsCTKc/FTT59GPE3g4J2+9yYJocNVZLrC9Q92YyL9QG5iPsOuQNYodUkOLu
tjdYs1v6LKJG+S8fBm5LvPfzx42hVtm201QA8X/lt82CkipxenyOawKptBuBiR3u
IrGSyZJxCD3GngDAHcuDMLhZHcfK/mXS054Jf7SSQIWNrmagx2c=
=MoC6
-----END PGP SIGNATURE-----

?
Your comment

Commenting via the web interface is currently disabled.

To comment on this conversation send an email to 68910@patchwise.org

To respond to this issue using the mumi CLI, first switch to it
mumi current 68910
Then, you may apply the latest patchset in this issue (with sign off)
mumi am -- -s
Or, compose a reply to this issue
mumi compose
Or, send patches to this issue
mumi send-email *.patch