From: Andy Wingo <wingo@pobox.com>
To: Ian Hulin <ian@hulin.org.uk>
Cc: guile-user <guile-user@gnu.org>, Han-Wen Nienhuys <hanwenn@gmail.com>
Subject: Re: Generating compiled scm (.go) files as part of LilyPond build
Date: Sat, 29 Jan 2011 12:21:36 +0100 [thread overview]
Message-ID: <m3d3ng551b.fsf@unquote.localdomain> (raw)
In-Reply-To: <4D433723.50501@hulin.org.uk> (Ian Hulin's message of "Fri, 28 Jan 2011 21:37:39 +0000")
Hi Ian,
[re-adding the list; please keep the list CC'd on all guile-related
topics]
On Fri 28 Jan 2011 22:37, Ian Hulin <ian@hulin.org.uk> writes:
> Are you going to fix the double extension bug for defaulted/cached
> output names? I.e. compiling c++.scm will produce an output filename of
> c++.scm.go in the cache.
As far as I'm concerned this isn't a bug. It only happens for writes to
the fallback path. Appending an extension instead of replacing an
extension makes the algorithm more robust (e.g, doesn't confuse `foo'
and `foo.scm'.
>> Basically compiled-file-name doesn't do any path searches. It simply
>> computes a place in ~/.cache in which to cache the result of compiling
>> FILE.
>>
> Yuk! This means we will need to have custom routines in our code to work
> out and specify the output path we want.
There is not a DWIM answer, for various reasons -- but the combinatorics
between %load-path, %load-compiled-path, %load-extensions,
%load-compiled-extensions, and the actual `load' procedure should give
you an idea. The autocompilation strategy is as good as we can get
without you actually telling Guile where you want your files.
> It also means that autocompilation is a hindrance rather than a help,
> since it hi-jacks the compiled files into the cache.
What is the problem with writing to the cache? It is a cache. It's
doing it's job.
>> Load (system base compile) then, no?
>>
> OK, this is another V1.8/V2.0 conditional kludge we need to put in the
> LilyPond initialization code.
Compiling files is a 2.0 thing, of course...
>>> It looks like (compiled-file-name) uses a hard-coded default setting for
>>> %load-compiled-files to use as the root for cache.
>>
>> It doesn't use that path at all. It uses %compile-fallback-path.
>>
> Is this now documented?
No. Would you like to document it?
Things are not perfect as they are, but they get better by people
writing code and documentation. Contributions will help us get there.
Thanks,
Andy
--
http://wingolog.org/
next prev parent reply other threads:[~2011-01-29 11:21 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-11-27 17:42 Generating compiled scm (.go) files as part of LilyPond build Ian Hulin
2010-11-28 12:01 ` Neil Jerram
2010-11-30 18:02 ` Ian Hulin
2010-11-29 21:17 ` Andy Wingo
2010-12-01 21:21 ` Ian Hulin
2010-12-01 22:08 ` Andy Wingo
2010-12-30 11:43 ` Ian Hulin
2011-01-28 16:17 ` Andy Wingo
[not found] ` <4D433723.50501@hulin.org.uk>
2011-01-29 11:21 ` Andy Wingo [this message]
2011-07-19 13:18 ` Ian Hulin
2011-07-19 14:28 ` Andy Wingo
2011-07-19 23:08 ` Ian Hulin
2011-07-20 17:38 ` Andy Wingo
2011-07-21 12:43 ` Ludovic Courtès
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/guile/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=m3d3ng551b.fsf@unquote.localdomain \
--to=wingo@pobox.com \
--cc=guile-user@gnu.org \
--cc=hanwenn@gmail.com \
--cc=ian@hulin.org.uk \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).