From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp0.migadu.com ([2001:41d0:403:58f0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms1.migadu.com with LMTPS id GINuHlikP2b2cAAAqHPOHw:P1 (envelope-from ) for ; Sat, 11 May 2024 19:01:12 +0200 Received: from aspmx1.migadu.com ([2001:41d0:403:58f0::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp0.migadu.com with LMTPS id GINuHlikP2b2cAAAqHPOHw (envelope-from ) for ; Sat, 11 May 2024 19:01:12 +0200 X-Envelope-To: larch@yhetil.org Authentication-Results: aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=gmail.com header.s=20230601 header.b=VwbjlwLW; dmarc=none; spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org" ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1715446872; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding:resent-cc: resent-from:resent-sender:resent-message-id:in-reply-to:in-reply-to: references:references:list-id:list-help:list-unsubscribe: list-subscribe:list-post:dkim-signature; bh=6rLSrPepdd4nBb2Xz3fHr9DOBDG1RY5CmVTM2rNDteY=; b=X61Bc3VFlOWeT9F3qsC1hUcSvHfM1pi5MhsXSf39Dd45WQRs6oYnbGGmJO1BQtQHOm793W xK49sayrsXHGTlMQGEJY0vOzziO43wNVPEo1C+ZgytvTV3df+01R2c7kxwQyxutPvqs5HP rfKeQV8n0TKT3DjcxGoIl2IgFCYjxOc50VX8L02aomXk8wgqJzJ7I/JAE936WGD2m1DvJQ 800YPziazF7MiKbMH7Sm+nY89XICXKSQYsewF2ehcppmD+tE0osYDRqQVgnkdUVklHZOO6 8z7AbbF+ogRcXf6begDaHhJiN1uJj9k/p334v6C80IT0D9+smkWGVzWUEVtMvA== ARC-Seal: i=1; s=key1; d=yhetil.org; t=1715446872; a=rsa-sha256; cv=none; b=LGck/03S9OIRtHgNxtwHSW1vK5+pmH6ixiI5cXGhBCJY3PAgqwnD0F8tS1ZXdCnBZjgMUm tbWVvDWAgO37vebzimTIr+qLVef48pSHuj524DZeMA1F7QT+XitRM6PmW6LOoaODePpDXa VpZ7g9ioOle0kd12ryW24grQmKiw8XN80yxgIW2xieeAMvrMHwK/s/MmCR7crv5T3PuVUR ywZWhorcKoh8Ib+b2OAEc8LwCGQO10SuiAbD8Eod7e9InBC98bgNcR895snjlVPtGRjR9c idfDUUiWnhREmsgCmc79LVcPvn1qTfMTBUuMkxu8GAjpheck5PeNv1D/k74oPA== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=gmail.com header.s=20230601 header.b=VwbjlwLW; dmarc=none; spf=pass (aspmx1.migadu.com: domain of "guix-patches-bounces+larch=yhetil.org@gnu.org" designates 209.51.188.17 as permitted sender) smtp.mailfrom="guix-patches-bounces+larch=yhetil.org@gnu.org" Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by aspmx1.migadu.com (Postfix) with ESMTPS id 0FB5B3F309 for ; Sat, 11 May 2024 19:01:12 +0200 (CEST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1s5q5o-0003bZ-CJ; Sat, 11 May 2024 13:01:04 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1s5q5n-0003az-07 for guix-patches@gnu.org; Sat, 11 May 2024 13:01:03 -0400 Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1s5q5m-0003gn-O3 for guix-patches@gnu.org; Sat, 11 May 2024 13:01:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1s5q5l-0003Vt-UP for guix-patches@gnu.org; Sat, 11 May 2024 13:01:01 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#62891] [PATCH v2] gnu: Add quirrel References: <20230417001037.6464-1-atai@atai.org> In-Reply-To: <20230417001037.6464-1-atai@atai.org> Resent-From: Andy Tai Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Sat, 11 May 2024 17:01:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 62891 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 62891@debbugs.gnu.org Cc: Andy Tai Received: via spool by 62891-submit@debbugs.gnu.org id=B62891.171544685612712 (code B ref 62891); Sat, 11 May 2024 17:01:01 +0000 Received: (at 62891) by debbugs.gnu.org; 11 May 2024 17:00:56 +0000 Received: from localhost ([127.0.0.1]:49313 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1s5q5f-0003Ht-TS for submit@debbugs.gnu.org; Sat, 11 May 2024 13:00:56 -0400 Received: from mail-oa1-f45.google.com ([209.85.160.45]:50189) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1s5q5d-0002zw-Aw for 62891@debbugs.gnu.org; Sat, 11 May 2024 13:00:54 -0400 Received: by mail-oa1-f45.google.com with SMTP id 586e51a60fabf-23d1c4c14ceso2028720fac.0 for <62891@debbugs.gnu.org>; Sat, 11 May 2024 10:00:53 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1715446788; x=1716051588; darn=debbugs.gnu.org; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:sender:from:to:cc:subject:date:message-id:reply-to; bh=6rLSrPepdd4nBb2Xz3fHr9DOBDG1RY5CmVTM2rNDteY=; b=VwbjlwLW1NMlE8UmKVHMAbT0ZV0YSZLOkISW3Apn7i4QubAe62t3aZeekVDd5iKjZi m54psXbYWp/LUA52Z/ldoyGXMuq8nbz1BdYKgy7W71oyAensRv9rEHY8+O5hEK3D5+68 2dvlWK5hXH7EHLZFQAm1Oi5phHdDR7eyo1juCCPMfoJtbD5pZp0wcFLdr9ScOXZYmJ2W O1nNqV508PSom+/JhVy3UzqSNPCM9moeUFuBla4691qNmza8oAoRVpJCgO9az7iqW2f7 yjgk1nPernidmh0+dalm+lKOCfv77v6q2ILCqRrq1Z5/SOH1kH9Yxq0/N3HDxLPltsg8 np9Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1715446788; x=1716051588; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:sender:x-gm-message-state:from:to:cc:subject:date :message-id:reply-to; bh=6rLSrPepdd4nBb2Xz3fHr9DOBDG1RY5CmVTM2rNDteY=; b=hbJOBW0MD9Ximomi/m5PfNU8zpRKbO93V1Q5qWk0OB3W5JN2k4fFnm95VDuYJ9u7DC F0wIWjzyDih3dx0w3LfGbgn73bswnaDMWCAI2MkLm+V39b7P8S7/Kbuec+uG77yKDlmT zeGyvwX38oHdfge28VFFR7+5JqsFznxgdPXgTDLBolLHZr2H6wQ6s303oKLvR5g51OF8 3Mi3egpCSd3N3VTaFwX48NEQdZeSwSsbLyNND3iiMNcI6J920pIg50HY+c5FQja9Feux cvHB0ReCEBTLqVPfW5GhG8WqAXoARCcINsLLljj1DAKRhRYqjvzLW6oQDrOOIJa4FpNk j3jA== X-Gm-Message-State: AOJu0YwiV1zyi2e9ToTAOpY+27ZiD8JEP8q1608uX0i/G0Op7daEknXt +8friADlElVW1wjFubQrBL/q2wjpbGcqelHc6OcLQG3QpghQxBzJrohyWQ== X-Google-Smtp-Source: AGHT+IHywDYJdwaaGNaPkBbLi4Ry3MwUv9MacV57pmcislCH/tcLdVXjNk1SZVfj20dDsPQ8eE8nQQ== X-Received: by 2002:a05:6870:d1c6:b0:23c:43d5:6025 with SMTP id 586e51a60fabf-24172e2ec4cmr6501912fac.46.1715446787683; Sat, 11 May 2024 09:59:47 -0700 (PDT) Received: from DEskMiniX300.. (c-98-37-226-154.hsd1.ca.comcast.net. [98.37.226.154]) by smtp.gmail.com with ESMTPSA id d2e1a72fcca58-6f4d2ae0d88sm4667337b3a.122.2024.05.11.09.59.46 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 11 May 2024 09:59:46 -0700 (PDT) From: Andy Tai Date: Sat, 11 May 2024 09:59:43 -0700 Message-Id: <129aa222dbae82ff4e2fc85f32a56b6405a63b12.1715446743.git.atai@atai.org> X-Mailer: git-send-email 2.34.1 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+larch=yhetil.org@gnu.org Sender: guix-patches-bounces+larch=yhetil.org@gnu.org X-Migadu-Flow: FLOW_IN X-Migadu-Country: US X-Migadu-Spam-Score: -1.38 X-Spam-Score: -1.38 X-Migadu-Queue-Id: 0FB5B3F309 X-Migadu-Scanner: mx11.migadu.com X-TUID: q7vLG5CkhOvK * gnu/packages/squirrel.scm (quirrel): New variable Change-Id: I3b25604f7c5cc4f046a6421810e3928d5c5ba276 --- gnu/packages/squirrel.scm | 64 ++++++++++++++++++++++++++++++++++++++- 1 file changed, 63 insertions(+), 1 deletion(-) diff --git a/gnu/packages/squirrel.scm b/gnu/packages/squirrel.scm index 1b9489882f..638f06ab8f 100644 --- a/gnu/packages/squirrel.scm +++ b/gnu/packages/squirrel.scm @@ -1,5 +1,5 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2019 Li-cheng (Andy) Tai +;;; Copyright © 2019, 2023 Li-Cheng (Andy) Tai ;; ;;; This file is part of GNU Guix. ;;; @@ -22,6 +22,7 @@ (define-module (gnu packages squirrel) #:use-module (gnu packages sphinx) #:use-module (guix build-system cmake) #:use-module (guix download) + #:use-module (guix git-download) #:use-module ((guix licenses) #:prefix license:) #:use-module (guix build utils) #:use-module (guix packages) @@ -81,3 +82,64 @@ (define-public squirrel size, memory bandwidth, and real-time requirements of applications like video games.") (license license:expat))) + + + +(define-public quirrel + (package + (name "quirrel") + (version "4.6.0") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/GaijinEntertainment/quirrel.git") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "18xvhssnh5lddi4ava7wzzvsiin8rh3vrbhcblv7l00qv0brh6gg")))) + (build-system cmake-build-system) + (arguments + '(#:configure-flags '("-DDISABLE_STATIC=ON") + #:tests? #f ;no tests + #:phases (modify-phases %standard-phases + ;; TODO: build and install doc files like squirrel above + (add-after 'install 'install-headers + (lambda* (#:key outputs #:allow-other-keys) + (let* ((out (assoc-ref outputs "out")) + (include-dir (string-append out "/include"))) + (mkdir-p include-dir) + (for-each (lambda (header-file) + (copy-recursively header-file + (string-append + include-dir "/" + (basename header-file)))) + (find-files "../include"))) #t))))) + (native-inputs `(("cmake" ,cmake-minimal) + ("python-sphinx" ,python-sphinx))) + (home-page "https://github.com/GaijinEntertainment/quirrel") + (synopsis "Script language that is based on Squirrel language and is +inspired by Python, Javascript and especially Lua") + (description + "Quirrel is a script language that is based on Squirrel language and is +inspired by Python, Javascript and especially Lua, with +@itemize +@item Lexical scoping +@item Higher order functions, closures and lambda +@item Classes and inheritance +@item Tail recursion +@item Delegation +@item String interpolation +@item Exception handling +@item Cooperative threads (coroutines) +@item Generators +@item Performance - Quirrel is fast and small (comparable with Lua and sometimes even faster) +@item Both compiler and virtual machine fit together in about 13k lines of C++ code and add only around 100kb-150kb the executable size. +@item Automatic memory management (CPU bursts free - reference counting and GC) +@item Optional 16bits characters strings +@item Dynamic typing type system is close to Javascript but stricter and simpler (there is integer type and no 'undefined') +@item Powerful embedding api +@item Modules +@item Hot-reload (if you implement it in your code) +@end itemize") + (license license:expat))) base-commit: 703ae431f4ad28658e34675310b4fdf58685ccdd -- 2.34.1