From patchwork Sun Aug 15 05:19:15 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Charles X-Patchwork-Id: 32118 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id 0D32927BC78; Sun, 15 Aug 2021 06:20:14 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.8 required=5.0 tests=BAYES_00,DKIM_SIGNED, FREEMAIL_FROM,HTML_MESSAGE,MAILING_LIST_MULTI,RCVD_IN_MSPIKE_H2, SPF_HELO_PASS,T_DKIM_INVALID,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.2 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id 8A16D27BC6B for ; Sun, 15 Aug 2021 06:20:13 +0100 (BST) Received: from localhost ([::1]:43170 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1mF8ZA-00017l-EG for patchwork@mira.cbaines.net; Sun, 15 Aug 2021 01:20:12 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:59352) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mF8Z0-00017b-76 for guix-patches@gnu.org; Sun, 15 Aug 2021 01:20:02 -0400 Received: from debbugs.gnu.org ([209.51.188.43]:34048) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1mF8Z0-0000dN-02 for guix-patches@gnu.org; Sun, 15 Aug 2021 01:20:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1mF8Yz-0008A0-P3 for guix-patches@gnu.org; Sun, 15 Aug 2021 01:20:01 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#50062] Add cl-yxorp-cli Resent-From: Charles Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Sun, 15 Aug 2021 05:20:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 50062 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: To: 50062@debbugs.gnu.org X-Debbugs-Original-To: "guix-patches@gnu.org" Received: via spool by submit@debbugs.gnu.org id=B.162900478031332 (code B ref -1); Sun, 15 Aug 2021 05:20:01 +0000 Received: (at submit) by debbugs.gnu.org; 15 Aug 2021 05:19:40 +0000 Received: from localhost ([127.0.0.1]:45594 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mF8Ya-00089D-Pb for submit@debbugs.gnu.org; Sun, 15 Aug 2021 01:19:40 -0400 Received: from lists.gnu.org ([209.51.188.17]:58904) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1mF8YV-000891-QC for submit@debbugs.gnu.org; Sun, 15 Aug 2021 01:19:35 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:59330) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mF8YV-00015w-AT for guix-patches@gnu.org; Sun, 15 Aug 2021 01:19:31 -0400 Received: from mail-40135.protonmail.ch ([185.70.40.135]:46777) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1mF8YS-0008VU-GA for guix-patches@gnu.org; Sun, 15 Aug 2021 01:19:30 -0400 Date: Sun, 15 Aug 2021 05:19:15 +0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=protonmail.com; s=protonmail; t=1629004757; bh=Hv5DP7pPAI1W45jbjS/vQRbZp1ZeKWkLHfYnceNuQhs=; h=Date:To:From:Reply-To:Subject:From; b=Ubp8zkCMm4FDhGd4qUdFBUqgVZTOkrMJM8y7iPXIj5Olpbv35Z4qa2EWyNIK4YJEK r1460VN3hGtv9380KZFqu6+CIULtdSCPius4iGrQicKIMvj6cIxwq6aGDo05Cd0XFf nrRW3Iq+byP1yA6VFU8CHhONdTUvO1nvb8290i18= Message-ID: MIME-Version: 1.0 Received-SPF: pass client-ip=185.70.40.135; envelope-from=charles.b.jackson@protonmail.com; helo=mail-40135.protonmail.ch X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, HTML_MESSAGE=0.001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action 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+patchwork=mira.cbaines.net@gnu.org Sender: "Guix-patches" Reply-to: Charles X-ACL-Warn: , Charles via Guix-patches X-Patchwork-Original-From: Charles via Guix-patches via From: Charles X-getmail-retrieved-from-mailbox: Patches let me know if something is wrong or could be better: thanks. From f7273b53facac11165e91af80a182837a85c064a Mon Sep 17 00:00:00 2001 From: Charles Date: Sat, 14 Aug 2021 23:54:03 -0500 Subject: [PATCH] gnu: Add cl-yxorp-cli. * gnu/packages/lisp-xyz.scm (sbcl-yxorp, ecl-yxorp, cl-yxorp): New variables. * gnu/packages/web.scm (cl-yxorp-cli): New variable. --- gnu/packages/lisp-xyz.scm | 41 +++++++++++++++++++++++++++++++++++++++ gnu/packages/web.scm | 34 ++++++++++++++++++++++++++++++++ 2 files changed, 75 insertions(+) diff --git a/gnu/packages/lisp-xyz.scm b/gnu/packages/lisp-xyz.scm index 38cc7d6695..e88f920ec2 100644 --- a/gnu/packages/lisp-xyz.scm +++ b/gnu/packages/lisp-xyz.scm @@ -18243,6 +18243,47 @@ functions allow Lisp programs to explore the web.") (define-public cl-aserve (sbcl-package->cl-source-package sbcl-aserve)) +(define-public sbcl-yxorp + (let ((commit "d2e8f9304549e47ae5c7fa35a6b114804603eac9") + (revision "1")) + (package + (name "sbcl-yxorp") + (version (git-version "0" revision commit)) + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/charJe/cl-yxorp") + (commit commit))) + (file-name (git-file-name "cl-yxorp" version)) + (sha256 + (base32 "1zz1j678vzwkf817h2z0pf0fcyf4mldv4hiv1wyam58hd4bcrjsw")))) + (build-system asdf-build-system/sbcl) + (inputs + `(("cl+ssl" ,sbcl-cl+ssl) + ("cl-binding-arrows" ,sbcl-binding-arrows) + ("cl-str" ,sbcl-cl-str) + ("cl-usocket" ,sbcl-usocket) + ("flexi-streams" ,sbcl-flexi-streams) + ("trivial-garbage" ,sbcl-trivial-garbage))) + (home-page "https://github.com/charje/cl-yxorp") + (synopsis + "A reverse proxy server written in and configurable in Common Lisp.") + (description "It supports WebSocket, HTTP, HTTPS, HTTP to HTTPS +redirecting, port and host forwarding configuration using a real programming +language, HTTP header and body manipulation (also using a real programming +language).") + (license license:agpl3)))) + +(define-public ecl-yxorp + ;; Note that due to a bug in ECL this package does not build. + ;; The bug has already been fixed on the development branch, + ;; so this package will work work in the version after 21.2.1. + (sbcl-package->ecl-package sbcl-yxorp))x + +(define-public cl-yxorp + (sbcl-package->cl-source-package sbcl-yxorp)) + (define-public sbcl-rss ;; No release. (let ((commit "51d0145e91b86327ae5c36364f9c3048052e7a58")) diff --git a/gnu/packages/web.scm b/gnu/packages/web.scm index ff53333169..d499fa0299 100644 --- a/gnu/packages/web.scm +++ b/gnu/packages/web.scm @@ -141,6 +141,7 @@ #:use-module (gnu packages libunistring) #:use-module (gnu packages libunwind) #:use-module (gnu packages linux) + #:use-module (gnu packages lisp) #:use-module (gnu packages lisp-xyz) #:use-module (gnu packages lsof) #:use-module (gnu packages lua) @@ -893,6 +894,39 @@ memory footprint compared to other webservers. Its features include FastCGI, CGI, authentication, output compression, URL rewriting and many more.") (license license:bsd-3))) +(define-public cl-yxorp-cli + (package + (inherit sbcl-yxorp) + (name "cl-yxorp-cli") + (build-system gnu-build-system) + (arguments + '(#:tests? #f + #:strip-binaries? #f + #:phases + (modify-phases %standard-phases + (delete 'configure) + (add-after 'unpack 'set-home + (lambda _ + (setenv "HOME" "/tmp") + #t)) + (replace 'build + (lambda _ + (invoke + "sbcl" "--noinform" + "--disable-debugger" + "--no-userinit" + "--eval" "(require :asdf)" + "--eval" "(pushnew (uiop:getcwd) asdf:*central-registry*)" + "--load" "build.lisp") + #t)) + (replace 'install + (lambda* (#:key outputs #:allow-other-keys) + (let ((bin (string-append (assoc-ref outputs "out") "/bin"))) + (mkdir-p bin) + (install-file"cl-yxorp" bin)) + #t))))) + (inputs (cons (list "sbcl" sbcl) (package-inputs sbcl-yxorp))))) + (define-public fcgi (package (name "fcgi") -- 2.32.0