[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[bug#63351] [PATCH] gnu: sqlite: Use g-expressions.
From: |
Juliana Sims |
Subject: |
[bug#63351] [PATCH] gnu: sqlite: Use g-expressions. |
Date: |
Sun, 7 May 2023 13:40:24 -0400 |
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(-)
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
base-commit: d16826cc32ba821e17236dea0536da7200947c97
--
2.39.2
- [bug#63351] [PATCH] gnu: sqlite: Use g-expressions.,
Juliana Sims <=