From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Freja Nordsiek Newsgroups: gmane.lisp.guile.devel Subject: Re: [PATCH] Add to the 2.1.x branch GUILE_SITE_CCACHE_DIR and GUILE_EXTENSION_DIR Autoconf macros along with needed siteccachdir entry in pkgconfig file Date: Tue, 14 Mar 2017 16:31:17 +0100 Message-ID: References: <878to9s5s9.fsf@pobox.com> <87h92v7vw3.fsf@pobox.com> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary=001a1146370af047b2054ab284f2 X-Trace: blaine.gmane.org 1489505493 1795 195.159.176.226 (14 Mar 2017 15:31:33 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Tue, 14 Mar 2017 15:31:33 +0000 (UTC) Cc: guile-devel@gnu.org To: Andy Wingo Original-X-From: guile-devel-bounces+guile-devel=m.gmane.org@gnu.org Tue Mar 14 16:31:27 2017 Return-path: Envelope-to: guile-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cnoQ1-0008Ic-6v for guile-devel@m.gmane.org; Tue, 14 Mar 2017 16:31:25 +0100 Original-Received: from localhost ([::1]:60136 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cnoQ7-0007vz-Bb for guile-devel@m.gmane.org; Tue, 14 Mar 2017 11:31:31 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:43199) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cnoPx-0007vV-AK for guile-devel@gnu.org; Tue, 14 Mar 2017 11:31:22 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1cnoPv-0006xl-T5 for guile-devel@gnu.org; Tue, 14 Mar 2017 11:31:21 -0400 Original-Received: from mail-wr0-x22c.google.com ([2a00:1450:400c:c0c::22c]:34541) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1cnoPv-0006xT-JL for guile-devel@gnu.org; Tue, 14 Mar 2017 11:31:19 -0400 Original-Received: by mail-wr0-x22c.google.com with SMTP id l37so126631087wrc.1 for ; Tue, 14 Mar 2017 08:31:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=NM6C/ER9mO9agWABaU4eTuYrZVaek1ihs5UCZUg4lQM=; b=BL3VFPLVut1dxnTy9t1XWh45EB3HceiEvEgR4OcvLpf90clmm2O7vCwTRlmmRGBBHQ g8+Y5Kn70buULrnbtTT6od8WPmNUIOnwVOoXIvgg66P1Xx2ANYoFDkEnAiMW4n+EygQ+ ZHiXCG7AgOr2De0MMTmnY8egptz+0xOMNbJXjeVkXrBapHrVIEvbVcwUzlpxsdesJcd/ zdDseBsMjZ8YewZMetYIcbm/q1BwWSjQ8GVT/PThbGBofJOEXEg/xYn4B/AHGwbQomt/ FV+vFISHub55y0jhy8pL6MbgpfnEqLaRHjBkiCIHaPkKe3Y0qqNxAaULMkZQn9Vms87H MMdQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=NM6C/ER9mO9agWABaU4eTuYrZVaek1ihs5UCZUg4lQM=; b=f6poASP67s01SwETWYg1AJeeY98UIv+Box+3YjHW7RJfYEdX+6z5B6JTbo9ilNTlxw xpkmYKFcjvJiK6vOwht7XZOSS94f1CQL64fteCSyTbozbW+Y3LQs+jcSVqKjTyPA7ryg lomdun9HZ/DK/YOGG6y+yZ6lPgBOYzyAiMoPcMSm2NlJGyXpI2RaMwKnupWa5t1H2UK0 hvqiZvukcIGINj1SDvSIZqTnOnW1cxf89e4ZbWAMhrenSMIx5M5eD3TVLXlmtMOe8Wti lErLsuTU0mrB5ula3Ap1r9d3x4WbPPAy8iYs7w9cvv9Ctz+g7c2ZgqqGEkpjGbAdGyh0 P8UQ== X-Gm-Message-State: AMke39lkuXnQCxShfmgnRbo2xFTbCapu3pPXoQGoBGSwMaopsjreOUC/plMsdiSAReC2T9bbvP5v7Kx6a48PKQ== X-Received: by 10.223.150.123 with SMTP id c56mr32340903wra.202.1489505478503; Tue, 14 Mar 2017 08:31:18 -0700 (PDT) Original-Received: by 10.28.234.73 with HTTP; Tue, 14 Mar 2017 08:31:17 -0700 (PDT) In-Reply-To: <87h92v7vw3.fsf@pobox.com> X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 2a00:1450:400c:c0c::22c X-BeenThere: guile-devel@gnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: "Developers list for Guile, the GNU extensibility library" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guile-devel-bounces+guile-devel=m.gmane.org@gnu.org Original-Sender: "guile-devel" Xref: news.gmane.org gmane.lisp.guile.devel:19047 Archived-At: --001a1146370af047b2054ab284f2 Content-Type: text/plain; charset=UTF-8 I improved the commit log and the comments to make them better formatted and more terse. Does the commit log look better? I also made it so that pkgconfig is tried first for finding site-ccache and only if that fails will the interpreter be used (the messages say specifically which method they are using now). It is definitely better to have both methods in there. Freja Nordsiek On Tue, Mar 14, 2017 at 3:53 PM, Andy Wingo wrote: > Hi :) > > Great patch, some comments. > > On Tue 14 Mar 2017 15:08, Freja Nordsiek writes: > >> From 90daf796c829f8e422a281d501f711138f21a334 Mon Sep 17 00:00:00 2001 >> From: Freja Nordsiek >> Date: Tue, 14 Mar 2017 15:04:38 +0100 >> Subject: [PATCH] Made GUILE_SITE_DIR Autoconf macro look for directories for >> compiled .go and C extensions in addition to the site directory for scheme >> files. > > Please adapt the commit log. (Just look at any other commit to see what > the standard is.) You might also be interested in "info standards". > >> -## GUILE_SITE_DIR -- find path to Guile "site" directory >> +## GUILE_SITE_DIR -- find path to Guile "site" directories for scheme, compiles GO files, and compiled C extensions > > Line too long. Probably just s/directories.*/directories./. > >> -# GUILE_SITE_DIR -- find path to Guile "site" directory >> +# GUILE_SITE_DIR -- find path to Guile site directories > >> -# This looks for Guile's "site" directory, usually something like >> -# PREFIX/share/guile/site, and sets var @var{GUILE_SITE} to the path. >> -# Note that the var name is different from the macro name. >> +# This looks for Guile's "site" directory for Scheme files (usually something like >> +# PREFIX/share/guile/site), "site-ccache" directory for compiled @code{.go} files >> +# (usually something like PREFIX/lib/guile/@var{GUILE_EFFECTIVE_VERSION}/site-ccache), >> +# and "extensions" directory for compiled C extensions (usually something like >> +# PREFIX/lib/guile/@var{GUILE_EFFECTIVE_VERSION}/extensions). The variables >> +# @var{GUILE_SITE}, @var{GUILE_SITE_CCACHE}, and @var{GUILE_EXTENSION} are set to these >> +# paths respectively. The latter two are set to blank if they are not found. Note that >> +# this macro will run the macros @code{GUILE_PKG} and @code{GUILE_PROGS} if they have >> +# not already been run. > > Can we make the text more terse? E.g. 'This looks for Guile's "site" > directories. The variable @var{GUILE_SITE} will be set to Guile's > "site" directory for Scheme source files (usually [...]). > @var{GUILE_SITE_CCACHE} will be set to the directory for compiled Scheme > files (usually [...])' and so on. Two spaces before periods please in > comments in Guile code. > >> -# The variable is marked for substitution, as by @code{AC_SUBST}. >> +# The variables are marked for substitution, as by @code{AC_SUBST}. >> # >> AC_DEFUN([GUILE_SITE_DIR], >> [AC_REQUIRE([GUILE_PKG]) >> + AC_REQUIRE([GUILE_PROGS]) > > I guess this is OK given that anyone installing Scheme files should > install .go files, and you need GUILE_PROGS to build .go files. > >> + AC_MSG_CHECKING([for Guile site-ccache directory]) >> + GUILE_SITE_CCACHE=`$GUILE -c "(display (if (defined? '%site-ccache-dir) (%site-ccache-dir) \"\"))"` > > You prefer this rather than first trying pkg-config? I would try > pkg-config first; but it doesn't really matter I guess :) > > Otherwise looking fine. Thanks! > > Andy --001a1146370af047b2054ab284f2 Content-Type: text/x-patch; charset=US-ASCII; name="0001-GUILE_SITE_DIR-Find-site-directories-for-compiled-fi.patch" Content-Disposition: attachment; filename="0001-GUILE_SITE_DIR-Find-site-directories-for-compiled-fi.patch" Content-Transfer-Encoding: base64 X-Attachment-Id: f_j09p1lcf0 RnJvbSA0MTQ5ODU0OWFjMjJlYTUwZTQ5Nzg4N2IzYTFlMDAyOTg1YmI2ZjhmIE1vbiBTZXAgMTcg MDA6MDA6MDAgMjAwMQpGcm9tOiBGcmVqYSBOb3Jkc2llayA8Zm5vcmRzaWVAZ21haWwuY29tPgpE YXRlOiBUdWUsIDE0IE1hciAyMDE3IDE2OjI4OjQ1ICswMTAwClN1YmplY3Q6IFtQQVRDSF0gR1VJ TEVfU0lURV9ESVI6IEZpbmQgc2l0ZSBkaXJlY3RvcmllcyBmb3IgY29tcGlsZWQgZmlsZXMuCgot LS0KIG1ldGEvZ3VpbGUtMi4yLnBjLmluIHwgIDEgKwogbWV0YS9ndWlsZS5tNCAgICAgICAgfCA0 MiArKysrKysrKysrKysrKysrKysrKysrKysrKysrKysrKysrKystLS0tLS0KIDIgZmlsZXMgY2hh bmdlZCwgMzcgaW5zZXJ0aW9ucygrKSwgNiBkZWxldGlvbnMoLSkKCmRpZmYgLS1naXQgYS9tZXRh L2d1aWxlLTIuMi5wYy5pbiBiL21ldGEvZ3VpbGUtMi4yLnBjLmluCmluZGV4IGM4ZjQ4NWIuLmM2 ZDEyYjUgMTAwNjQ0Ci0tLSBhL21ldGEvZ3VpbGUtMi4yLnBjLmluCisrKyBiL21ldGEvZ3VpbGUt Mi4yLnBjLmluCkBAIC0xMCw2ICsxMCw3IEBAIHBrZ2luY2x1ZGVkaXI9QGluY2x1ZGVkaXJAL2d1 aWxlCiAKIHNpdGVkaXI9QHNpdGVkaXJACiBleHRlbnNpb25kaXI9QGxpYmRpckAvZ3VpbGUvQEdV SUxFX0VGRkVDVElWRV9WRVJTSU9OQC9leHRlbnNpb25zCitzaXRlY2NhY2h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