From patchwork Sun May 7 17:40:24 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Juliana Sims X-Patchwork-Id: 12859 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 3CC3227BBE2; Sun, 7 May 2023 18:42:22 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-3.7 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,RCVD_IN_MSPIKE_H2,SPF_HELO_PASS, URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id 2E5D527BBE9 for ; Sun, 7 May 2023 18:42:17 +0100 (BST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1pviOb-0003mt-Ks; Sun, 07 May 2023 13:42: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 1pviOY-0003mL-ND for guix-patches@gnu.org; Sun, 07 May 2023 13:42:02 -0400 Received: from debbugs.gnu.org ([209.51.188.43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1pviOY-0008PQ-F3 for guix-patches@gnu.org; Sun, 07 May 2023 13:42:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1pviOY-0006mM-AE for guix-patches@gnu.org; Sun, 07 May 2023 13:42:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#63351] [PATCH] gnu: sqlite: Use g-expressions. Resent-From: Juliana Sims Original-Sender: "Debbugs-submit" Resent-CC: guix-patches@gnu.org Resent-Date: Sun, 07 May 2023 17:42:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 63351 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 63351@debbugs.gnu.org Cc: Juliana Sims X-Debbugs-Original-To: guix-patches@gnu.org Received: via spool by submit@debbugs.gnu.org id=B.168348130526030 (code B ref -1); Sun, 07 May 2023 17:42:02 +0000 Received: (at submit) by debbugs.gnu.org; 7 May 2023 17:41:45 +0000 Received: from localhost ([127.0.0.1]:38378 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pviOD-0006li-J6 for submit@debbugs.gnu.org; Sun, 07 May 2023 13:41:45 -0400 Received: from lists.gnu.org ([209.51.188.17]:53188) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1pviO8-0006lW-Qx for submit@debbugs.gnu.org; Sun, 07 May 2023 13:41:40 -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 1pviO8-0003fo-E2 for guix-patches@gnu.org; Sun, 07 May 2023 13:41:36 -0400 Received: from relay6-d.mail.gandi.net ([217.70.183.198]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1pviO3-0008Jy-1U for guix-patches@gnu.org; Sun, 07 May 2023 13:41:36 -0400 Received: (Authenticated sender: juli@incana.org) by mail.gandi.net (Postfix) with ESMTPSA id 1D4A2C0002; Sun, 7 May 2023 17:41:25 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=incana.org; s=gm1; t=1683481286; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding; bh=6HZnhamf4xg8eeo28fZ3DnPRymSE/VcgFA9sDvgvYOg=; b=aM1+FgZ+yirCNajZ38txo55w+yvidWDodlYxcZ2YjVUUIhB/OKzlpTQcYl3cDo84ces0xf qBB76Fp0cyoLdIdJl6b9k1Q5yAmt1EA9hv6qEOsi/M/Q5Dp36K6mk7G3LQh6aJWsWRMCFW VTuSkZaHdufK+7zbQsPYC7YvcuL6RpoqqB8ozLag3ODaXCOJFQksiD4tYzLX0IvyVn8PdF Dx2++9bEylhRPxiCkl42SbE+BJ/kFTadD8LcS0iRAtweq3qE4L/cbEU4kOT9Nwtv7yB+XW 3G3mkTgEY/AY2Lfs/TbY+hZOBoFT+fI1wry3T3Qsy+B0xaPu75lATT4aQiJbCQ== From: Juliana Sims Date: Sun, 7 May 2023 13:40:24 -0400 Message-Id: <91dc61f35e0684a2e0ddff916d3622e768d0fc4a.1683480983.git.juli@incana.org> X-Mailer: git-send-email 2.39.2 MIME-Version: 1.0 Received-SPF: pass client-ip=217.70.183.198; envelope-from=juli@incana.org; helo=relay6-d.mail.gandi.net X-Spam_score_int: -27 X-Spam_score: -2.8 X-Spam_bar: -- X-Spam_report: (-2.8 / 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, RCVD_IN_DNSWL_LOW=-0.7, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 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-bounces+patchwork=mira.cbaines.net@gnu.org X-getmail-retrieved-from-mailbox: Patches Hello! This patch simply ports sqlite to use g-expressions. Because the diff was so large anyway, I also took the liberty of doing a bit of cleanup and running guix style. Thanks, Juli * gnu/packages/sqlite.scm (sqlite): Use g-expressions. --- gnu/packages/sqlite.scm | 93 ++++++++++++++++++++--------------------- 1 file changed, 45 insertions(+), 48 deletions(-) base-commit: d16826cc32ba821e17236dea0536da7200947c97 diff --git a/gnu/packages/sqlite.scm b/gnu/packages/sqlite.scm index 2e727bd933..727b5aa91a 100644 --- a/gnu/packages/sqlite.scm +++ b/gnu/packages/sqlite.scm @@ -33,12 +33,13 @@ (define-module (gnu packages sqlite) #:use-module (gnu packages) #:use-module (gnu packages hurd) #:use-module (gnu packages readline) + #:use-module (guix build-system gnu) + #:use-module (guix deprecation) + #:use-module (guix download) + #:use-module (guix gexp) #:use-module ((guix licenses) #:prefix license:) #:use-module (guix packages) - #:use-module (guix download) - #:use-module (guix build-system gnu) #:use-module (guix utils) - #:use-module (guix deprecation) #:use-module (ice-9 match) #:use-module (srfi srfi-26)) @@ -62,54 +63,50 @@ (define (sqlite-uri version year) (define-public sqlite (package - (name "sqlite") - (version "3.39.3") - (source (origin - (method url-fetch) - (uri (sqlite-uri version 2022)) - (patches (search-patches "sqlite-hurd.patch")) - (sha256 - (base32 - "1f922kq16g7f4h3gpzim78lvrp5xw9nvlvqw97s2qgxyh8qgns3q")))) - (build-system gnu-build-system) - (inputs (list readline)) - (outputs '("out" "static")) - (arguments - `(#:configure-flags - ;; Add -DSQLITE_SECURE_DELETE, -DSQLITE_ENABLE_FTS3, - ;; -DSQLITE_ENABLE_UNLOCK_NOTIFY and -DSQLITE_ENABLE_DBSTAT_VTAB - ;; to CFLAGS. GNU Icecat will refuse to use the system SQLite - ;; unless these options are enabled. - (list (string-append "CFLAGS=-O2 -g -DSQLITE_SECURE_DELETE " - "-DSQLITE_ENABLE_FTS3 " - "-DSQLITE_ENABLE_UNLOCK_NOTIFY " - "-DSQLITE_ENABLE_DBSTAT_VTAB " - ;; Column metadata is required by GNU Jami and Qt, et.al. - "-DSQLITE_ENABLE_COLUMN_METADATA")) - #:phases (modify-phases %standard-phases - (add-after 'install 'move-static-library - (lambda* (#:key outputs #:allow-other-keys) - (let* ((out (assoc-ref outputs "out")) - (static (assoc-ref outputs "static")) - (source (string-append out "/lib/libsqlite3.a"))) - (mkdir-p (string-append static "/lib")) - (link source (string-append static "/lib/libsqlite3.a")) - (delete-file source) - - ;; Remove reference to the static library from the .la file - ;; so that Libtool looks for it in the usual places. - (substitute* (string-append out "/lib/libsqlite3.la") - (("^old_library=.*") - "old_library=''\n")) - #t)))))) - (home-page "https://www.sqlite.org/") - (synopsis "The SQLite database management system") - (description - "SQLite is a software library that implements a self-contained, serverless, + (name "sqlite") + (version "3.39.3") + (source (origin + (method url-fetch) + (uri (sqlite-uri version 2022)) + (patches (search-patches "sqlite-hurd.patch")) + (sha256 + (base32 + "1f922kq16g7f4h3gpzim78lvrp5xw9nvlvqw97s2qgxyh8qgns3q")))) + (build-system gnu-build-system) + (inputs (list readline)) + (outputs '("out" "static")) + (arguments + (list #:configure-flags + ;; Add -DSQLITE_SECURE_DELETE, -DSQLITE_ENABLE_FTS3, + ;; -DSQLITE_ENABLE_UNLOCK_NOTIFY and -DSQLITE_ENABLE_DBSTAT_VTAB + ;; to CFLAGS. GNU Icecat will refuse to use the system SQLite + ;; unless these options are enabled. + #~(list (string-append "CFLAGS=-O2 -g -DSQLITE_SECURE_DELETE " + "-DSQLITE_ENABLE_FTS3 " + "-DSQLITE_ENABLE_UNLOCK_NOTIFY " + "-DSQLITE_ENABLE_DBSTAT_VTAB " + ;; Column metadata is required by GNU Jami and Qt, et.al. + "-DSQLITE_ENABLE_COLUMN_METADATA")) + #:phases #~(modify-phases %standard-phases + (add-after 'install 'move-static-library + (lambda _ + (let* ((source (string-append #$output "/lib/libsqlite3.a"))) + (mkdir-p (string-append #$output:static "/lib")) + (link source (string-append #$output:static "/lib/libsqlite3.a")) + (delete-file source) + ;; Remove reference to the static library from the .la file + ;; so that Libtool looks for it in the usual places. + (substitute* (string-append #$output "/lib/libsqlite3.la") + (("^old_library=.*") + "old_library=''\n")))))))) + (home-page "https://www.sqlite.org/") + (synopsis "The SQLite database management system") + (description + "SQLite is a software library that implements a self-contained, serverless, zero-configuration, transactional SQL database engine. SQLite is the most widely deployed SQL database engine in the world. The source code for SQLite is in the public domain.") - (license license:public-domain))) + (license license:public-domain))) ;; Newer version required for e.g. fossil. (define-public sqlite-next