From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Maxim Cournoyer Newsgroups: gmane.lisp.guile.bugs Subject: bug#32580: Setting variables %load-should-autocompile and GUILE_AUTO_COMPILE in ~/.guile doesn't prevent compiling Date: Sun, 14 Oct 2018 20:21:07 -0400 Message-ID: <8736t89i18.fsf@gmail.com> References: <1871411535582940@sas1-d856b3d759c7.qloud-c.yandex.net> <87in3rbabx.fsf@gmail.com> <7152691535724008@iva7-7c2970ec7645.qloud-c.yandex.net> <87zhx19h8c.fsf@gmail.com> <2474841539446639@myt2-cd7fa496c4f7.qloud-c.yandex.net> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Trace: blaine.gmane.org 1539562807 10847 195.159.176.226 (15 Oct 2018 00:20:07 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Mon, 15 Oct 2018 00:20:07 +0000 (UTC) User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/26.1 (gnu/linux) Cc: 32580@debbugs.gnu.org To: seamus phenetols Original-X-From: bug-guile-bounces+guile-bugs=m.gmane.org@gnu.org Mon Oct 15 02:20:03 2018 Return-path: Envelope-to: guile-bugs@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 1gBqc6-0002ie-Fi for guile-bugs@m.gmane.org; Mon, 15 Oct 2018 02:20:02 +0200 Original-Received: from localhost ([::1]:49894 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gBqeC-0006yQ-R5 for guile-bugs@m.gmane.org; Sun, 14 Oct 2018 20:22:12 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:39295) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1gBqe5-0006yL-Fo for bug-guile@gnu.org; Sun, 14 Oct 2018 20:22:06 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1gBqe2-00087u-BV for bug-guile@gnu.org; Sun, 14 Oct 2018 20:22:05 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:45414) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1gBqe2-00087o-5R for bug-guile@gnu.org; Sun, 14 Oct 2018 20:22:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1gBqe2-0007La-0O for bug-guile@gnu.org; Sun, 14 Oct 2018 20:22:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Maxim Cournoyer Original-Sender: "Debbugs-submit" Resent-CC: bug-guile@gnu.org Resent-Date: Mon, 15 Oct 2018 00:22:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 32580 X-GNU-PR-Package: guile X-GNU-PR-Keywords: Original-Received: via spool by 32580-submit@debbugs.gnu.org id=B32580.153956287828189 (code B ref 32580); Mon, 15 Oct 2018 00:22:01 +0000 Original-Received: (at 32580) by debbugs.gnu.org; 15 Oct 2018 00:21:18 +0000 Original-Received: from localhost ([127.0.0.1]:49671 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gBqdK-0007Ka-DY for submit@debbugs.gnu.org; Sun, 14 Oct 2018 20:21:18 -0400 Original-Received: from mail-it1-f174.google.com ([209.85.166.174]:37781) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1gBqdI-0007KN-6s for 32580@debbugs.gnu.org; Sun, 14 Oct 2018 20:21:16 -0400 Original-Received: by mail-it1-f174.google.com with SMTP id e74-v6so25314488ita.2 for <32580@debbugs.gnu.org>; Sun, 14 Oct 2018 17:21:16 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:references:date:in-reply-to:message-id :user-agent:mime-version; bh=m4rRKkAUbvm6SlibdXn1BUc46BS23vEk02UtMWKVoFI=; b=aYBZ0sxgPvG3Byh8WTRrUPargQM+d7kMFNy8+Nqm5Zl51rJ3e1gap+taUF9AZHDO8j a35hPITeetOyyHRw6RMzGuJGRrnHYVj8JnSZeHjcAg87NMEv4R/9cYP1bE1hw7TuIuSE cYMBruLJUtVfULyrpmIxmldyF6ePyd21n7Rlx/HyDPp7TsCQujBAiRC57+P5kQ6guxF4 vEaPZKiicD+Hj5AfCQ71aoX6f/z4O9uoRsRIRL8YFzmDbxV0ob7q9P55th57KYqXK8GB QUYguLsY/hOalh0lCaGor068ofzjUtLvzHyba0G1d2QRvKLZrPVoR09ZRZK5ZhPu4FUt PfyQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:references:date:in-reply-to :message-id:user-agent:mime-version; bh=m4rRKkAUbvm6SlibdXn1BUc46BS23vEk02UtMWKVoFI=; b=e3lHkcLazTOmbfjiPERYDJSvw+WekinJX2nXbzZVpaz2N9F6JWBa2w/V+DcCaOIqkf kdpNixzYtE7Zc8Z47rIdUW/fsEXQOdU+oMRwtcKaW7vXEJ/6ePaMdNQZsa0diJP42Lkz QwM0FxTgDI+fPCZktFrZHfckSz/5pyoNuZgjtMz3w2jmKqWgMLypZLYTFGDfM2w7dbN/ Thpo+Zag+t+xL2XxSWbfR+xVxYmkT2snXNTDBNn6NxUtnMa1mCM3YZiZqql7ke86lBDG 2FhTLf6x28f9e+tkcHuleKUj3IpDXfwd0t1Eo/a3kPUlhi+MlMCz/7vXvS0cArm9W7iD xOZQ== X-Gm-Message-State: ABuFfojlw6M8HqTADZM8+pVtDMqbISyhVTbhtdcBD1D64d7VFvANEsWc UqEnCQrc9FRX/4CUDianHnJah8x9 X-Google-Smtp-Source: ACcGV61s71ub+dlGvYhNj7pY71HZxN56o/vhZ5bF26H0ryhN4wEF86KxnIkLixsg6k24xdKV5DM1zw== X-Received: by 2002:a24:d647:: with SMTP id o68-v6mr11432715itg.56.1539562870128; Sun, 14 Oct 2018 17:21:10 -0700 (PDT) Original-Received: from apteryx (76-10-140-126.dsl.teksavvy.com. [76.10.140.126]) by smtp.gmail.com with ESMTPSA id e20-v6sm3464828ita.34.2018.10.14.17.21.08 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Sun, 14 Oct 2018 17:21:08 -0700 (PDT) In-Reply-To: <2474841539446639@myt2-cd7fa496c4f7.qloud-c.yandex.net> (seamus phenetols's message of "Sat, 13 Oct 2018 12:03:59 -0400") X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 208.118.235.43 X-BeenThere: bug-guile@gnu.org List-Id: "Bug reports for GUILE, GNU's Ubiquitous Extension Language" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-guile-bounces+guile-bugs=m.gmane.org@gnu.org Original-Sender: "bug-guile" Xref: news.gmane.org gmane.lisp.guile.bugs:9191 Archived-At: --=-=-= Content-Type: text/plain Hello Seamus, seamus phenetols writes: > Setting GUILE_AUTO_COMPILE in ~/.profile and in ~/.bash_profile > doesn't seem to have any effect. I'm giving up on guile for now. > Thank you very much for helping. I'm sorry it hasn't worked for you! Let's see if we can find out why. What exactly did you put in your ~/.profile or ~/.bash_profile? What version of Guile are you using? When launching a new pseudo terminal (i.e. xterm, gnome-terminal, etc.) and typing 'echo $GUILE_AUTO_COMPILE', does it return the expected value defined in your ~/.profile or ~/.bash_profile? Note that you would need to logout then login of your session for new variable definition to take effect; otherwise you can test it in your current shell by sourcing it: --8<---------------cut here---------------start------------->8--- source ~/.bash_profile # or source ~/.profile --8<---------------cut here---------------start------------->8--- I've put the following Scheme code in a file named 'test-auto-compile.scm' (attached for your convenience): --8<---------------cut here---------------start------------->8--- #!/usr/bin/env guile !# (define (main) "Print whether auto-compilation is enabled or not and exit with an exit status of 1 if it is enabled, 0 otherwise." (let ((guile-auto-compile-value (getenv "GUILE_AUTO_COMPILE"))) (display (format #f "The value of GUILE_AUTO_COMPILE is ~s\n" guile-auto-compile-value)) (when (and guile-auto-compile-value (string=? guile-auto-compile-value "0")) (display "Auto-compilation is disabled.\n") (exit 0)) (display "Auto-compilation is enabled.\n") (exit 1))) (main) --8<---------------cut here---------------start------------->8--- Here's a small demonstration of what the above script gives on my system (guile --version is 2.2.4, but this should work for any Guile version >= 2.0): --8<---------------cut here---------------start------------->8--- echo $GUILE_AUTO_COMPILE maxim@apteryx ~/Documents$ guile test-auto-compile.scm ;;; note: auto-compilation is enabled, set GUILE_AUTO_COMPILE=0 ;;; or pass the --no-auto-compile argument to disable. ;;; compiling /home/maxim/Documents/test-auto-compile.scm ;;; compiled /home/maxim/.cache/guile/ccache/2.2-LE-8-3.A/home/maxim/Documents/test-auto-compile.scm.go The value of GUILE_AUTO_COMPILE is #f Auto-compilation is enabled. maxim@apteryx ~/Documents$ maxim@apteryx ~/Documents$ rm /home/maxim/.cache/guile/ccache/2.2-LE-8-3.A/home/maxim/Documents/test-auto-compile.scm.go maxim@apteryx ~/Documents$ export GUILE_AUTO_COMPILE=0 maxim@apteryx ~/Documents$ guile test-auto-compile.scm The value of GUILE_AUTO_COMPILE is "0" Auto-compilation is disabled. --8<---------------cut here---------------end--------------->8--- I hope this helps, Maxim --=-=-= Content-Type: text/plain Content-Disposition: attachment; filename=test-auto-compile.scm Content-Description: Short program demonstrating GUILE_AUTO_COMPILE #!/usr/bin/env guile !# (define (main) "Print whether auto-compilation is enabled or not and exit with an exit status of 1 if it is enabled, 0 otherwise." (let ((guile-auto-compile-value (getenv "GUILE_AUTO_COMPILE"))) (display (format #f "The value of GUILE_AUTO_COMPILE is ~s\n" guile-auto-compile-value)) (when (and guile-auto-compile-value (string=? guile-auto-compile-value "0")) (display "Auto-compilation is disabled.\n") (exit 0)) (display "Auto-compilation is enabled.\n") (exit 1))) (main) --=-=-=--