Raymond Toy <raymond.toy at ericsson.com> writes:
> Aleksej Saushev wrote:
>> Raymond Toy <toy.raymond at gmail.com> writes:
>>>
>>> However, there is no guarantee that different systems will always have
>>> different filenames, so they'll overwrite each other. Also,
>>> *maxima-tempdir* defaults to the user's home directory, so fasls from
>>> maxima subsystems will clutter the users home directory.
>>>
>>
>> Maybe it is better to default to /tmp or ${TMPDIR}?
>>
> Do you mean *maxima-tempdir* should default to /tmp? I assume there's a
> good reason for making it the home directory. Perhaps to support windows?
>
> Or do you mean put fasls into /tmp/binary-<lisp>? I don't think that's
> a good idea. We still have the problem with non-unique names, and I
> certainly don't want to be loading up someone else's fasls.
>
> We could do /tmp/<user>/<stuff>, but I think I would want my fasls to
> survive a reboot.
No, I mean that _temp_-dir should be temporary (in accordance to POLA),
that is /tmp or like. User home directory should have another descriptive
name. (This is the problem with gnuplot interface, it spits its temporary
files into my ${HOME} instead of /tmp, thus entering backups &c. Not that
it is critical, but this is annoying.)
> (We do have an issue with gcl in that gcl doesn't have
> ensure-directories-exist, so mk:defsystem can't create the directories
> if they don't already exist. One possible workaround is to make
> ensure-directories-exist call mkdir -p to create the directories. This
> will probably work on all unix systems we have today, but I don't know
> how to do that on windows.)
Maybe someone interested should read documentation on command shell.
My knowledge is almost useless now, since it changed heavily in NT 5.
>>> I propose that systems should place fasls not in *maxima-tempdir* but in
>>> *maxima-userdir*, and they should be in some subdirectory, preferably
>>> based on the actual source pathname. Thus, affine would store it fasls
>>> in *maxima-userdir*/share/affine/binary-foo and minpack goes in
>>> *maxima-userdir*/share/minpack/binary-foo.
>>
>> This is called OBJDIR ("object directory") in BSDs. See make(1) at
>>
>> http://man.netbsd.org/cgi-bin/man-cgi?make++NetBSD-current
>> http://man.freebsd.org/cgi/man.cgi?sektion=0&query=make&manpath=FreeBSD+7.1-RELEASE&format=html
>>
>> Specifically, note the first rule for .OBJDIR
>>
> I suppose we could do that. I don't want to make it overly complicated.
That wasn't meant as instruction, it is information about "prior art."
I'm not sure about precise usage pattern for generated files, but if
they are meant completely intermediate without own value, quite like
object files, you may follow this way.
--
HE CE3OH...