From patchwork Fri Feb 26 01:37:22 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Raghav Gururajan X-Patchwork-Id: 27313 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 3326E27BC4A; Fri, 26 Feb 2021 01:38:13 +0000 (GMT) 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, MAILING_LIST_MULTI,RCVD_IN_MSPIKE_H3,RCVD_IN_MSPIKE_WL,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 73B6C27BC4D for ; Fri, 26 Feb 2021 01:38:10 +0000 (GMT) Received: from localhost ([::1]:39110 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1lFS53-00024s-KY for patchwork@mira.cbaines.net; Thu, 25 Feb 2021 20:38:09 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:43232) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lFS4w-00023q-To for guix-patches@gnu.org; Thu, 25 Feb 2021 20:38:02 -0500 Received: from debbugs.gnu.org ([209.51.188.43]:56524) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1lFS4w-0005dO-MM for guix-patches@gnu.org; Thu, 25 Feb 2021 20:38:02 -0500 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1lFS4w-0002l8-KY for guix-patches@gnu.org; Thu, 25 Feb 2021 20:38:02 -0500 X-Loop: help-debbugs@gnu.org Subject: [bug#46788] gnu: Add qhttp. Resent-From: Raghav Gururajan Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Fri, 26 Feb 2021 01:38:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 46788 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: To: 46788@debbugs.gnu.org X-Debbugs-Original-To: guix-patches@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.161430345110552 (code B ref -1); Fri, 26 Feb 2021 01:38:02 +0000 Received: (at submit) by debbugs.gnu.org; 26 Feb 2021 01:37:31 +0000 Received: from localhost ([127.0.0.1]:39835 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lFS4R-0002k8-BR for submit@debbugs.gnu.org; Thu, 25 Feb 2021 20:37:31 -0500 Received: from lists.gnu.org ([209.51.188.17]:40652) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1lFS4P-0002k1-L9 for submit@debbugs.gnu.org; Thu, 25 Feb 2021 20:37:30 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]:43150) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lFS4P-00021n-DG for guix-patches@gnu.org; Thu, 25 Feb 2021 20:37:29 -0500 Received: from out2.migadu.com ([2001:41d0:2:aacc::]:45592) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1lFS4N-0005Q3-Cc for guix-patches@gnu.org; Thu, 25 Feb 2021 20:37:29 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=raghavgururajan.name; s=key1; t=1614303444; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type; bh=WeiSf9tXCVgN3Dp7NcFuYUqAkn8+7PpstMopdHUT94U=; b=Z5tW3P+0BkEpZC6kjJBiF5YJPSPeLwXJR1lR7XyDf84F9nCeMQCbFms8Ipj8m6zajIyc01 BTRuyaofn4d3PlJ97JLMVZo1qB+j4X96d8eroOICKfhIfhGpZl8SyHmoPKMPsEVC1bIEAm oEBjFn3fv5EF1K3rn/hwwZ6Ud4ShtoYx8ckbpARDa0ccyyvFKAEkU1vguhHDDkzHYY+ViR eiAVGh69FCu4CW4bAO6iUYNSRr/SP+O/qJ16pqH1IlZNzwCFVl1PS9/H0O6VagJ+Hj/zoq YtBesEZERGAq3vYH+laroYOg+kR0gIBGTmFWxJNErTdna5nzdUAZTxp6bJz4nw== X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. Message-ID: <1696eb36-ffe5-18ce-81fa-7ddb87f486a7@raghavgururajan.name> Date: Thu, 25 Feb 2021 20:37:22 -0500 MIME-Version: 1.0 X-Migadu-Flow: FLOW_OUT X-Migadu-Auth-User: rg@raghavgururajan.name Received-SPF: pass client-ip=2001:41d0:2:aacc::; envelope-from=rg@raghavgururajan.name; helo=out2.migadu.com X-Spam_score_int: -1 X-Spam_score: -0.2 X-Spam_bar: / X-Spam_report: (-0.2 / 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, PDS_OTHER_BAD_TLD=1.948, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=no 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: Raghav Gururajan X-ACL-Warn: , Raghav Gururajan via Guix-patches X-Patchwork-Original-From: Raghav Gururajan via Guix-patches via From: Raghav Gururajan X-getmail-retrieved-from-mailbox: Patches From 0b32a63b75d1faffcb7c7b5c71414eacce4b46e8 Mon Sep 17 00:00:00 2001 From: Raghav Gururajan Date: Thu, 25 Feb 2021 19:45:04 -0500 Subject: [PATCH 2/3] gnu: Add qhttp. * gnu/packages/web.scm (qhttp): New variable. --- gnu/packages/web.scm | 62 ++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 62 insertions(+) diff --git a/gnu/packages/web.scm b/gnu/packages/web.scm index e4ba0d5bf9..cb277947e9 100644 --- a/gnu/packages/web.scm +++ b/gnu/packages/web.scm @@ -170,6 +170,68 @@ #:use-module (gnu packages xml) #:use-module ((srfi srfi-1) #:select (delete-duplicates))) +(define-public qhttp + (package + (name "qhttp") + (version "3.1") + (source + (origin + (method git-fetch) + (uri + (git-reference + (url "https://github.com/azadkuh/qhttp.git") + (commit + (string-append "version-" version)))) + (file-name + (git-file-name name version)) + (sha256 + (base32 "0cx23g4y4k4v9p5ph6h7gfhp8sfy1gcdv1g6bl44hppar1y0zfdq")))) + (build-system gnu-build-system) + (arguments + `(#:tests? #f ; No target + #:phases + (modify-phases %standard-phases + (add-after 'unpack 'patch-source + (lambda* (#:key outputs #:allow-other-keys) + (substitute* "commondir.pri" + (("\\$\\$PRJDIR/xbin") + (string-append (assoc-ref outputs "out") "/lib")) + (("-L") + "-lhttp_parser -L") + (("\\$\\$PRJDIR/3rdparty") + "")) + (substitute* "src/src.pro" + (("SOURCES \\+= \\$\\$PRJDIR/3rdparty/http-parser/http_parser.c") + "") + (("HEADERS \\+= \\$\\$PRJDIR/3rdparty/http-parser/http_parser.h") + "")) + (substitute* '("src/private/qhttpbase.hpp" "src/qhttpabstracts.cpp") + (("http-parser/http_parser.h") + "http_parser.h")) + #t)) + (replace 'configure + (lambda _ + (invoke "qmake") + #t)) + (add-after 'install 'remove-examples + (lambda* (#:key outputs #:allow-other-keys) + (with-directory-excursion + (string-append (assoc-ref outputs "out") "/lib") + (for-each delete-file + (list + "basic-server" + "helloworld" + "postcollector"))) + #t))))) + (inputs + `(("http-parser" ,http-parser) + ("qtbase" ,qtbase))) + (synopsis "Qt-based HTTP Library") + (description "Qhttp is a light-weight and asynchronous HTTP library +(both server & client) in Qt5 and c++14.") + (home-page "https://github.com/azadkuh/qhttp/") + (license license:expat))) + (define-public httpd (package (name "httpd") -- 2.30.1