;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2013, 2014, 2015, 2017, 2018 Ludovic Courtès ;;; Copyright © 2014 Mark H Weaver ;;; Copyright © 2018 Tobias Geerinckx-Rice ;;; ;;; This file is part of GNU Guix. ;;; ;;; GNU Guix is free software; you can redistribute it and/or modify it ;;; under the terms of the GNU General Public License as published by ;;; the Free Software Foundation; either version 3 of the License, or (at ;;; your option) any later version. ;;; ;;; GNU Guix is distributed in the hope that it will be useful, but ;;; WITHOUT ANY WARRANTY; without even the implied warranty of ;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ;;; GNU General Public License for more details. ;;; ;;; You should have received a copy of the GNU General Public License ;;; along with GNU Guix. If not, see . (define-module (gnu packages avahi) #:use-module ((guix licenses) #:select (lgpl2.1+)) #:use-module (guix packages) #:use-module (guix download) #:use-module (guix build-system gnu) #:use-module (gnu packages) #:use-module (gnu packages dbm) #:use-module (gnu packages libdaemon) #:use-module (gnu packages linux) #:use-module (gnu packages pkg-config) #:use-module (gnu packages glib) #:use-module (gnu packages xml)) (define-public avahi (package (name "avahi") (version "0.7") (home-page "http://avahi.org") (source (origin (method url-fetch) (uri (string-append home-page "/download/avahi-" version ".tar.gz")) (sha256 (base32 "0128n7jlshw4bpx0vg8lwj8qwdisjxi7mvniwfafgnkzzrfrpaap")) (patches (search-patches "avahi-localstatedir.patch" "avahi-CVE-2018-1000845.patch")))) ;; Hide a duplicate of the CVE fixed above. (properties `((lint-hidden-cve . ("CVE-2017-6519")))) (build-system gnu-build-system) (arguments '(#:configure-flags '("--with-distro=none" "--localstatedir=/var" ; for the DBus socket "--disable-python" "--disable-mono" "--disable-doxygen-doc" "--disable-xmltoman" "--enable-tests" "--disable-qt3" "--disable-qt4" "--disable-gtk" "--disable-gtk3" "--enable-compat-libdns_sd"))) (inputs `(("expat" ,expat) ("glib" ,glib) ("dbus" ,dbus) ("gdbm" ,gdbm) ("libcap" ,libcap) ;to enable chroot support in avahi-daemon ("libdaemon" ,libdaemon))) (native-inputs `(("intltool" ,intltool) ("glib" ,glib "bin") ("pkg-config" ,pkg-config))) (synopsis "Implementation of mDNS/DNS-SD protocols") (description "Avahi is a system which facilitates service discovery on a local network. It is an implementation of the mDNS (for \"Multicast DNS\") and DNS-SD (for \"DNS-Based Service Discovery\") protocols.") (license lgpl2.1+))) (define-public nss-mdns (package (name "nss-mdns") (version "0.14.1") (home-page "https://github.com/lathiat/nss-mdns") (source (origin (method url-fetch) (uri (string-append home-page "/releases/download/v" version "/" name "-" version ".tar.gz")) (sha256 (base32 "134wdr0n9cm5ab4g6dwq76lvzqns9dcylr470i2xxjimnw0l22d2")))) (build-system gnu-build-system) (arguments ;; The Avahi daemon socket is expected by 'configure.ac' to be at ;; "$(localstatedir)/run/avahi-daemon/socket", but nowadays it lives in ;; /run/avahi-daemon/socket. Remove the "$(localstatedir)" bit. '(#:configure-flags '("AVAHI_SOCKET=/run/avahi-daemon/socket"))) (synopsis "Multicast DNS Name Service Switch (@dfn{NSS}) plug-in") (description "Nss-mdns is a plug-in for the GNU C Library's Name Service Switch (@dfn{NSS}) that resolves host names via multicast DNS (@dfn{mDNS}). It is most often used in home and other small networks without a local name server, to resolve host names in the @samp{.local} top-level domain.") (license lgpl2.1+))) ore/non-blocking): New syntax rule. * .dir-locals.el (scheme-mode): Add entry for with-store/non-blocking. Change-Id: I8225762b78448bc1f7b698c8de5d736e13f577bf Christopher Baines 2024-05-13.dir-locals: Configure indentation for swap-space....* .dir-locals.el (scheme-mode): Indent swap-space same as file-system. Change-Id: Id9f2cbd3c81343b479ab1e4df29c65f8b5bd739f Signed-off-by: Ludovic Courtès <ludo@gnu.org> Tomas Volf 2024-04-03store: database: Remove with-statement and associated code....I think using dynamic-wind to finalize all statements is the wrong approach. Firstly it would be good to allow reseting statements rather than finalizing them. Then for the problem of handling errors, the approach I've settled on in the build coordinator is to close the database connection, since that'll trigger guile-sqlite3 to finalize all the cached statements. This reverts commit 5d6e2255286e591def122ec2f4a3cbda497fea21. * .dir-locals.el (scheme-mode): Remove with-statement. * guix/store/database.scm (call-with-statement): Remove procedure. (with-statement): Remove syntax rule. (call-with-transaction, last-insert-row-id, path-id, update-or-insert, add-references): Don't use with-statement. Change-Id: I2fd976b3f12ec8105cc56350933a953cf53647e8 Christopher Baines 2024-04-03store: database: Remove call-with-savepoint and associated code....While care does need to be taken with making updates or inserts to the ValidPaths table, I think that trying to ensure this within update-or-insert is the wrong approach. Instead, when working with the store database, only one connection should be used to make changes to the database and those changes should happen in transactions that ideally begin immediately. This reverts commit 37545de4a3bf59611c184b31506fe9a16abe4c8b. * .dir-locals.el (scheme-mode): Remove entries for call-with-savepoint and call-with-retrying-savepoint. * guix/store/database.scm (call-with-savepoint, call-with-retrying-savepoint): Remove procedures. (update-or-insert): Remove use of call-with-savepoint. Change-Id: I2f986e8623d8235a90c40d5f219c1292c1ab157b Christopher Baines