GNU bug report logs - #31989
vim-build-system

Please note: This is a static page, with minimal formatting, updated once a day.
Click here to see this page with the latest information and nicer formatting.

Package: guix-patches; Reported by: Efraim Flashner <efraim@HIDDEN>; Keywords: patch moreinfo; merged with #30385; dated Wed, 27 Jun 2018 20:06:01 UTC; Maintainer for guix-patches is guix-patches@HIDDEN.
Merged 30385 31989. Request was from Ricardo Wurmus <ricardo.wurmus@HIDDEN> to control <at> debbugs.gnu.org. Full text available.

Message received at 31989 <at> debbugs.gnu.org:


Received: (at 31989) by debbugs.gnu.org; 28 Jun 2018 04:56:30 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Thu Jun 28 00:56:30 2018
Received: from localhost ([127.0.0.1]:38082 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1fYOyk-0001gk-DF
	for submit <at> debbugs.gnu.org; Thu, 28 Jun 2018 00:56:29 -0400
Received: from static.195.114.201.195.clients.your-server.de
 ([195.201.114.195]:47704 helo=conspiracy.of.n0.is)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <ng0@HIDDEN>) id 1fYOyg-0001gY-CM
 for 31989 <at> debbugs.gnu.org; Thu, 28 Jun 2018 00:56:20 -0400
Received: by conspiracy.of.n0.is (OpenSMTPD) with ESMTPSA id 36e983eb
 (TLSv1.2:ECDHE-RSA-AES256-GCM-SHA384:256:NO); 
 Thu, 28 Jun 2018 04:56:13 +0000 (UTC)
Date: Thu, 28 Jun 2018 04:56:53 +0000
From: Nils Gillmann <ng0@HIDDEN>
To: Efraim Flashner <efraim@HIDDEN>
Subject: Re: [bug#31989] vim-build-system
Message-ID: <20180628045653.kai2zkfi7caevgkw@abyayala>
References: <20180627200454.GC1537@macbook41>
MIME-Version: 1.0
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
Content-Transfer-Encoding: 8bit
In-Reply-To: <20180627200454.GC1537@macbook41>
X-Spam-Score: -0.0 (/)
X-Debbugs-Envelope-To: 31989
Cc: 31989 <at> debbugs.gnu.org
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -1.0 (-)

Efraim Flashner transcribed 16K bytes:
> This patch got forgotten about a year ago
> 
> -- 
> Efraim Flashner   <efraim@HIDDEN>   אפרים פלשנר
> GPG key = A28B F40C 3E55 1372 662D  14F7 41AA E7DC CA3D 8351
> Confidentiality cannot be guaranteed on emails sent or received unencrypted

> Date: Sun, 2 Jul 2017 19:56:07 +0000
> From: ng0 <ng0@HIDDEN>
> To: Efraim Flashner <efraim@HIDDEN>, guix-devel@HIDDEN
> Subject: Re: PATCH in need for discussion: vim-build-system
> 
> ng0 transcribed 1.3K bytes:
> > I found the mistake, a simple typo. Updated patch coming soon.
> 
> That would've been too easy, but there was a typo.

hm... right, July 2017. Time flies.
I think I'll look at the differences and fix it.

So here's something with regards to the 'test' phase:
it seems like the few packages using tests, use a Makefile.
When it is a rare exception, does it still count as part
of the system? We would run gnu's make there.

> -- 
> ng0
> GnuPG: A88C8ADD129828D7EAC02E52E22F9BBFEE348588
> GnuPG: https://n0is.noblogs.org/my-keys
> https://www.infotropique.org https://krosos.org

> From 1596e2ca4b9d237359287e35a65acdfd99a48879 Mon Sep 17 00:00:00 2001
> From: ng0 <ng0@HIDDEN>
> Date: Sun, 2 Jul 2017 16:07:48 +0000
> Subject: [PATCH 1/2] build-system: Add 'vim-build-system'.
> 
> * Makefile.am (MODULES): Add 'guix/build-system/vim.scm' and
> 'guix/build/vim-build-system.scm'.
> * guix/build-system/vim.scm: New file.
> * guix/build/vim-build-system.scm: New file.
> ---
>  Makefile.am                     |   2 +
>  guix/build-system/vim.scm       | 127 ++++++++++++++++++++++++++++++++++++++++
>  guix/build/vim-build-system.scm |  70 ++++++++++++++++++++++
>  3 files changed, 199 insertions(+)
>  create mode 100644 guix/build-system/vim.scm
>  create mode 100644 guix/build/vim-build-system.scm
> 
> diff --git a/Makefile.am b/Makefile.am
> index f6059d94b..cb36bd849 100644
> --- a/Makefile.am
> +++ b/Makefile.am
> @@ -85,6 +85,7 @@ MODULES =					\
>    guix/build-system/perl.scm			\
>    guix/build-system/python.scm			\
>    guix/build-system/ocaml.scm			\
> +  guix/build-system/vim.scm                     \
>    guix/build-system/waf.scm			\
>    guix/build-system/r.scm			\
>    guix/build-system/ruby.scm			\
> @@ -106,6 +107,7 @@ MODULES =					\
>    guix/build/emacs-build-system.scm		\
>    guix/build/font-build-system.scm		\
>    guix/build/asdf-build-system.scm		\
> +  guix/build/vim-build-system.scm               \
>    guix/build/git.scm				\
>    guix/build/hg.scm				\
>    guix/build/glib-or-gtk-build-system.scm	\
> diff --git a/guix/build-system/vim.scm b/guix/build-system/vim.scm
> new file mode 100644
> index 000000000..b3f9831c0
> --- /dev/null
> +++ b/guix/build-system/vim.scm
> @@ -0,0 +1,127 @@
> +;;; GNU Guix --- Functional package management for GNU
> +;;; Copyright © 2017 ng0 <ng0@HIDDEN>
> +;;;
> +;;; 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 <http://www.gnu.org/licenses/>.
> +
> +(define-module (guix build-system vim)
> +  #:use-module (guix utils)
> +  #:use-module (guix packages)
> +  #:use-module (guix derivations)
> +  #:use-module (guix search-paths)
> +  #:use-module (guix build-system gnu)
> +  #:use-module (ice-9 match)
> +  #:export (%vim-build-system-modules
> +            vim-build
> +            vim-build-system))
> +
> +;; Commentary:
> +;;
> +;; Standard build procedure for vim packages.  This is
> +;; implemented as an extension of 'gnu-build-system'.
> +;;
> +;; Code:
> +
> +(define %vim-build-system-modules
> +  ;; Build-side modules imported by default.
> +  `((guix build vim-build-system)
> +    ,@%gnu-build-system-modules))
> +
> +(define* (lower name
> +                #:key source inputs native-inputs outputs system target
> +                #:allow-other-keys
> +                #:rest arguments)
> +  "Return a bag for NAME."
> +  (define private-keywords
> +    '(#:target #:inputs #:native-inputs))
> +
> +  (bag
> +    (name name)
> +    (system system)
> +    (host-inputs `(,@(if source
> +                         `(("source" ,source))
> +                         '())
> +                   ,@inputs
> +                   ,(list "tar" (module-ref (resolve-interface '(gnu packages base)) 'tar))
> +                   ,@(let ((compression (resolve-interface '(gnu packages compression))))
> +                       (map (match-lambda
> +                              ((name package)
> +                               (list name (module-ref compression package))))
> +                            `(("gzip" gzip)
> +                              ("bzip2" bzip2)
> +                              ("unzip" unzip)
> +                              ("xz" xz))))))
> +    (build-inputs native-inputs)
> +    (outputs outputs)
> +    (build vim-build)
> +    (arguments (strip-keyword-arguments private-keywords arguments))))
> +
> +(define* (vim-build store name inputs
> +                     #:key source
> +                     (tests? #t)
> +                     (test-target "test")
> +                     (configure-flags ''())
> +                     (phases '(@ (guix build vim-build-system)
> +                                 %standard-phases))
> +                     (outputs '("out"))
> +                     (search-paths '())
> +                     (system (%current-system))
> +                     (guile #f)
> +                     (imported-modules %vim-build-system-modules)
> +                     (modules '((guix build vim-build-system)
> +                                (guix build utils))))
> +  "Build SOURCE with INPUTS."
> +  (define builder
> +    `(begin
> +       (use-modules ,@modules)
> +       (vim-build #:name ,name
> +                   #:source ,(match (assoc-ref inputs "source")
> +                               (((? derivation? source))
> +                                (derivation->output-path source))
> +                               ((source)
> +                                source)
> +                               (source
> +                                source))
> +                   #:configure-flags ,configure-flags
> +                   #:system ,system
> +                   #:test-target ,test-target
> +                   #:tests? ,tests?
> +                   #:phases ,phases
> +                   #:outputs %outputs
> +                   #:search-paths ',(map search-path-specification->sexp
> +                                         search-paths)
> +                   #:inputs %build-inputs)))
> +
> +  (define guile-for-build
> +    (match guile
> +      ((? package?)
> +       (package-derivation store guile system #:graft? #f))
> +      (#f                                         ; the default
> +       (let* ((distro (resolve-interface '(gnu packages commencement)))
> +              (guile  (module-ref distro 'guile-final)))
> +         (package-derivation store guile system #:graft? #f)))))
> +
> +  (build-expression->derivation store name builder
> +                                #:inputs inputs
> +                                #:system system
> +                                #:modules imported-modules
> +                                #:outputs outputs
> +                                #:guile-for-build guile-for-build))
> +
> +(define vim-build-system
> +  (build-system
> +    (name 'vim)
> +    (description "The build system for vim packages")
> +    (lower lower)))
> diff --git a/guix/build/vim-build-system.scm b/guix/build/vim-build-system.scm
> new file mode 100644
> index 000000000..ca863cef8
> --- /dev/null
> +++ b/guix/build/vim-build-system.scm
> @@ -0,0 +1,70 @@
> +;;; GNU Guix --- Functional package management for GNU
> +;;; Copyright © 2017 ng0 <ng0@HIDDEN>
> +;;;
> +;;; 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 <http://www.gnu.org/licenses/>.
> +
> +(define-module (guix build vim-build-system)
> +  #:use-module ((guix build gnu-build-system) #:prefix gnu:)
> +  #:use-module (guix build utils)
> +  #:use-module (srfi srfi-1)
> +  #:use-module (srfi srfi-26)
> +  #:export (%standard-phases
> +            vim-build))
> +
> +;; Commentary:
> +;;
> +;; Builder-side code of the build procedure for vim packages.
> +;;
> +;; Code:
> +
> +(define gnu:unpack (assoc-ref gnu:%standard-phases 'unpack))
> +
> +(define* (unpack #:key source #:allow-other-keys)
> +  "Unpack SOURCE into the build directory.  SOURCE may be a compressed
> +archive, a directory or a '.vim' file."
> +  (if (any (cut string-suffix? <> source)
> +           (list ".vim" ".vital"))
> +      (begin
> +        (mkdir "source")
> +        (chdir "source")
> +        (copy-file source (strip-store-file-name source))
> +        #t)
> +      (gnu:unpack #:source source)))
> +
> +(define* (install #:key outputs #:allow-other-keys)
> +  "Install the package contents."
> +  (let* ((out (assoc-ref outputs "out"))
> +         (source (getcwd))
> +         (vimfiles (string-append out "/share/vim/vimfiles")))
> +    (lambda (dir)
> +      (when (file-exists? dir)
> +        (copy-recursively dir (string-append vimfiles "/" dir))))
> +    (list "autoload" "after" "doc" "ftdetect" "ftplugin"
> +          "indent" "plugin" "rplugin" "syntax")
> +    #t))
> +
> +(define %standard-phases
> +  (modify-phases gnu:%standard-phases
> +    (replace 'unpack unpack)
> +    (delete 'configure)
> +    (delete 'check)
> +    (delete 'build)
> +    (replace 'install install)))
> +
> +(define* (vim-build #:key inputs (phases %standard-phases)
> +                      #:allow-other-keys #:rest args)
> +  "Build the given vim package, applying all of PHASES in order."
> +  (apply gnu:gnu-build #:inputs inputs #:phases phases args))
> -- 
> 2.13.2
> 

> From bb8cf78af6569d2fc9beb1d766d6d748c488e012 Mon Sep 17 00:00:00 2001
> From: ng0 <ng0@HIDDEN>
> Date: Sun, 2 Jul 2017 16:11:19 +0000
> Subject: [PATCH 2/2] gnu: vim-neocomplete: Use 'vim-build-system'.
> 
> * gnu/packages/vim.scm (vim-neocomplete): Switch to 'vim-build-system'.
> ---
>  gnu/packages/vim.scm | 22 +++-------------------
>  1 file changed, 3 insertions(+), 19 deletions(-)
> 
> diff --git a/gnu/packages/vim.scm b/gnu/packages/vim.scm
> index 27c0b0da9..5672fab69 100644
> --- a/gnu/packages/vim.scm
> +++ b/gnu/packages/vim.scm
> @@ -1,7 +1,7 @@
>  ;;; GNU Guix --- Functional package management for GNU
>  ;;; Copyright © 2013 Cyril Roelandt <tipecaml@HIDDEN>
>  ;;; Copyright © 2016 Efraim Flashner <efraim@HIDDEN>
> -;;; Copyright © 2016, 2017 ng0 <ng0@HIDDEN>
> +;;; Copyright © 2016, 2017 ng0 <ng0@HIDDEN>
>  ;;; Copyright © 2017 Ricardo Wurmus <rekado@HIDDEN>
>  ;;; Copyright © 2017 Marius Bakke <mbakke@HIDDEN>
>  ;;;
> @@ -28,6 +28,7 @@
>    #:use-module (guix git-download)
>    #:use-module (guix build-system cmake)
>    #:use-module (guix build-system gnu)
> +  #:use-module (guix build-system vim)
>    #:use-module (gnu packages)
>    #:use-module (gnu packages acl)
>    #:use-module (gnu packages admin) ; For GNU hostname
> @@ -195,24 +196,7 @@ configuration files.")
>         (sha256
>          (base32
>           "1307gbrdwam2akq9w2lpijc41740i4layk2qkd9sjkqxfch5lni2"))))
> -    (build-system gnu-build-system)
> -    (arguments
> -     `(#:tests? #f
> -       #:phases
> -       (modify-phases %standard-phases
> -         (delete 'configure)
> -         (delete 'build)
> -         (replace 'install
> -           (lambda* (#:key outputs #:allow-other-keys)
> -             (let* ((out (assoc-ref outputs "out"))
> -                    (vimfiles (string-append out "/share/vim/vimfiles"))
> -                    (autoload (string-append vimfiles "/autoload"))
> -                    (doc (string-append vimfiles "/doc"))
> -                    (plugin (string-append vimfiles "/plugin")))
> -               (copy-recursively "autoload" autoload)
> -               (copy-recursively "doc" doc)
> -               (copy-recursively "plugin" plugin)
> -               #t))))))
> +    (build-system vim-build-system)
>      (synopsis "Next generation completion framework for Vim")
>      (description
>       "@code{neocomplete}, an abbreviation of 'neo-completion with cache',
> -- 
> 2.13.2
> 










Information forwarded to guix-patches@HIDDEN:
bug#31989; Package guix-patches. Full text available.

Message received at submit <at> debbugs.gnu.org:


Received: (at submit) by debbugs.gnu.org; 27 Jun 2018 20:05:33 +0000
From debbugs-submit-bounces <at> debbugs.gnu.org Wed Jun 27 16:05:33 2018
Received: from localhost ([127.0.0.1]:37884 helo=debbugs.gnu.org)
	by debbugs.gnu.org with esmtp (Exim 4.84_2)
	(envelope-from <debbugs-submit-bounces <at> debbugs.gnu.org>)
	id 1fYGgv-00088w-Sk
	for submit <at> debbugs.gnu.org; Wed, 27 Jun 2018 16:05:33 -0400
Received: from eggs.gnu.org ([208.118.235.92]:34039)
 by debbugs.gnu.org with esmtp (Exim 4.84_2)
 (envelope-from <efraim@HIDDEN>) id 1fYGgl-00088Z-RV
 for submit <at> debbugs.gnu.org; Wed, 27 Jun 2018 16:05:21 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
 (envelope-from <efraim@HIDDEN>) id 1fYGgZ-0007T5-UI
 for submit <at> debbugs.gnu.org; Wed, 27 Jun 2018 16:05:10 -0400
X-Spam-Checker-Version: SpamAssassin 3.3.2 (2011-06-06) on eggs.gnu.org
X-Spam-Level: **
X-Spam-Status: No, score=2.3 required=5.0 tests=BAYES_50,RCVD_IN_SORBS_WEB
 autolearn=disabled version=3.3.2
Received: from lists.gnu.org ([2001:4830:134:3::11]:41554)
 by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_256_CBC_SHA1:32)
 (Exim 4.71) (envelope-from <efraim@HIDDEN>)
 id 1fYGgZ-0007Sp-MU
 for submit <at> debbugs.gnu.org; Wed, 27 Jun 2018 16:05:03 -0400
Received: from eggs.gnu.org ([2001:4830:134:3::10]:53128)
 by lists.gnu.org with esmtp (Exim 4.71)
 (envelope-from <efraim@HIDDEN>) id 1fYGgX-0001dQ-Dl
 for guix-patches@HIDDEN; Wed, 27 Jun 2018 16:05:03 -0400
Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71)
 (envelope-from <efraim@HIDDEN>) id 1fYGgU-0007Js-2x
 for guix-patches@HIDDEN; Wed, 27 Jun 2018 16:05:01 -0400
Received: from flashner.co.il ([178.62.234.194]:50418)
 by eggs.gnu.org with esmtp (Exim 4.71)
 (envelope-from <efraim@HIDDEN>) id 1fYGgT-0007G5-GT
 for guix-patches@HIDDEN; Wed, 27 Jun 2018 16:04:58 -0400
Received: from localhost (unknown [31.210.182.47])
 by flashner.co.il (Postfix) with ESMTPSA id BF16C400D7
 for <guix-patches@HIDDEN>; Wed, 27 Jun 2018 20:04:55 +0000 (UTC)
Date: Wed, 27 Jun 2018 23:04:54 +0300
From: Efraim Flashner <efraim@HIDDEN>
To: guix-patches@HIDDEN
Subject: vim-build-system
Message-ID: <20180627200454.GC1537@macbook41>
MIME-Version: 1.0
Content-Type: multipart/signed; micalg=pgp-sha512;
 protocol="application/pgp-signature"; boundary="SO98HVl1bnMOfKZd"
Content-Disposition: inline
User-Agent: Mutt/1.10.0 (2018-05-17)
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic]
 [fuzzy]
X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6.x
X-Received-From: 2001:4830:134:3::11
X-Spam-Score: 2.5 (++)
X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.org",
 has NOT identified this incoming email as spam.  The original
 message has been attached to this so you can view it or label
 similar future email.  If you have any questions, see
 the administrator of that system for details.
 
 Content preview:  This patch got forgotten about a year ago -- Efraim Flashner
    <efraim@HIDDEN> אפרים פלש ר GPG key = A28B F40C 3E55 1372
    662D 14F7 41AA E7DC CA3D 8351 Confidentiality cannot be guaranteed on emails
    sent or received unencrypted [...] 
 
 Content analysis details:   (2.5 points, 10.0 required)
 
  pts rule name              description
 ---- ---------------------- --------------------------------------------------
  1.5 RCVD_IN_SORBS_WEB      RBL: SORBS: sender is an abusable web server
                             [31.210.182.47 listed in dnsbl.sorbs.net]
 -0.0 RCVD_IN_MSPIKE_H3      RBL: Good reputation (+3)
                             [208.118.235.92 listed in wl.mailspike.net]
  1.0 SPF_SOFTFAIL           SPF: sender does not match SPF record (softfail)
 -0.0 RCVD_IN_MSPIKE_WL      Mailspike good senders
X-Debbugs-Envelope-To: submit
X-BeenThere: debbugs-submit <at> debbugs.gnu.org
X-Mailman-Version: 2.1.18
Precedence: list
List-Id: <debbugs-submit.debbugs.gnu.org>
List-Unsubscribe: <https://debbugs.gnu.org/cgi-bin/mailman/options/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=unsubscribe>
List-Archive: <https://debbugs.gnu.org/cgi-bin/mailman/private/debbugs-submit/>
List-Post: <mailto:debbugs-submit <at> debbugs.gnu.org>
List-Help: <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=help>
List-Subscribe: <https://debbugs.gnu.org/cgi-bin/mailman/listinfo/debbugs-submit>, 
 <mailto:debbugs-submit-request <at> debbugs.gnu.org?subject=subscribe>
Errors-To: debbugs-submit-bounces <at> debbugs.gnu.org
Sender: "Debbugs-submit" <debbugs-submit-bounces <at> debbugs.gnu.org>
X-Spam-Score: -0.0 (/)


--SO98HVl1bnMOfKZd
Content-Type: multipart/mixed; boundary="yLVHuoLXiP9kZBkt"
Content-Disposition: inline


--yLVHuoLXiP9kZBkt
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

This patch got forgotten about a year ago

--=20
Efraim Flashner   <efraim@HIDDEN>   =D7=90=D7=A4=D7=A8=D7=99=D7=9D =
=D7=A4=D7=9C=D7=A9=D7=A0=D7=A8
GPG key =3D A28B F40C 3E55 1372 662D  14F7 41AA E7DC CA3D 8351
Confidentiality cannot be guaranteed on emails sent or received unencrypted

--yLVHuoLXiP9kZBkt
Content-Type: message/rfc822
Content-Disposition: inline

Return-Path: <ng0@HIDDEN>
Delivered-To: efraim@HIDDEN
Received: from flashner.co.il
	by do1 (Dovecot) with LMTP id +gZVK+BPWVlLAgAAymwEiA
	for <efraim@HIDDEN>; Sun, 02 Jul 2017 19:56:16 +0000
Received: from aibo.runbox.com (aibo.runbox.com [91.220.196.211])
	by flashner.co.il (Postfix) with ESMTPS id 95DD540231
	for <efraim@HIDDEN>; Sun,  2 Jul 2017 19:56:16 +0000 (UTC)
Received: from [10.9.9.211] (helo=mailfront11.runbox.com)
	by mailtransmit02.runbox with esmtp (Exim 4.86_2)
	(envelope-from <ng0@HIDDEN>)
	id 1dRkyd-0008QD-R5; Sun, 02 Jul 2017 21:56:15 +0200
Received: from tor-relay.zwiebeltoralf.de ([5.9.158.75] helo=localhost)
	by mailfront11.runbox.com with esmtpsa  (uid:892961 )  (TLS1.2:RSA_AES_256_CBC_SHA1:256)
	(Exim 4.82)
	id 1dRkyX-00057Z-40; Sun, 02 Jul 2017 21:56:09 +0200
Date: Sun, 2 Jul 2017 19:56:07 +0000
From: ng0 <ng0@HIDDEN>
To: Efraim Flashner <efraim@HIDDEN>, guix-devel@HIDDEN
Subject: Re: PATCH in need for discussion: vim-build-system
Message-ID: <20170702195607.jmt4v6sfpqhckfga@abyayala>
Mail-Followup-To: Efraim Flashner <efraim@HIDDEN>,
	guix-devel@HIDDEN
References: <20170702161926.yuvhmb52rqyymnmj@abyayala>
 <20170702190337.GC2938@HIDDEN>
 <20170702194422.hleuwl5zy6a6h37w@abyayala>
MIME-Version: 1.0
Content-Type: multipart/signed; micalg=pgp-sha512;
	protocol="application/pgp-signature"; boundary="sqarxox42mqzc5i6"
Content-Disposition: inline
In-Reply-To: <20170702194422.hleuwl5zy6a6h37w@abyayala>


--sqarxox42mqzc5i6
Content-Type: multipart/mixed; boundary="ks24m2q6dqwgbw6v"
Content-Disposition: inline


--ks24m2q6dqwgbw6v
Content-Type: text/plain; charset=utf-8
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

ng0 transcribed 1.3K bytes:
> I found the mistake, a simple typo. Updated patch coming soon.

That would've been too easy, but there was a typo.
--=20
ng0
GnuPG: A88C8ADD129828D7EAC02E52E22F9BBFEE348588
GnuPG: https://n0is.noblogs.org/my-keys
https://www.infotropique.org https://krosos.org

--ks24m2q6dqwgbw6v
Content-Type: text/plain; charset=utf-8
Content-Disposition: attachment; filename="0001-build-system-Add-vim-build-system.patch"
Content-Transfer-Encoding: quoted-printable

=46rom 1596e2ca4b9d237359287e35a65acdfd99a48879 Mon Sep 17 00:00:00 2001
=46rom: ng0 <ng0@HIDDEN>
Date: Sun, 2 Jul 2017 16:07:48 +0000
Subject: [PATCH 1/2] build-system: Add 'vim-build-system'.

* Makefile.am (MODULES): Add 'guix/build-system/vim.scm' and
'guix/build/vim-build-system.scm'.
* guix/build-system/vim.scm: New file.
* guix/build/vim-build-system.scm: New file.
---
 Makefile.am                     |   2 +
 guix/build-system/vim.scm       | 127 ++++++++++++++++++++++++++++++++++++=
++++
 guix/build/vim-build-system.scm |  70 ++++++++++++++++++++++
 3 files changed, 199 insertions(+)
 create mode 100644 guix/build-system/vim.scm
 create mode 100644 guix/build/vim-build-system.scm

diff --git a/Makefile.am b/Makefile.am
index f6059d94b..cb36bd849 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -85,6 +85,7 @@ MODULES =3D					\
   guix/build-system/perl.scm			\
   guix/build-system/python.scm			\
   guix/build-system/ocaml.scm			\
+  guix/build-system/vim.scm                     \
   guix/build-system/waf.scm			\
   guix/build-system/r.scm			\
   guix/build-system/ruby.scm			\
@@ -106,6 +107,7 @@ MODULES =3D					\
   guix/build/emacs-build-system.scm		\
   guix/build/font-build-system.scm		\
   guix/build/asdf-build-system.scm		\
+  guix/build/vim-build-system.scm               \
   guix/build/git.scm				\
   guix/build/hg.scm				\
   guix/build/glib-or-gtk-build-system.scm	\
diff --git a/guix/build-system/vim.scm b/guix/build-system/vim.scm
new file mode 100644
index 000000000..b3f9831c0
--- /dev/null
+++ b/guix/build-system/vim.scm
@@ -0,0 +1,127 @@
+;;; GNU Guix --- Functional package management for GNU
+;;; Copyright =C2=A9 2017 ng0 <ng0@HIDDEN>
+;;;
+;;; 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 <http://www.gnu.org/licenses/>.
+
+(define-module (guix build-system vim)
+  #:use-module (guix utils)
+  #:use-module (guix packages)
+  #:use-module (guix derivations)
+  #:use-module (guix search-paths)
+  #:use-module (guix build-system gnu)
+  #:use-module (ice-9 match)
+  #:export (%vim-build-system-modules
+            vim-build
+            vim-build-system))
+
+;; Commentary:
+;;
+;; Standard build procedure for vim packages.  This is
+;; implemented as an extension of 'gnu-build-system'.
+;;
+;; Code:
+
+(define %vim-build-system-modules
+  ;; Build-side modules imported by default.
+  `((guix build vim-build-system)
+    ,@%gnu-build-system-modules))
+
+(define* (lower name
+                #:key source inputs native-inputs outputs system target
+                #:allow-other-keys
+                #:rest arguments)
+  "Return a bag for NAME."
+  (define private-keywords
+    '(#:target #:inputs #:native-inputs))
+
+  (bag
+    (name name)
+    (system system)
+    (host-inputs `(,@(if source
+                         `(("source" ,source))
+                         '())
+                   ,@inputs
+                   ,(list "tar" (module-ref (resolve-interface '(gnu packa=
ges base)) 'tar))
+                   ,@(let ((compression (resolve-interface '(gnu packages =
compression))))
+                       (map (match-lambda
+                              ((name package)
+                               (list name (module-ref compression package)=
)))
+                            `(("gzip" gzip)
+                              ("bzip2" bzip2)
+                              ("unzip" unzip)
+                              ("xz" xz))))))
+    (build-inputs native-inputs)
+    (outputs outputs)
+    (build vim-build)
+    (arguments (strip-keyword-arguments private-keywords arguments))))
+
+(define* (vim-build store name inputs
+                     #:key source
+                     (tests? #t)
+                     (test-target "test")
+                     (configure-flags ''())
+                     (phases '(@ (guix build vim-build-system)
+                                 %standard-phases))
+                     (outputs '("out"))
+                     (search-paths '())
+                     (system (%current-system))
+                     (guile #f)
+                     (imported-modules %vim-build-system-modules)
+                     (modules '((guix build vim-build-system)
+                                (guix build utils))))
+  "Build SOURCE with INPUTS."
+  (define builder
+    `(begin
+       (use-modules ,@modules)
+       (vim-build #:name ,name
+                   #:source ,(match (assoc-ref inputs "source")
+                               (((? derivation? source))
+                                (derivation->output-path source))
+                               ((source)
+                                source)
+                               (source
+                                source))
+                   #:configure-flags ,configure-flags
+                   #:system ,system
+                   #:test-target ,test-target
+                   #:tests? ,tests?
+                   #:phases ,phases
+                   #:outputs %outputs
+                   #:search-paths ',(map search-path-specification->sexp
+                                         search-paths)
+                   #:inputs %build-inputs)))
+
+  (define guile-for-build
+    (match guile
+      ((? package?)
+       (package-derivation store guile system #:graft? #f))
+      (#f                                         ; the default
+       (let* ((distro (resolve-interface '(gnu packages commencement)))
+              (guile  (module-ref distro 'guile-final)))
+         (package-derivation store guile system #:graft? #f)))))
+
+  (build-expression->derivation store name builder
+                                #:inputs inputs
+                                #:system system
+                                #:modules imported-modules
+                                #:outputs outputs
+                                #:guile-for-build guile-for-build))
+
+(define vim-build-system
+  (build-system
+    (name 'vim)
+    (description "The build system for vim packages")
+    (lower lower)))
diff --git a/guix/build/vim-build-system.scm b/guix/build/vim-build-system.=
scm
new file mode 100644
index 000000000..ca863cef8
--- /dev/null
+++ b/guix/build/vim-build-system.scm
@@ -0,0 +1,70 @@
+;;; GNU Guix --- Functional package management for GNU
+;;; Copyright =C2=A9 2017 ng0 <ng0@HIDDEN>
+;;;
+;;; 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 <http://www.gnu.org/licenses/>.
+
+(define-module (guix build vim-build-system)
+  #:use-module ((guix build gnu-build-system) #:prefix gnu:)
+  #:use-module (guix build utils)
+  #:use-module (srfi srfi-1)
+  #:use-module (srfi srfi-26)
+  #:export (%standard-phases
+            vim-build))
+
+;; Commentary:
+;;
+;; Builder-side code of the build procedure for vim packages.
+;;
+;; Code:
+
+(define gnu:unpack (assoc-ref gnu:%standard-phases 'unpack))
+
+(define* (unpack #:key source #:allow-other-keys)
+  "Unpack SOURCE into the build directory.  SOURCE may be a compressed
+archive, a directory or a '.vim' file."
+  (if (any (cut string-suffix? <> source)
+           (list ".vim" ".vital"))
+      (begin
+        (mkdir "source")
+        (chdir "source")
+        (copy-file source (strip-store-file-name source))
+        #t)
+      (gnu:unpack #:source source)))
+
+(define* (install #:key outputs #:allow-other-keys)
+  "Install the package contents."
+  (let* ((out (assoc-ref outputs "out"))
+         (source (getcwd))
+         (vimfiles (string-append out "/share/vim/vimfiles")))
+    (lambda (dir)
+      (when (file-exists? dir)
+        (copy-recursively dir (string-append vimfiles "/" dir))))
+    (list "autoload" "after" "doc" "ftdetect" "ftplugin"
+          "indent" "plugin" "rplugin" "syntax")
+    #t))
+
+(define %standard-phases
+  (modify-phases gnu:%standard-phases
+    (replace 'unpack unpack)
+    (delete 'configure)
+    (delete 'check)
+    (delete 'build)
+    (replace 'install install)))
+
+(define* (vim-build #:key inputs (phases %standard-phases)
+                      #:allow-other-keys #:rest args)
+  "Build the given vim package, applying all of PHASES in order."
+  (apply gnu:gnu-build #:inputs inputs #:phases phases args))
--=20
2.13.2


--ks24m2q6dqwgbw6v
Content-Type: text/plain; charset=utf-8
Content-Disposition: attachment; filename="0002-gnu-vim-neocomplete-Use-vim-build-system.patch"
Content-Transfer-Encoding: quoted-printable

=46rom bb8cf78af6569d2fc9beb1d766d6d748c488e012 Mon Sep 17 00:00:00 2001
=46rom: ng0 <ng0@HIDDEN>
Date: Sun, 2 Jul 2017 16:11:19 +0000
Subject: [PATCH 2/2] gnu: vim-neocomplete: Use 'vim-build-system'.

* gnu/packages/vim.scm (vim-neocomplete): Switch to 'vim-build-system'.
---
 gnu/packages/vim.scm | 22 +++-------------------
 1 file changed, 3 insertions(+), 19 deletions(-)

diff --git a/gnu/packages/vim.scm b/gnu/packages/vim.scm
index 27c0b0da9..5672fab69 100644
--- a/gnu/packages/vim.scm
+++ b/gnu/packages/vim.scm
@@ -1,7 +1,7 @@
 ;;; GNU Guix --- Functional package management for GNU
 ;;; Copyright =C2=A9 2013 Cyril Roelandt <tipecaml@HIDDEN>
 ;;; Copyright =C2=A9 2016 Efraim Flashner <efraim@HIDDEN>
-;;; Copyright =C2=A9 2016, 2017 ng0 <ng0@HIDDEN>
+;;; Copyright =C2=A9 2016, 2017 ng0 <ng0@HIDDEN>
 ;;; Copyright =C2=A9 2017 Ricardo Wurmus <rekado@HIDDEN>
 ;;; Copyright =C2=A9 2017 Marius Bakke <mbakke@HIDDEN>
 ;;;
@@ -28,6 +28,7 @@
   #:use-module (guix git-download)
   #:use-module (guix build-system cmake)
   #:use-module (guix build-system gnu)
+  #:use-module (guix build-system vim)
   #:use-module (gnu packages)
   #:use-module (gnu packages acl)
   #:use-module (gnu packages admin) ; For GNU hostname
@@ -195,24 +196,7 @@ configuration files.")
        (sha256
         (base32
          "1307gbrdwam2akq9w2lpijc41740i4layk2qkd9sjkqxfch5lni2"))))
-    (build-system gnu-build-system)
-    (arguments
-     `(#:tests? #f
-       #:phases
-       (modify-phases %standard-phases
-         (delete 'configure)
-         (delete 'build)
-         (replace 'install
-           (lambda* (#:key outputs #:allow-other-keys)
-             (let* ((out (assoc-ref outputs "out"))
-                    (vimfiles (string-append out "/share/vim/vimfiles"))
-                    (autoload (string-append vimfiles "/autoload"))
-                    (doc (string-append vimfiles "/doc"))
-                    (plugin (string-append vimfiles "/plugin")))
-               (copy-recursively "autoload" autoload)
-               (copy-recursively "doc" doc)
-               (copy-recursively "plugin" plugin)
-               #t))))))
+    (build-system vim-build-system)
     (synopsis "Next generation completion framework for Vim")
     (description
      "@code{neocomplete}, an abbreviation of 'neo-completion with cache',
--=20
2.13.2


--ks24m2q6dqwgbw6v--

--sqarxox42mqzc5i6
Content-Type: application/pgp-signature; name="signature.asc"

-----BEGIN PGP SIGNATURE-----

iQIzBAABCgAdFiEEqIyK3RKYKNfqwC5S4i+bv+40hYgFAllZT9cACgkQ4i+bv+40
hYiwcA//ZFVgKS9BzJfuadIwVU60OH0xT6KR2J5Sw5hHDthSv3l407iIuByoXcJF
29MAT/o15lhQF3IZufPbAXqWG67JHscelh6eDKWdwnJPwcTztzw4OOLCsaSiYKvC
TexqNOS3de8c08Wtg3vYZZ5wmaRBhnh4Pyk2btoMOnpsWcOZx9Rae0jfEEELhozi
nrZiAW0DSdXKGorqXO3hSdNj6vS11tVlprDb/n8RPDDdETqWAp+cnZw7RKVbFN3b
SM16bUdvgQY/y9HbldDY1zGXr8Z8sJn4W7Q/4LqFbawBJnq+eMyHQ2sM3Mb9VgAz
84ZBsEpR4nn3jlJ7ufiafet3FwJT1AapDeZT/3HXmvi5Uze+LLRHaDeVCgFQiM9a
bxMRgarhuN3QtoXeeO2yZkqSTn/2Ja7UtuhV635p5KnY6Dq7deTd85uFxn6pAAr9
fwYlBtomwCPBk0vnd6QN2i28u3DmcJPlk7kPe5hCGzJ83WIyL6e4wRgtG4xgf9VI
p1ppuvrE1Sy3CTUz8T7a5cmD5w4qlwNSOI3/lyy1SAczSdWNcocQNQGByJLUnQWK
R8MBQbwJAeNsqiMBL/5/sYJWHVocjgAF2nk+r7e+gF1vxqRqpAzkAW47Hd0pU5O2
OTKNvvfIIlNi3YqJCq0t5d48GsGcl0xcLMZnK+qMYnpt1SRE0A8=
=o0eJ
-----END PGP SIGNATURE-----

--sqarxox42mqzc5i6--

--yLVHuoLXiP9kZBkt--

--SO98HVl1bnMOfKZd
Content-Type: application/pgp-signature; name="signature.asc"

-----BEGIN PGP SIGNATURE-----

iQIzBAABCgAdFiEEoov0DD5VE3JmLRT3Qarn3Mo9g1EFAlsz7eMACgkQQarn3Mo9
g1GN0BAAuyy74ZFgCcvsjkE4fRHJRk8I5hpuREpSf2zntP/9p4xsqZYErdSNjW3/
mEkNiJJIiRnIdvFvpzJNUc0KYBkXhOLVR/vsNRp/bW/FGYUexkK8ilO/eotwsPPY
F44qLJ+vDoQ5YUWic/C+q2GqZlSet7xfuReXvMkHHvX36cpAPHa4Tk21hHEJUQBU
9xSWOqaxmBnFYwtGskM3xndDOTPuH6rUmGx/o2mnEwWToltcuPljcS0SVhL7eiZu
nD0Ou8Yb0cQ9VWcqfRvbVFaSoRoM5kGJWiEh+ZTGOIIJpLo/sxJ5+TaWJgoZLn2n
M9DsOzNY5wrcsbNbXniuEOL9g/qWCK/+PPNyuO1mIjYphFNMKvK0nOr99UlK93wC
bsj55Y869jUJWsiyhV9sOjWZnBk61V6lcwv1QLTv8oEM3+NisoBoQRY1qaPW/7c5
Rp/Jk4vhsmFMQhPnPnBvONwpa0AEu4JyDDZFuSAJR3eiyN76nUTU67CaEd11O4vF
lVp03nKuTXOZ36rveYjktGFYPtx6pOOG2rZwDS7NUp4TTjpMn3j4b0i3zns1Zf/D
O6rcSH8NXfn+OeOpawGtU3GWkCVwuY7TSrEO+WsuJHLg7L0Lk5H/hKozco+8tGit
Dod0AUvSroG9qDsiKRQ5HoRdrBGpQOhX0wz7/V6uWz1sfwcJOiw=
=g9Mp
-----END PGP SIGNATURE-----

--SO98HVl1bnMOfKZd--




Acknowledgement sent to Efraim Flashner <efraim@HIDDEN>:
New bug report received and forwarded. Copy sent to guix-patches@HIDDEN. Full text available.
Report forwarded to guix-patches@HIDDEN:
bug#31989; Package guix-patches. Full text available.
Please note: This is a static page, with minimal formatting, updated once a day.
Click here to see this page with the latest information and nicer formatting.
Last modified: Mon, 2 Jul 2018 21:30:02 UTC

GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997 nCipher Corporation Ltd, 1994-97 Ian Jackson.