From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mp0.migadu.com ([2001:41d0:403:4876::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by ms1.migadu.com with LMTPS id +MGPH+5FP2b6OQEAqHPOHw:P1 (envelope-from ) for ; Sat, 11 May 2024 12:18:22 +0200 Received: from aspmx1.migadu.com ([2001:41d0:403:4876::]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) by mp0.migadu.com with LMTPS id +MGPH+5FP2b6OQEAqHPOHw (envelope-from ) for ; Sat, 11 May 2024 12:18:22 +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=E6FsJBbd; 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"; dmarc=none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=yhetil.org; s=key1; t=1715422702; 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=ow8so5FLlkHHropNDoEiMLOFYC7VnzxTTDJvrXzKqjyzTQHYcoG1RBKZJXRCmYLy3AKxHl pX8iSGi3QxHyPfFn0l5f55TL5Gx9YnEBVZmSym54dqDsTM1QOuVbVaHr23/+a6Uu3GHPie Ld3lt4aMNfTFx8u27B+9Ff8zXSzDV/3mmqhRTBSFDioBK57yq+kfN2JY6PrDio/BF5XPQK ODKJj22F4EDAdddvrpDgwc3hw0BXLayatRXv9zFr/HB3a1igsk8j+lIui8101XHATgFtyG zE1e+xnJdiU+vzWpRfFwxD7gzAa4X0PR1dOFFQwk5vtBahIbbwaFdLn77aUgyw== ARC-Authentication-Results: i=1; aspmx1.migadu.com; dkim=fail ("headers rsa verify failed") header.d=gmail.com header.s=20230601 header.b=E6FsJBbd; 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"; dmarc=none ARC-Seal: i=1; s=key1; d=yhetil.org; t=1715422702; a=rsa-sha256; cv=none; b=WGBHfnJtGStWs/1of0StqcQUdAElfl0ClS9gWv19U47/DiZB4kqozChCuucKx5SuXhVL8N 2l4S2kS5kA/o4GpyEKeV4bLsUmkWWITzev8EvBayJfBGIxYBsMf4W1ROTycd2SD3/ed3qF P4Xsy7BpX7BfvOn365d5RC0iOfhkpdgJV5hID+A5LyYJLbjZUJ/mhwjvibqCdQajD1w6CW etos/SdmjydeZ66GkTu8b/6/fzd0sGIXansD/kQ9o711bT/6Sfs/pFdqOydXP1QcEsUmLY jDATNQoJpYqrAQ28dgLsI85Olho0lSBs4Zvc0FK3z9w9QFmHIkap1dTDcET5qg== 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 2B9C724C8D for ; Sat, 11 May 2024 12:18:22 +0200 (CEST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1s5jnp-0004ek-UO; Sat, 11 May 2024 06:18:05 -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 1s5jnn-0004eK-W9 for guix-patches@gnu.org; Sat, 11 May 2024 06:18:04 -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 1s5jnn-0003A4-O9 for guix-patches@gnu.org; Sat, 11 May 2024 06:18:03 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1s5jnm-00020p-H2 for guix-patches@gnu.org; Sat, 11 May 2024 06:18:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#70875] [PATCH v2] gnu: Add quirrel References: In-Reply-To: Resent-From: Andy Tai Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Sat, 11 May 2024 10:18:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 70875 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 70875@debbugs.gnu.org Cc: Andy Tai Received: via spool by 70875-submit@debbugs.gnu.org id=B70875.17154226647724 (code B ref 70875); Sat, 11 May 2024 10:18:02 +0000 Received: (at 70875) by debbugs.gnu.org; 11 May 2024 10:17:44 +0000 Received: from localhost ([127.0.0.1]:47547 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1s5jnT-00020W-Ex for submit@debbugs.gnu.org; Sat, 11 May 2024 06:17:43 -0400 Received: from mail-pl1-f172.google.com ([209.85.214.172]:56713) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1s5jnR-00020P-Hl for 70875@debbugs.gnu.org; Sat, 11 May 2024 06:17:42 -0400 Received: by mail-pl1-f172.google.com with SMTP id d9443c01a7336-1e83a2a4f2cso17339085ad.1 for <70875@debbugs.gnu.org>; Sat, 11 May 2024 03:17:42 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1715422596; x=1716027396; 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=E6FsJBbdPLyKJzNr2xEPh3lBkrmSjerGUj15Gsqsvq+/jgoolYRXdMCycsPvCgCaBp 8OFQ+GTCb7VT2ts+jrijUArEr/DKsYNGMX4pnwb9fkDp7JiKHllKItzb9+vSg1LaFILO +NerbWvkfr+zBI3TeIIGJ7GPLf7k7zhE4oWQkLRZSPBXFbh95GvTZ3Tsok5a+ZxLTZh2 ih9KvsgqVHwtJPhfjK8kZSb0V+uHtuw8TdxIyv+oPKiO0cQArcE3xUZbV7LyucSyt/y+ xFWy+aLXF/uGiDteYtqKRpbcDqobT7a/fnBuQnJ+MJ0Prh8Sht+IbJBPg5iqxPpKqfBS F++Q== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1715422596; x=1716027396; 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=Blt21JLmpFXxC0ZIeWuP3JDFb4wGHEDl30zgR75ujQyklnnZKGlF3J0xn21P8kjbGf yh/XuruC8CjH/e22zM1WH2NLHlmRgZgrcY9xSxfMgKslL9HsdAcrtRgum7WBUwy++XsX ksD2+hFpgRxWmFQsJIfVtuVw3OaKqZ2rO91ozKBjr5r6SQc8xrbzBhR75IAVFMdw+ROS oyitpwYJLDNjpQzDsjRGhWSKzVhEx8KoEgXu4EAjeh55Aakm8soitUKWtIHlXSNlY1HD cYmRTbJEq0Qxp3UBZ+eDBP3WFQzJoBuRFYLdMQtbNIIufstJLul86sCIMrRPcqwG/8w7 WxNw== X-Gm-Message-State: AOJu0YyOxWmaMrdHz5VkQvNprPr/sYGJL3hFUjuYxhO6yhkIVXWUawCA ErqNprNK8uv90sqX/kxE0T5gNOHOD9soEFvPjCJw9aIFSQL2b+R9d2MHfA== X-Google-Smtp-Source: AGHT+IExS4pyRZJIFTgJc/AF64jj3OdACjU0CXGq+2EpDVghTOgjFzSSNi9zE4nfTF7vNN1AXxmtBQ== X-Received: by 2002:a17:902:dace:b0:1dd:81a3:8dc3 with SMTP id d9443c01a7336-1ef4404a1cfmr61082395ad.46.1715422596039; Sat, 11 May 2024 03:16:36 -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 d9443c01a7336-1ef0c035d0esm45905425ad.189.2024.05.11.03.16.35 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sat, 11 May 2024 03:16:35 -0700 (PDT) From: Andy Tai Date: Sat, 11 May 2024 03:16:31 -0700 Message-Id: <129aa222dbae82ff4e2fc85f32a56b6405a63b12.1715422522.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-Country: US X-Migadu-Flow: FLOW_IN X-Spam-Score: -1.38 X-Migadu-Queue-Id: 2B9C724C8D X-Migadu-Scanner: mx10.migadu.com X-Migadu-Spam-Score: -1.38 X-TUID: Xnh+rLl9HTor * 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