From mboxrd@z Thu Jan 1 00:00:00 1970 From: Maxim Cournoyer Subject: bug#27222: [PATCH] emacs-build-system install phase doesn't honor directory hierarchy Date: Mon, 05 Jun 2017 07:54:38 -0700 Message-ID: <87r2yyo575.fsf@gmail.com> References: <87h8zwptdn.fsf@gmail.com> <874lvwp7km.fsf@gmail.com> <87wp8rq57k.fsf@gmail.com> <87vaobnhtn.fsf@gmail.com> <73a30871.AEQALMWm9gcAAAAAAAAAAAPHPfsAAAACwQwAAAAAAAW9WABZNSx9@mailjet.com> Mime-Version: 1.0 Content-Type: text/plain Return-path: Received: from eggs.gnu.org ([2001:4830:134:3::10]:48936) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1dHtPN-0005jF-Rs for bug-guix@gnu.org; Mon, 05 Jun 2017 10:55:07 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1dHtPK-0001lc-O1 for bug-guix@gnu.org; Mon, 05 Jun 2017 10:55:05 -0400 Received: from debbugs.gnu.org ([208.118.235.43]:55032) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1dHtPK-0001kc-IU for bug-guix@gnu.org; Mon, 05 Jun 2017 10:55:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1dHtPK-000153-59 for bug-guix@gnu.org; Mon, 05 Jun 2017 10:55:02 -0400 Sender: "Debbugs-submit" Resent-Message-ID: In-Reply-To: <73a30871.AEQALMWm9gcAAAAAAAAAAAPHPfsAAAACwQwAAAAAAAW9WABZNSx9@mailjet.com> (Arun Isaac's message of "Mon, 05 Jun 2017 15:33:28 +0530") List-Id: Bug reports for GNU Guix List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-guix-bounces+gcggb-bug-guix=m.gmane.org@gnu.org Sender: "bug-Guix" To: Arun Isaac Cc: Alex Kost , 27222@debbugs.gnu.org Hello Arun, Arun Isaac writes: >> this might have to do with the fact that until recently most Elisp >> projects were organized as a single file of thousands of lines of code >> ;). > > Exactly! :-) > >> I've also factorized out the default args of the include and exclude >> option of the emacs-build-system install phase. Please see the two >> patches attached. > > Thanks! Both patches LGTM. I just have a few doubts and minor comments. > Thanks for the prompt review! >> (define-module (guix build-system emacs) >> + #:use-module ((guix build emacs-build-system) >> + #:select (%default-include %default-exclude)) > > Interesting solution to the problem. I didn't think of this > earlier. Importing host side to build side would be a problem, but you > are importing build side to host side, and I think that's ok. > >> #:use-module (guix store) >> #:use-module (guix utils) >> #:use-module (guix packages) >> @@ -28,7 +30,10 @@ >> #:use-module (srfi srfi-26) >> #:export (%emacs-build-system-modules >> emacs-build >> - emacs-build-system)) >> + emacs-build-system) >> + #:re-export (%default-include ;for convenience >> + %default-exclude)) > > What is this re-export for? ert-runner seems to build fine without > this. I don't understand what you mean by "convenience" here. If you take another look at the second patch I sent, you'll see I build the include argument value of the emacs-build-sysltem by consing the new regexp in front of %default-include instead of building it from scratch. That's what these re-exports are for: they enable their use in gnu/packages/emacs.scm (and anywhere we've imported (guix build-system emacs). > Also, perhaps we should deduplicate default values of arguments in the > gnu-build-system as well. But, I don't know if it is worth deduplicating > simple default values like #t. WDYT? There's not much value in deduplicating simple things such as a boolean flag, but for more complicated ones it could be useful; although it would be very nice if instead of having to do this Scheme/Guile offered something for "querying" the defaults values of function. One could then go and extend the defaults rather than override them them in a similar way to what we can do with records. Maxim