diff options
Diffstat (limited to 'gnu/packages')
39 files changed, 2269 insertions, 181 deletions
diff --git a/gnu/packages/base.scm b/gnu/packages/base.scm index 4bdc3e7792..2a9f2f34fc 100644 --- a/gnu/packages/base.scm +++ b/gnu/packages/base.scm @@ -20,6 +20,7 @@ ;;; Copyright © 2021 Maxime Devos <maximedevos@telenet.be> ;;; Copyright © 2021 Guillaume Le Vaillant <glv@posteo.net> ;;; Copyright © 2021 Maxim Cournoyer <maxim.cournoyer@gmail.com> +;;; Copyright © 2022 John Kehayias <john.kehayias@protonmail.com> ;;; ;;; This file is part of GNU Guix. ;;; @@ -928,6 +929,20 @@ with the Linux kernel.") (license lgpl2.0+) (home-page "https://www.gnu.org/software/libc/"))) +;; Define a variation of glibc which uses the default /etc/ld.so.cache, useful +;; in FHS containers. +(define-public glibc-for-fhs + (hidden-package + (package/inherit glibc + (name "glibc-for-fhs") + (source (origin (inherit (package-source glibc)) + ;; Remove Guix's patch to read ld.so.cache from /gnu/store + ;; directories, re-enabling the default /etc/ld.so.cache + ;; behavior. + (patches + (delete (search-patch "glibc-dl-cache.patch") + (origin-patches (package-source glibc))))))))) + ;; Below are old libc versions, which we use mostly to build locale data in ;; the old format (which the new libc cannot cope with.) (define-public glibc-2.32 diff --git a/gnu/packages/bioconductor.scm b/gnu/packages/bioconductor.scm index ecb60f2e24..3692bb94af 100644 --- a/gnu/packages/bioconductor.scm +++ b/gnu/packages/bioconductor.scm @@ -1384,6 +1384,29 @@ genomation package. Included are Chip Seq, Methylation and Cage data, downloaded from Encode.") (license license:gpl3+))) +(define-public r-macrophage + (package + (name "r-macrophage") + (version "1.12.0") + (source (origin + (method url-fetch) + (uri (bioconductor-uri "macrophage" version + 'experiment)) + (sha256 + (base32 + "0ml8v92w021fmzsn4yl90ap3l4l3b9c1pk8pzsrm122p82wzlyms")))) + (properties `((upstream-name . "macrophage"))) + (build-system r-build-system) + (native-inputs (list r-knitr)) + (home-page "https://bioconductor.org/packages/macrophage") + (synopsis "Human macrophage immune response data") + (description + "This package provides the output of running @code{Salmon} on a set of 24 +RNA-seq samples from Alasoo, et al. \"Shared genetic effects on chromatin and +gene expression indicate a role for enhancer priming in immune response\", published +in Nature Genetics, January 2018.") + (license license:gpl2+))) + (define-public r-msdata (package (name "r-msdata") diff --git a/gnu/packages/c.scm b/gnu/packages/c.scm index 84b537022d..e3d50b1190 100644 --- a/gnu/packages/c.scm +++ b/gnu/packages/c.scm @@ -1183,6 +1183,47 @@ performance concurrent systems developed in C99+.") (license (list license:bsd-2 ;everything except... license:asl2.0)))) ;src/ck_hp.c +(define-public tinydir + (package + (name "tinydir") + (version "1.2.5") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/cxong/tinydir") + (commit version))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "1nprgdfx4i8wzc1idw6chan4fjfa75b5ll8kghdc0q2278pny259")) + (patches (search-patches "tinydir-fix-cbehave-test.patch")) + (modules '((guix build utils))) + (snippet '(delete-file-recursively "tests/cbehave")))) + (build-system cmake-build-system) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'path-cmake + (lambda _ + (substitute* "tests/CMakeLists.txt" + (("^include_dir.*cbehave.*") + (string-append "include_directories("#$cbehave "/include)")) + (("^add_subdir.*cbeha.*") "")))) + (add-before 'configure 'chdir + (lambda _ + (chdir "tests"))) + (replace 'install + (lambda _ + (install-file "../tinydir.h" + (string-append #$output "/include"))))))) + (native-inputs (list cbehave)) + (home-page "https://github.com/cxong/tinydir") + (synopsis "List directories programmatically") + (description "@code{tinydir} is a header-only C wrapper for listing +directory contents.") + (license license:bsd-2))) + (define-public libdispatch (package (name "libdispatch") diff --git a/gnu/packages/check.scm b/gnu/packages/check.scm index a02f4621ac..9768e5f8a4 100644 --- a/gnu/packages/check.scm +++ b/gnu/packages/check.scm @@ -38,6 +38,7 @@ ;;; Copyright © 2020, 2021, 2022 Maxim Cournoyer <maxim.cournoyer@gmail.com> ;;; Copyright © 2021 Hugo Lecomte <hugo.lecomte@inria.fr> ;;; Copyright © 2022 Maxime Devos <maximedevos@telenet.be> +;;; Copyright © 2022 David Elsing <david.elsing@posteo.net> ;;; ;;; This file is part of GNU Guix. ;;; @@ -491,6 +492,63 @@ a multi-paradigm automated test framework for C++ and Objective-C.") a multi-paradigm automated test framework for C++ and Objective-C.") (license license:boost1.0))) +(define-public cbehave + (let ((commit "5deaea0eaaf52f1c5ccdac0c68c003988f348fb4") + (revision "1")) + (package + (name "cbehave") + (version (git-version "0.2.0" revision commit)) + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/bigwhite/cbehave") + (commit commit))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "0kicawxmxn059n3rmfc7r2q5wfjrqbr6lm8dmsi86ba76ak0f9gi")) + (snippet + #~(begin + (for-each delete-file + '("aclocal.m4" + "config.guess" "config.sub" "configure" + "depcomp" "install-sh" + "libtool" "ltmain.sh" "missing" + "Makefile.in" "src/Makefile.in" + "src/example/Makefile.in")))))) + (build-system gnu-build-system) + (arguments + (list + #:configure-flags #~(list "--enable-shared" "--disable-static") + #:phases + #~(modify-phases %standard-phases + (add-before 'bootstrap 'rename-configure.in + (lambda _ + (rename-file "configure.in" "configure.ac"))) + (add-after 'rename-configure.in 'set-AM_PROG_AR + (lambda _ + (substitute* "configure.ac" + (("^AC_PROG_LIBTOOL.*" orig) + (string-append "AM_PROG_AR\n" orig))))) + (add-after 'set-AM_PROG_AR 'enable-tests + (lambda _ + (let ((port (open-file "src/example/Makefile.am" "a"))) + (display (string-append "\nTESTS = calculator_test" + " text_editor_test string_test" + " product_database_test mock_test\n") + port) + (close-port port)))) + (add-before 'check 'create-dummy-file + (lambda _ + (invoke "touch" "src/example/foo.txt")))))) + (native-inputs (list autoconf automake libtool)) + (home-page "https://github.com/bigwhite/cbehave") + (synopsis "Behavior-driven development framework") + (description "CBehave is a behavior-driven development implemented in C. +It allows the specification of behaviour scenarios using a given-when-then +pattern.") + (license license:apsl2)))) + (define-public cmdtest (package (name "cmdtest") diff --git a/gnu/packages/chemistry.scm b/gnu/packages/chemistry.scm index c517610fe8..d0582c4b6f 100644 --- a/gnu/packages/chemistry.scm +++ b/gnu/packages/chemistry.scm @@ -6,6 +6,7 @@ ;;; Copyright © 2020 Björn Höfling <bjoern.hoefling@bjoernhoefling.de> ;;; Copyright © 2020 Vincent Legoll <vincent.legoll@gmail.com> ;;; Copyright © 2021 Ricardo Wurmus <rekado@elephly.net> +;;; Copyright © 2022 David Elsing <david.elsing@posteo.net> ;;; ;;; This file is part of GNU Guix. ;;; @@ -27,18 +28,27 @@ #:use-module (guix utils) #:use-module ((guix licenses) #:prefix license:) #:use-module (guix download) + #:use-module (guix gexp) #:use-module (guix git-download) #:use-module (gnu packages) #:use-module (gnu packages algebra) #:use-module (gnu packages autotools) #:use-module (gnu packages backup) + #:use-module (gnu packages base) + #:use-module (gnu packages bison) #:use-module (gnu packages boost) #:use-module (gnu packages check) #:use-module (gnu packages compression) + #:use-module (gnu packages c) + #:use-module (gnu packages cpp) #:use-module (gnu packages documentation) + #:use-module (gnu packages flex) + #:use-module (gnu packages fonts) #:use-module (gnu packages fontutils) + #:use-module (gnu packages gcc) #:use-module (gnu packages gl) #:use-module (gnu packages graphviz) + #:use-module (gnu packages gtk) #:use-module (gnu packages gv) #:use-module (gnu packages image) #:use-module (gnu packages maths) @@ -50,8 +60,13 @@ #:use-module (gnu packages qt) #:use-module (gnu packages serialization) #:use-module (gnu packages sphinx) + #:use-module (gnu packages sqlite) + #:use-module (gnu packages stb) + #:use-module (gnu packages tex) + #:use-module (gnu packages web) #:use-module (gnu packages xml) #:use-module (guix build-system cmake) + #:use-module (guix build-system copy) #:use-module (guix build-system gnu) #:use-module (guix build-system python)) @@ -566,3 +581,651 @@ symmetries written in C. Spglib can be used to: used to prepare publication-quality figures, to share interactive results with your colleagues, or to generate pre-rendered animations.") (license license:bsd-3))) + +(define-public gemmi + (package + (name "gemmi") + (version "0.5.7") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/project-gemmi/gemmi") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "00km5q726bslrw7xbfwb3f3mrsk19qbimfnl3hvr4wi1y3z8i18a")) + (patches + (search-patches "gemmi-fix-sajson-types.patch" + "gemmi-fix-pegtl-usage.patch")) + (modules '((guix build utils))) + (snippet + '(begin + (delete-file-recursively "include/gemmi/third_party") + (delete-file-recursively "third_party"))))) + (outputs '("out" "bin" "python")) + (build-system cmake-build-system) + (arguments + (list + #:modules '((guix build cmake-build-system) + (guix build utils) + ((guix build python-build-system) + #:select (site-packages))) + #:imported-modules (append %cmake-build-system-modules + '((guix build python-build-system))) + #:configure-flags + #~(list "-DUSE_PYTHON=ON" + (string-append "-DPYTHON_INSTALL_DIR=" + (site-packages %build-inputs %outputs))) + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'patch-includes + (lambda _ + (substitute* (list "include/gemmi/sprintf.hpp" + "include/gemmi/dirwalk.hpp" + "include/gemmi/cif.hpp" + "include/gemmi/json.hpp" + "python/gemmi.cpp" + "include/gemmi/atof.hpp" + "include/gemmi/numb.hpp" + "include/gemmi/fourier.hpp") + (("<stb/stb_sprintf.h>") "<stb_sprintf.h>") + (("\"third_party/tinydir.h\"") "<tinydir.h>") + (("\"third_party/tao/pegtl.hpp\"") "<tao/pegtl.hpp>") + (("\"third_party/sajson.h\"") "<sajson.h>") + (("\"gemmi/third_party/tao/pegtl/parse_error.hpp\"") + "<tao/pegtl/parse_error.hpp>") + (("\"third_party/fast_float.h\"") + "<fast_float/fast_float.h>") + (("\"third_party/pocketfft_hdronly.h\"") + "<pocketfft_hdronly.h>")))) + (add-after 'unpack 'change-bin-prefix + (lambda _ + (substitute* "CMakeLists.txt" + (("install\\(TARGETS program DESTINATION bin\\)") + (string-append + "install(TARGETS program DESTINATION " + #$output:bin "/bin)"))))) + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (with-directory-excursion "../source" + (setenv "PYTHONPATH" "../build") + (invoke "python3" "-m" "unittest" "discover" "-v" + "-s" "tests")))))))) + (inputs (list python zlib)) + (native-inputs + (list fast-float + optionparser + pegtl + pocketfft-cpp + pybind11 + sajson-for-gemmi + stb-sprintf + tinydir)) + (home-page "https://gemmi.readthedocs.io/en/latest/") + (synopsis "Macromolecular crystallography library and utilities") + (description "GEMMI is a C++ library for macromolecular crystallography. +It can be used for working with +@enumerate +@item macromolecular models (content of PDB, PDBx/mmCIF and mmJSON files), +@item refinement restraints (CIF files), +@item reflection data (MTZ and mmCIF formats), +@item data on a 3D grid (electron density maps, masks, MRC/CCP4 format) +@item crystallographic symmetry. +@end enumerate") + (license license:mpl2.0))) + +(define-public freesasa + (package + (name "freesasa") + (version "2.1.2") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/mittinatten/freesasa") + (commit version))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "07wdnahf3g355ryaiqvfxd5f4rl54wv8jwxcbn0nia89fqysbv0f")) + (modules '((guix build utils))) + (snippet + '(begin + ;; Remove C files generated by Flex and Bison + (for-each delete-file + '("src/parser.c" "src/parser.h" + "src/lexer.c" "src/lexer.h")))))) + (outputs '("out" "doc")) + (build-system gnu-build-system) + (arguments + (list + #:configure-flags + #~(list "--enable-check" + "--enable-parser-generator" + "CXXFLAGS=-std=c++17" + "--enable-doxygen") + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'remove-libc++-linking + (lambda _ + (substitute* "src/Makefile.am" + (("-lc\\+\\+") "")))) + (add-after 'unpack 'build-shared-library + (lambda _ + (substitute* "src/Makefile.am" + (("lib_LIBRARIES") "lib_LTLIBRARIES") + (("libfreesasa\\.a") "libfreesasa.la") + (("freesasa_LDADD \\+= libfreesasa\\.la" prev) + (string-append prev "\nlibfreesasa_la_LIBADD" + " = -ljson-c ${libxml2_LIBS}\n")) + (("_a_SOURCES") "_la_SOURCES")) + (substitute* "configure.ac" + (("AC_PROG_INSTALL" inst) + (string-append "AM_PROG_LIBTOOL\n" inst))) + (substitute* "tests/Makefile.am" + (("libfreesasa\\.a") "libfreesasa.la")))) + (add-before 'build 'build-lexer-and-parser + (lambda _ + (with-directory-excursion "src" + (invoke "make" "lexer.h" "parser.h")))) + (add-after 'install 'install-doc + (lambda _ + (copy-recursively + "doc/html" + (string-append #$output:doc "/share/doc/" + #$name "-" #$version))))))) + (inputs (list gemmi json-c libxml2)) + (native-inputs + (list autoconf + automake + bison + check + doxygen + fast-float + flex + libtool + pegtl + perl + pkg-config)) + (home-page "https://freesasa.github.io/") + (synopsis "Calculate the solvent accessible surface area (SASA) of +molecules") + (description "FreeSASA is a command line tool and C-library for +calculating @acronym{SASAs, solvent accessible surface areas}. By default Lee +& Richards' algorithm is used, but Shrake & Rupley's is also available. Both +can be parameterized to arbitrary precision, and for high resolution versions +of the algorithms, the calculations give identical results.") + (license license:expat))) + +(define-public maeparser + (package + (name "maeparser") + (version "1.3.0") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/schrodinger/maeparser") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "1yv4y5hn49fhylziigsg922bb244lb57p69r7vg9q899zd3l5b7l")))) + (build-system cmake-build-system) + (inputs (list boost zlib)) + (home-page "https://github.com/schrodinger/maeparser") + (synopsis "Maestro file parser") + (description "maeparser is a parser for Schrodinger Maestro files.") + (license license:expat))) + +(define-public coordgenlibs + (package + (name "coordgenlibs") + (version "3.0.1") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/schrodinger/coordgenlibs/") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "0d09x3v38i9y184bml020bq7xizdrdwng38qmdxlplzfhqkjdidv")))) + (build-system cmake-build-system) + (arguments + (list + #:configure-flags + #~(list "-DCOORDGEN_RIGOROUS_BUILD=OFF" + "-DCOORDGEN_USE_MAEPARSER=ON"))) + (inputs (list boost maeparser)) + (home-page "https://github.com/schrodinger/coordgenlibs/") + (synopsis "2D molecule coordinate generation") + (description "@code{coordgenlibs} contains algorithms to generate 2D +coordinates of molecules including macrocycles and metal complexes. It has an +emphasis on quality rather than speed.") + (license license:bsd-3))) + +(define-public yaehmop + (package + (name "yaehmop") + (version "2022.09.1") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/greglandrum/yaehmop") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "1x0d75m1hgdb411fiv7c5bwq1n4y0swrll0gigh8v5c73kjxrja0")) + (modules '((guix build utils))) + (snippet + '(begin + ;; Separate program + (delete-file-recursively "viewkel") + ;; Remove example output (some are corrupted) + (for-each delete-file (find-files "examples" "\\.Z$")) + ;; Documentation outputs + (for-each delete-file (find-files "docs" "\\.(ps|pdf)$")) + ;; These are transpiled from Fortran to C, but we build the + ;; Fortran code instead + (delete-file-recursively "tightbind/f2c_files") + (with-directory-excursion "tightbind" + (for-each delete-file '("abfns.c" + "cboris.c" + "diag.c" + "lovlap.c"))))))) + (build-system cmake-build-system) + (arguments + (list + #:configure-flags + #~(list + "-DUSE_BLAS_LAPACK=ON" + (string-append "-DPARM_FILE_LOC=" #$output + "/share/" #$name "-" #$version "/eht_parms.dat") + "-DBIND_EXE_NAME=yaehmop-bind") + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'chdir + (lambda _ + (chdir "tightbind"))) + (add-after 'chdir 'patch-fortran-functions + (lambda _ + (substitute* '("mov.c" "prototypes.h") + (("lovlap\\(") "lovlap_(") + (("abfns\\(") "abfns_(")))) + (add-after 'chdir 'patch-cmake + (lambda _ + (substitute* "CMakeLists.txt" + (("project\\(yaehmop C\\)") "project(yaehmop C Fortran)") + (("abfns.c") "fortran77/abfns.f") + (("lovlap.c") "fortran77/lovlap.f") + (("(set\\(PARM_FILE_LOC.*)\\)" all init) + (string-append init " CACHE STRING \"\")")) + (("add_library\\(yaehmop_eht" lib) + (string-append lib " SHARED ")) + (("target_link_libraries\\(test_eht \\$\\{LAPACK_LIBRARIES\\}.*" + all) + (string-append all "\ntarget_link_libraries(yaehmop_eht " + "${LAPACK_LIBRARIES})\n"))))) + (add-after 'build 'build-doc + (lambda _ + (with-directory-excursion "../docs" + (substitute* "bind_manual.tex" + (("\\\\usepackage\\{bindpage\\}") + (string-append + "\\usepackage[left=2cm,right=2cm,top=4cm,bottom=2cm]" + "{geometry}\n" + "\\pdfsuppressptexinfo=-1\n"))) + (substitute* "Zmat_appendix.tex" + (("file=dihedral\\.eps") + "file=figs/dihedral.eps")) + (setenv "FORCE_SOURCE_DATE" "1") + (invoke "latexmk" "-pdf" "bind_manual.tex")))) + (add-after 'install 'install-eht-parms + (lambda _ + (install-file "../tightbind/eht_parms.dat" + (string-append #$output "/share/" + #$name "-" #$version)))) + (add-after 'install-eht-parms 'install-doc + (lambda _ + (install-file "../docs/bind_manual.pdf" + (string-append #$output "/share/doc/" + #$name "-" #$version)))) + (delete 'check) + (add-after 'install-doc 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "./test_eht"))))))) + (inputs (list openblas)) + (native-inputs + (list gfortran + (texlive-updmap.cfg (list texlive-fonts-ec + texlive-latex-graphics + texlive-latex-geometry)))) + (home-page "https://github.com/greglandrum/yaehmop") + (synopsis "Perform extended Hückel calculations") + (description "@acronym{YAeHMOP, Yet Another extended Hueckel Molecular +Orbital Package} contains a program and library for performing extended Hückel +calculations and analyzing the results.") + (license license:bsd-2))) + +(define-public avalon-toolkit + (package + (name "avalon-toolkit") + (version "1.2.0") + (source + (origin + (method url-fetch) + (uri (string-append + "mirror://sourceforge/avalontoolkit/" + "AvalonToolkit_" (substring version 0 3) "/AvalonToolkit_" + version ".source.tar")) + (sha256 + (base32 + "0rnnyy6axs2da7aa4q6l30ldavbk49v6l22llj1adn74h1i67bpv")) + (modules '((guix build utils) (ice-9 ftw))) + (snippet + #~(begin + (delete-file-recursively "../SourceDistribution/java"))))) + (build-system gnu-build-system) + (arguments + (list + ;; There are no intended tests + #:tests? #f + #:phases + #~(let ((programs '("canonizer" "matchtest" "sketch" "smi2mol" "struchk"))) + (modify-phases %standard-phases + (add-after 'unpack 'chdir + (lambda _ (chdir "common"))) + (delete 'configure) + (add-before 'build 'dont-free-static-memory + (lambda _ + (substitute* "reaccsio.c" + (("MyFree\\(.*tempdir\\)" m) + (string-append "/* freeing memory from getenv is bad */" + "// " m))))) + ;; The makefile has incorrect compiler flags and is missing some + ;; object files, so we build it ourselves. + (replace 'build + (lambda _ + (for-each + (lambda (part) + (format #t "Compiling ~a.c ~~> ~a.o~%" part part) + (invoke #$(cc-for-target) "-c" "-fPIC" "-O2" + (string-append part ".c") + "-o" (string-append part ".o"))) + (list "aacheck" "casutils" "denormal" "depictutil" + "didepict" "fixcharges" "forio" "geometry" + "graph" "hashcode" "layout" "local" "pattern" + "perceive" "reaccsio" "rtutils" "set" "shortcut" + "sketch" "ssmatch" "stereo" "symbol_lists" + "symboltable" "utilities")) + (display "Building libavalontoolkit.so\n") + (apply invoke "gcc" "-fPIC" "-shared" "-lm" + "-o" "libavalontoolkit.so" "canonizer.c" "smi2mol.c" + "struchk.c" "patclean.c" (find-files "." "\\.o$")) + ;; patclean is not built here as there is an undeclared + ;; variable in main(). + (for-each + (lambda (program) + (display (string-append "Building " program "\n")) + (invoke "gcc" "-L." "-lavalontoolkit" "-lm" "-O2" + (string-append "-Wl,-rpath=" #$output "/lib") + "-DMAIN" (string-append program ".c") "-o" program)) + programs))) + (replace 'install + (lambda _ + ;; Executables + (for-each + (lambda (program) + (install-file program (string-append #$output "/bin"))) + programs) + (for-each + (lambda (name) + (symlink (string-append #$output "/bin/smi2mol") + (string-append #$output "/bin/" name))) + '("mol2smi" "rdf2smi" "mol2tbl" "mol2sma" "smi2rdf")) + ;; Library + (install-file "libavalontoolkit.so" + (string-append #$output "/lib")) + (for-each + (lambda (file) + (install-file file (string-append #$output + "/include/avalontoolkit"))) + (find-files "." "\\.h$")) + (install-file "../license.txt" + (string-append #$output "/share/doc/" + #$name "-" #$version "/")))))))) + (home-page "https://sourceforge.net/projects/avalontoolkit/") + (synopsis "Tools for SMILES and MOL files and for structure fingerprinting") + (description "This package contains a library and programs for +canonicalization of SMILES and MOL files, molecular structure fingerprinting +and rendering molecules.") + (license license:bsd-3))) + +(define-public ringdecomposerlib + (package + (name "ringdecomposerlib") + (version "1.1.3") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/rareylab/RingDecomposerLib") + (commit (string-append "v" version "_rdkit")))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "1rxzs2wpkkdi40wdzxc4sn0brk7dm7ivgqyfh38gf2f5c7pbg0wi")))) + (build-system cmake-build-system) + (arguments + (list + #:configure-flags + #~(list "-DBUILD_PYTHON_WRAPPER=ON" + "-DPYTHON_EXECUTABLE=python3" + (string-append "-DPYTHON_FLAGS=;--prefix=" #$output ";--root=/")) + #:imported-modules (append %cmake-build-system-modules + '((guix build python-build-system))) + #:modules '((guix build cmake-build-system) + (guix build utils) + ((guix build python-build-system) + #:select (add-installed-pythonpath))) + #:phases + #~(modify-phases %standard-phases + (add-before 'configure 'patch-cmake + (lambda _ + (substitute* (list "src/Test/CMakeLists.txt" + "src/RingDecomposerLib/CMakeLists.txt") + (("build_.*STATIC") "#")) + (substitute* "test/CMakeLists.txt" + (("STATIC_TEST") "SHARED_TEST")) + ;; Link Python library against shared library + (substitute* "src/python/CMakeLists.txt" + (("RingDecomposerLibStatic") "RingDecomposerLib")) + (substitute* "src/python/setup.py.in" + (("static_libs =.*") "static_libs = []\n") + (("shared_libs\\s*=.*") + (string-append + "shared_libs = ['RingDecomposerLib']")) + (("library_dirs\\s*=\\s*\\[\\]") + "library_dirs = ['${CMAKE_BINARY_DIR}/src/RingDecomposerLib']") + (("extra_objects=.*") + (string-append + "extra_link_args=['-Wl,-rpath=" #$output "/lib'],\n"))))) + (add-after 'build 'build-doc + (lambda _ + ;; Disable redundant LaTeX documentation + (substitute* "../source/documentation/sphinx/conf.py" + (("^(subprocess.*latex|shutil).*") "")) + (substitute* "../source/documentation/doxygen.cfg" + (("GENERATE_LATEX.*YES") "GENERATE_LATEX = NO")) + ;; Build HTML documentation + (invoke "sphinx-build" "-b" "html" + "../source/documentation/sphinx" "html"))) + (add-after 'install 'install-doc + (lambda _ + ;; Not reproducible + (delete-file-recursively "html/.doctrees") + (copy-recursively "html" + (string-append #$output "/share/doc/" + #$name "-" #$version "/html")))) + (delete 'check) + (add-after 'install 'check + (assoc-ref %standard-phases 'check)) + (add-before 'check 'set-pythonpath + (lambda* (#:key inputs outputs #:allow-other-keys) + (add-installed-pythonpath inputs outputs)))))) + (inputs (list python)) + (native-inputs (list doxygen python python-cython python-sphinx)) + (home-page "https://github.com/rareylab/RingDecomposerLib") + (synopsis "Calculate ring topology descriptions") + (description "RingDecomposerLib is a library for the calculation of +unique ring families, relevant cycles, the smallest set of smallest rings and +other ring topology descriptions.") + (license license:bsd-3))) + +(define-public rdkit + (package + (name "rdkit") + (version "2022.03.5") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/rdkit/rdkit") + (commit + (string-append + "Release_" (string-replace-substring version "." "_"))))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "19idgilabh04cbr1qj6zgrgsfjm248mmfz6fsr0smrd68d0xnml9")) + (patches + (search-patches "rdkit-unbundle-external-dependencies.patch")) + (modules '((guix build utils))) + (snippet + #~(begin + ;; Remove pickle files (only used in tests), + ;; as they are compiled programs + (for-each + (lambda (name) + (display (string-append name "\n")) + (delete-file name)) + (find-files "." "\\.pkl(\\.gz)?$")) + ;; Remove SQLite data files (can be generated) + (delete-file "Data/RDData.sqlt") + (delete-file "Data/RDTests.sqlt"))))) + (build-system cmake-build-system) + (arguments + (list + #:imported-modules (append %cmake-build-system-modules + '((guix build python-build-system))) + #:modules '((guix build cmake-build-system) + (guix build utils) + ((guix build python-build-system) + #:select (add-installed-pythonpath))) + #:configure-flags + #~(list "-DRDK_BUILD_AVALON_SUPPORT=ON" + "-DRDK_BUILD_CAIRO_SUPPORT=ON" + "-DRDK_BUILD_FREESASA_SUPPORT=ON" + "-DRDK_BUILD_INCHI_SUPPORT=ON" + "-DRDK_BUILD_YAEHMOP_SUPPORT=ON" + (string-append "-DCATCH_DIR=" + (search-input-directory %build-inputs + "/include/catch2")) + "-DRDK_INSTALL_INTREE=OFF" + "-DRDK_INSTALL_STATIC_LIBS=OFF" + (string-append + "-DRDK_OPTIMIZE_POPCNT=" + #$(let ((system (or (%current-target-system) + (%current-system)))) + (cond + ((string-prefix? "x86_64" system) "ON") + ((string-prefix? "i686" system) "ON") + (else "OFF")))) + "-DRDK_USE_FLEXBISON=ON" + (string-append + "-DCMAKE_INCLUDE_PATH=" + (search-input-directory %build-inputs "/include/avalontoolkit"))) + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'copy-external-dependencies + (lambda _ + (symlink + (string-append + (search-input-file + %build-inputs "/share/fonts/truetype/ComicNeue-Regular.ttf")) + "Data/Fonts/ComicNeue-Regular.ttf"))) + (add-after 'unpack 'fix-inchi-include + (lambda _ + (substitute* "Code/cmake/Modules/FindInchi.cmake" + (("inchi_api.h.*\\)") "inchi/inchi_api.h)") + (("INCHI_LIBRARY NAMES.*\\)") + "INCHI_LIBRARY NAMES inchi PATH_SUFFIXES inchi)") + (("find_library" prev) + (string-append + "list(APPEND CMAKE_FIND_LIBRARY_SUFFIXES .so.1)\n" + prev))) + (substitute* "External/INCHI-API/inchi.cpp" + (("<inchi_api.h>") "<inchi/inchi_api.h>")))) + (add-before 'build 'enable-bytecode-determinism + (lambda _ + (setenv "PYTHONHASHSEED" "0") + (setenv "PYTHONDONTWRITEBYTECODE" "1"))) + (add-after 'install 'pre-check + (lambda* (#:key inputs outputs #:allow-other-keys) + (with-directory-excursion "../source" + (invoke "sqlite3" "Data/RDData.sqlt" + ".read rdkit/Dbase/test_data/RDData.sqlite") + (invoke "sqlite3" "Data/RDTests.sqlt" + ".read rdkit/Dbase/test_data/RDTests.sqlite") + (setenv "RDBASE" (canonicalize-path "."))) + (add-installed-pythonpath inputs outputs))) + (delete 'check) + (add-after 'pre-check 'check + (lambda* (#:key tests? parallel-tests? #:allow-other-keys) + (when tests? + (let ((job-count (number->string + (if parallel-tests? (parallel-job-count) 1)))) + (invoke + "ctest" "-j" job-count + "-E" (string-append + "(" + (string-join + '(;; need pickled data + "pyDiscreteValueVect" "pySparseIntVect" + "graphmoltestPickler" "pyPartialCharges" + "substructLibraryTest" "pyFeatures" + "pythonTestDirML" "pythonTestDirChem" + ;; Catching Python exception fails + "pyRanker") "|") + ")"))))))))) + (inputs + (list avalon-toolkit + cairo + coordgenlibs + font-comic-neue + freetype + inchi + maeparser + python + ringdecomposerlib + sqlite + yaehmop)) + (native-inputs + (list bison + boost + catch2 + eigen + flex + freesasa + pkg-config + rapidjson + tar)) + (propagated-inputs + (list python-numpy python-cairocffi python-pillow)) + (home-page "https://rdkit.org/") + (synopsis "Collection of cheminformatics software") + (description "RDKit is a C++ and Python library for cheminformatics, which +includes (among other things) the analysis and modification of molecules in 2D +and 3D and descriptor generation for machine learning.") + (license license:bsd-3))) diff --git a/gnu/packages/chromium.scm b/gnu/packages/chromium.scm index c847e4cac2..17719fd844 100644 --- a/gnu/packages/chromium.scm +++ b/gnu/packages/chromium.scm @@ -319,7 +319,7 @@ ;; run the Blink performance tests, just remove everything to save ~70MiB. '("third_party/blink/perf_tests")) -(define %chromium-version "106.0.5249.103") +(define %chromium-version "106.0.5249.119") (define %ungoogled-revision (string-append %chromium-version "-1")) (define %debian-revision "debian/102.0.5005.61-1") (define %arch-revision "6afedb08139b97089ce8ef720ece5cd14c83948c") @@ -332,7 +332,7 @@ (file-name (git-file-name "ungoogled-chromium" %ungoogled-revision)) (sha256 (base32 - "00acfq9hsdjqqlxddr9lr45l4372mpqxj717qpf78z8iyrccjm23")))) + "0mgyakq0g3v24b1qn76zblhjf9zzbiv1fq95w7w42nv3fvxfrxr2")))) (define %debian-origin (origin @@ -516,7 +516,7 @@ %chromium-version ".tar.xz")) (sha256 (base32 - "0k2f3hc6mdmwzw9zzwcv6pnpibdz47a3xxkhfcvdki5gbag6cpr2")) + "14niglj8q6mfkmgbbjhaipmyhv6vryx93crswb1xa871a14in28g")) (modules '((guix build utils))) (snippet (force ungoogled-chromium-snippet)))) (build-system gnu-build-system) diff --git a/gnu/packages/cobol.scm b/gnu/packages/cobol.scm index c1699b7e3a..a67eef3cd4 100644 --- a/gnu/packages/cobol.scm +++ b/gnu/packages/cobol.scm @@ -1,5 +1,5 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2017, 2018, 2021 Efraim Flashner <efraim@flashner.co.il> +;;; Copyright © 2017, 2018, 2021, 2022 Efraim Flashner <efraim@flashner.co.il> ;;; ;;; This file is part of GNU Guix. ;;; @@ -22,6 +22,7 @@ #:use-module (guix licenses) #:use-module (guix packages) #:use-module (guix download) + #:use-module (guix gexp) #:use-module (gnu packages dbm) #:use-module (gnu packages multiprecision) #:use-module (gnu packages ncurses) @@ -43,21 +44,22 @@ (base32 "0x15ybfm63g7c9340fc6712h9v59spnbyaz4rf85pmnp3zbhaw2r")))) (arguments - '(#:configure-flags (list (string-append "LDFLAGS=-Wl,-rpath=" - (assoc-ref %outputs "out") - "/lib") - (string-append "JSON_C_CFLAGS=-I" - (assoc-ref %build-inputs "json-c") - "/include/json-c")) + (list + #:configure-flags + #~(list (string-append "LDFLAGS=-Wl,-rpath=" + #$output "/lib") + (string-append "JSON_C_CFLAGS=-I" + (search-input-directory %build-inputs + "/include/json-c"))) #:phases - (modify-phases %standard-phases - (add-after 'unpack 'place-cobol85-test-suite - (lambda* (#:key inputs #:allow-other-keys) - (let ((newcob (assoc-ref inputs "newcob"))) - (copy-file newcob "tests/cobol85/newcob.val.Z")))) - (add-before 'check 'set-TERM - ;; Some tests expect a known terminal - (lambda _ (setenv "TERM" "xterm-256color")))) + #~(modify-phases %standard-phases + (add-after 'unpack 'place-cobol85-test-suite + (lambda* (#:key inputs #:allow-other-keys) + (let ((newcob (assoc-ref inputs "newcob"))) + (copy-file newcob "tests/cobol85/newcob.val.Z")))) + (add-before 'check 'set-TERM + ;; Some tests expect a known terminal + (lambda _ (setenv "TERM" "xterm-256color")))) #:test-target "checkall")) (native-inputs `(("perl" ,perl) @@ -72,10 +74,9 @@ (build-system gnu-build-system) (home-page "https://www.gnu.org/software/gnucobol/") (synopsis "Modern COBOL compiler") - (description "GnuCOBOL is a free, modern COBOL compiler. GnuCOBOL -implements a substantial part of the COBOL 85, COBOL 2002 and COBOL 2014 -standards and X/Open COBOL, as well as many extensions included in other -COBOL compilers (IBM COBOL, MicroFocus COBOL, ACUCOBOL-GT and others). -GnuCOBOL translates COBOL into C and compiles the translated code using -a native C compiler.") + (description + "GnuCOBOL is a free, modern COBOL compiler. It implements a substantial +part of COBOL 85, X/Open COBOL and newer ISO COBOL standards as well as many +extensions from other COBOL compilers (IBM COBOL, MicroFocus COBOL, ACUCOBOL-GT +and others).") (license gpl3+))) diff --git a/gnu/packages/cpp.scm b/gnu/packages/cpp.scm index 805413cc61..c8df516834 100644 --- a/gnu/packages/cpp.scm +++ b/gnu/packages/cpp.scm @@ -29,6 +29,7 @@ ;;; Copyright © 2022 muradm <mail@muradm.net> ;;; Copyright © 2022 Attila Lendvai <attila@lendvai.name> ;;; Copyright © 2022 Arun Isaac <arunisaac@systemreboot.net> +;;; Copyright © 2022 David Elsing <david.elsing@posteo.net> ;;; ;;; This file is part of GNU Guix. ;;; @@ -56,6 +57,7 @@ #:use-module (guix build-system gnu) #:use-module (guix build-system meson) #:use-module (guix build-system python) + #:use-module (guix build-system scons) #:use-module (guix modules) #:use-module (guix gexp) #:use-module (gnu packages) @@ -1954,3 +1956,211 @@ std::wstring, etc).") "This package provides architecture-specific implementations of the CRC32C algorithm, which is specified in RFC 3720, section 12.1.") (license license:bsd-3))) + +(define fast-float-test-files + (let ((commit "97a0b2e638feb479387554cf253e346500541e7e")) + (origin + (method git-fetch) + (uri (git-reference + (url (string-append "https://github.com/fastfloat" + "/supplemental_test_files.git")) + (commit "97a0b2e638feb479387554cf253e346500541e7e"))) + (file-name (string-append "fast-float-test-files-" + (string-take commit 8))) + (sha256 + (base32 + "0dxbiyzyh7i847i89ablfzypfc3ckhm7f74w98jsh73v1mppmxlf"))))) + +(define-public fast-float + (package + (name "fast-float") + (version "3.5.1") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/fastfloat/fast_float") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "0z3rxxd0pwvw70dbnv63rm67biw829vdqf50y16isxm6g3sbrz8g")))) + (build-system cmake-build-system) + (arguments + (list + #:configure-flags #~(list "-DFASTFLOAT_TEST=ON" + "-DSYSTEM_DOCTEST=ON") + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'patch-cmake-tests + (lambda* (#:key inputs native-inputs #:allow-other-keys) + (substitute* "tests/CMakeLists.txt" + (("FetchContent_GetProperties\\(supplemental_test_files.*") + "") + (("if\\(NOT supplemental_test_files_POPULATED.*") + (string-append + "set(supplemental_test_files_BINARY_DIR " + (search-input-directory (or native-inputs inputs) + "data") + ")\nif(0)\n")))))))) + (native-inputs (list doctest fast-float-test-files)) + (home-page "https://github.com/fastfloat/fast_float") + (synopsis "Floating point number parser for C++") + (description "@code{fast_float} is a header-only C++ library for parsing +floating point numbers from strings. It implements the C++ from_chars +functions for the float and double types.") + (license (list license:asl2.0 license:expat)))) ; dual licensed + +(define-public pocketfft-cpp + (let ((commit "daa8bb18327bc5c7d22c69428c25cf5dc64167d3") + (revision "0")) + (package + (name "pocketfft-cpp") + (version (git-version "0" revision commit)) + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/mreineck/pocketfft") + (commit commit))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "1dbkkqkmkxgmz1qjpsqzic5ig3qw1pqndbb3dvjc7xq5f2rdzyq1")) + (patches (search-patches + "pocketfft-cpp-prefer-preprocessor-if.patch")))) + (build-system copy-build-system) + (arguments + (list + #:install-plan #~'(("pocketfft_hdronly.h" "include/")))) + (home-page "https://github.com/mreineck/pocketfft") + (synopsis "C++11 header-only Fast Fourier Transform library") + (description "This package provides a single-header C++11 library for +computing Fast Fourier transformations. It supports multidimensional arrays, +different floating point sizes and complex transformations.") + (license license:bsd-3)))) + +(define-public sajson + (let ((commit "ec644013e34f9984a3cc9ba568cab97a391db9cd") + (revision "0")) + (package + (name "sajson") + (version (git-version "1.0" revision commit)) + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/chadaustin/sajson") + (commit commit))) + (file-name (git-file-name name version)) + (patches + (search-patches "sajson-build-with-gcc10.patch")) + (sha256 + (base32 + "0fjag27w7gvkc5pdhq3ad7yc09rabpzahndw1sgsg04ipznidmmq")) + (modules '((guix build utils))) + (snippet '(delete-file-recursively "third-party")))) + (build-system scons-build-system) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'disable-other-builds + (lambda _ + (substitute* "SConstruct" + (("for name, tools in builds:") + "for name, tools in [('opt', [gcc, opt])]:")))) + (add-after 'unpack 'use-external-unittest-cpp + (lambda _ + (substitute* "SConscript" + (("unittestpp_env\\.Library") "_dummy = ") + (("test_env = env.Clone\\(tools=\\[unittestpp, sajson\\]\\)") + (string-append + "test_env = env.Clone(tools=[sajson])\n" + "test_env.Append(CPPPATH='" + (search-input-directory %build-inputs "/include/UnitTest++") + "', LIBPATH='" + (string-append #$(this-package-native-input "unittest-cpp") + "/lib") + "', LIBS=['UnitTest++'])"))))) + (replace 'build + (lambda* (#:key tests? #:allow-other-keys #:rest args) + (when tests? + (apply (assoc-ref %standard-phases 'build) + args)))) + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "build/opt/test") + (invoke "build/opt/test_unsorted")))) + (replace 'install + (lambda _ + (let ((out (string-append #$output "/include"))) + (install-file "include/sajson.h" out) + (install-file "include/sajson_ostream.h" out))))))) + (native-inputs (list unittest-cpp)) + (home-page "https://github.com/chadaustin/sajson") + (synopsis "C++11 header-only, in-place JSON parser") + (description "@code{sajson} is an in-place JSON parser with support for +parsing with only a single memory allocation.") + (license license:expat)))) + +(define-public sajson-for-gemmi + (package/inherit sajson + (name "sajson-for-gemmi") + (source (origin + (inherit (package-source sajson)) + (patches (cons + (search-patch + "sajson-for-gemmi-numbers-as-strings.patch") + (origin-patches (package-source sajson)))))) + (arguments + (substitute-keyword-arguments (package-arguments sajson) + ;; This is a modified version used in gemmi, in which numbers are kept + ;; as strings. Building the tests fails with the modification. + ((#:tests? _ #f) #f))) + (properties '((hidden? . #t))))) + +(define-public optionparser + (package + (name "optionparser") + (version "1.7") + (source (origin + (method url-fetch) + (uri + (string-append "mirror://sourceforge/optionparser/" + "optionparser-" version ".tar.gz")) + (sha256 + (base32 + "04gfxrdzwacaynb8scsz6rr7nh64n6yk6w9dh2qdhrxw4caqr0dk")))) + (outputs '("out" "doc")) + (build-system gnu-build-system) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + (delete 'configure) + (add-before 'build 'chdir + (lambda _ (chdir "src"))) + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (begin + (invoke "./example_arg") + (invoke "./testparse") + (invoke "./testprintusage") + (invoke "./testodr") + (invoke "./example"))))) + (replace 'install + (lambda _ + (install-file "optionparser.h" + (string-append #$output "/include")))) + (add-after 'install 'install-doc + (lambda _ + (copy-recursively + "../html" + (string-append #$output:doc "/share/doc/optionparser/html"))))))) + (native-inputs (list doxygen)) + (home-page "https://optionparser.sourceforge.net/") + (synopsis "Header-only C++ library to parse command line options") + (description "This package provides a header-only C++ library to parse +command line options. It supports the short and long option formats of +getopt(), getopt_long() and getopt_long_only().") + (license license:expat))) diff --git a/gnu/packages/databases.scm b/gnu/packages/databases.scm index 1142f99531..3faf50435a 100644 --- a/gnu/packages/databases.scm +++ b/gnu/packages/databases.scm @@ -58,6 +58,7 @@ ;;; Copyright © 2022 Zhu Zihao <all_but_last@163.com> ;;; Copyright © 2021 Brice Waegeneire <brice@waegenei.re> ;;; Copyright © 2022 muradm <mail@muradm.net> +;;; Copyright © 2022 Thomas Albers Raviola <thomas@thomaslabs.org> ;;; ;;; This file is part of GNU Guix. ;;; @@ -2470,6 +2471,31 @@ sets, bitmaps and hyperloglogs.") (home-page "https://redis.io/") (license license:bsd-3))) +(define-public hiredis + (package + (name "hiredis") + (version "1.0.2") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/redis/hiredis") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 "0a55zk3qrw9yl27i87h3brg2hskmmzbfda77dhq9a4if7y70xnfb")))) + (build-system cmake-build-system) + (native-inputs + ;; needed for testing + (list redis)) + (synopsis "Minimalistic C client library for the Redis database") + (description "This package provides a library for sending commands and +receiving replies to and from a Redis server. It comes with a synchronous +API, asynchronous API and reply parsing API. Only the binary-safe Redis +protocol is supported.") + (home-page "https://github.com/redis/hiredis") + (license license:bsd-3))) + (define-public ruby-redis (package (name "ruby-redis") diff --git a/gnu/packages/emacs-xyz.scm b/gnu/packages/emacs-xyz.scm index 2ac29e8225..d6c5831205 100644 --- a/gnu/packages/emacs-xyz.scm +++ b/gnu/packages/emacs-xyz.scm @@ -827,13 +827,13 @@ information in the mode line.") (define-public emacs-project (package (name "emacs-project") - (version "0.8.1") + (version "0.8.2") (source (origin (method url-fetch) (uri (string-append "https://elpa.gnu.org/packages/project-" version ".tar")) (sha256 - (base32 "0q2js8qihlhchpx2mx0f992ygslsqri2q4iv8kcl4fx31lpp7c1k")))) + (base32 "1l5yxw6xqml176vskd5fz2y2dbjh8925g3kyimda4gdprz4y7aci")))) (build-system emacs-build-system) (propagated-inputs (list emacs-xref)) (home-page "https://elpa.gnu.org/packages/project.html") @@ -12356,6 +12356,18 @@ a file, or a complete directory.") (base32 "1wn94nkfv6qyyj6clvms7m7ncqf09bgszv67may530y75kylivav")))) (build-system emacs-build-system) + (arguments + (list #:phases + #~(modify-phases %standard-phases + (add-after 'unpack 'disable-native-comp + (lambda _ + ;; Native compilation of this package may crash your system, + ;; see <https://bugs.gnu.org/57878>. + (for-each + (lambda (file) + (make-file-writable file) + (emacs-batch-disable-compilation file #:native? #t)) + (find-files "." "\\.el$"))))))) (propagated-inputs (list emacs-s)) (home-page "https://github.com/DarwinAwardWinner/ido-ubiquitous") @@ -13419,21 +13431,21 @@ arguments, such as arguments separated by commas and semicolons.") (define-public emacs-evil-escape (package (name "emacs-evil-escape") - (version "3.14") + (version "3.16") (source (origin (method git-fetch) (uri (git-reference - (url "https://github.com/syl20bnr/evil-escape") + (url "https://github.com/emacsorphanage/evil-escape") (commit (string-append "v" version)))) (file-name (git-file-name name version)) (sha256 - (base32 "0s8lmmm25qabicwaj9jybpbd8mkc62yl7jnhk1lpablydjkv3w2i")))) + (base32 "1z30v59igndqzxg9gcx4bsbf5jkh11wp936il8azkrz3qdryaj4a")))) (propagated-inputs (list emacs-evil)) (build-system emacs-build-system) - (home-page "https://github.com/syl20bnr/evil-escape") + (home-page "https://github.com/emacsorphanage/evil-escape") (synopsis "Escape from insert state and everything else in Emacs") (description "Evil escape provides a customizable key sequence to escape from insert @@ -17207,7 +17219,7 @@ editing RPM spec files.") (define-public emacs-lcr (package (name "emacs-lcr") - (version "1.3") + (version "1.5") (source (origin (method git-fetch) @@ -17216,7 +17228,7 @@ editing RPM spec files.") (commit version))) (file-name (git-file-name name version)) (sha256 - (base32 "1xhrjvlx3vbjkwx31w18y854hk15qf7h5ccg8yb3jdxl0pm9f41f")))) + (base32 "0hhn0gqkwki0dfk6j759hmbj1ijn4bs550jh3kgy9jfmnb7cd81l")))) (build-system emacs-build-system) (propagated-inputs (list emacs-dash)) @@ -17625,7 +17637,7 @@ groups.") (define-public emacs-taxy-magit-section (package (name "emacs-taxy-magit-section") - (version "0.11") + (version "0.12") (source (origin (method url-fetch) (uri (string-append @@ -17633,7 +17645,7 @@ groups.") ".tar")) (sha256 (base32 - "058z95c0z2hxplr5pfgph1cdq68zcrkmwx1wqyd5fy4a5h43yknq")))) + "1x4sfa8kl3f85n8lm381yr7f72zfb73bj6a6r8caw3n8bkv38i3r")))) (build-system emacs-build-system) (propagated-inputs (list emacs-magit emacs-taxy)) (home-page "https://github.com/alphapapa/taxy.el") @@ -19146,7 +19158,7 @@ object has been freed.") (define-public emacs-emacsql (package (name "emacs-emacsql") - (version "3.0.0") + (version "3.1.1") (source (origin (method git-fetch) @@ -19155,44 +19167,41 @@ object has been freed.") (commit (string-append version)))) (file-name (git-file-name name version)) (sha256 - (base32 "1c84gxr1majqj4b59wgdy3lzm3ap66w9qsrnkx8hdbk9895ak81g")))) + (base32 "1xpmji2qgr9r38cdhws65x9s9jy7fk93q8g1j2fm7j8kcfjh9x3g")))) (build-system emacs-build-system) (arguments - `(#:modules ((guix build emacs-build-system) + (list + #:modules '((guix build emacs-build-system) (guix build utils) (guix build emacs-utils) (srfi srfi-26)) - #:phases - (modify-phases %standard-phases - (add-before 'install 'patch-elisp-shell-shebangs - (lambda _ - (substitute* (find-files "." "\\.el") - (("/bin/sh") (which "sh"))))) - (add-after 'patch-elisp-shell-shebangs 'setenv-shell - (lambda _ - (setenv "SHELL" "sh"))) - (add-after 'setenv-shell 'build-emacsql-sqlite - (lambda _ - (invoke "make" "binary" (string-append "CC=" ,(cc-for-target))))) - (add-after 'build-emacsql-sqlite 'install-emacsql-sqlite - ;; This build phase installs emacs-emacsql binary. - (lambda* (#:key outputs #:allow-other-keys) - (install-file "sqlite/emacsql-sqlite" - (string-append (assoc-ref outputs "out") "/bin")))) - (add-after 'install-emacsql-sqlite 'patch-emacsql-sqlite.el - ;; This build phase removes interactive prompts - ;; and makes sure Emacs look for binaries in the right places. - (lambda* (#:key outputs #:allow-other-keys) - (let ((file "emacsql-sqlite.el")) - (chmod file #o644) - (emacs-substitute-sexps file - ;; Make sure Emacs looks for ‘GCC’ binary in the right place. - ("(executable-find" (which "gcc")) - ;; Make sure Emacs looks for ‘emacsql-sqlite’ binary - ;; in the right place. - ("(defvar emacsql-sqlite-executable" - (string-append (assoc-ref outputs "out") - "/bin/emacsql-sqlite"))))))))) + #:phases + #~(modify-phases %standard-phases + (add-before 'install 'patch-elisp-shell-shebangs + (lambda _ + (substitute* (find-files "." "\\.el") + (("/bin/sh") (which "sh"))))) + (add-after 'patch-elisp-shell-shebangs 'setenv-shell + (lambda _ + (setenv "SHELL" "sh"))) + (add-after 'setenv-shell 'build-emacsql-sqlite + (lambda _ + (invoke "make" "binary" (string-append "CC=" #$(cc-for-target))))) + (add-after 'build-emacsql-sqlite 'install-emacsql-sqlite + ;; This build phase installs emacs-emacsql binary. + (lambda _ + (install-file "sqlite/emacsql-sqlite" + (string-append #$output "/bin")))) + (add-after 'install-emacsql-sqlite 'patch-emacsql-sqlite.el + ;; This build phase removes interactive prompts + ;; and makes sure Emacs look for binaries in the right places. + (lambda _ + (emacs-substitute-variables "emacsql-sqlite.el" + ("emacsql-sqlite-executable" + (string-append #$output "/bin/emacsql-sqlite")) + ;; Make sure Emacs looks for ‘GCC’ binary in the right place. + ("emacsql-sqlite-c-compilers" + `(list ,(which "gcc"))))))))) (inputs (list emacs-minimal `(,mariadb "dev") `(,mariadb "lib") postgresql)) (propagated-inputs @@ -25625,18 +25634,24 @@ comments.") (define-public emacs-libmpdel (package (name "emacs-libmpdel") - (version "1.3.0") + (version "1.3.1") (source (origin (method git-fetch) (uri (git-reference - (url "https://gitea.petton.fr/mpdel/libmpdel.git") + (url "https://github.com/mpdel/libmpdel") (commit (string-append "v" version)))) (file-name (git-file-name name version)) (sha256 (base32 - "0krxhcay5s9s7i41q7ga5skj31vaz2qx3djcrlwajf203bl8j4m9")))) + "0fsg2si7afrnsz91i0ziza6nbc4ds9kpnr2z71wf6896zb1afhfx")))) (build-system emacs-build-system) - (home-page "https://gitea.petton.fr/mpdel/libmpdel") + (arguments + (list + #:tests? #t + #:test-command #~(list "ert-runner"))) + (native-inputs + (list emacs-ert-runner)) + (home-page "https://github.com/mpdel/libmpdel") (synopsis "Emacs library to communicate with Music Player Daemon (MPD)") (description "LibMPDel is an Emacs library client to communicate with Music Player @@ -25647,20 +25662,20 @@ music.") (define-public emacs-mpdel (package (name "emacs-mpdel") - (version "1.0.0") + (version "2.0.0") (source (origin (method git-fetch) (uri (git-reference - (url "https://gitea.petton.fr/mpdel/mpdel.git") + (url "https://github.com/mpdel/mpdel") (commit (string-append "v" version)))) (file-name (git-file-name name version)) (sha256 (base32 - "0pyyvbzskr44dxbmlp3y0r6s459fd51cvwjmnjaqxfxflr5v891g")))) + "1wg48z0g6qqsd38r2ydba8dp7cq72cnkzshmhj6900xak6f5ywfd")))) (build-system emacs-build-system) - (inputs - (list emacs-libmpdel)) + (propagated-inputs + (list emacs-libmpdel emacs-navigel)) (home-page "https://gitea.petton.fr/mpdel/mpdel") (synopsis "Emacs user interface for Music Player Daemon (MPD)") (description @@ -25669,6 +25684,36 @@ next, volume) and display and control the current playlist as well as your stored playlists.") (license license:gpl3+))) +(define-public emacs-navigel + (package + (name "emacs-navigel") + (version "0.7.0") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/DamienCassou/navigel") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "0v9f7wb6yghds3hjj8x5di6gfa8n5kjwhav7la1ca2zwgs2c1a9p")))) + (build-system emacs-build-system) + (arguments + (list + #:tests? #t + #:test-command #~(list "ert-runner"))) + (native-inputs + (list emacs-ert-runner)) + (propagated-inputs + (list emacs-tablist)) + (home-page "https://github.com/DamienCassou/navigel") + (synopsis "Emacs library for creating tabulated-list based user-interfaces") + (description + "The navigel package is a library that makes it simpler for Emacs Lisp +developers to define user-interfaces based on tablists (also known as +tabulated-lists).") + (license license:gpl3+))) + (define-public emacs-vterm (let ((version "0.0.1") (revision "1") @@ -26785,7 +26830,7 @@ commands (a prefix and a suffix) we prefer to call it just a \"transient\".") (define-public emacs-forge (package (name "emacs-forge") - (version "0.3.1") + (version "0.3.2") (source (origin (method git-fetch) @@ -26794,7 +26839,7 @@ commands (a prefix and a suffix) we prefer to call it just a \"transient\".") (commit (string-append "v" version)))) (file-name (git-file-name name version)) (sha256 - (base32 "112mghydfzrbiwnzrb2f9d74y6ja702157p66ss94kqps0lj7rkp")))) + (base32 "0p1jlq169hpalhzmjm3h4q3x5xr9kdmz0qig8jwfvisyqay5vbih")))) (build-system emacs-build-system) (arguments `(#:tests? #f ;no tests @@ -27911,7 +27956,7 @@ or regions to a REPL from ~a buffers.") language)))) (make-emacs-eval-in-repl "elm" #:inputs (list emacs-elm-mode))) (define-public emacs-eval-in-repl-erlang - (make-emacs-eval-in-repl "erlang" #:inputs (list emacs-erlang))) + (make-emacs-eval-in-repl "erlang" #:inputs (delay (list emacs-erlang)))) (define-public emacs-eval-in-repl-geiser (make-emacs-eval-in-repl "geiser" #:language "Scheme" diff --git a/gnu/packages/emacs.scm b/gnu/packages/emacs.scm index ae6de00844..6c9a991cf7 100644 --- a/gnu/packages/emacs.scm +++ b/gnu/packages/emacs.scm @@ -381,8 +381,8 @@ languages.") (license license:gpl3+))) (define-public emacs-next - (let ((commit "0a5477b448e6b62bcedc1803e531ec7686eea48d") - (revision "1")) + (let ((commit "4aeb80ccecd0dc3f3b3f567779632a0f23476a09") + (revision "2")) (package (inherit emacs) (name "emacs-next") @@ -395,9 +395,13 @@ languages.") (url "https://git.savannah.gnu.org/git/emacs.git/") (commit commit))) (file-name (git-file-name name version)) + ;; emacs-source-date-epoch.patch is no longer necessary + (patches (search-patches "emacs-exec-path.patch" + "emacs-fix-scheme-indent-function.patch" + "emacs-native-comp-driver-options.patch")) (sha256 (base32 - "0dqmrawkvbypxp8gcnspnhhmfamzp3l62gfgp1pw2l6svz58v991")))) + "0rr2iiqsma37gbg4irn69cc2f3mr83ndycg0dsl3ba96i5fw60zs")))) (inputs (modify-inputs (package-inputs emacs) (prepend sqlite))) diff --git a/gnu/packages/emulators.scm b/gnu/packages/emulators.scm index 38795b703c..3528a24a0e 100644 --- a/gnu/packages/emulators.scm +++ b/gnu/packages/emulators.scm @@ -718,7 +718,7 @@ The following systems are supported: (define-public mgba (package (name "mgba") - (version "0.9.3") + (version "0.10.0") (source (origin (method git-fetch) @@ -727,7 +727,7 @@ The following systems are supported: (commit version))) (file-name (git-file-name name version)) (sha256 - (base32 "1bg4ax5gjkr6d4cpzsgzv3bpa3i2c2b1ckwrjklqiy835b5ni6yi")) + (base32 "14miy6fgg4dy2pp0w17pnqzizrj6yf468i5l7rswn3yszpd5rn6s")) (modules '((guix build utils))) (snippet ;; Make sure we don't use the bundled software. diff --git a/gnu/packages/entr.scm b/gnu/packages/entr.scm index 29fd5b7db6..b74a00fec3 100644 --- a/gnu/packages/entr.scm +++ b/gnu/packages/entr.scm @@ -5,6 +5,7 @@ ;;; Copyright © 2019, 2020 Tobias Geerinckx-Rice <me@tobias.gr> ;;; Copyright © 2020 Jakub Kądziołka <kuba@kadziolka.net> ;;; Copyright © 2021 Solene Rapenne <solene@perso.pw> +;;; Copyright © 2022 jgart <jgart@dismail.de> ;;; ;;; This file is part of GNU Guix. ;;; @@ -34,14 +35,14 @@ (define-public entr (package (name "entr") - (version "4.9") + (version "5.2") (source (origin (method url-fetch) - (uri (string-append "http://entrproject.org/code/entr-" + (uri (string-append "https://eradman.com/entrproject/code/entr-" version ".tar.gz")) (sha256 (base32 - "18h58k69f0qmqkknbcnhm5dz7mv5gr2blcq88qr62vz4zg9a8mp2")))) + "1063b33bqggyqd0h7cvcvznpgiy9s2zqkdsc1q622xdh8sfk0zi3")))) (build-system gnu-build-system) (arguments `(#:test-target "test" @@ -67,7 +68,7 @@ #t))))) (inputs (list bash coreutils ncurses)) - (home-page "http://entrproject.org/") + (home-page "https://eradman.com/entrproject/") (synopsis "Run arbitrary commands when files change") (description "entr is a zero-configuration tool with no external build or run-time diff --git a/gnu/packages/fonts.scm b/gnu/packages/fonts.scm index 2d653abf32..63f274e59d 100644 --- a/gnu/packages/fonts.scm +++ b/gnu/packages/fonts.scm @@ -118,14 +118,18 @@ titling.") (package (name "font-ibm-plex") (version "6.1.1") + ;; We prefer git-fetch since it lets us get the opentype, truetype and web + ;; fonts all in one download. The zip archive releases separate the + ;; opentype, truetype and web fonts into three separate archives. (source (origin - (method url-fetch) - (uri (string-append - "https://github.com/IBM/plex/releases/download/" - "v" version "/OpenType.zip")) + (method git-fetch) + (uri (git-reference + (url "https://github.com/IBM/plex") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) (sha256 (base32 - "1z9nxac9ha6gqz5yvfy5lp6hyl39f8f8hdrw3llcp89rdpjfqdn9")))) + "1jxyd0zl7jssn7mwz8x5xvjmw59x4mn82s2kywf9583k1pg949k1")))) (build-system font-build-system) (home-page "https://github.com/IBM/plex") (synopsis "IBM Plex typeface") diff --git a/gnu/packages/gl.scm b/gnu/packages/gl.scm index 5f54aa7483..68c751ace5 100644 --- a/gnu/packages/gl.scm +++ b/gnu/packages/gl.scm @@ -756,7 +756,7 @@ OpenGL graphics API.") (define-public libglvnd (package (name "libglvnd") - (version "1.3.4") + (version "1.5.0") (home-page "https://gitlab.freedesktop.org/glvnd/libglvnd") (source (origin (method git-fetch) @@ -766,7 +766,7 @@ OpenGL graphics API.") (file-name (git-file-name name version)) (sha256 (base32 - "0phvgg2h3pcz3x39gaymwb37bnw1s26clq9wsj0zx398zmp3dwpk")))) + "1nvlcwzivrdchp70i2l7ic7qdlsdmlsb0ckydscr43rhqldswx69")))) (build-system meson-build-system) (arguments '(#:configure-flags '("-Dx11=enabled") diff --git a/gnu/packages/gnome.scm b/gnu/packages/gnome.scm index 0c9cf40c65..bae585ea6c 100644 --- a/gnu/packages/gnome.scm +++ b/gnu/packages/gnome.scm @@ -7305,7 +7305,7 @@ a secret password store, an adblocker, and a modern UI.") libhandy libnotify libportal - librsvg ; for loading SVG files + (librsvg-for-system) ; for loading SVG files libsecret libsoup libxslt diff --git a/gnu/packages/golang.scm b/gnu/packages/golang.scm index 767f2dcd7f..1e37732d10 100644 --- a/gnu/packages/golang.scm +++ b/gnu/packages/golang.scm @@ -1261,6 +1261,83 @@ proxy protocol.") configuration file.") (license license:isc))) +(define-public go-github-com-savsgio-gotils + (let ((commit "52f3993e8d6d2629f18e7b7383b7f54a3d3f1d1f") + (revision "0")) + (package + (name "go-github-com-savsgio-gotils") + (version (git-version "0.0.0" revision commit)) + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/savsgio/gotils") + (commit commit))) + (file-name (git-file-name name version)) + (sha256 + (base32 "0qr7i62h53frcig26vj027r2hn9zxsjzd7113wvbxy7qpprjjbjb")))) + (build-system go-build-system) + (native-inputs + (list go-github-com-google-uuid + go-github-com-valyala-bytebufferpool)) + (arguments + '(#:import-path "github.com/savsgio/gotils" + #:phases + (modify-phases %standard-phases + (replace 'build + (lambda arguments + (for-each + (lambda (directory) + (apply (assoc-ref %standard-phases 'build) + `(,@arguments #:import-path ,directory))) + (list + "github.com/savsgio/gotils/bytes" + "github.com/savsgio/gotils/encoding/base64" + "github.com/savsgio/gotils/math" + "github.com/savsgio/gotils/nocopy" + "github.com/savsgio/gotils/strconv" + "github.com/savsgio/gotils/strings" + "github.com/savsgio/gotils/sync" + "github.com/savsgio/gotils/time" + "github.com/savsgio/gotils/uuid")))) + (replace 'check + (lambda arguments + (for-each + (lambda (directory) + (apply (assoc-ref %standard-phases 'check) + `(,@arguments #:import-path ,directory))) + (list + "github.com/savsgio/gotils/bytes" + "github.com/savsgio/gotils/encoding/base64" + "github.com/savsgio/gotils/math" + "github.com/savsgio/gotils/nocopy" + "github.com/savsgio/gotils/strconv" + "github.com/savsgio/gotils/strings" + "github.com/savsgio/gotils/sync" + "github.com/savsgio/gotils/time" + "github.com/savsgio/gotils/uuid")))) + (replace 'install + (lambda arguments + (for-each + (lambda (directory) + (apply (assoc-ref %standard-phases 'install) + `(,@arguments #:import-path ,directory))) + (list + "github.com/savsgio/gotils/bytes" + "github.com/savsgio/gotils/encoding/base64" + "github.com/savsgio/gotils/math" + "github.com/savsgio/gotils/nocopy" + "github.com/savsgio/gotils/strconv" + "github.com/savsgio/gotils/strings" + "github.com/savsgio/gotils/sync" + "github.com/savsgio/gotils/time" + "github.com/savsgio/gotils/uuid"))))))) + (home-page "https://github.com/savsgio/gotils") + (synopsis "Golang utlities") + (description + "Golang utlities to make your life easier with zero allocations.") + (license license:asl2.0)))) + (define-public go-github-com-riobard-go-bloom (let ((commit "cdc8013cb5b3eb0efebec85f0e904efccac42df9") (revision "0")) diff --git a/gnu/packages/haskell-crypto.scm b/gnu/packages/haskell-crypto.scm index 422e00035b..6ddb459138 100644 --- a/gnu/packages/haskell-crypto.scm +++ b/gnu/packages/haskell-crypto.scm @@ -260,7 +260,7 @@ the C implementation.") (build-system haskell-build-system) (arguments `(#:cabal-revision - ("1" "0v5ppc7r2lxbk49h1kwj4b5vyb1dw2fnppykvp5m9rm0p3vhlykr") + ("1" "1hyzqv30rpj920ddnr0zypyjjlh52vyp2d140pn2byayj820rkgs") #:tests? #f)) ; TODO: tasty ==1.1.* (native-inputs (list ghc-base16-bytestring ghc-sha ghc-tasty ghc-tasty-hunit diff --git a/gnu/packages/haskell-xyz.scm b/gnu/packages/haskell-xyz.scm index db653f8c93..849db40e6e 100644 --- a/gnu/packages/haskell-xyz.scm +++ b/gnu/packages/haskell-xyz.scm @@ -53,6 +53,7 @@ #:use-module (gnu packages compression) #:use-module (gnu packages databases) #:use-module (gnu packages emacs) + #:use-module (gnu packages freedesktop) #:use-module (gnu packages gl) #:use-module (gnu packages graphviz) #:use-module (gnu packages gtk) @@ -7217,7 +7218,7 @@ online}.") (arguments `(#:cabal-revision ("1" - "1f0whk5ncanxfjjanrf6rqyncig2xgc5mh2j0sqy3nrlyjr9aqq9"))) + "1xllyf26ypk37k807g5v6fl1449mhpvk18dljmqgwj723n0v8rpj"))) (home-page "https://github.com/chrisdone/lucid") (synopsis "Haskell DSL for rendering HTML") (description "Clear to write, read and edit Haskell DSL for HTML. @@ -16118,6 +16119,33 @@ data Dec a pages.") (license license:bsd-3))) +(define-public ghc-open-browser + (package + (name "ghc-open-browser") + (version "0.2.1.0") + (source (origin + (method url-fetch) + (uri (hackage-uri "open-browser" version)) + (sha256 + (base32 + "0rna8ir2cfp8gk0rd2q60an51jxc08lx4gl0liw8wwqgh1ijxv8b")))) + (build-system haskell-build-system) + (arguments + (list + #:phases + #~(modify-phases %standard-phases + (add-before 'configure 'patch-xdg-open + (lambda* (#:key inputs #:allow-other-keys) + (let ((xdg-open (assoc-ref inputs "xdg-utils"))) + (substitute* "lib/Web/Browser/Linux.hs" + (("xdg-open") + (search-input-file inputs "/bin/xdg-open"))))))))) + (inputs (list xdg-utils)) + (home-page "https://github.com/rightfold/open-browser") + (synopsis "Open a web browser from Haskell") + (description "Haskell library for opening the web browser.") + (license license:bsd-3))) + (define-public ghc-singleton-bool (package (name "ghc-singleton-bool") diff --git a/gnu/packages/linux.scm b/gnu/packages/linux.scm index 7ddbb2f8bd..26dfcae2c5 100644 --- a/gnu/packages/linux.scm +++ b/gnu/packages/linux.scm @@ -65,6 +65,7 @@ ;;; Copyright © 2022 Rene Saavedra <nanuui@protonmail.com> ;;; Copyright © 2022 muradm <mail@muradm.net> ;;; Copyright © 2022 Denis 'GNUtoo' Carikli <GNUtoo@cyberdimension.org> +;;; Copyright © 2022 Hunter Jozwiak <hunter.t.joz@gmail.com> ;;; ;;; This file is part of GNU Guix. @@ -354,7 +355,7 @@ corresponding UPSTREAM-SOURCE (an origin), using the given DEBLOB-SCRIPTS." ;; The current "stable" kernels. That is, the most recently released major ;; versions that are still supported upstream. -(define-public linux-libre-5.19-version "5.19.14") +(define-public linux-libre-5.19-version "5.19.15") (define-public linux-libre-5.19-gnu-revision "gnu") (define deblob-scripts-5.19 (linux-libre-deblob-scripts @@ -364,7 +365,7 @@ corresponding UPSTREAM-SOURCE (an origin), using the given DEBLOB-SCRIPTS." (base32 "092myqjixvy1k3ylcj0hfc4whfxapjvxsxm4gk30a3jv5dnh7mly"))) (define-public linux-libre-5.19-pristine-source (let ((version linux-libre-5.19-version) - (hash (base32 "1h8srn3fw4vw61qi0xxlk9fq0fqq4wl7fbrzz7sivdd8qkhjgv8x"))) + (hash (base32 "06zband5q6m9imyvn4y4naafdakjcj00rg23227cagnv8wwf71j6"))) (make-linux-libre-source version (%upstream-linux-source version hash) deblob-scripts-5.19))) @@ -373,7 +374,7 @@ corresponding UPSTREAM-SOURCE (an origin), using the given DEBLOB-SCRIPTS." ;; The "longterm" kernels — the older releases with long-term upstream support. ;; Here are the support timelines: ;; <https://www.kernel.org/category/releases.html> -(define-public linux-libre-5.15-version "5.15.72") +(define-public linux-libre-5.15-version "5.15.73") (define-public linux-libre-5.15-gnu-revision "gnu") (define deblob-scripts-5.15 (linux-libre-deblob-scripts @@ -383,7 +384,7 @@ corresponding UPSTREAM-SOURCE (an origin), using the given DEBLOB-SCRIPTS." (base32 "048r4synfax2ajyzlmp672b68yshxwlfccdah2vz1kh88rqfmgsc"))) (define-public linux-libre-5.15-pristine-source (let ((version linux-libre-5.15-version) - (hash (base32 "1aq75z2spa1jvxv9m89gsaxza29n25k8j1f0pg9yj6j7bcxk5430"))) + (hash (base32 "0pbi640llcdbx57vwwzc5axa75w0y5rixa9r752h725f4naz08m8"))) (make-linux-libre-source version (%upstream-linux-source version hash) deblob-scripts-5.15))) @@ -700,6 +701,11 @@ for ARCH and optionally VARIANT, or #f if there is no such configuration." ("CONFIG_ZSWAP" . #t) ("CONFIG_ZSMALLOC" . #t) ("CONFIG_ZRAM" . m) + ;; Accessibility support. + ("CONFIG_ACCESSIBILITY" . #t) + ("CONFIG_A11Y_BRAILLE_CONSOLE" . #t) + ("CONFIG_SPEAKUP" . m) + ("CONFIG_SPEAKUP_SYNTH_SOFT" . m) ;; Modules required for initrd: ("CONFIG_NET_9P" . m) ("CONFIG_NET_9P_VIRTIO" . m) @@ -933,7 +939,8 @@ It has been modified to remove all non-free binary blobs.") (make-linux-libre* linux-libre-5.19-version linux-libre-5.19-gnu-revision linux-libre-5.19-source - '("x86_64-linux" "i686-linux" "armhf-linux" "aarch64-linux" "riscv64-linux") + '("x86_64-linux" "i686-linux" "armhf-linux" + "aarch64-linux" "powerpc64le-linux" "riscv64-linux") #:configuration-file kernel-config)) (define-public linux-libre-version linux-libre-5.19-version) @@ -946,42 +953,47 @@ It has been modified to remove all non-free binary blobs.") (make-linux-libre* linux-libre-5.15-version linux-libre-5.15-gnu-revision linux-libre-5.15-source - '("x86_64-linux" "i686-linux" "armhf-linux" "aarch64-linux" "riscv64-linux") + '("x86_64-linux" "i686-linux" "armhf-linux" + "aarch64-linux" "powerpc64le-linux" "riscv64-linux") #:configuration-file kernel-config)) (define-public linux-libre-5.10 (make-linux-libre* linux-libre-5.10-version linux-libre-5.10-gnu-revision linux-libre-5.10-source - '("x86_64-linux" "i686-linux" "armhf-linux" "aarch64-linux" "riscv64-linux") + '("x86_64-linux" "i686-linux" "armhf-linux" + "aarch64-linux" "powerpc64le-linux" "riscv64-linux") #:configuration-file kernel-config)) (define-public linux-libre-5.4 (make-linux-libre* linux-libre-5.4-version linux-libre-5.4-gnu-revision linux-libre-5.4-source - '("x86_64-linux" "i686-linux" "armhf-linux" "aarch64-linux" "riscv64-linux") + '("x86_64-linux" "i686-linux" "armhf-linux" + "aarch64-linux" "powerpc64le-linux" "riscv64-linux") #:configuration-file kernel-config)) (define-public linux-libre-4.19 (make-linux-libre* linux-libre-4.19-version linux-libre-4.19-gnu-revision linux-libre-4.19-source - '("x86_64-linux" "i686-linux" "armhf-linux" "aarch64-linux") + '("x86_64-linux" "i686-linux" "armhf-linux" + "aarch64-linux" "powerpc64le-linux") #:configuration-file kernel-config)) (define-public linux-libre-4.14 (make-linux-libre* linux-libre-4.14-version linux-libre-4.14-gnu-revision linux-libre-4.14-source - '("x86_64-linux" "i686-linux" "armhf-linux") + '("x86_64-linux" "i686-linux" "armhf-linux" + "powerpc64le-linux") #:configuration-file kernel-config)) (define-public linux-libre-4.9 (make-linux-libre* linux-libre-4.9-version linux-libre-4.9-gnu-revision linux-libre-4.9-source - '("x86_64-linux" "i686-linux") + '("x86_64-linux" "i686-linux" "powerpc64le-linux") #:configuration-file kernel-config)) ;; Linux-Libre-LTS points to the *newest* released long-term support version of @@ -1169,7 +1181,7 @@ It has been modified to remove all non-free binary blobs.") linux-libre-5.19-gnu-revision linux-libre-5.19-source '("x86_64-linux" "i686-linux" "armhf-linux" - "aarch64-linux" "riscv64-linux") + "aarch64-linux" "powerpc64le-linux" "riscv64-linux") #:extra-version "bpf" #:configuration-file kernel-config #:extra-options diff --git a/gnu/packages/maths.scm b/gnu/packages/maths.scm index 79664918cb..a3089efabb 100644 --- a/gnu/packages/maths.scm +++ b/gnu/packages/maths.scm @@ -7690,7 +7690,8 @@ when an application performs repeated divisions by the same divisor.") (sha256 (base32 "05mm4vrxsac35hjf5djif9r6rdxj9ippg97ia3p6q6b8lrp7srwv")) - (patches (search-patches "fp16-system-libraries.patch")))) + (patches (search-patches "fp16-implicit-double.patch" + "fp16-system-libraries.patch")))) (build-system cmake-build-system) (arguments `(#:imported-modules ((guix build python-build-system) diff --git a/gnu/packages/messaging.scm b/gnu/packages/messaging.scm index 6516f46a54..11abde0959 100644 --- a/gnu/packages/messaging.scm +++ b/gnu/packages/messaging.scm @@ -2384,7 +2384,7 @@ for the Matrix protocol. It is built on to of @code{Boost.Asio}.") (define-public nheko (package (name "nheko") - (version "0.10.1") + (version "0.10.2") (source (origin (method git-fetch) @@ -2393,7 +2393,7 @@ for the Matrix protocol. It is built on to of @code{Boost.Asio}.") (commit (string-append "v" version)))) (file-name (git-file-name name version)) (sha256 - (base32 "0a3wvv7vzh60hvyzy6776v6wa9d6n020684dqbcl4dw608mf4ahk")) + (base32 "114hbv58209bwar6qjdjg2l1vh3xk20ppv6n301i7zkmwrf7q9w2")) (modules '((guix build utils))) (snippet '(begin diff --git a/gnu/packages/mpd.scm b/gnu/packages/mpd.scm index 05737f3a86..329574e7f7 100644 --- a/gnu/packages/mpd.scm +++ b/gnu/packages/mpd.scm @@ -9,7 +9,7 @@ ;;; Copyright © 2019 Evan Straw <evan.straw99@gmail.com> ;;; Copyright © 2020, 2021 Ricardo Wurmus <rekado@elephly.net> ;;; Copyright © 2020 Lars-Dominik Braun <lars@6xq.net> -;;; Copyright © 2020, 2021 Simon Streit <simon@netpanic.org> +;;; Copyright © 2020–2022 Simon Streit <simon@netpanic.org> ;;; Copyright © 2021 Noah Evans <noah@nevans.me> ;;; ;;; This file is part of GNU Guix. @@ -63,6 +63,7 @@ #:use-module (gnu packages glib) #:use-module (gnu packages linux) #:use-module (gnu packages mp3) + #:use-module (gnu packages music) #:use-module (gnu packages ncurses) #:use-module (gnu packages pcre) #:use-module (gnu packages pkg-config) @@ -442,7 +443,7 @@ support") (define-public cantata (package (name "cantata") - (version "2.4.2") + (version "2.5.0") (source (origin (method url-fetch) (uri (string-append "https://github.com/CDrummond/" @@ -450,16 +451,18 @@ support") "cantata-" version ".tar.bz2")) (sha256 (base32 - "10pcrpmb4n1mkgr21xd580nrbmh57q7s72cbs1zay847hc65vliy")))) + "090ph8kb2vicjaajn64kmfppb90ix0pnxj525shglyjn7ymh0zpb")))) (build-system cmake-build-system) (arguments `(#:tests? #f)) ; No test suite (native-inputs (list pkg-config)) (inputs - (list eudev + (list avahi + eudev ffmpeg libcdio-paranoia + libmusicbrainz libebur128 libmtp mpg123 @@ -480,42 +483,41 @@ artists along with albumart.") (define-public mcg (package (name "mcg") - (version "2.1.2") - (source - (origin - (method git-fetch) - (uri - (git-reference - (url "https://gitlab.com/coderkun/mcg") - (commit (string-append "v" version)))) - (file-name (git-file-name name version)) - (sha256 - (base32 - "01iqxydssxyi4s644dwl64vm7xhn0szd99hdpywbipvb7kwp5196")))) - (build-system python-build-system) - (native-inputs - `(("glib:bin" ,glib "bin") - ("gobject-introspection" ,gobject-introspection) - ("pkg-config" ,pkg-config))) - (inputs - (list avahi dconf gsettings-desktop-schemas gtk+ python-pygobject)) + (version "3.1") + (source (origin + (method git-fetch) + (uri (git-reference + (url "https://gitlab.com/coderkun/mcg") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 + "087d3gvx8z1yj7rg9d9h1x02vkw57h4v6xf5pxqyhqyk2435kk17")))) + (build-system meson-build-system) (arguments - `(#:imported-modules ((guix build glib-or-gtk-build-system) - ,@%python-build-system-modules) - #:modules ((guix build python-build-system) - ((guix build glib-or-gtk-build-system) #:prefix glib-or-gtk:) - (guix build utils)) - #:phases - (modify-phases %standard-phases - (add-after 'install 'wrap-program - (lambda* (#:key outputs #:allow-other-keys) - (let ((prog (string-append (assoc-ref outputs "out") - "/bin/mcg"))) - (wrap-program prog - `("GUIX_PYTHONPATH" = (,(getenv "GUIX_PYTHONPATH"))) - `("GI_TYPELIB_PATH" = (,(getenv "GI_TYPELIB_PATH"))))))) - (add-after 'wrap-program 'glib-or-gtk-wrap - (assoc-ref glib-or-gtk:%standard-phases 'glib-or-gtk-wrap))))) + (list + #:glib-or-gtk? #t + #:phases + #~(modify-phases %standard-phases + (add-after 'install 'wrap-program + (lambda* (#:key outputs #:allow-other-keys) + (let ((prog (string-append (assoc-ref outputs "out") + "/bin/mcg"))) + (wrap-program prog + `("GUIX_PYTHONPATH" = (,(getenv "GUIX_PYTHONPATH"))) + `("GI_TYPELIB_PATH" = (,(getenv "GI_TYPELIB_PATH")))))))))) + (inputs (list avahi + dconf + gsettings-desktop-schemas + gtk+ + python + python-pygobject)) + (native-inputs (list desktop-file-utils + gettext-minimal + `(,glib "bin") + gobject-introspection + `(,gtk+ "bin") + pkg-config)) (synopsis "Covergrid for the MPD") (description "mcg (CoverGrid) is a client for the Music Player Daemon (MPD), focusing diff --git a/gnu/packages/package-management.scm b/gnu/packages/package-management.scm index 7b5363aa8c..0d7f8a23ca 100644 --- a/gnu/packages/package-management.scm +++ b/gnu/packages/package-management.scm @@ -1366,8 +1366,8 @@ environments.") "0k9zkdyyzir3fvlbcfcqy17k28b51i20rpbjwlx2i1mwd2pw9cxc"))))))) (define-public guix-build-coordinator - (let ((commit "2cd06f2cf8a20f719aa3823eeffac8c39b768504") - (revision "62")) + (let ((commit "b15be71ded7a178857ccabea37f000248385f514") + (revision "63")) (package (name "guix-build-coordinator") (version (git-version "0" revision commit)) @@ -1378,7 +1378,7 @@ environments.") (commit commit))) (sha256 (base32 - "0jy7scw1vwgpz54yjzhw0kavws8f54xk287axmfd0dqqvbbb164l")) + "08d794mq9p4n26b6d0qn9790qavxl4s9l8yp6rwbfc8l10j2gksb")) (file-name (string-append name "-" version "-checkout")))) (build-system gnu-build-system) (arguments diff --git a/gnu/packages/patches/emacs-native-comp-driver-options.patch b/gnu/packages/patches/emacs-native-comp-driver-options.patch new file mode 100644 index 0000000000..308c4f1212 --- /dev/null +++ b/gnu/packages/patches/emacs-native-comp-driver-options.patch @@ -0,0 +1,17 @@ +We substitute this anyway, so let's make it easier to substitute. + +--- a/lisp/emacs-lisp/comp.el ++++ b/lisp/emacs-lisp/comp.el +@@ -178,8 +178,7 @@ and above." + :type '(repeat string) + :version "28.1") + +-(defcustom native-comp-driver-options (when (eq system-type 'darwin) +- '("-Wl,-w")) ++(defcustom native-comp-driver-options nil + "Options passed verbatim to the native compiler's back-end driver. + Note that not all options are meaningful; typically only the options + affecting the assembler and linker are likely to be useful. +-- +2.38.0 + diff --git a/gnu/packages/patches/fp16-implicit-double.patch b/gnu/packages/patches/fp16-implicit-double.patch new file mode 100644 index 0000000000..87ed9a6a53 --- /dev/null +++ b/gnu/packages/patches/fp16-implicit-double.patch @@ -0,0 +1,23 @@ +Prevent implicit conversion of float to double to avoid precision +error on i686. + + https://github.com/Maratyszcza/FP16/issues/20 + +Taken from Debian: + + https://salsa.debian.org/deeplearning-team/fp16/-/blob/master/debian/patches/ftbfs-i386.patch + +Index: fp16/include/fp16/fp16.h +=================================================================== +--- fp16.orig/include/fp16/fp16.h ++++ fp16/include/fp16/fp16.h +@@ -228,7 +228,8 @@ static inline uint16_t fp16_ieee_from_fp + const float scale_to_inf = fp32_from_bits(UINT32_C(0x77800000)); + const float scale_to_zero = fp32_from_bits(UINT32_C(0x08800000)); + #endif +- float base = (fabsf(f) * scale_to_inf) * scale_to_zero; ++ const volatile float base_inf = fabsf(f) * scale_to_inf; ++ float base = base_inf * scale_to_zero; + + const uint32_t w = fp32_to_bits(f); + const uint32_t shl1_w = w + w; diff --git a/gnu/packages/patches/gemmi-fix-pegtl-usage.patch b/gnu/packages/patches/gemmi-fix-pegtl-usage.patch new file mode 100644 index 0000000000..3667474847 --- /dev/null +++ b/gnu/packages/patches/gemmi-fix-pegtl-usage.patch @@ -0,0 +1,31 @@ +Use the definitions from (newer) upstream PEGTL. + +diff --git a/include/gemmi/cif.hpp b/include/gemmi/cif.hpp +index c7ffdb44..35d24210 100644 +--- a/include/gemmi/cif.hpp ++++ b/include/gemmi/cif.hpp +@@ -37,7 +37,6 @@ namespace pegtl = tao::pegtl; + namespace rules { + + template<int TableVal> struct lookup_char { +- using analyze_t = pegtl::analysis::generic<pegtl::analysis::rule_type::ANY>; + template<typename Input> static bool match(Input& in) { + if (!in.empty() && cif::char_table(in.peek_char()) == TableVal) { + if (TableVal == 2) // this set includes new-line +@@ -71,11 +70,11 @@ namespace rules { + struct ws_or_eof : pegtl::sor<whitespace, pegtl::eof> {}; + + // (b) Reserved words. +- struct str_data : TAOCPP_PEGTL_ISTRING("data_") {}; +- struct str_loop : TAOCPP_PEGTL_ISTRING("loop_") {}; +- struct str_global : TAOCPP_PEGTL_ISTRING("global_") {}; +- struct str_save : TAOCPP_PEGTL_ISTRING("save_") {}; +- struct str_stop : TAOCPP_PEGTL_ISTRING("stop_") {}; ++ struct str_data : TAO_PEGTL_ISTRING("data_") {}; ++ struct str_loop : TAO_PEGTL_ISTRING("loop_") {}; ++ struct str_global : TAO_PEGTL_ISTRING("global_") {}; ++ struct str_save : TAO_PEGTL_ISTRING("save_") {}; ++ struct str_stop : TAO_PEGTL_ISTRING("stop_") {}; + struct keyword : pegtl::sor<str_data, str_loop, str_global, + str_save, str_stop> {}; + diff --git a/gnu/packages/patches/gemmi-fix-sajson-types.patch b/gnu/packages/patches/gemmi-fix-sajson-types.patch new file mode 100644 index 0000000000..9633ddac8b --- /dev/null +++ b/gnu/packages/patches/gemmi-fix-sajson-types.patch @@ -0,0 +1,11 @@ +diff -ur a/include/gemmi/json.hpp b/include/gemmi/json.hpp +--- a/include/gemmi/json.hpp ++++ b/include/gemmi/json.hpp +@@ -38,6 +38,7 @@ + + inline std::string as_cif_value(const sajson::value& val) { + switch (val.get_type()) { ++ case sajson::TYPE_INTEGER: + case sajson::TYPE_DOUBLE: + return val.as_string(); + case sajson::TYPE_NULL: diff --git a/gnu/packages/patches/pocketfft-cpp-prefer-preprocessor-if.patch b/gnu/packages/patches/pocketfft-cpp-prefer-preprocessor-if.patch new file mode 100644 index 0000000000..028bdf2f89 --- /dev/null +++ b/gnu/packages/patches/pocketfft-cpp-prefer-preprocessor-if.patch @@ -0,0 +1,109 @@ +This patch replaces #ifndef POCKETFFT_NO_VECTORS by #if POCKETFFT_NO_VECTORS. +It also makes it the default, as SIMD instructions are not that well-suited +for substitutes. + +diff --git a/pocketfft_hdronly.h b/pocketfft_hdronly.h +index d75ada6..b2d0a23 100644 +--- a/pocketfft_hdronly.h ++++ b/pocketfft_hdronly.h +@@ -39,6 +39,10 @@ SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + #ifndef POCKETFFT_HDRONLY_H + #define POCKETFFT_HDRONLY_H + ++#ifndef POCKETFFT_NO_VECTORS ++#define POCKETFFT_NO_VECTORS 1 ++#endif ++ + #ifndef __cplusplus + #error This file is C++ and requires a C++ compiler. + #endif +@@ -106,29 +110,29 @@ constexpr bool FORWARD = true, + BACKWARD = false; + + // only enable vector support for gcc>=5.0 and clang>=5.0 +-#ifndef POCKETFFT_NO_VECTORS +-#define POCKETFFT_NO_VECTORS ++#if !(POCKETFFT_NO_VECTORS) ++#define POCKETFFT_NO_VECTORS 1 + #if defined(__INTEL_COMPILER) + // do nothing. This is necessary because this compiler also sets __GNUC__. + #elif defined(__clang__) + // AppleClang has their own version numbering + #ifdef __apple_build_version__ + # if (__clang_major__ > 9) || (__clang_major__ == 9 && __clang_minor__ >= 1) +-# undef POCKETFFT_NO_VECTORS ++#define POCKETFFT_NO_VECTORS 0 + # endif + #elif __clang_major__ >= 5 +-# undef POCKETFFT_NO_VECTORS ++#define POCKETFFT_NO_VECTORS 0 + #endif + #elif defined(__GNUC__) + #if __GNUC__>=5 +-#undef POCKETFFT_NO_VECTORS ++#define POCKETFFT_NO_VECTORS 0 + #endif + #endif + #endif + + template<typename T> struct VLEN { static constexpr size_t val=1; }; + +-#ifndef POCKETFFT_NO_VECTORS ++#if !(POCKETFFT_NO_VECTORS) + #if (defined(__AVX512F__)) + template<> struct VLEN<float> { static constexpr size_t val=16; }; + template<> struct VLEN<double> { static constexpr size_t val=8; }; +@@ -145,7 +149,7 @@ template<> struct VLEN<double> { static constexpr size_t val=2; }; + template<> struct VLEN<float> { static constexpr size_t val=4; }; + template<> struct VLEN<double> { static constexpr size_t val=2; }; + #else +-#define POCKETFFT_NO_VECTORS ++#define POCKETFFT_NO_VECTORS 1 + #endif + #endif + +@@ -180,7 +184,7 @@ template<typename T> class arr + T *p; + size_t sz; + +-#if defined(POCKETFFT_NO_VECTORS) ++#if POCKETFFT_NO_VECTORS + static T *ralloc(size_t num) + { + if (num==0) return nullptr; +@@ -3026,7 +3030,7 @@ class rev_iter + template<typename T> struct VTYPE {}; + template <typename T> using vtype_t = typename VTYPE<T>::type; + +-#ifndef POCKETFFT_NO_VECTORS ++#if !(POCKETFFT_NO_VECTORS) + template<> struct VTYPE<float> + { + using type = float __attribute__ ((vector_size (VLEN<float>::val*sizeof(float)))); +@@ -3139,7 +3143,7 @@ POCKETFFT_NOINLINE void general_nd(const cndarr<T> &in, ndarr<T> &out, + auto storage = alloc_tmp<T0>(in.shape(), len, sizeof(T)); + const auto &tin(iax==0? in : out); + multi_iter<vlen> it(tin, out, axes[iax]); +-#ifndef POCKETFFT_NO_VECTORS ++#if !(POCKETFFT_NO_VECTORS) + if (vlen>1) + while (it.remaining()>=vlen) + { +@@ -3245,7 +3249,7 @@ template<typename T> POCKETFFT_NOINLINE void general_r2c( + constexpr auto vlen = VLEN<T>::val; + auto storage = alloc_tmp<T>(in.shape(), len, sizeof(T)); + multi_iter<vlen> it(in, out, axis); +-#ifndef POCKETFFT_NO_VECTORS ++#if !(POCKETFFT_NO_VECTORS) + if (vlen>1) + while (it.remaining()>=vlen) + { +@@ -3300,7 +3304,7 @@ template<typename T> POCKETFFT_NOINLINE void general_c2r( + constexpr auto vlen = VLEN<T>::val; + auto storage = alloc_tmp<T>(out.shape(), len, sizeof(T)); + multi_iter<vlen> it(in, out, axis); +-#ifndef POCKETFFT_NO_VECTORS ++#if !(POCKETFFT_NO_VECTORS) + if (vlen>1) + while (it.remaining()>=vlen) + { diff --git a/gnu/packages/patches/rdkit-unbundle-external-dependencies.patch b/gnu/packages/patches/rdkit-unbundle-external-dependencies.patch new file mode 100644 index 0000000000..8ee0611d3b --- /dev/null +++ b/gnu/packages/patches/rdkit-unbundle-external-dependencies.patch @@ -0,0 +1,384 @@ +Remove CMake code for downloading and builing bundled dependencies: +They are packaged separately as rapidjson, avalon-toolkit, freesasa, +ringdecomposerlib and yaehmop. + +diff --git a/Code/GraphMol/MolInterchange/CMakeLists.txt b/Code/GraphMol/MolInterchange/CMakeLists.txt +index 1673386a4..c3504e6f1 100644 +--- a/Code/GraphMol/MolInterchange/CMakeLists.txt ++++ b/Code/GraphMol/MolInterchange/CMakeLists.txt +@@ -1,18 +1,3 @@ +- +-if(NOT EXISTS "${CMAKE_SOURCE_DIR}/External/rapidjson-1.1.0") +- downloadAndCheckMD5("https://github.com/Tencent/rapidjson/archive/v1.1.0.tar.gz" +- "${CMAKE_SOURCE_DIR}/External/rapidjson-1.1.0.tar.gz" +- "badd12c511e081fec6c89c43a7027bce") +- execute_process(COMMAND ${CMAKE_COMMAND} -E tar zxf +- ${CMAKE_SOURCE_DIR}/External/rapidjson-1.1.0.tar.gz +- WORKING_DIRECTORY ${CMAKE_SOURCE_DIR}/External) +-else() +- message("-- Found RapidJSON source in ${CMAKE_SOURCE_DIR}/External") +-endif() +- +-include_directories(${CMAKE_SOURCE_DIR}/External/rapidjson-1.1.0/include) +- +- + rdkit_library(MolInterchange + Parser.cpp Writer.cpp + LINK_LIBRARIES GraphMol) +diff --git a/External/AvalonTools/AvalonTools.cpp b/External/AvalonTools/AvalonTools.cpp +index e6c382123..d83d80668 100644 +--- a/External/AvalonTools/AvalonTools.cpp ++++ b/External/AvalonTools/AvalonTools.cpp +@@ -24,15 +24,15 @@ + #include "AvalonTools.h" + + extern "C" { +-#include "local.h" +-#include "reaccs.h" +-#include "reaccsio.h" +-#include "utilities.h" +-#include "ssmatch.h" +-#include "smi2mol.h" +-#include "canonizer.h" +-#include "layout.h" +-#include "struchk.h" ++#include <avalontoolkit/local.h> ++#include <avalontoolkit/reaccs.h> ++#include <avalontoolkit/reaccsio.h> ++#include <avalontoolkit/utilities.h> ++#include <avalontoolkit/ssmatch.h> ++#include <avalontoolkit/smi2mol.h> ++#include <avalontoolkit/canonizer.h> ++#include <avalontoolkit/layout.h> ++#include <avalontoolkit/struchk.h> + + extern int RunStruchk(struct reaccs_molecule_t **mpp, + struct data_line_t *data_list); +diff --git a/External/AvalonTools/CMakeLists.txt b/External/AvalonTools/CMakeLists.txt +index 3e31195fc..314ba35b5 100644 +--- a/External/AvalonTools/CMakeLists.txt ++++ b/External/AvalonTools/CMakeLists.txt +@@ -2,107 +2,14 @@ if(NOT RDK_BUILD_AVALON_SUPPORT) + return() + endif(NOT RDK_BUILD_AVALON_SUPPORT) + +-if(NOT DEFINED AVALONTOOLS_DIR) +- set(AVALONTOOLS_DIR "${CMAKE_CURRENT_SOURCE_DIR}/SourceDistribution") +- set(fileToPatch "${CMAKE_CURRENT_SOURCE_DIR}/SourceDistribution/common/reaccsio.c") +- set(needDownload "TRUE") +- if(EXISTS "${fileToPatch}") +- file(READ "${fileToPatch}" buffer) +- if("${buffer}" MATCHES "//MyFree\\(\\(char \\*\\)tempdir\\);") +- set(needDownload "FALSE") +- endif() +- endif() +-else() +- string(REGEX REPLACE "\\\\" "/" AVALONTOOLS_DIR ${AVALONTOOLS_DIR}) +- set(needDownload "FALSE") +-endif() +- +-set(AVALON_SRC_PATH ${AVALONTOOLS_DIR}/common) +- +-if(needDownload) +- if(NOT DEFINED AVALONTOOLS_URL) +- set(AVALONTOOLS_URL "https://sourceforge.net/projects/avalontoolkit/files/AvalonToolkit_1.2/AvalonToolkit_1.2.0.source.tar") +- endif() +- if(NOT DEFINED AVALONTOOLS_MD5SUM) +- set(AVALONTOOLS_MD5SUM "092a94f421873f038aa67d4a6cc8cb54") +- endif() +- if(NOT DEFINED AVALONTOOLS_BASE) +- string(REGEX REPLACE "^.*/" "" AVALONTOOLS_BASE "${AVALONTOOLS_URL}") +- endif() +- downloadAndCheckMD5(${AVALONTOOLS_URL} "${CMAKE_CURRENT_SOURCE_DIR}/${AVALONTOOLS_BASE}" ${AVALONTOOLS_MD5SUM}) +- execute_process(COMMAND ${CMAKE_COMMAND} -E tar xf +- ${CMAKE_CURRENT_SOURCE_DIR}/AvalonToolkit_1.2.0.source.tar +- WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}) +- # apply patch to AvalonTools +- configure_file("${fileToPatch}" "${fileToPatch}.orig" COPYONLY) +- file(READ "${fileToPatch}" buffer) +- string(REGEX REPLACE "MyFree\\(\\(char \\*\\)tempdir\\);" +- "//MyFree((char *)tempdir);" buffer "${buffer}") +- file(WRITE "${fileToPatch}" "${buffer}") +-endif() + + if (MSVC) + add_definitions("/D_CRT_SECURE_NO_WARNINGS") + add_compile_options(/wd4224 /wd4101 /wd4018 /wd4996 /wd4244 /wd4305 /wd4013 /wd4146 /wd4334 /wd4715 /wd4715 /nologo) + endif(MSVC) + +-set(avalon_clib_srcs ${AVALON_SRC_PATH}/layout.c +- ${AVALON_SRC_PATH}/symboltable.c +- ${AVALON_SRC_PATH}/patclean.c +- ${AVALON_SRC_PATH}/utilities.c +- ${AVALON_SRC_PATH}/symbol_lists.c +- ${AVALON_SRC_PATH}/stereo.c +- ${AVALON_SRC_PATH}/set.c +- ${AVALON_SRC_PATH}/perceive.c +- ${AVALON_SRC_PATH}/local.c +- ${AVALON_SRC_PATH}/graph.c +- ${AVALON_SRC_PATH}/geometry.c +- ${AVALON_SRC_PATH}/forio.c +- ${AVALON_SRC_PATH}/depictutil.c +- ${AVALON_SRC_PATH}/denormal.c +- ${AVALON_SRC_PATH}/casutils.c +- ${AVALON_SRC_PATH}/ssmatch.c +- ${AVALON_SRC_PATH}/rtutils.c +- ${AVALON_SRC_PATH}/smi2mol.c +- ${AVALON_SRC_PATH}/didepict.c +- ${AVALON_SRC_PATH}/pattern.c +- ${AVALON_SRC_PATH}/canonizer.c +- ${AVALON_SRC_PATH}/aacheck.c +- ${AVALON_SRC_PATH}/fixcharges.c +- ${AVALON_SRC_PATH}/struchk.c +- ${AVALON_SRC_PATH}/reaccsio.c +- ${AVALON_SRC_PATH}/hashcode.c +- ) +- +-# we need this to ensure that builds continue +-# to work on linux systems with older versions +-# of glibc when we're building with gcc-4.1. +-# Without this flag, we'll endup requiring +-# glibc 2.7. +-if(CMAKE_SYSTEM_NAME STREQUAL "Linux") +- add_definitions(-D_GNU_SOURCE=1) +-endif() +- +-if(CMAKE_CXX_COMPILER_ID STREQUAL "Clang") +- set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-return-type -Wno-implicit-function-declaration -Wno-absolute-value -Wno-parentheses -Wno-logical-op-parentheses -Wno-dangling-else -Wno-format") +-endif() +-if(CMAKE_CXX_COMPILER_ID STREQUAL "GNU") +- set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wno-unused-result -Wformat-overflow=0 -Wformat=0 -Wno-format-security -Wno-implicit-function-declaration") +-endif() +- +- +- +-rdkit_library(avalon_clib ${avalon_clib_srcs}) +-target_compile_definitions(avalon_clib PRIVATE RDKIT_AVALONLIB_BUILD) +-if((MSVC AND RDK_INSTALL_DLLS_MSVC) OR ((NOT MSVC) AND WIN32)) +- set_target_properties(avalon_clib PROPERTIES WINDOWS_EXPORT_ALL_SYMBOLS TRUE) +-endif() +- +-include_directories(${CMAKE_CURRENT_SOURCE_DIR}) +-include_directories(${AVALON_SRC_PATH}) +- + rdkit_library(AvalonLib AvalonTools.cpp SHARED +- LINK_LIBRARIES avalon_clib SubstructMatch FileParsers SmilesParse GraphMol DataStructs ) ++ LINK_LIBRARIES -lavalontoolkit SubstructMatch FileParsers SmilesParse GraphMol DataStructs ) + target_compile_definitions(AvalonLib PRIVATE RDKIT_AVALONLIB_BUILD) + rdkit_headers(AvalonTools.h DEST GraphMol) + rdkit_test(testAvalonLib1 test1.cpp +diff --git a/External/AvalonTools/Wrap/pyAvalonTools.cpp b/External/AvalonTools/Wrap/pyAvalonTools.cpp +index fb24c497e..31997bc0a 100644 +--- a/External/AvalonTools/Wrap/pyAvalonTools.cpp ++++ b/External/AvalonTools/Wrap/pyAvalonTools.cpp +@@ -12,7 +12,7 @@ + #include <boost/cstdint.hpp> + + extern "C" { +-#include "struchk.h" ++#include <avalontoolkit/struchk.h> + } + + namespace python = boost::python; +diff --git a/External/FreeSASA/CMakeLists.txt b/External/FreeSASA/CMakeLists.txt +index 43dfbdc40..81165a143 100644 +--- a/External/FreeSASA/CMakeLists.txt ++++ b/External/FreeSASA/CMakeLists.txt +@@ -2,88 +2,8 @@ if(NOT RDK_BUILD_FREESASA_SUPPORT) + return() + endif(NOT RDK_BUILD_FREESASA_SUPPORT) + +-if(NOT DEFINED FREESASA_DIR) +- set(FREESASA_DIR "${CMAKE_CURRENT_SOURCE_DIR}/freesasa") +- set(needDownload "TRUE") +- if(EXISTS "${FREESASA_DIR}/src/freesasa.h") +- set(needDownload "FALSE") +- endif() +-endif() +- +-if(needDownload) +- # don't actually use the md5 here +- set(FREESASA_VERSION "2.0.3") +- set(FREESASA_SRC_DIR "${CMAKE_CURRENT_SOURCE_DIR}/freesasa-${FREESASA_VERSION}") +- if(NOT EXISTS "${FREESASA_SRC_DIR}/src") +- downloadAndCheckMD5("https://github.com/mittinatten/freesasa/releases/download/${FREESASA_VERSION}/freesasa-${FREESASA_VERSION}.tar.gz" +- "${CMAKE_CURRENT_SOURCE_DIR}/master.tar.gz" +- "") +- execute_process(COMMAND ${CMAKE_COMMAND} -E tar zxf +- ${CMAKE_CURRENT_SOURCE_DIR}/master.tar.gz +- WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}) +- message("Copying freesasa2.c to ${FREESASA_SRC_DIR}/src/freesasa2.c") +- file(COPY freesasa2.c DESTINATION ${FREESASA_SRC_DIR}/src/) +- else() +- message("FreeSASA found in ${FREESASA_SRC_DIR}, no download required") +- endif() +-endif() +- +-set(CMAKE_C_STANDARD 99) +- +-set (freesasa_clib_srcs +- ${FREESASA_SRC_DIR}/src/classifier.c +- ${FREESASA_SRC_DIR}/src/classifier_naccess.c +- ${FREESASA_SRC_DIR}/src/classifier_oons.c +- ${FREESASA_SRC_DIR}/src/classifier_protor.c +- ${FREESASA_SRC_DIR}/src/coord.c +- ${FREESASA_SRC_DIR}/src/freesasa2.c +- ${FREESASA_SRC_DIR}/src/lexer.c +- ${FREESASA_SRC_DIR}/src/log.c +- ${FREESASA_SRC_DIR}/src/nb.c +- ${FREESASA_SRC_DIR}/src/node.c +- ${FREESASA_SRC_DIR}/src/parser.c +- ${FREESASA_SRC_DIR}/src/pdb.c +- ${FREESASA_SRC_DIR}/src/rsa.c +- ${FREESASA_SRC_DIR}/src/sasa_lr.c +- ${FREESASA_SRC_DIR}/src/sasa_sr.c +- ${FREESASA_SRC_DIR}/src/selection.c +- ${FREESASA_SRC_DIR}/src/structure.c +- ${FREESASA_SRC_DIR}/src/util.c +- ) +-if((MSVC AND RDK_INSTALL_DLLS_MSVC) OR ((NOT MSVC) AND WIN32)) +- set(freesasa_additional_exports ${CMAKE_CURRENT_SOURCE_DIR}/additional_exports.def) +- file(WRITE ${freesasa_additional_exports} +- "EXPORTS\n" +- "freesasa_default_parameters DATA\n" +- "freesasa_protor_classifier DATA\n" +- "freesasa_naccess_classifier DATA\n" +- "freesasa_oons_classifier DATA\n" +- ) +- set (freesasa_clib_srcs +- ${freesasa_clib_srcs} +- ${freesasa_additional_exports} +- ) +-endif() +- +-set (freesasa_h ${FREESASA_SRC_DIR}/src/freesasa.h) +-file(READ ${freesasa_h} freesasa_h_data) +-string(REGEX REPLACE "(#include <stdio.h>)" "\\1\n#include <RDGeneral/export.h>" freesasa_h_data "${freesasa_h_data}") +-string(REGEX REPLACE "([^R][^D][^K][^I][^T][^_][^F][^R][^E][^E][^S][^A][^S][^A][^_][^C][^L][^I][^B][^_][^E][^X][^P][^O][^R][^T][^ ])(extern const)" "\\1RDKIT_FREESASA_CLIB_EXPORT \\2" freesasa_h_data "${freesasa_h_data}") +-file(WRITE ${freesasa_h} "${freesasa_h_data}") +- +-add_definitions(-DUSE_THREADS=0) +-add_definitions(-DUSE_JSON=0) +-add_definitions(-DUSE_XML=0) +-rdkit_library(freesasa_clib ${freesasa_clib_srcs}) +-target_compile_definitions(freesasa_clib PRIVATE RDKIT_FREESASALIB_BUILD) +- +-if((MSVC AND RDK_INSTALL_DLLS_MSVC) OR ((NOT MSVC) AND WIN32)) +- set_target_properties(freesasa_clib PROPERTIES WINDOWS_EXPORT_ALL_SYMBOLS TRUE) +-endif() +-include_directories("${FREESASA_SRC_DIR}/src") +- + rdkit_library(FreeSASALib RDFreeSASA.cpp SHARED +- LINK_LIBRARIES freesasa_clib GraphMol ) ++ LINK_LIBRARIES -lfreesasa GraphMol ) + target_compile_definitions(FreeSASALib PRIVATE RDKIT_FREESASALIB_BUILD) + + rdkit_headers(RDFreeSASA.h DEST GraphMol) +diff --git a/External/RingFamilies/CMakeLists.txt b/External/RingFamilies/CMakeLists.txt +index 08dd1fe04..66ecd5834 100644 +--- a/External/RingFamilies/CMakeLists.txt ++++ b/External/RingFamilies/CMakeLists.txt +@@ -1,47 +1,6 @@ +-add_custom_target(ringdecomposerlib_support ALL) +- + if(NOT RDK_USE_URF) + return() + endif(NOT RDK_USE_URF) + +-if(NOT DEFINED URFLIB_DIR) +- set(URFLIB_DIR "${CMAKE_CURRENT_SOURCE_DIR}/RingDecomposerLib/src/RingDecomposerLib") +-endif() +- +-if(NOT EXISTS "${URFLIB_DIR}/RingDecomposerLib.h") +- set(RELEASE_NO "1.1.3_rdkit") +- set(MD5 "e9a0bcdda8b921a35e812b9888a9a874") +- downloadAndCheckMD5("https://github.com/rareylab/RingDecomposerLib/archive/v${RELEASE_NO}.tar.gz" +- "${CMAKE_CURRENT_SOURCE_DIR}/RingDecomposerLib-v${RELEASE_NO}.tar.gz" ${MD5}) +- execute_process(COMMAND ${CMAKE_COMMAND} -E tar zxf +- ${CMAKE_CURRENT_SOURCE_DIR}/RingDecomposerLib-v${RELEASE_NO}.tar.gz +- WORKING_DIRECTORY ${CMAKE_CURRENT_SOURCE_DIR}) +- file(RENAME "RingDecomposerLib-${RELEASE_NO}" "RingDecomposerLib") +-else() +- message("-- Found RingDecomposerLib source in ${URFLIB_DIR}") +-endif() +- +-set(urflib_INCLUDE_DIRS ${URFLIB_DIR} +- CACHE STRING "RingDecomposerLib Include Dir" FORCE) +-file(GLOB URFSOURCES "${URFLIB_DIR}/*.c") +- +-#if((MSVC AND RDK_INSTALL_DLLS_MSVC) OR ((NOT MSVC) AND WIN32 AND (NOT RDK_INSTALL_STATIC_LIBS))) +-if(WIN32) +- set (ringdecomposerlib_h ${URFLIB_DIR}/RingDecomposerLib.h) +- file(READ ${ringdecomposerlib_h} ringdecomposerlib_h_data) +- if (NOT "${ringdecomposerlib_h_data}" MATCHES "RDKIT_URFLIB_BUILD") +- string(REGEX REPLACE "(#if[ ]+\\([ ]*defined[ ]*\\([ ]*_WIN32[ ]*\\)[ ]*&&[ ]*)(defined\\([ ]*_MSC_VER[ ]*\\))" "\\1!defined( RDL_WIN_STATIC )" ringdecomposerlib_h_data "${ringdecomposerlib_h_data}") +- string(REGEX REPLACE "([ ]*)(#define[ ]+RDL_API[ ]+__declspec)(\\([ ]*dllexport[ ]*\\))" "\\1#ifdef RDKIT_URFLIB_BUILD\n\\1\\1\\2\\3\n\\1#else\n\\1\\1\\2(dllimport)\n\\1#endif" ringdecomposerlib_h_data "${ringdecomposerlib_h_data}") +- file(WRITE ${ringdecomposerlib_h} "${ringdecomposerlib_h_data}") +- endif() +-endif() +-rdkit_library(RingDecomposerLib ${URFSOURCES} SHARED) +-if((MSVC AND RDK_INSTALL_DLLS_MSVC) OR ((NOT MSVC) AND WIN32 AND (NOT RDK_INSTALL_STATIC_LIBS))) +- target_compile_definitions(RingDecomposerLib PRIVATE RDKIT_URFLIB_BUILD) +-endif() +-install(TARGETS RingDecomposerLib DESTINATION ${RDKit_LibDir}) +-rdkit_headers(${URFLIB_DIR}/RingDecomposerLib.h DEST "") +- +- +-set(RDK_URF_LIBS RingDecomposerLib +- CACHE STRING "the libraries for the URF calculation" FORCE) ++rdkit_library(RingDecomposerLib dummy.cpp SHARED LINK_LIBRARIES -lRingDecomposerLib) ++set(RDK_URF_LIBS RingDecomposerLib CACHE STRING "" FORCE) +diff --git a/External/RingFamilies/dummy.cpp b/External/RingFamilies/dummy.cpp +new file mode 100644 +index 000000000..e69de29bb +diff --git a/External/YAeHMOP/CMakeLists.txt b/External/YAeHMOP/CMakeLists.txt +index f1027b3bd..8bee2f910 100644 +--- a/External/YAeHMOP/CMakeLists.txt ++++ b/External/YAeHMOP/CMakeLists.txt +@@ -18,32 +18,8 @@ endif() + + include_directories( ${RDKit_ExternalDir}/YAeHMOP ) + +-ExternalProject_Add(yaehmop_project +- GIT_REPOSITORY https://github.com/greglandrum/yaehmop.git +- GIT_TAG master +- UPDATE_COMMAND "" +- PATCH_COMMAND "" +- PREFIX ${CMAKE_CURRENT_SOURCE_DIR} +- SOURCE_DIR "${CMAKE_CURRENT_SOURCE_DIR}/yaehmop" +- SOURCE_SUBDIR "tightbind" +- CMAKE_ARGS -DUSE_BLAS_LAPACK=OFF -DCMAKE_INSTALL_PREFIX=${PROJECT_BINARY_DIR} -DCMAKE_C_FLAGS=${CMAKE_C_FLAGS} -DCMAKE_BUILD_TYPE=${CMAKE_BUILD_TYPE} +- TEST_COMMAND "") +- +-include_directories(${PROJECT_BINARY_DIR}/include) +-link_directories(${PROJECT_BINARY_DIR}/lib) +-link_directories(${CMAKE_CURRENT_SOURCE_DIR}/src/yaehmop_project-build) +- +-set(EHT_PARAM_FILE ${CMAKE_CURRENT_SOURCE_DIR}/yaehmop/tightbind/eht_parms.dat ) +-install(FILES ${EHT_PARAM_FILE} +- DESTINATION ${RDKit_ShareDir}/Data +- COMPONENT data) +- +-message("YAeHMOP include_dirs: ${PROJECT_BINARY_DIR}/include") +-message("YAeHMOP link_dirs: ${PROJECT_BINARY_DIR}/lib ${CMAKE_CURRENT_SOURCE_DIR}/src/yaehmop_project-build") +- +-rdkit_library(EHTLib EHTTools.cpp SHARED LINK_LIBRARIES yaehmop_eht GraphMol ) ++rdkit_library(EHTLib EHTTools.cpp SHARED LINK_LIBRARIES -lyaehmop_eht GraphMol ) + target_compile_definitions(EHTLib PRIVATE RDKIT_EHTLIB_BUILD) +-add_dependencies(EHTLib yaehmop_project) + rdkit_headers(EHTTools.h DEST GraphMol) + rdkit_catch_test(testEHTLib1 test1.cpp + LINK_LIBRARIES EHTLib FileParsers SmilesParse ) +diff --git a/External/YAeHMOP/EHTTools.cpp b/External/YAeHMOP/EHTTools.cpp +index 7a229f51f..71033dc5c 100644 +--- a/External/YAeHMOP/EHTTools.cpp ++++ b/External/YAeHMOP/EHTTools.cpp +@@ -10,7 +10,7 @@ + #include <fstream> + + extern "C" { +-#include <yaehmop/tightbind/bind.h> ++#include <yaehmop/bind.h> + } + + namespace RDKit { diff --git a/gnu/packages/patches/sajson-build-with-gcc10.patch b/gnu/packages/patches/sajson-build-with-gcc10.patch new file mode 100644 index 0000000000..878706dc79 --- /dev/null +++ b/gnu/packages/patches/sajson-build-with-gcc10.patch @@ -0,0 +1,45 @@ +This patch is from the upstream pull request +https://github.com/chadaustin/sajson/pull/54. +It fixes linking with GCC. + +diff --git a/include/sajson.h b/include/sajson.h +index 8b4e05a..1bd045b 100644 +--- a/include/sajson.h ++++ b/include/sajson.h +@@ -138,12 +138,17 @@ constexpr inline size_t make_element(tag t, size_t value) { + // header. This trick courtesy of Rich Geldreich's Purple JSON parser. + template <typename unused = void> + struct globals_struct { ++ static const unsigned char parse_flags[256]; ++}; ++typedef globals_struct<> globals; ++ + // clang-format off + + // bit 0 (1) - set if: plain ASCII string character + // bit 1 (2) - set if: whitespace + // bit 4 (0x10) - set if: 0-9 e E . +- constexpr static const uint8_t parse_flags[256] = { ++ template <typename unused> ++ const unsigned char globals_struct<unused>::parse_flags[256] = { + // 0 1 2 3 4 5 6 7 8 9 A B C D E F + 0, 0, 0, 0, 0, 0, 0, 0, 0, 2, 2, 0, 0, 2, 0, 0, // 0 + 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, // 1 +@@ -162,15 +167,13 @@ struct globals_struct { + }; + + // clang-format on +-}; +-typedef globals_struct<> globals; + +-constexpr inline bool is_plain_string_character(char c) { ++inline bool is_plain_string_character(char c) { + // return c >= 0x20 && c <= 0x7f && c != 0x22 && c != 0x5c; + return (globals::parse_flags[static_cast<unsigned char>(c)] & 1) != 0; + } + +-constexpr inline bool is_whitespace(char c) { ++inline bool is_whitespace(char c) { + // return c == '\r' || c == '\n' || c == '\t' || c == ' '; + return (globals::parse_flags[static_cast<unsigned char>(c)] & 2) != 0; + } diff --git a/gnu/packages/patches/sajson-for-gemmi-numbers-as-strings.patch b/gnu/packages/patches/sajson-for-gemmi-numbers-as-strings.patch new file mode 100644 index 0000000000..6f476b8583 --- /dev/null +++ b/gnu/packages/patches/sajson-for-gemmi-numbers-as-strings.patch @@ -0,0 +1,195 @@ +Patch for gemmi: Keep numbers in JSON file as strings. + +Adapted from this commit of the bundled fork of sajson in gemmi: +https://github.com/project-gemmi/gemmi/commit/fccbca4f6040364ba708613e1429c2251872240d + +diff -ur a/include/sajson.h b/include/sajson.h +--- a/include/sajson.h ++++ b/include/sajson.h +@@ -411,43 +411,6 @@ + }; + } // namespace internal + +-namespace integer_storage { +-enum { word_length = 1 }; +- +-inline int load(const size_t* location) { +- int value; +- memcpy(&value, location, sizeof(value)); +- return value; +-} +- +-inline void store(size_t* location, int value) { +- // NOTE: Most modern compilers optimize away this constant-size +- // memcpy into a single instruction. If any don't, and treat +- // punning through a union as legal, they can be special-cased. +- static_assert( +- sizeof(value) <= sizeof(*location), +- "size_t must not be smaller than int"); +- memcpy(location, &value, sizeof(value)); +-} +-} // namespace integer_storage +- +-namespace double_storage { +-enum { word_length = sizeof(double) / sizeof(size_t) }; +- +-inline double load(const size_t* location) { +- double value; +- memcpy(&value, location, sizeof(double)); +- return value; +-} +- +-inline void store(size_t* location, double value) { +- // NOTE: Most modern compilers optimize away this constant-size +- // memcpy into a single instruction. If any don't, and treat +- // punning through a union as legal, they can be special-cased. +- memcpy(location, &value, sizeof(double)); +-} +-} // namespace double_storage +- + /// Represents a JSON value. First, call get_type() to check its type, + /// which determines which methods are available. + /// +@@ -585,70 +548,10 @@ + return length; + } + +- /// If a numeric value was parsed as a 32-bit integer, returns it. +- /// Only legal if get_type() is TYPE_INTEGER. +- int get_integer_value() const { +- assert_tag(tag::integer); +- return integer_storage::load(payload); +- } +- +- /// If a numeric value was parsed as a double, returns it. +- /// Only legal if get_type() is TYPE_DOUBLE. +- double get_double_value() const { +- assert_tag(tag::double_); +- return double_storage::load(payload); +- } +- +- /// Returns a numeric value as a double-precision float. +- /// Only legal if get_type() is TYPE_INTEGER or TYPE_DOUBLE. +- double get_number_value() const { +- assert_tag_2(tag::integer, tag::double_); +- if (value_tag == tag::integer) { +- return get_integer_value(); +- } else { +- return get_double_value(); +- } +- } +- +- /// Returns true and writes to the output argument if the numeric value +- /// fits in a 53-bit integer. This is useful for timestamps and other +- /// situations where integral values with greater than 32-bit precision +- /// are used, as 64-bit values are not understood by all JSON +- /// implementations or languages. +- /// Returns false if the value is not an integer or not in range. +- /// Only legal if get_type() is TYPE_INTEGER or TYPE_DOUBLE. +- bool get_int53_value(int64_t* out) const { +- // Make sure the output variable is always defined to avoid any +- // possible situation like +- // https://gist.github.com/chadaustin/2c249cb850619ddec05b23ca42cf7a18 +- *out = 0; +- +- assert_tag_2(tag::integer, tag::double_); +- switch (value_tag) { +- case tag::integer: +- *out = get_integer_value(); +- return true; +- case tag::double_: { +- double v = get_double_value(); +- if (v < -(1LL << 53) || v > (1LL << 53)) { +- return false; +- } +- int64_t as_int = static_cast<int64_t>(v); +- if (as_int != v) { +- return false; +- } +- *out = as_int; +- return true; +- } +- default: +- return false; +- } +- } +- + /// Returns the length of the string. + /// Only legal if get_type() is TYPE_STRING. + size_t get_string_length() const { +- assert_tag(tag::string); ++ assert_tag_3(tag::string, tag::integer, tag::double_); + return payload[1] - payload[0]; + } + +@@ -659,7 +562,7 @@ + /// embedded NULs. + /// Only legal if get_type() is TYPE_STRING. + const char* as_cstring() const { +- assert_tag(tag::string); ++ assert_tag_3(tag::string, tag::integer, tag::double_); + return text + payload[0]; + } + +@@ -667,7 +570,7 @@ + /// Returns a string's value as a std::string. + /// Only legal if get_type() is TYPE_STRING. + std::string as_string() const { +- assert_tag(tag::string); ++ assert_tag_3(tag::string, tag::integer, tag::double_); + return std::string(text + payload[0], text + payload[1]); + } + #endif +@@ -690,6 +593,10 @@ + assert(e1 == value_tag || e2 == value_tag); + } + ++ void assert_tag_3(tag e1, tag e2, tag e3) const { ++ assert(e1 == value_tag || e2 == value_tag || e3 == value_tag); ++ } ++ + void assert_in_bounds(size_t i) const { assert(i < get_length()); } + + const tag value_tag; +@@ -2059,6 +1966,8 @@ + std::pair<char*, internal::tag> parse_number(char* p) { + using internal::tag; + ++ size_t start = p - input.get_data(); ++ + // Assume 32-bit, two's complement integers. + static constexpr unsigned RISKY = INT_MAX / 10u; + unsigned max_digit_after_risky = INT_MAX % 10u; +@@ -2235,23 +2144,18 @@ + u = 0u - u; + } + } ++ ++ bool success; ++ size_t* out = allocator.reserve(2, &success); ++ if (SAJSON_UNLIKELY(!success)) { ++ return std::make_pair(oom(p, "number"), tag::null); ++ } ++ out[0] = start; ++ out[1] = p - input.get_data(); ++ + if (try_double) { +- bool success; +- size_t* out +- = allocator.reserve(double_storage::word_length, &success); +- if (SAJSON_UNLIKELY(!success)) { +- return std::make_pair(oom(p, "double"), tag::null); +- } +- double_storage::store(out, d); + return std::make_pair(p, tag::double_); + } else { +- bool success; +- size_t* out +- = allocator.reserve(integer_storage::word_length, &success); +- if (SAJSON_UNLIKELY(!success)) { +- return std::make_pair(oom(p, "integer"), tag::null); +- } +- integer_storage::store(out, static_cast<int>(u)); + return std::make_pair(p, tag::integer); + } + } diff --git a/gnu/packages/patches/tinydir-fix-cbehave-test.patch b/gnu/packages/patches/tinydir-fix-cbehave-test.patch new file mode 100644 index 0000000000..84ecee12c2 --- /dev/null +++ b/gnu/packages/patches/tinydir-fix-cbehave-test.patch @@ -0,0 +1,16 @@ +Make test work with upstream cbehave +(tinydir bundles a modified version) + +diff --git a/tests/file_open_test.c b/tests/file_open_test.c +index 3e659bc..9f6f88d 100644 +--- a/tests/file_open_test.c ++++ b/tests/file_open_test.c +@@ -19,4 +19,7 @@ FEATURE(file_open, "File open") + SCENARIO_END + FEATURE_END + +-CBEHAVE_RUN("File open:", TEST_FEATURE(file_open)) ++int main(void) { ++ cbehave_feature _cfeatures[] = {{feature_idx(file_open)}}; ++ return cbehave_runner("File open:", _cfeatures); ++} diff --git a/gnu/packages/python-xyz.scm b/gnu/packages/python-xyz.scm index c45e6019b5..60ca7d1506 100644 --- a/gnu/packages/python-xyz.scm +++ b/gnu/packages/python-xyz.scm @@ -4024,6 +4024,28 @@ e.g. filters, callbacks and errbacks can all be promises.") "Virtualenv is a tool to create isolated Python environments.") (license license:expat))) +(define-public python-crossenv + (package + (name "python-crossenv") + (version "1.3.0") + (source + (origin + (method url-fetch) + (uri (pypi-uri "crossenv" version)) + (sha256 + (base32 + "07rv4650n19740ixmnsf4qbxyqlgi7f5m1cy8cq0gl01q3r6hps4")))) + (build-system python-build-system) + (arguments + (list #:tests? #f)) ; tests not distributed on pypi + (home-page "https://github.com/benfogle/virtualenv") + (synopsis "Cross-compiling virtualenv for Python") + (description "This package is a tool for cross-compiling extension +modules. It creates a special virtual environment such that @command{pip} or +@file{setup.py} will cross compile packages for you, usually with no further +work on your part.") + (license license:expat))) + (define-public python-markupsafe (package (name "python-markupsafe") diff --git a/gnu/packages/python.scm b/gnu/packages/python.scm index edbdf7cfad..e31158dfc0 100644 --- a/gnu/packages/python.scm +++ b/gnu/packages/python.scm @@ -59,6 +59,7 @@ ;;; Copyright © 2020 Jan (janneke) Nieuwenhuizen <janneke@gnu.org> ;;; Copyright © 2020, 2021 Greg Hogan <code@greghogan.com> ;;; Copyright © 2022 Philip McGrath <philip@philipmcgrath.com> +;;; Copyright © 2022 jgart <jgart@dismail.de> ;;; ;;; This file is part of GNU Guix. ;;; @@ -680,7 +681,7 @@ and the unversioned commands available."))) (define-public micropython (package (name "micropython") - (version "1.18") + (version "1.19") (source (origin (method url-fetch) @@ -688,7 +689,7 @@ and the unversioned commands available."))) "releases/download/v" version "/micropython-" version ".tar.xz")) (sha256 - (base32 "1d1yza02pwq3kh8531ryq9sjk7zjqh786nnw397cccfk5ss73z4n")) + (base32 "090bbls5vnicynjyjqqd5zqwx8d6zxp7wlnrxgh0b4s8cyf5i8zj")) (modules '((guix build utils))) (snippet '(begin diff --git a/gnu/packages/security-token.scm b/gnu/packages/security-token.scm index 447a7a582d..5f10b5592a 100644 --- a/gnu/packages/security-token.scm +++ b/gnu/packages/security-token.scm @@ -909,7 +909,8 @@ phone is required.") "-DPKG_CONFIG_EXECUTABLE=" (search-input-file %build-inputs (string-append - "/bin/" ,(pkg-config-for-target))))) + "/bin/" ,(pkg-config-for-target)))) + (string-append "-DUDEV_RULES_DIR=" %output "/lib/udev/rules.d")) #:phases (modify-phases %standard-phases ;; regress tests enabled only for debug builds diff --git a/gnu/packages/terminals.scm b/gnu/packages/terminals.scm index f29d7e3773..8f2ac9974c 100644 --- a/gnu/packages/terminals.scm +++ b/gnu/packages/terminals.scm @@ -743,7 +743,7 @@ embedded kernel situations.") "")) (for-each (lambda (file) - (let ((start-rx (make-regexp " *ListElement\\{")) + (let ((start-rx (make-regexp " *ListElement *\\{")) (end-rx (make-regexp " *\\}"))) (with-atomic-file-replacement file (lambda (in out) diff --git a/gnu/packages/web-browsers.scm b/gnu/packages/web-browsers.scm index 26754225ec..83ede228b1 100644 --- a/gnu/packages/web-browsers.scm +++ b/gnu/packages/web-browsers.scm @@ -159,14 +159,14 @@ management, extensions such as advertisement blocker and colorful tabs.") (define-public links (package (name "links") - (version "2.27") + (version "2.28") (source (origin (method url-fetch) (uri (string-append "http://links.twibright.com/download/" "links-" version ".tar.bz2")) (sha256 (base32 - "1d7bz6bbis94jq82xydwnazaczzmb1ij62pbmf0dxkg7xpycppfq")))) + "1d2lyj9k2s6brk38k51qfpddwh2w96w6gh9jq5br9rfy2fdlkm9g")))) (build-system gnu-build-system) (arguments (list diff --git a/gnu/packages/xdisorg.scm b/gnu/packages/xdisorg.scm index 2533744633..7307360d6a 100644 --- a/gnu/packages/xdisorg.scm +++ b/gnu/packages/xdisorg.scm @@ -313,7 +313,7 @@ used to further tweak the behaviour of the different profiles.") (define-public bemenu (package (name "bemenu") - (version "0.6.4") + (version "0.6.10") (source (origin (method git-fetch) @@ -322,27 +322,28 @@ used to further tweak the behaviour of the different profiles.") (commit version))) (file-name (git-file-name name version)) (sha256 - (base32 "18vplvnymgc6576sdh84lm5rlwyb9d038plqpjs638hzskf4q577")))) + (base32 "0i2pv3qnb0l2ryvj9ycf9d5rng6yfk0kpjkq8hy6g956672wdzx6")))) (build-system gnu-build-system) (arguments - `(#:tests? #f - #:make-flags (list ,(string-append "CC=" (cc-for-target)) - "CFLAGS=-O2 -fPIC" - (string-append "LDFLAGS=-Wl,-rpath=" - (assoc-ref %outputs "out") "/lib") - (string-append "PREFIX=" (assoc-ref %outputs "out"))) - #:phases - (modify-phases %standard-phases - (delete 'configure)))) ; no configure script + (list + #:tests? #f + #:make-flags + #~(list (string-append "CC=" #$(cc-for-target)) + "CFLAGS=-O2 -fPIC" + (string-append "LDFLAGS=-Wl,-rpath=" #$output "/lib") + (string-append "PREFIX=" #$output)) + #:phases + #~(modify-phases %standard-phases + (delete 'configure)))) ; no configure script (inputs - `(("cairo" ,cairo) - ("libx11" ,libx11) - ("libxkbcomon" ,libxkbcommon) - ("libxinerama" ,libxinerama) - ("ncurses" ,ncurses) - ("pango" ,pango) - ("wayland" ,wayland) - ("wayland-protocols" ,wayland-protocols))) + (list cairo + libx11 + libxkbcommon + libxinerama + ncurses + pango + wayland + wayland-protocols)) (native-inputs (list doxygen pkg-config)) (home-page "https://github.com/Cloudef/bemenu") @@ -3168,3 +3169,24 @@ that support @samp{wlr-gamma-control-unstable-v1}. It is also known as a blue light filter or night light.") (license license:expat))) +(define-public ydotool + (package + (name "ydotool") + (version "1.0.1") + (source + (origin + (method git-fetch) + (uri (git-reference + (url "https://github.com/ReimuNotMoe/ydotool") + (commit (string-append "v" version)))) + (file-name (git-file-name name version)) + (sha256 + (base32 "1h19dh7kai0iikssr7sq0wfkh0sb18dylyfg7c3dkwc158cdg9cr")))) + (build-system cmake-build-system) + (arguments '(#:tests? #f)) ; no tests + (native-inputs (list scdoc)) + (home-page "https://github.com/ReimuNotMoe/ydotool") + (synopsis "Generic Linux command-line automation tool (no X!)") + (description "@code{ydotool} is a Linux command-line tool that simulates +keyboard input, mouse actions, etc. programmatically or manually.") + (license license:agpl3+))) |