Re: NetworkManager doesn't "Connect automatically"
Chris Marusichwrites: > Andy Wingo writes: > >> On Wed 14 Dec 2016 10:13, Chris Marusich writes: >> >>> Did I make a mistake, or does NetworkManager just not recognize elogind? >>> I'll look into this more, but unless I made a mistake, I suspect that >>> either elogind or network-manager might require some tweaks to convince >>> network-manager that elogind is equivalent to systemd in this case. >> >> See README where it mentions differences to logind: >> >> https://github.com/elogind/elogind >> >> In particular see the changes in gnu/packages/polkit.scm to get >> PolicyKit to recognize elogind. >> >> ANdy > > Awesome, thank you for the tip! At first blush it looks like the word > "systemd" is mentioned in surprisingly many files inside the > NetworkManager source. I'll try following the example of polkit and see > how it goes! Upon closer inspection, it looks almost as if NetworkManager has extracted code from systemd for its own internal use. I'll continue to look into this, but I don't expect to be able to make progress on my own very soon, so if someone else wants to dive in and help figure out what substitutions to make in the NetworkManager code, it would be welcome. -- Chris signature.asc Description: PGP signature
Re: Guix IceCat users have had early access to security fixes
On Wed, Dec 14, 2016 at 08:20:45PM -0600, Christopher Allan Webber wrote: > Mark H Weaver writes: > > > Yesterday, Mozilla released Firefox ESR 45.6 and announced several CVEs > > fixed by it: > > > > https://www.mozilla.org/en-US/security/advisories/mfsa2016-95/ > > > > I'm pleased to announce that Guix users of IceCat have had early access > > all of these fixes. > > > > Since November 30 (commit 9689e71d2f2b5e766415a40d5f5ab267768d217d), > > we've had fixes for CVE-2016-9897, CVE-2016-9898, CVE-2016-9899, > > CVE-2016-9900, CVE-2016-9904, and 4 out of 11 patches for CVE-2016-9893. > > > > Since December 3 (commit 5bdec7d634ce0058801cd212e9e4ea56e914ca0c), > > we've had the fixes that were later announced as CVE-2016-9901, > > CVE-2016-9902, CVE-2016-9905, and another patch for CVE-2016-9893. > > > > On December 10 (commit 56c394ee4397015d6144dab002ee43fc7e32a331), I > > cherry-picked the remaining fixes from the not-yet-released Firefox > > ESR 45.6: CVE-2016-9895, and the final six patches for CVE-2016-9893. > > > > Mark > > Wow! Thank you for staying on top of things, Mark! Indeed! Thank you for your diligence!
Re: [PATCH] utils: file-extension should work with urls.
Fixed yesterdays stupidity with 6976c68158e9c6bb264ca48041da5be1c24521cf
Re: [PATCH] utils: file-extension should work with urls.
> guix/utils.scm (file-extension): Detect the lack of file extensions in urls. This is so stupid. Just to cover up some other stupidity I did earlier that day.
Re: 03/03: import: cpan: Add updater.
On Tue, 13 Dec 2016 08:42:24 +0100 l...@gnu.org (Ludovic Courtès) wrote: > Hi! > > bav...@member.fsf.org (Eric Bavier) skribis: > > > commit ff55fe559951b88bfd691b9dada3a0f26002c4cb > > Author: Eric Bavier> > Date: Mon Dec 12 21:59:27 2016 -0600 > > > > import: cpan: Add updater. > > > > * guix/import/cpan.scm (module->dist-name): Fetch the field of interest. > > (cpan-fetch): Accept release name rather than module name. > > (fix-source-url): Rename to ... > > (cpan-source-url): ... this. Take metadata as parameter. > > (package->upstream-name, cpan-version, cpan-package?, latest-release): > > New procedures. > > (cpan-module->sexp): Use cpan-version and cpan-source-url. > > (%cpan-updater): New variable. > > * guix/scripts/refresh.scm (%updaters): Add %CPAN-UPDATER. > > Awesome! Could you mention it in guix.texi, under “Invoking guix > refresh”? Thanks for the reminder! Done in 200cdf81c6e5b92dc486b705d158a4a8565f5f40 `~Eric
Re: Guix IceCat users have had early access to security fixes
Very nice! Thanks :) On Wed, Dec 14, 2016 at 6:20 PM, Christopher Allan Webber < cweb...@dustycloud.org> wrote: > Mark H Weaver writes: > > > Yesterday, Mozilla released Firefox ESR 45.6 and announced several CVEs > > fixed by it: > > > > https://www.mozilla.org/en-US/security/advisories/mfsa2016-95/ > > > > I'm pleased to announce that Guix users of IceCat have had early access > > all of these fixes. > > > > Since November 30 (commit 9689e71d2f2b5e766415a40d5f5ab267768d217d), > > we've had fixes for CVE-2016-9897, CVE-2016-9898, CVE-2016-9899, > > CVE-2016-9900, CVE-2016-9904, and 4 out of 11 patches for CVE-2016-9893. > > > > Since December 3 (commit 5bdec7d634ce0058801cd212e9e4ea56e914ca0c), > > we've had the fixes that were later announced as CVE-2016-9901, > > CVE-2016-9902, CVE-2016-9905, and another patch for CVE-2016-9893. > > > > On December 10 (commit 56c394ee4397015d6144dab002ee43fc7e32a331), I > > cherry-picked the remaining fixes from the not-yet-released Firefox > > ESR 45.6: CVE-2016-9895, and the final six patches for CVE-2016-9893. > > > > Mark > > Wow! Thank you for staying on top of things, Mark! > >
Re: Guix IceCat users have had early access to security fixes
Mark H Weaver writes: > Yesterday, Mozilla released Firefox ESR 45.6 and announced several CVEs > fixed by it: > > https://www.mozilla.org/en-US/security/advisories/mfsa2016-95/ > > I'm pleased to announce that Guix users of IceCat have had early access > all of these fixes. > > Since November 30 (commit 9689e71d2f2b5e766415a40d5f5ab267768d217d), > we've had fixes for CVE-2016-9897, CVE-2016-9898, CVE-2016-9899, > CVE-2016-9900, CVE-2016-9904, and 4 out of 11 patches for CVE-2016-9893. > > Since December 3 (commit 5bdec7d634ce0058801cd212e9e4ea56e914ca0c), > we've had the fixes that were later announced as CVE-2016-9901, > CVE-2016-9902, CVE-2016-9905, and another patch for CVE-2016-9893. > > On December 10 (commit 56c394ee4397015d6144dab002ee43fc7e32a331), I > cherry-picked the remaining fixes from the not-yet-released Firefox > ESR 45.6: CVE-2016-9895, and the final six patches for CVE-2016-9893. > > Mark Wow! Thank you for staying on top of things, Mark!
Guix IceCat users have had early access to security fixes
Yesterday, Mozilla released Firefox ESR 45.6 and announced several CVEs fixed by it: https://www.mozilla.org/en-US/security/advisories/mfsa2016-95/ I'm pleased to announce that Guix users of IceCat have had early access all of these fixes. Since November 30 (commit 9689e71d2f2b5e766415a40d5f5ab267768d217d), we've had fixes for CVE-2016-9897, CVE-2016-9898, CVE-2016-9899, CVE-2016-9900, CVE-2016-9904, and 4 out of 11 patches for CVE-2016-9893. Since December 3 (commit 5bdec7d634ce0058801cd212e9e4ea56e914ca0c), we've had the fixes that were later announced as CVE-2016-9901, CVE-2016-9902, CVE-2016-9905, and another patch for CVE-2016-9893. On December 10 (commit 56c394ee4397015d6144dab002ee43fc7e32a331), I cherry-picked the remaining fixes from the not-yet-released Firefox ESR 45.6: CVE-2016-9895, and the final six patches for CVE-2016-9893. Mark
[PATCH] gnu: Add python-xopen.
* gnu/packages/python.scm (python-xopen, python2-xopen): New variables. --- gnu/packages/python.scm | 26 ++ 1 file changed, 26 insertions(+) diff --git a/gnu/packages/python.scm b/gnu/packages/python.scm index 789e199..70c5aed 100644 --- a/gnu/packages/python.scm +++ b/gnu/packages/python.scm @@ -11929,3 +11929,29 @@ network.") (define-public python2-argcomplete (package-with-python2 python-argcomplete)) + +(define-public python-xopen + (package +(name "python-xopen") +(version "0.1.1") +(source + (origin +(method url-fetch) +(uri (string-append "https://github.com/marcelm/xopen/archive/v; +version ".tar.gz")) +(sha256 + (base32 + "1dp0fg56fk5kiz9n1h82b6bf9vf15p4c79bvidlbgvsx3jqqaa39")) +(file-name (string-append name "-" version ".tar.gz" +(build-system python-build-system) +(home-page "https://github.com/marcelm/xopen/;) +(synopsis "Open compressed files transparently") +(description "This module provides an @code{xopen} function that works like +Python's built-in @code{open} function, but can also deal with compressed files. +Supported compression formats are gzip, bzip2 and, xz, and are automatically +recognized by their file extensions. The focus is on being as efficient as +possible on all supported Python versions.") +(license license:expat))) + +(define-public python2-xopen + (package-with-python2 python-xopen)) -- 2.9.3
Re: Shutdown of googlecode end of the year - we have affected packages!
On 14/12/16 21:37, Ricardo Wurmus wrote: > ng0writes: >> Are we done then and we only need to find the right source for >> key-mon if there is a new one? > > There’s more: [...] > > Most of them are home page fields (will they also disappear?), but there > are some where the sources are affected. I've pushed some more quick home-page updates bringing the total down to the following, most (if not all) of which don't have new homes yet: key-mon.scm: (home-page "http://code.google.com/p/key-mon;) key-mon.scm: "http://key-mon.googlecode.com/files/key-mon-; games.scm: "google-code-archive-downloads/v2/code.google.com/" games.scm: (home-page "http://code.google.com/p/abbaye-for-linux/;) python.scm: (home-page "https://code.google.com/p/py-bcrypt;) python.scm: (home-page "https://code.google.com/archive/p/socksipy-branch/;) python.scm: (home-page "http://code.google.com/p/prettytable/;) fontutils.scm: "code.google.com/ttf2eot/" fontutils.scm: (home-page "https://code.google.com/archive/p/ttf2eot/;))) java.scm: "code.google.com/jarjar/jarjar-src-" version ".zip")) java.scm: (home-page "https://code.google.com/archive/p/jarjar/;) Only 6 more to go! Kind regards, T G-R signature.asc Description: OpenPGP digital signature
Re: NetworkManager doesn't "Connect automatically"
On Wed, 2016-12-14 at 01:38 -0800, Chris Marusich wrote: > Hi Thomas, > > Thank you for the quick response! > > Thomas Hallerwrites: > > > Did you build NetworkManager yourself? Is session-tracking properly > > enabled to use systemd-logind or consolekit. > > Yes, I'm building it from source [1]. It looks like we might need to > adjust the way we build it to enable session-tracking, like you've > suggested. Am I correct in understanding that I should only need to > pass the option "--with-systemd-logind=yes" to the configure script > to > enable session tracking via systemd-logind? Is anything else > required? Hi, No, that should be enough. Possibly it was already enabled before, detected automatically? Thomas signature.asc Description: This is a digitally signed message part
Re: Shutdown of googlecode end of the year - we have affected packages!
ng0writes: > ng0@wasp ~$ cd src/guix/guix > ng0@wasp ~/src/guix/guix$ git grep googlecode > gnu/packages/key-mon.scm: > "http://key-mon.googlecode.com/files/key-mon-; > > > Are we done then and we only need to find the right source for > key-mon if there is a new one? There’s more: $ grep -r 'code\.google' gnu/packages --8<---cut here---start->8--- gnu/packages/key-mon.scm:(home-page "http://code.google.com/p/key-mon;) gnu/packages/scheme.scm:(home-page "https://code.google.com/p/chibi-scheme/;) gnu/packages/python.scm:(home-page "https://code.google.com/p/py-bcrypt;) gnu/packages/python.scm:(home-page "http://code.google.com/p/mock/;) gnu/packages/python.scm:(home-page "https://code.google.com/archive/p/socksipy-branch/;) gnu/packages/python.scm:(home-page "http://code.google.com/p/prettytable/;) gnu/packages/java.scm:"code.google.com/jarjar/jarjar-src-" version ".zip")) gnu/packages/java.scm:(home-page "https://code.google.com/archive/p/jarjar/;) gnu/packages/boost.scm:(home-page "https://code.google.com/p/multidimalgorithm/;) gnu/packages/image.scm: ;; https://code.google.com/p/tesseract-ocr/issues/detail?id=1436 gnu/packages/games.scm: "google-code-archive-downloads/v2/code.google.com/" gnu/packages/games.scm:(home-page "http://code.google.com/p/abbaye-for-linux/;) gnu/packages/openstack.scm:(http://code.google.com/p/pymox/) to Python 3. It was meant to be as compatible gnu/packages/fontutils.scm: "code.google.com/ttf2eot/" gnu/packages/fontutils.scm:(home-page "https://code.google.com/archive/p/ttf2eot/;))) gnu/packages/patches/ttf2eot-cstddef.patch:From resolution of https://code.google.com/p/ttf2eot/issues/detail?id=26 gnu/packages/bioinformatics.scm:(home-page "https://code.google.com/p/cutadapt/;) gnu/packages/bioinformatics.scm: (home-page "https://code.google.com/p/mosaik-aligner/;) gnu/packages/bioinformatics.scm:(home-page "https://code.google.com/p/pepr-chip-seq/;) --8<---cut here---end--->8--- Most of them are home page fields (will they also disappear?), but there are some where the sources are affected. -- Ricardo GPG: BCA6 89B6 3655 3801 C3C6 2150 197A 5888 235F ACAC http://elephly.net
Re: [PATCH] doc: Fix "could could" typo in Submitting Patches section
On Wed, Dec 14, 2016 at 09:38:36AM -0800, Maxim Cournoyer wrote: > Hi Guix! > > Please receive this trivial patch (attached) for the Guix info manual. > > From 805165a6114f745a2e9713215f9935ff78437c49 Mon Sep 17 00:00:00 2001 > From: Maxim Cournoyer> Date: Wed, 14 Dec 2016 09:30:17 -0800 > Subject: [PATCH] doc: Fix "could could" typo in Submitting Patches section > > * doc/contributing.texi (Submitting Patches): s/could could/could / Thanks! I edited the commit message and pushed.
[PATCH 4/6] gnu: Add qtdeclarative 5.5.1.
* gnu/packages/qt.scm (qtdeclarative55): New variable. --- gnu/packages/qt.scm | 23 +++ 1 file changed, 23 insertions(+) diff --git a/gnu/packages/qt.scm b/gnu/packages/qt.scm index 68324bd..431aa18 100644 --- a/gnu/packages/qt.scm +++ b/gnu/packages/qt.scm @@ -1364,3 +1364,26 @@ time Web content can be enhanced with native controls.") "1v78s0jygg83yzyldwms8zb72cwp718cc5ialc2ki3lqa81fndxm" (native-inputs `(("perl" ,perl))) (inputs `(("qtbase" ,qtbase55) + +(define-public qtdeclarative55 + (package (inherit qtsvg55) +(name "qtdeclarative") +(version "5.5.1") +(source (origin + (method url-fetch) + (uri (string-append "https://download.qt.io/official_releases/qt/; + (version-major+minor version) "/" version + "/submodules/" name "-opensource-src-" + version ".tar.xz")) + (sha256 + (base32 + "14b7naaa0rk4q6cxf0w62gvamxk812kr65k82zxkdzrzp3plxlaz" +(native-inputs + `(("perl" ,perl) + ("pkg-config" ,pkg-config) + ("python" ,python-2) + ("qtsvg" ,qtsvg55) + ("qtxmlpatterns" ,qtxmlpatterns55))) +(inputs + `(("mesa" ,mesa) + ("qtbase" ,qtbase55) -- 2.10.2
[PATCH 2/6] gnu: Add qtsvg 5.5.1.
* gnu/packages/qt.scm (qtsvg55): New variable. --- gnu/packages/qt.scm | 38 ++ 1 file changed, 38 insertions(+) diff --git a/gnu/packages/qt.scm b/gnu/packages/qt.scm index 291f3ee..cee341c 100644 --- a/gnu/packages/qt.scm +++ b/gnu/packages/qt.scm @@ -1310,3 +1310,41 @@ time Web content can be enhanced with native controls.") ;; Remove the bundled sqlite copy in addition to ;; passing "-system-sqlite". (delete-file-recursively "src/3rdparty/sqlite"))) + +(define-public qtsvg55 + (package (inherit qtbase55) +(name "qtsvg") +(version "5.5.1") +(source (origin + (method url-fetch) + (uri (string-append "https://download.qt.io/official_releases/qt/; + (version-major+minor version) "/" version + "/submodules/" name "-opensource-src-" + version ".tar.xz")) + (sha256 + (base32 + "1iwibbh835cpxbfh7rnrpvl9k20valr6h256np59rzdy92z8ixgp" +(propagated-inputs `()) +(native-inputs `(("perl" ,perl))) +(inputs + `(("mesa" ,mesa) + ("qtbase" ,qtbase55) + ("zlib" ,zlib))) +(arguments + `(#:phases + (modify-phases %standard-phases + (replace 'configure + (lambda* (#:key outputs #:allow-other-keys) + (let ((out (assoc-ref outputs "out"))) + (and (zero? (system* "qmake" (string-append "PREFIX=" out))) +(system* "make" "clean") ; Generate broken Makefiles + ; to be substituted + (add-before 'build 'fix-Makefiles + (lambda* (#:key inputs outputs #:allow-other-keys) + (let ((out (assoc-ref outputs "out")) + (qtbase (assoc-ref inputs "qtbase"))) + (substitute* (find-files "." "Makefile") + (((string-append "-Wl,-rpath," qtbase "/lib") all) + (string-append all " -Wl,-rpath," out "/lib ")) + (((string-append "INSTALL_ROOT)" qtbase)) + (string-append "INSTALL_ROOT)" out))) -- 2.10.2
[PATCH 5/6] gnu: Add qtwebkit 5.5.1.
* gnu/packages/qt.scm (qtwebkit55): New variable. --- gnu/packages/qt.scm | 98 + 1 file changed, 98 insertions(+) diff --git a/gnu/packages/qt.scm b/gnu/packages/qt.scm index 431aa18..4de6337 100644 --- a/gnu/packages/qt.scm +++ b/gnu/packages/qt.scm @@ -1387,3 +1387,101 @@ time Web content can be enhanced with native controls.") (inputs `(("mesa" ,mesa) ("qtbase" ,qtbase55) + +(define-public qtwebkit55 + (package +(inherit qtwebkit) +(name "qtwebkit") +(version "5.5.1") +(source (origin + (method url-fetch) + (uri (string-append +"https://download.qt.io/official_releases/qt/; +(version-major+minor version) +"/" version +"/submodules/" name "-opensource-src-" +version ".tar.xz")) + (sha256 + (base32 +"0sbdglcf57lmgbcybimvvbpqikn3blb1pxvd71sdhsiypnfkyn3p" +(inputs + `(("icu" ,icu4c) + ("libjpeg" ,libjpeg) + ("libpng" ,libpng) + ("libwebp" ,libwebp) + ("sqlite" ,sqlite) + ("fontconfig" ,fontconfig) + ("libxrender", libxrender) + ("qtbase" ,qtbase55) + ("qtdeclarative" ,qtdeclarative55) + ("libxml2" ,libxml2) + ("libxslt" ,libxslt) + ("libx11" ,libx11) + ("libxcomposite" ,libxcomposite))) +(arguments + `(#:phases + (modify-phases %standard-phases + (replace 'configure + (lambda* (#:key outputs #:allow-other-keys) +(let ((out (assoc-ref outputs "out"))) + (setenv "QMAKEPATH" + (string-append (getcwd) "/Tools/qmake:" + (getenv "QMAKEPATH"))) + (system* "qmake" + ;; prevent webkit from trying to install into the qtbase store directory, + ;; and replace references to the build directory in linker options: + (add-before 'build 'patch-installpaths + (lambda* (#:key outputs inputs #:allow-other-keys) + (let* ((out (assoc-ref outputs "out")) + (qtbase (assoc-ref inputs "qtbase")) + (builddir (getcwd)) + (linkbuild (string-append "-L" builddir)) + (linkout (string-append "-L" out)) + (makefiles + (map-in-order +(lambda (i) + (let* ((in (car i)) + (mf (string-append (dirname in) "/" +(cdr i +;; by default, these Makefiles are +;; generated during install, but we need +;; to generate them now +(system* "qmake" in "-o" mf) +mf)) +'(("Source/api.pri" . "Makefile.api") + ("Source/widgetsapi.pri" + . "Makefile.widgetsapi") + ("Source/WebKit2/WebProcess.pro" + . "Makefile.WebProcess") + ("Source/WebKit2/PluginProcess.pro" + . "Makefile.PluginProcess") + ("Source/WebKit/qt/declarative/public.pri" + . "Makefile.declarative.public") + ("Source/WebKit/qt/declarative/experimental/experimental.pri" + . "Makefile.declarative.experimental") + ("Source/WebKit/qt/examples/platformplugin/platformplugin.pro" + . "Makefile") + ;; Order of qmake calls and substitutions matters here. + (system* "qmake" "-prl" "Source/widgetsapi.pri" + "-o" "Source/Makefile") + (substitute* (find-files "lib" "libQt5.*\\.prl") + ((linkbuild) linkout)) + (substitute* (find-files "lib" + "libQt5WebKit.*\\.la") + (("libdir='.*'") +(string-append "libdir='" out "/lib'")) + ((linkbuild) linkout)) + (substitute* (find-files "lib/pkgconfig" + "Qt5WebKit.*\\.pc") + (((string-append "prefix=" qtbase)) +(string-append "prefix=" out)) +
[PATCH 3/6] gnu: Add qtxmlpatterns 5.5.1.
* gnu/packages/qt.scm (qtxmlpatterns55): New variable. --- gnu/packages/qt.scm | 16 1 file changed, 16 insertions(+) diff --git a/gnu/packages/qt.scm b/gnu/packages/qt.scm index cee341c..68324bd 100644 --- a/gnu/packages/qt.scm +++ b/gnu/packages/qt.scm @@ -1348,3 +1348,19 @@ time Web content can be enhanced with native controls.") (string-append all " -Wl,-rpath," out "/lib ")) (((string-append "INSTALL_ROOT)" qtbase)) (string-append "INSTALL_ROOT)" out))) + +(define-public qtxmlpatterns55 + (package (inherit qtsvg55) +(name "qtxmlpatterns") +(version "5.5.1") +(source (origin + (method url-fetch) + (uri (string-append "https://download.qt.io/official_releases/qt/; + (version-major+minor version) "/" version + "/submodules/" name "-opensource-src-" + version ".tar.xz")) + (sha256 + (base32 + "1v78s0jygg83yzyldwms8zb72cwp718cc5ialc2ki3lqa81fndxm" +(native-inputs `(("perl" ,perl))) +(inputs `(("qtbase" ,qtbase55) -- 2.10.2
Phantomjs with minimal old qt5.5 dependencies
As suggested by ng0, a split version of my PhantomJS patch. Greetings, Jan
[PATCH 6/6] gnu: Add phantomjs.
* gnu/packages/patches/phantomjs-qt55.patch: New file. * gnu/local.mk (dist_patch_DATA): Add it. * gnu/packages/qt.scm (phantomjs): New variable. --- gnu/local.mk | 1 + gnu/packages/patches/phantomjs-qt55.patch | 269 ++ gnu/packages/qt.scm | 56 +++ 3 files changed, 326 insertions(+) create mode 100644 gnu/packages/patches/phantomjs-qt55.patch diff --git a/gnu/local.mk b/gnu/local.mk index f780b24..96fde14 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -787,6 +787,7 @@ dist_patch_DATA = \ %D%/packages/patches/perl-module-pluggable-search.patch \ %D%/packages/patches/perl-reproducible-build-date.patch \ %D%/packages/patches/perl-www-curl-remove-symbol.patch \ + %D%/packages/patches/phantomjs-qt55.patch\ %D%/packages/patches/pidgin-add-search-path.patch\ %D%/packages/patches/pinball-const-fix.patch \ %D%/packages/patches/pinball-cstddef.patch \ diff --git a/gnu/packages/patches/phantomjs-qt55.patch b/gnu/packages/patches/phantomjs-qt55.patch new file mode 100644 index 000..d0a544c --- /dev/null +++ b/gnu/packages/patches/phantomjs-qt55.patch @@ -0,0 +1,269 @@ +This patch ports PhantomJS to QT5.5. + +Taken from Debian phantomjs/debian/patches/ + +Last-Update: 2016-02-15 +Forwarded: no +Author: Dmitry Smirnov+Description: fix FTBFS. + +--- a/src/phantomjs.pro b/src/phantomjs.pro +@@ -8,9 +8,9 @@ + } + + TEMPLATE = app + TARGET = phantomjs +-QT += network webkitwidgets ++QT += network webkitwidgets printsupport + CONFIG += console + + DESTDIR = ../bin + +Last-Update: 2016-02-15 +Forwarded: no +Bug-Upstream: https://github.com/ariya/phantomjs/issues/13727 +Author: Ximin Luo +Reviewed-By: Dmitry Smirnov +Description: Port to Qt 5.5 + - Remove second argument to evaluateJavascript(), which was not really used + for anything, anyways + +--- a/src/utils.cpp b/src/utils.cpp +@@ -131,9 +132,9 @@ + } + return false; + } + // Execute JS code in the context of the document +-targetFrame->evaluateJavaScript(scriptBody, QString(JAVASCRIPT_SOURCE_CODE_URL).arg(QFileInfo(scriptPath).fileName())); ++targetFrame->evaluateJavaScript(scriptBody); + return true; + } + + bool loadJSForDebug(const QString& jsFilePath, const QString& libraryPath, QWebFrame* targetFrame, const bool autorun) +@@ -146,12 +147,12 @@ + QString scriptPath = findScript(jsFilePath, libraryPath); + QString scriptBody = jsFromScriptFile(scriptPath, jsFileLanguage, jsFileEnc); + + scriptBody = QString("function __run() {\n%1\n}").arg(scriptBody); +-targetFrame->evaluateJavaScript(scriptBody, QString(JAVASCRIPT_SOURCE_CODE_URL).arg(QFileInfo(scriptPath).fileName())); ++targetFrame->evaluateJavaScript(scriptBody); + + if (autorun) { +-targetFrame->evaluateJavaScript("__run()", QString()); ++targetFrame->evaluateJavaScript("__run()"); + } + + return true; + } +--- a/src/repl.cpp b/src/repl.cpp +@@ -146,9 +146,9 @@ + // Set the static callback to offer Completions to the User + linenoiseSetCompletionCallback(REPL::offerCompletion); + + // Inject REPL utility functions +-m_webframe->evaluateJavaScript(Utils::readResourceFileUtf8(":/repl.js"), QString(JAVASCRIPT_SOURCE_PLATFORM_URL).arg("repl.js")); ++m_webframe->evaluateJavaScript(Utils::readResourceFileUtf8(":/repl.js")); + + // Add self to JavaScript world + m_webframe->addToJavaScriptWindowObject("_repl", this); + +@@ -183,10 +183,9 @@ + // This will return an array of String with the possible completions + QStringList completions = REPL::getInstance()->m_webframe->evaluateJavaScript( + QString(JS_RETURN_POSSIBLE_COMPLETIONS).arg( + toInspect, +- toComplete), +- QString() ++ toComplete) + ).toStringList(); + + foreach(QString c, completions) { + if (lastIndexOfDot > -1) { +@@ -209,9 +208,9 @@ + if (userInput[0] != '\0') { + // Send the user input to the main Phantom frame for evaluation + m_webframe->evaluateJavaScript( + QString(JS_EVAL_USER_INPUT).arg( +-QString(userInput).replace('"', "\\\"")), QString("phantomjs://repl-input")); ++QString(userInput).replace('"', "\\\""))); + + // Save command in the REPL history + linenoiseHistoryAdd(userInput); + linenoiseHistorySave(m_historyFilepath.data()); //< requires "char *" +--- a/src/phantom.cpp b/src/phantom.cpp +@@ -380,9 +380,9 @@ + "require.cache['" +
[PATCH 1/6] gnu: Add qtbase 5.5.1.
* gnu/packages/qt.scm (qtbase55): New variable. --- gnu/packages/qt.scm | 25 + 1 file changed, 25 insertions(+) diff --git a/gnu/packages/qt.scm b/gnu/packages/qt.scm index b442356..291f3ee 100644 --- a/gnu/packages/qt.scm +++ b/gnu/packages/qt.scm @@ -5,6 +5,7 @@ ;;; Copyright © 2015, 2016 Efraim Flashner;;; Copyright © 2016 ng0 ;;; Copyright © 2016 Thomas Danckaert +;;; Copyright © 2016 Jan Nieuwenhuizen ;;; ;;; This file is part of GNU Guix. ;;; @@ -1285,3 +1286,27 @@ embed content from the World Wide Web into your Qt application. At the same time Web content can be enhanced with native controls.") (license license:lgpl2.1+))) + +(define-public qtbase55 + (package +(inherit qtbase) +(name "qtbase") +(version "5.5.1") +(source (origin + (method url-fetch) + (uri (string-append "https://download.qt.io/official_releases/qt/; + (version-major+minor version) "/" version + "/submodules/" name "-opensource-src-" + version ".tar.xz")) + (sha256 + (base32 +"05p91m1d9b3gdfm5pgmxw63rk0fdxqz87s77hn9bdip4syjfi96z")) + (modules '((guix build utils))) + (snippet + '(begin + ;; Remove one of the two bundled harfbuzz copies in addition + ;; to passing "-system-harfbuzz". + (delete-file-recursively "src/3rdparty/harfbuzz-ng") + ;; Remove the bundled sqlite copy in addition to + ;; passing "-system-sqlite". + (delete-file-recursively "src/3rdparty/sqlite"))) -- 2.10.2
Re: [PATCH 11/11] gnu: Add pagure.
ng0writes: > Leo Famulari writes: > >> On Wed, Dec 14, 2016 at 12:25:26PM +, ng0 wrote: >>> * gnu/packages/version-control.scm (pagure): New variable. >> >> How can I test this? Is there supposed to be 'runserver.py' file to run? >> >> https://pagure.io/pagure > > It's mostly "read the docs" and as I progressed in reading the > docs, I realized I forgot to add some more files. > So... New patch coming in later, sorry. Can everything else > except pagure be merged already? Or do you want to wait on that? > > https://docs.pagure.org/pagure/install.html#installing-pagure-via-setup-py Appending to my last message, it can take a while until I submit the next change. Getting this package working is in my own interest so I will definitely finish this. -- ♥Ⓐ ng0 | ng0.chaosnet.org
Re: [PATCH] gnu: Add phantomjs.
ng0 writes: > I think it will be easier to review when you split it. This is > all somewhat related, but those are 6 new public(?) packages and > one very long patch. Sure I can do that, I'll prepare a new series. > I don't know much about Qt, skipping through this I just saw one > http which could be changed to https, that's all so far. Okay. Greetings, Jan -- Jan Nieuwenhuizen| GNU LilyPond http://lilypond.org Freelance IT http://JoyofSource.com | Avatar® http://AvatarAcademy.nl
[PATCH] doc: Fix "could could" typo in Submitting Patches section
Hi Guix! Please receive this trivial patch (attached) for the Guix info manual. >From 805165a6114f745a2e9713215f9935ff78437c49 Mon Sep 17 00:00:00 2001 From: Maxim CournoyerDate: Wed, 14 Dec 2016 09:30:17 -0800 Subject: [PATCH] doc: Fix "could could" typo in Submitting Patches section * doc/contributing.texi (Submitting Patches): s/could could/could / --- doc/contributing.texi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/doc/contributing.texi b/doc/contributing.texi index 18d891db4..de08f9b35 100644 --- a/doc/contributing.texi +++ b/doc/contributing.texi @@ -368,4 +368,4 @@ a subject. You may use your email client or the @command{git send-email} command. We prefer to get patches in plain text messages, either inline or as MIME attachments. You are advised to pay attention if your email client changes anything like line breaks or indentation which -could could potentially break the patches. +could potentially break the patches. -- 2.11.0 Maxim
Re: [PATCH 11/11] gnu: Add pagure.
Leo Famulariwrites: > On Wed, Dec 14, 2016 at 12:25:26PM +, ng0 wrote: >> * gnu/packages/version-control.scm (pagure): New variable. > > How can I test this? Is there supposed to be 'runserver.py' file to run? > > https://pagure.io/pagure It's mostly "read the docs" and as I progressed in reading the docs, I realized I forgot to add some more files. So... New patch coming in later, sorry. Can everything else except pagure be merged already? Or do you want to wait on that? https://docs.pagure.org/pagure/install.html#installing-pagure-via-setup-py -- ♥Ⓐ ng0 | ng0.chaosnet.org
Re: [PATCH 11/11] gnu: Add pagure.
On Wed, Dec 14, 2016 at 04:27:18PM +, ng0 wrote: > Leo Famulariwrites: > > > On Wed, Dec 14, 2016 at 12:25:26PM +, ng0 wrote: > >> * gnu/packages/version-control.scm (pagure): New variable. > > > > How can I test this? Is there supposed to be 'runserver.py' file to run? > > > > https://pagure.io/pagure > > It's mostly "read the docs" and as I progressed in reading the > docs, I realized I forgot to add some more files. > So... New patch coming in later, sorry. Can everything else > except pagure be merged already? Or do you want to wait on that? Seeing Pagure run is the best way to test the rest of the patches, so I'd rather wait. Note that the v2 patches still need to be changed to download their source code from PyPi.
Re: Shutdown of googlecode end of the year - we have affected packages!
Marius Bakkewrites: > Adonay Felipe Nogueira writes: > >> I can't work on this issue right now, but I can at least do some >> preliminary listing of affected recipes, so here's a small contribution >> (although some removal of false-positives must be done): >> >> From root of git repository (binary matches removed). >> >> $ grep -r 'googlecode' > > Thanks for the list! > > Here's a pro tip: `git grep` is recursive by default and excludes the > .git directory :) > > Patches to update any of these welcome. ng0@wasp ~$ cd src/guix/guix ng0@wasp ~/src/guix/guix$ git grep googlecode gnu/packages/key-mon.scm: "http://key-mon.googlecode.com/files/key-mon-; Are we done then and we only need to find the right source for key-mon if there is a new one? >> gnu/packages/key-mon.scm: >> "http://key-mon.googlecode.com/files/key-mon-; >> >> $ grep -r 'code\.google' >> gnu/packages/bioinformatics.scm:(home-page >> "https://code.google.com/p/cutadapt/;) >> gnu/packages/bioinformatics.scm: (home-page >> "https://code.google.com/p/mosaik-aligner/;) >> gnu/packages/bioinformatics.scm:(home-page >> "https://code.google.com/p/pepr-chip-seq/;) >> gnu/packages/python.scm:(home-page >> "https://code.google.com/p/py-bcrypt;) >> gnu/packages/python.scm:(home-page "http://code.google.com/p/mock/;) >> gnu/packages/python.scm:(home-page >> "https://code.google.com/archive/p/socksipy-branch/;) >> gnu/packages/python.scm:(home-page >> "http://code.google.com/p/prettytable/;) >> gnu/packages/java.scm: >> "code.google.com/jarjar/jarjar-src-" version ".zip")) >> gnu/packages/java.scm:(home-page >> "https://code.google.com/archive/p/jarjar/;) >> gnu/packages/protobuf.scm:(home-page >> "http://code.google.com/p/protobuf/;) >> gnu/packages/games.scm: >> "google-code-archive-downloads/v2/code.google.com/" >> gnu/packages/games.scm:(home-page >> "http://code.google.com/p/abbaye-for-linux/;) >> gnu/packages/scheme.scm:(home-page >> "https://code.google.com/p/chibi-scheme/;) >> gnu/packages/boost.scm:(home-page >> "https://code.google.com/p/multidimalgorithm/;) >> gnu/packages/key-mon.scm:(home-page >> "http://code.google.com/p/key-mon;) >> gnu/packages/image.scm: ;; >> https://code.google.com/p/tesseract-ocr/issues/detail?id=1436 >> gnu/packages/mtools.scm:(home-page >> "https://code.google.com/p/exfat;) >> gnu/packages/fontutils.scm: >> "code.google.com/ttf2eot/" >> gnu/packages/fontutils.scm:(home-page >> "https://code.google.com/archive/p/ttf2eot/;))) >> gnu/packages/openstack.scm:(http://code.google.com/p/pymox/) to Python >> 3. It was meant to be as compatible >> gnu/packages/patches/ttf2eot-cstddef.patch:From resolution of >> https://code.google.com/p/ttf2eot/issues/detail?id=26 >> gnu/packages/linux.scm:(home-page "http://code.google.com/p/exfat/;) >> doc/guix.texi:@url{http://code.google.com/p/cryptsetup,Linux Unified Key >> Setup}, a -- ♥Ⓐ ng0 | ng0.chaosnet.org
Re: [PATCH] gnu: Add phantomjs.
Jan Nieuwenhuizenwrites: > Hi, > > I need phantomjs for a client and finally managed to built it from > source. > > I tried to build it with our current qt-5.6/qtwebkit-5.7 but gave up; > apparently phantomjs needs patches to even build with qt-5.5. > > While I think it's a waste not to share this patch, I don't intend to > spend much effort on these (I have very little respect, patience or love > for qt), please don't put too much effort in reviewing if this needs > much work. > > Greetings, > Jan. > > From 25f9e007ee2c7f641e7761d990c61bc142440430 Mon Sep 17 00:00:00 2001 > From: Jan Nieuwenhuizen > Date: Thu, 17 Nov 2016 11:39:00 +0100 > Subject: [PATCH] gnu: Add phantomjs. I think it will be easier to review when you split it. This is all somewhat related, but those are 6 new public(?) packages and one very long patch. I don't know much about Qt, skipping through this I just saw one http which could be changed to https, that's all so far. > * gnu/packages/patches/phantomjs-qt55.patch: New file. > * gnu/local.mk (dist_patch_DATA): Add it. > * gnu/packages/qt.scm (qtbase55, qtsvg55, qtxmlpatterns55, qtdeclarative55, > qtwebkit55, phantomjs): New variable. > --- > gnu/local.mk | 1 + > gnu/packages/patches/phantomjs-qt55.patch | 277 > ++ > gnu/packages/qt.scm | 256 +++ > 3 files changed, 534 insertions(+) > create mode 100644 gnu/packages/patches/phantomjs-qt55.patch > > diff --git a/gnu/local.mk b/gnu/local.mk > index f780b24..96fde14 100644 > --- a/gnu/local.mk > +++ b/gnu/local.mk > @@ -787,6 +787,7 @@ dist_patch_DATA = > \ >%D%/packages/patches/perl-module-pluggable-search.patch\ >%D%/packages/patches/perl-reproducible-build-date.patch\ >%D%/packages/patches/perl-www-curl-remove-symbol.patch \ > + %D%/packages/patches/phantomjs-qt55.patch \ >%D%/packages/patches/pidgin-add-search-path.patch \ >%D%/packages/patches/pinball-const-fix.patch \ >%D%/packages/patches/pinball-cstddef.patch \ > diff --git a/gnu/packages/patches/phantomjs-qt55.patch > b/gnu/packages/patches/phantomjs-qt55.patch > new file mode 100644 > index 000..2a306f0 > --- /dev/null > +++ b/gnu/packages/patches/phantomjs-qt55.patch > @@ -0,0 +1,277 @@ > +Taken from Debian phantomjs/debian/patches/ > + > +Last-Update: 2016-02-15 > +Forwarded: no > +Author: Dmitry Smirnov > +Description: fix FTBFS. > + > +--- a/src/phantomjs.pro > b/src/phantomjs.pro > +@@ -8,9 +8,9 @@ > + } > + > + TEMPLATE = app > + TARGET = phantomjs > +-QT += network webkitwidgets > ++QT += network webkitwidgets printsupport > + CONFIG += console > + > + DESTDIR = ../bin > + > +Last-Update: 2016-02-15 > +Forwarded: no > +Bug-Upstream: https://github.com/ariya/phantomjs/issues/13727 > +Author: Ximin Luo > +Reviewed-By: Dmitry Smirnov > +Description: Port to Qt 5.5 > + - Remove second argument to evaluateJavascript(), which was not really used > + for anything, anyways > + > +--- a/src/utils.cpp > b/src/utils.cpp > +@@ -37,8 +37,9 @@ > + #include > + #include > + #include > + > ++ > + static QString findScript(const QString& jsFilePath, const QString& > libraryPath) > + { > + if (!jsFilePath.isEmpty()) { > + QFile jsFile; > +@@ -131,9 +132,9 @@ > + } > + return false; > + } > + // Execute JS code in the context of the document > +-targetFrame->evaluateJavaScript(scriptBody, > QString(JAVASCRIPT_SOURCE_CODE_URL).arg(QFileInfo(scriptPath).fileName())); > ++targetFrame->evaluateJavaScript(scriptBody); > + return true; > + } > + > + bool loadJSForDebug(const QString& jsFilePath, const QString& libraryPath, > QWebFrame* targetFrame, const bool autorun) > +@@ -146,12 +147,12 @@ > + QString scriptPath = findScript(jsFilePath, libraryPath); > + QString scriptBody = jsFromScriptFile(scriptPath, jsFileLanguage, > jsFileEnc); > + > + scriptBody = QString("function __run() {\n%1\n}").arg(scriptBody); > +-targetFrame->evaluateJavaScript(scriptBody, > QString(JAVASCRIPT_SOURCE_CODE_URL).arg(QFileInfo(scriptPath).fileName())); > ++targetFrame->evaluateJavaScript(scriptBody); > + > + if (autorun) { > +-targetFrame->evaluateJavaScript("__run()", QString()); > ++targetFrame->evaluateJavaScript("__run()"); > + } > + > + return true; > + } > +--- a/src/repl.cpp > b/src/repl.cpp > +@@ -146,9 +146,9 @@ > + // Set the static callback to offer Completions to the User > + linenoiseSetCompletionCallback(REPL::offerCompletion); > + > + // Inject REPL utility functions > +- > m_webframe->evaluateJavaScript(Utils::readResourceFileUtf8(":/repl.js"), >
Re: Help acme-client find its certificate store
Leo Famulariwrites: > On Tue, Dec 13, 2016 at 05:15:05PM -0500, Leo Famulari wrote: >> I'm successfully using this package with this change. >> >> I don't know if this is the "right way" to solve this. Your thoughts? > > To clarify, here is what happens on Debian Jessie without this change: > > $ acme-client -nN example.com > acme-client: tls_config_set_ca_file: failed to open CA file > '/etc/ssl/cert.pem': No such file or directory: No such file or directory > > And here are the upstream notes on this subject [0]: > > "You can also set DEFAULT_CA_FILE for the location of the certificate > file loaded by libtls." > > https://github.com/kristapsdz/acme-client-portable/blob/master/README.md#configuration > >> + (let ((pem (string-append (assoc-ref inputs "libressl") >> + "/etc/ssl/cert.pem"))) >> + (substitute* "http.c" >> + (("/etc/ssl/cert.pem") pem)) > > The upstream maintainer recommends setting this value in 'config.h', but > it's only used in 'http.c', so I thought this solution would be a little > easier to read. LGTM. I did not know libressl maintains their own root trust. signature.asc Description: PGP signature
Re: [PATCH 11/11] gnu: Add pagure.
On Wed, Dec 14, 2016 at 12:25:26PM +, ng0 wrote: > * gnu/packages/version-control.scm (pagure): New variable. How can I test this? Is there supposed to be 'runserver.py' file to run? https://pagure.io/pagure
[PATCH] utils: file-extension should work with urls.
* guix/utils.scm (file-extension): Detect the lack of file extensions in urls. --- guix/utils.scm | 8 ++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/guix/utils.scm b/guix/utils.scm index 06f49daca..2bae2eb60 100644 --- a/guix/utils.scm +++ b/guix/utils.scm @@ -24,6 +24,7 @@ (define-module (guix utils) #:use-module (guix config) #:use-module (srfi srfi-1) + #:use-module (srfi srfi-2) #:use-module (srfi srfi-9) #:use-module (srfi srfi-11) #:use-module (srfi srfi-26) @@ -559,8 +560,11 @@ minor version numbers from version-string." (define (file-extension file) "Return the extension of FILE or #f if there is none." - (let ((dot (string-rindex file #\.))) -(and dot (substring file (+ 1 dot) (string-length file) + (and-let* ((dot (string-rindex file #\.)) + (ext (substring file (+ 1 dot) (string-length file +;; Make sure that a file-extension does not contain forward +;; slashes incase file is a URL. +(and (not (string-rindex file #\/)) ext))) (define (file-sans-extension file) "Return the substring of FILE without its extension, if any." -- 2.11.0
Re: [PATCH 1/2] import: json: Silence json-fetch output.
I think this commit broke the pypi tests.
Re: Help acme-client find its certificate store
On Tue, Dec 13, 2016 at 05:15:05PM -0500, Leo Famulari wrote: > I'm successfully using this package with this change. > > I don't know if this is the "right way" to solve this. Your thoughts? To clarify, here is what happens on Debian Jessie without this change: $ acme-client -nN example.com acme-client: tls_config_set_ca_file: failed to open CA file '/etc/ssl/cert.pem': No such file or directory: No such file or directory And here are the upstream notes on this subject [0]: "You can also set DEFAULT_CA_FILE for the location of the certificate file loaded by libtls." https://github.com/kristapsdz/acme-client-portable/blob/master/README.md#configuration > + (let ((pem (string-append (assoc-ref inputs "libressl") > + "/etc/ssl/cert.pem"))) > + (substitute* "http.c" > + (("/etc/ssl/cert.pem") pem)) The upstream maintainer recommends setting this value in 'config.h', but it's only used in 'http.c', so I thought this solution would be a little easier to read. signature.asc Description: PGP signature
[PATCH 02/11] gnu: Add python-flask-multistatic.
* gnu/packages/python.scm (python-flask-multistatic): New variable. --- gnu/packages/python.scm | 24 1 file changed, 24 insertions(+) diff --git a/gnu/packages/python.scm b/gnu/packages/python.scm index 763e452f1..b324f993e 100644 --- a/gnu/packages/python.scm +++ b/gnu/packages/python.scm @@ -9263,6 +9263,30 @@ file upload, and reCAPTCHA.") (define-public python2-flask-wtf (package-with-python2 python-flask-wtf)) +(define-public python-flask-multistatic + (package +(name "python-flask-multistatic") +(version "1.0") +(source + (origin + (method url-fetch) + (uri (pypi-uri "flask-multistatic" version)) + (sha256 +(base32 + "0p4v50rwv64wcd0zlq7rzl4waprwr4hj19s3cgf1isywa7jcisgm" +(build-system python-build-system) +(propagated-inputs + `(("python-flask" ,python-flask))) +(home-page "https://pagure.io/flask-multistatic;) +(synopsis "Flask plugin to allow overriding static files") +(description + "@code{flask-multistatic} is a simple plugin to add +support for overriding static files to flask.") +(license license:gpl3+))) + +(define-public python2-flask-multistatic + (package-with-python2 python-flask-multistatic)) + (define-public python-cookies (package (name "python-cookies") -- 2.11.0
[PATCH 11/11] gnu: Add pagure.
* gnu/packages/version-control.scm (pagure): New variable. --- gnu/packages/version-control.scm | 87 +++- 1 file changed, 86 insertions(+), 1 deletion(-) diff --git a/gnu/packages/version-control.scm b/gnu/packages/version-control.scm index 7918b90ca..3b8fecc38 100644 --- a/gnu/packages/version-control.scm +++ b/gnu/packages/version-control.scm @@ -10,7 +10,7 @@ ;;; Copyright © 2015 Kyle Meyer;;; Copyright © 2015 Ricardo Wurmus ;;; Copyright © 2016 Leo Famulari -;;; Copyright © 2016 ng0 +;;; Copyright © 2016 ng0 ;;; ;;; This file is part of GNU Guix. ;;; @@ -1263,3 +1263,88 @@ a built-in wiki, built-in file browsing, built-in tickets system, etc.") (description "Stagit creates static pages for git repositories, the results can be served with a HTTP file server of your choice.") (license license:expat))) + +(define-public pagure + (package +(name "pagure") +(version "2.10.1") +(source + (origin + (method url-fetch) + (uri (list + ;; XXX: upstream serves an invalid certificate, + ;; https://pagure.io/fedora-infrastructure/issue/5600 + (string-append "https://web.archive.org/web/20161211142731/; +"https://releases.pagure.org/pagure/pagure-; +version ".tar.gz") + (string-append "https://releases.pagure.org/pagure/; + name "-" version ".tar.gz"))) + (sha256 +(base32 + "1h629hd8wfvdnmlrd1g3hpxcgkqzrxdpnxnmqhd2wi04g86pn7pg" +(build-system python-build-system) +(arguments + `(#:python ,python-2 + #:phases + (modify-phases %standard-phases + (add-after 'install 'install-additional-files + ;; Copy the sample files as they can help setting up + ;; the service. This is a step mentioned at + ;; https://docs.pagure.org/pagure/install.html#installing-pagure-via-setup-py + (lambda* (#:key outputs #:allow-other-keys) + (install-file "files/pagure.cfg.sample" + (string-append (assoc-ref outputs "out") "/etc/pagure/")) + (install-file "files/alembic.ini" + (string-append (assoc-ref outputs "out") "/etc/pagure/")) + (install-file "files/pagure.conf" + (string-append (assoc-ref outputs "out") "/etc/httpd/conf.d/")) + (install-file "files/pagure.wsgi" + (string-append (assoc-ref outputs "out") "/share/pagure/")) + (install-file "createdb.py" + (string-append (assoc-ref outputs "out") "/share/pagure/")) + #t) +(propagated-inputs + ;; There are no executables provided, it is all provided + ;; as a library. + `(("python2-alembic" ,python2-alembic) + ("python2-arrow" ,python2-arrow) + ("python2-binaryornot" ,python2-binaryornot) + ("python2-bleach" ,python2-bleach) + ("python2-blinker" ,python2-blinker) + ("python2-chardet" ,python2-chardet) + ("python2-docutils" ,python2-docutils) + ("python2-enum34" ,python2-enum34) + ("python2-flask" ,python2-flask) + ("python2-flask-wtf" ,python2-flask-wtf) + ("python2-flask-multistatic" ,python2-flask-multistatic) + ("python2-kitchen" ,python2-kitchen) + ("python2-markdown" ,python2-markdown) + ("python2-munch" ,python2-munch) + ("python2-pillow" ,python2-pillow) + ("python2-psutil" ,python2-psutil) + ;; TODO: pyclamd ; only for VIRUS_SCAN_ATTACHMENTS + ("python2-pygit2" ,python2-pygit2) + ("python2-pygments" ,python2-pygments) + ("python2-openid" ,python2-openid) + ("python2-openid-cla" ,python2-openid-cla) + ("python2-openid-teams" ,python2-openid-teams) + ("python2-redis" ,python2-redis) + ("python2-six" ,python2-six) + ("python2-sqlalchemy" ,python2-sqlalchemy) + ("python2-straight.plugin" ,python2-straight.plugin) + ("python2-trollius-redis" ,python2-trollius-redis) + ("python2-wtforms" ,python2-wtforms) + ("python2-cryptography" ,python2-cryptography) + ;; TODO: python2-fedora ;for fas and openid auth backends + ("python2-py-bcrypt" ,python2-py-bcrypt))) +(home-page "https://pagure.io/pagure/;) +(synopsis "Web-based collaborative software platform based on pygit2") +(description + "Pagure is a git-centered, web-based collaborative +software platform, Python-based using pygit2. +With pagure you can host your project with its documentation, +let your users report issues or request enhancements using the +ticketing system and build your community of contributors by +allowing them to fork your project and contribute to it via +the pull-request
[PATCH 10/11] gnu: Add python-trollius-redis.
* gnu/packages/python.scm (python-trollius-redis): New variable. --- gnu/packages/python.scm | 23 +++ 1 file changed, 23 insertions(+) diff --git a/gnu/packages/python.scm b/gnu/packages/python.scm index b1bfc4850..1ff4bc8f6 100644 --- a/gnu/packages/python.scm +++ b/gnu/packages/python.scm @@ -8048,6 +8048,29 @@ minimal and fast API targetting the following uses: (define-public python2-execnet (package-with-python2 python-execnet)) +(define-public python-trollius-redis +(package + (name "python-trollius-redis") + (version "0.1.4") + (source +(origin + (method url-fetch) + (uri (pypi-uri "trollius_redis" version)) + (sha256 + (base32 +"0k3vypszmgmaipgw9xscvgm79h2zd6p6ci8gdp5sxl6g5kbqr9fy" + (build-system python-build-system) + (home-page "https://github.com/benjolitz/trollius-redis;) + (synopsis "Port of asyncio-redis to trollius") + (description + "@code{trollius-redis} is a Redis client for Python +trollius. It is a PEP 3156 implementation of the redis +protocol.") + (license license:bsd-2))) + +(define-public python2-trollius-redis + (package-with-python2 python-trollius-redis)) + ;;; The software provided by this package was integrated into pytest 2.8. (define-public python-pytest-cache (package -- 2.11.0
[PATCH 07/11] gnu: Add python-openid-cla.
* gnu/packages/python.scm (python-openid-cla): New variable. --- gnu/packages/python.scm | 25 + 1 file changed, 25 insertions(+) diff --git a/gnu/packages/python.scm b/gnu/packages/python.scm index ca5201f33..8246a33d5 100644 --- a/gnu/packages/python.scm +++ b/gnu/packages/python.scm @@ -5309,6 +5309,31 @@ another XPath engine to find the matching elements in an XML or HTML document.") (define-public python2-cssselect (package-with-python2 python-cssselect)) +(define-public python-openid-cla + (package +(name "python-openid-cla") +(version "1.2") +(source + (origin + (method url-fetch) + (uri (string-append "https://github.com/puiterwijk/; + "python-openid-cla/archive/v" + version ".tar.gz")) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 +(base32 + "18iri5zls94fa4wk1r7hyk4mr9z669km4g1858yrnq64dkr13a0w" +(build-system python-build-system) +(home-page "https://github.com/puiterwijk/python-openid-cla/;) +(synopsis "Implementation of the OpenID cla extension for python-openid") +(description + "@code{openid-cla} is an implementation of the OpenID cla +extension for python-openid.") +(license license:bsd-3))) + +(define-public python2-openid-cla + (package-with-python2 python-openid-cla)) + (define-public python-netifaces (package (name "python-netifaces") -- 2.11.0
[PATCH 09/11] gnu: Add python-straight-plugin.
* gnu/packages/python.scm (python-straight-plugin): New variable. --- gnu/packages/python.scm | 27 +++ 1 file changed, 27 insertions(+) diff --git a/gnu/packages/python.scm b/gnu/packages/python.scm index e7e10dc90..b1bfc4850 100644 --- a/gnu/packages/python.scm +++ b/gnu/packages/python.scm @@ -6026,6 +6026,33 @@ term.js Javascript terminal emulator library.") ,python2-backport-ssl-match-hostname) ,@(package-propagated-inputs terminado)) +(define-public python-straight-plugin + (package +(name "python-straight-plugin") +(version "1.4.1") +(source + (origin + (method url-fetch) + (uri (string-append "https://github.com/ironfroggy/; + "straight.plugin/archive/" + version ".tar.gz")) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 +(base32 + "0yy7ymng4d2dgqg81dz48b176zarbk1il7ig1m1q8zl8l559n817" +(build-system python-build-system) +(home-page "https://github.com/ironfroggy/straight.plugin;) +(synopsis "Simple namespaced plugin facility") +(description + "Straight Plugin provides a type of plugin you can create +from almost any existing Python modules, and an easy way for +outside developers to add functionality and customization to +your projects with their own plugins.") +(license license:expat))) + +(define-public python2-straight-plugin + (package-with-python2 python-straight-plugin)) + (define-public python-fonttools (package (name "python-fonttools") -- 2.11.0
[PATCH 08/11] gnu: Add python-openid-teams.
* gnu/packages/python.scm (python-openid-teams): New variable. --- gnu/packages/python.scm | 25 + 1 file changed, 25 insertions(+) diff --git a/gnu/packages/python.scm b/gnu/packages/python.scm index 8246a33d5..e7e10dc90 100644 --- a/gnu/packages/python.scm +++ b/gnu/packages/python.scm @@ -5334,6 +5334,31 @@ extension for python-openid.") (define-public python2-openid-cla (package-with-python2 python-openid-cla)) +(define-public python-openid-teams + (package +(name "python-openid-teams") +(version "1.1") +(source + (origin + (method url-fetch) + (uri (string-append "https://github.com/puiterwijk/; + "python-openid-teams/archive/v" + version ".tar.gz")) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 +(base32 + "08m26gsikibfawr5hn01gh8q2f9csrwjqi9jliyln4cdwvz318xw" +(build-system python-build-system) +(home-page "https://github.com/puiterwijk/python-openid-teams/;) +(synopsis "Implementation of the OpenID teams extension for python-openid") +(description + "@code{openid-teams} is an implementation of the OpenID +teams extension for python-openid.") +(license license:bsd-3))) + +(define-public python2-openid-teams + (package-with-python2 python-openid-teams)) + (define-public python-netifaces (package (name "python-netifaces") -- 2.11.0
[PATCH] series: Add pagure (v2).
Applied the feedback, thanks. Regarding the extra files, read the changed comment and the link I included. It's my understanding that this will help people to use pagure. My intention is to write a service for it, so I do not need the sample files, but it might serve as a reference for systems which are not GuixSD.
[PATCH 03/11] gnu: Add python-kitchen.
* gnu/packages/python.scm (python-kitchen): New variable. --- gnu/packages/python.scm | 32 1 file changed, 32 insertions(+) diff --git a/gnu/packages/python.scm b/gnu/packages/python.scm index b324f993e..9ebdbc420 100644 --- a/gnu/packages/python.scm +++ b/gnu/packages/python.scm @@ -2436,6 +2436,38 @@ version numbers.") (propagated-inputs `(("python2-functools32" ,python2-functools32)) +(define-public python-kitchen + (package +(name "python-kitchen") +(version "1.2.4") +(source + (origin + (method url-fetch) + (uri (string-append "https://github.com/fedora-infra/; + "kitchen/archive/" version ".tar.gz")) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 +(base32 + "1ybx8nccbh6j1v6xj60j8dkbwnhlj0i1hizfrxzcdvrm9wn6a8wa" +(build-system python-build-system) +(propagated-inputs + `(("python-chardet" ,python-chardet))) +(home-page "https://fedorahosted.org/kitchen;) +(synopsis "Python API for snippets") +(description + "@code{kitchen} module provides a python API for all sorts +of little useful snippets of code that everybody ends up +writing for their projects but never seem big enough to build +an independent release. Use kitchen and stop cutting and +pasting that code over and over.") +(license (list license:lgpl2.1+ + ;; subprocess.py, test_subprocess.py, + ;; kitchen/pycompat25/defaultdict.py: + license:psfl + +(define-public python2-kitchen + (package-with-python2 python-kitchen)) + (define-public python-unidecode (package (name "python-unidecode") -- 2.11.0
[PATCH 06/11] gnu: Add python2-openid.
* gnu/packages/python.scm (python2-openid): New variable. --- gnu/packages/python.scm | 21 + 1 file changed, 21 insertions(+) diff --git a/gnu/packages/python.scm b/gnu/packages/python.scm index c28dac0f8..ca5201f33 100644 --- a/gnu/packages/python.scm +++ b/gnu/packages/python.scm @@ -5055,6 +5055,27 @@ features useful for text console applications.") (define-public python2-urwid (package-with-python2 python-urwid)) +(define-public python2-openid + (package +(name "python2-openid") +(version "2.2.5") +(source + (origin + (method url-fetch) + (uri (string-append "https://github.com/openid/; + "python-openid/archive/" version ".tar.gz")) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 +(base32 + "1rkgsx1cxb85zl8jkaqmnbhdm3rvs8qcvv3z0k6jwmgkwi0kda1z" +(build-system python-build-system) +(arguments + `(#:python ,python-2)) ; No Python 3 support. +(home-page "https://github.com/openid/python-openid;) +(synopsis "OpenID support for servers and consumers") +(description "OpenID library for Python.") +(license license:asl2.0))) + (define-public python-urwidtrees (package (name "python-urwidtrees") -- 2.11.0
[PATCH 05/11] gnu: Add python-pygit2.
* gnu/packages/python.scm (python-pygit2): New variable. --- gnu/packages/python.scm | 30 ++ 1 file changed, 30 insertions(+) diff --git a/gnu/packages/python.scm b/gnu/packages/python.scm index 8578b917b..c28dac0f8 100644 --- a/gnu/packages/python.scm +++ b/gnu/packages/python.scm @@ -3379,6 +3379,36 @@ association studies (GWAS) on extremely large data sets.") (define-public python2-numpy (package-with-python2 python-numpy)) +(define-public python-pygit2 + (package +(name "python-pygit2") +(version "0.24.2") +(source + (origin + (method url-fetch) + (uri (string-append "https://github.com/libgit2/; + "pygit2/archive/v" version ".tar.gz")) + (file-name (string-append name "-" version ".tar.gz")) + (sha256 +(base32 + "1j7zkz2bsn4wqmkg1zkxb3r00xx28rkz9jdwcsikcl4ffa298xwa" +(build-system python-build-system) +(propagated-inputs + `(("python-six" ,python-six) + ("python-cffi" ,python-cffi) + ("libgit2" ,libgit2) + ("python-tox" ,python-tox))) +(home-page "http://github.com/libgit2/pygit2;) +(synopsis "Python bindings for libgit2") +(description + "Pygit2 is a set of Python bindings to the libgit2 +shared library, libgit2 implements Git plumbing.") +;; GPL2.0 only, with linking exception. +(license license:gpl2))) + +(define-public python2-pygit2 + (package-with-python2 python-pygit2)) + (define-public python-pyparsing (package (name "python-pyparsing") -- 2.11.0
[PATCH 01/11] gnu: Add python-flask-wtf.
* gnu/packages/python.scm (python-flask-wtf): New variable. --- gnu/packages/python.scm | 27 +++ 1 file changed, 27 insertions(+) diff --git a/gnu/packages/python.scm b/gnu/packages/python.scm index 6d6d880bb..763e452f1 100644 --- a/gnu/packages/python.scm +++ b/gnu/packages/python.scm @@ -9236,6 +9236,33 @@ presume or force a developer to use a particular tool or library.") (define-public python2-flask (package-with-python2 python-flask)) +(define-public python-flask-wtf + (package +(name "python-flask-wtf") +(version "0.13.1") +(source + (origin + (method url-fetch) + (uri (pypi-uri "Flask-WTF" version)) + (sha256 +(base32 + "04l5743j2dici46038sqlzvf0xzpg8rf7s9ld2x24xv7f4idg990" +(build-system python-build-system) +(propagated-inputs + `(("python-flask-babel" ,python-flask-babel))) +(native-inputs + `(("python-nose" ,python-nose) + ("python-wtforms" ,python-wtforms))) + (home-page "https://github.com/lepture/flask-wtf;) + (synopsis "Simple integration of Flask and WTForms") + (description + "Simple integration of Flask and WTForms, including CSRF, +file upload, and reCAPTCHA.") + (license license:bsd-3))) + +(define-public python2-flask-wtf + (package-with-python2 python-flask-wtf)) + (define-public python-cookies (package (name "python-cookies") -- 2.11.0
[PATCH 04/11] gnu: Add python-munch.
* gnu/packages/python.scm (python-munch): New variable. --- gnu/packages/python.scm | 22 ++ 1 file changed, 22 insertions(+) diff --git a/gnu/packages/python.scm b/gnu/packages/python.scm index 9ebdbc420..8578b917b 100644 --- a/gnu/packages/python.scm +++ b/gnu/packages/python.scm @@ -3260,6 +3260,28 @@ capabilities.") (define python2-numpy-bootstrap (package-with-python2 python-numpy-bootstrap)) +(define-public python-munch + (package +(name "python-munch") +(version "2.0.4") +(source + (origin + (method url-fetch) + (uri (pypi-uri "munch" version)) + (sha256 +(base32 + "1cmqg91xnqx8gvnh4pmp0bfl1dfcm65d5p9mg73zz8pkjhx6h80l" +(build-system python-build-system) +(home-page "https://github.com/Infinidat/munch;) +(synopsis "Dot-accessible dictionary") +(description + "Munch is a dot-accessible dictionary similar to +JavaScript objects.") +(license license:expat))) + +(define-public python2-munch + (package-with-python2 python-munch)) + (define-public python2-fastlmm (package (name "python2-fastlmm") -- 2.11.0
Re: [PATCH 1/7] build-system: Add cargo build system.
> Would that help? Awesome! Thank you. The bootstrapping solution turned out much better. I added the #:system argument to rustc-bootstrap and cargo-bootstrap and moved the gcc -> cc symlink into rust-bootstrap, so that we get a native toolchain. We can build rustc on i686 and x86_64 using the same binary.
Re: [PATCH 1/2] gnu: Add r-bit.
On 14/12/16 02:30, Ricardo Wurmus wrote: [..] Okay with these changes. Thanks! Quite right. I made a few more changes to the description and push the series ending in 'ce3f92e7018e140f5e6b7333a604f26506de6c2a'. Thanks for the prompt review. ben
Re: NetworkManager doesn't "Connect automatically"
Andy Wingowrites: > On Wed 14 Dec 2016 10:13, Chris Marusich writes: > >> Did I make a mistake, or does NetworkManager just not recognize elogind? >> I'll look into this more, but unless I made a mistake, I suspect that >> either elogind or network-manager might require some tweaks to convince >> network-manager that elogind is equivalent to systemd in this case. > > See README where it mentions differences to logind: > > https://github.com/elogind/elogind > > In particular see the changes in gnu/packages/polkit.scm to get > PolicyKit to recognize elogind. > > ANdy Awesome, thank you for the tip! At first blush it looks like the word "systemd" is mentioned in surprisingly many files inside the NetworkManager source. I'll try following the example of polkit and see how it goes! -- Chris signature.asc Description: PGP signature
Re: NetworkManager doesn't "Connect automatically"
Hi Thomas, Thank you for the quick response! Thomas Hallerwrites: > Did you build NetworkManager yourself? Is session-tracking properly > enabled to use systemd-logind or consolekit. Yes, I'm building it from source [1]. It looks like we might need to adjust the way we build it to enable session-tracking, like you've suggested. Am I correct in understanding that I should only need to pass the option "--with-systemd-logind=yes" to the configure script to enable session tracking via systemd-logind? Is anything else required? > Starting NetworkManager with --debug is usually not that useful. The > most interesting thing it does is to turn on debug-logging, which you > can do otherwise [1]. Understood. Thank you for the tip! [1] The NetworkManager package definition [2] as of today is here: http://git.savannah.gnu.org/cgit/guix.git/tree/gnu/packages/gnome.scm?id=72c0b687800a617b891565f5a85bb06c1e1ba015#n4391 [2] If you're curious, you can learn more here: https://www.gnu.org/software/guix/manual/html_node/Defining-Packages.html#Defining-Packages -- Chris signature.asc Description: PGP signature
Re: NetworkManager doesn't "Connect automatically"
On Wed 14 Dec 2016 10:13, Chris Marusichwrites: > Did I make a mistake, or does NetworkManager just not recognize elogind? > I'll look into this more, but unless I made a mistake, I suspect that > either elogind or network-manager might require some tweaks to convince > network-manager that elogind is equivalent to systemd in this case. See README where it mentions differences to logind: https://github.com/elogind/elogind In particular see the changes in gnu/packages/polkit.scm to get PolicyKit to recognize elogind. ANdy
Re: NetworkManager doesn't "Connect automatically"
Hi Ludo, l...@gnu.org (Ludovic Courtès) writes: > Hello network managers! :-) Hopefully soon we will MANAGE to get it working! ;-) > ren...@openmailbox.org skribis: > >> Accordig to what Thomas comments, I have two ideas: >> >> * I wil try to compile 'network-manager' with >> '--with-session-tracking=consolekit'. > > On GuixSD we use “elogind”, which is like “systemd-logind”. > > However, the build log says: > > Platform: > session tracking: consolekit > suspend/resume: consolekit > > … which is definitely wrong. > > We need to tell it to use elogind, but adding it as an input is not > enough. Ideas? By running "./configure --help", I found these promising options: --8<---cut here---start->8--- --with-systemd-logind=yes|no Support systemd session tracking --with-consolekit=yes|no Support consolekit session tracking --8<---cut here---end--->8--- I tried the attached patch, but when I built network-manager, I got: --8<---cut here---start->8--- checking for SYSTEMD_200... no checking for LIBSYSTEMD... no checking for SYSTEMD_JOURNAL... no checking for SYSTEMD_JOURNAL... no checking for SYSTEMD_LOGIN... no checking for SYSTEMD_LOGIN... no configure: error: You must have libsystemd installed to build with systemd-logind support. phase `configure' failed after 5.3 seconds builder for `/gnu/store/2zv14p720wfw594g86sf8wsd6fmkh8s7-network-manager-1.4.2.drv' failed with exit code 1 @ build-failed /gnu/store/2zv14p720wfw594g86sf8wsd6fmkh8s7-network-manager-1.4.2.drv - 1 builder for `/gnu/store/2zv14p720wfw594g86sf8wsd6fmkh8s7-network-manager-1.4.2.drv' failed with exit code 1 guix build: error: build failed: build of `/gnu/store/2zv14p720wfw594g86sf8wsd6fmkh8s7-network-manager-1.4.2.drv' failed --8<---cut here---end--->8--- Did I make a mistake, or does NetworkManager just not recognize elogind? I'll look into this more, but unless I made a mistake, I suspect that either elogind or network-manager might require some tweaks to convince network-manager that elogind is equivalent to systemd in this case. -- Chris From 2c3973f566a889e291555a208813f45a371134b7 Mon Sep 17 00:00:00 2001 From: Chris MarusichDate: Wed, 14 Dec 2016 00:44:54 -0800 Subject: [PATCH] gnome: Enable session tracking in network-manager. * gnu/packages/gnome.scm (network-manager): Add configuration options "--with-systemd-logind=yes" (so we can use elogind to track login sessions) and "--with-consolekit=no" (so we don't use consolekit to track sessions, since it isn't packaged yet). Add elogind as an input. --- gnu/packages/gnome.scm | 7 +-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/gnu/packages/gnome.scm b/gnu/packages/gnome.scm index 1762381cf..c2b4f0ce4 100644 --- a/gnu/packages/gnome.scm +++ b/gnu/packages/gnome.scm @@ -4409,7 +4409,9 @@ users.") (doc (assoc-ref %outputs "doc")) (dhclient (string-append (assoc-ref %build-inputs "isc-dhcp") "/sbin/dhclient"))) - (list "--with-crypto=gnutls" + (list "--with-systemd-logind=yes" ; In Guix, this is provided via elogind. + "--with-consolekit=no" ; We haven't packaged consolekit yet. + "--with-crypto=gnutls" "--disable-config-plugin-ibft" "--sysconfdir=/etc" "--localstatedir=/var" @@ -4474,7 +4476,8 @@ users.") ("polkit" ,polkit) ("ppp" ,ppp) ("readline" ,readline) - ("util-linux" ,util-linux))) + ("util-linux" ,util-linux) + ("elogind" ,elogind))) (synopsis "Network connection manager") (home-page "http://www.gnome.org/projects/NetworkManager/;) (description -- 2.11.0 signature.asc Description: PGP signature
[PATCH 2/2] services: postgresql: Add locale to configuration
* gnu/services/databases.scm (): Add locale field. (postgresql-shepherd-service): Pass locale to initdb. (postgresql-service): Add locale default. --- doc/guix.texi | 8 gnu/services/databases.scm | 22 ++ 2 files changed, 22 insertions(+), 8 deletions(-) diff --git a/doc/guix.texi b/doc/guix.texi index af5869314..46f95035d 100644 --- a/doc/guix.texi +++ b/doc/guix.texi @@ -10151,13 +10151,13 @@ The @code{(gnu services databases)} module provides the following services. @deffn {Scheme Procedure} postgresql-service [#:postgresql postgresql] @ [#:config-file] [#:data-directory ``/var/lib/postgresql/data''] @ - [#:port 5432] + [#:port 5432] [#:locale ``en_US.utf8''] Return a service that runs @var{postgresql}, the PostgreSQL database server. -The PostgreSQL daemon loads its runtime configuration from -@var{config-file}, stores the database cluster in @var{data-directory} and -listens on @var{port}. +The PostgreSQL daemon loads its runtime configuration from @var{config-file}, +creates a database cluster with @var{locale} as the default +locale, stored in @var{data-directory}. It then listens on @var{port}. @end deffn @deffn {Scheme Procedure} mysql-service [#:config (mysql-configuration)] diff --git a/gnu/services/databases.scm b/gnu/services/databases.scm index 7cdcfc4d7..d88c839f7 100644 --- a/gnu/services/databases.scm +++ b/gnu/services/databases.scm @@ -50,6 +50,8 @@ (default postgresql)) (port postgresql-configuration-port (default 5432)) + (locale postgresql-configuration-locale + (default "en_US.utf8")) (config-filepostgresql-configuration-file) (data-directory postgresql-configuration-data-directory)) @@ -82,13 +84,18 @@ hostall all ::1/128 trust")) (define postgresql-activation (match-lambda -(($ postgresql port config-file data-directory) +(($ postgresql port locale config-file data-directory) #~(begin (use-modules (guix build utils) (ice-9 match)) (let ((user (getpwnam "postgres")) - (initdb (string-append #$postgresql "/bin/initdb"))) + (initdb (string-append #$postgresql "/bin/initdb")) + (initdb-args +(append + (if #$locale + (list (string-append "--locale=" #$locale)) + '() ;; Create db state directory. (mkdir-p #$data-directory) (chown #$data-directory (passwd:uid user) (passwd:gid user)) @@ -103,14 +110,19 @@ host all all ::1/128 trust")) (lambda () (setgid (passwd:gid user)) (setuid (passwd:uid user)) - (primitive-exit (system* initdb "-D" #$data-directory))) + (primitive-exit + (apply system* + initdb + "-D" + #$data-directory + initdb-args))) (lambda () (primitive-exit 1 (pid (waitpid pid (define postgresql-shepherd-service (match-lambda -(($ postgresql port config-file data-directory) +(($ postgresql port locale config-file data-directory) (let ((start-script ;; Wrapper script that switches to the 'postgres' user before ;; launching daemon. @@ -144,6 +156,7 @@ hostall all ::1/128 trust")) (define* (postgresql-service #:key (postgresql postgresql) (port 5432) + (locale "en_US.utf8") (config-file %default-postgres-config) (data-directory "/var/lib/postgresql/data")) "Return a service that runs @var{postgresql}, the PostgreSQL database server. @@ -154,6 +167,7 @@ and stores the database cluster in @var{data-directory}." (postgresql-configuration (postgresql postgresql) (port port) +(locale locale) (config-file config-file) (data-directory data-directory -- 2.11.0
[PATCH 1/2] services: postgresql: Add port to configuration
* gnu/services/databases.scm (): Add port field. (postgresql-shepherd-service): Pass port to postgres. (postgresql-service): Add port default. --- doc/guix.texi | 7 --- gnu/services/databases.scm | 9 +++-- 2 files changed, 11 insertions(+), 5 deletions(-) diff --git a/doc/guix.texi b/doc/guix.texi index f1c5963f7..af5869314 100644 --- a/doc/guix.texi +++ b/doc/guix.texi @@ -10150,13 +10150,14 @@ Users need to be in the @code{lp} group to access the D-Bus service. The @code{(gnu services databases)} module provides the following services. @deffn {Scheme Procedure} postgresql-service [#:postgresql postgresql] @ - [#:config-file] [#:data-directory ``/var/lib/postgresql/data''] + [#:config-file] [#:data-directory ``/var/lib/postgresql/data''] @ + [#:port 5432] Return a service that runs @var{postgresql}, the PostgreSQL database server. The PostgreSQL daemon loads its runtime configuration from -@var{config-file} and stores the database cluster in -@var{data-directory}. +@var{config-file}, stores the database cluster in @var{data-directory} and +listens on @var{port}. @end deffn @deffn {Scheme Procedure} mysql-service [#:config (mysql-configuration)] diff --git a/gnu/services/databases.scm b/gnu/services/databases.scm index f7e08e696..7cdcfc4d7 100644 --- a/gnu/services/databases.scm +++ b/gnu/services/databases.scm @@ -48,6 +48,8 @@ postgresql-configuration? (postgresql postgresql-configuration-postgresql ; (default postgresql)) + (port postgresql-configuration-port + (default 5432)) (config-filepostgresql-configuration-file) (data-directory postgresql-configuration-data-directory)) @@ -80,7 +82,7 @@ host all all ::1/128 trust")) (define postgresql-activation (match-lambda -(($ postgresql config-file data-directory) +(($ postgresql port config-file data-directory) #~(begin (use-modules (guix build utils) (ice-9 match)) @@ -108,7 +110,7 @@ hostall all ::1/128 trust")) (define postgresql-shepherd-service (match-lambda -(($ postgresql config-file data-directory) +(($ postgresql port config-file data-directory) (let ((start-script ;; Wrapper script that switches to the 'postgres' user before ;; launching daemon. @@ -121,6 +123,7 @@ hostall all ::1/128 trust")) (system* postgres (string-append "--config-file=" #$config-file) + "-p" (number->string #$port) "-D" #$data-directory) (list (shepherd-service (provision '(postgres)) @@ -140,6 +143,7 @@ hostall all ::1/128 trust")) (const %postgresql-accounts)) (define* (postgresql-service #:key (postgresql postgresql) + (port 5432) (config-file %default-postgres-config) (data-directory "/var/lib/postgresql/data")) "Return a service that runs @var{postgresql}, the PostgreSQL database server. @@ -149,6 +153,7 @@ and stores the database cluster in @var{data-directory}." (service postgresql-service-type (postgresql-configuration (postgresql postgresql) +(port port) (config-file config-file) (data-directory data-directory -- 2.11.0