[Asdf-devel] Need to do uiop:setup-temporary-directory in image built with uiop

Dave Cooper david.cooper at genworks.com
Tue Jun 17 17:29:02 UTC 2014


I think my issue is that I am not using the UIOP image dump facility. This
is because in Allegro CL we use thei built-in excl functions like
excl:generate-application
--- it's not a matter of a generic dumplisp.

So I'm pretty sure the solution is to call the
register-image-restore-hook myself as part of e.g. the post-load-form of
e.g. excl:generate-application. Longer term, maybe I can look into
extending the UIOP image dump mechanism itself, to be able to use the
different mechanisms in Allegro in addition to the generic excl:dumplisp.

I will study the code and that the current documentation some more, and
assuming the current code is sufficient for these situations, I'll see what
I can do at least to contribute to the documentation to cover these kinds
of situations.


On Tuesday, June 17, 2014, Robert P. Goldman <rpgoldman at sift.info> wrote:

> Dave Cooper wrote:
> >
> > Dear ASDF maintainer(s),
> >
> > I just noticed that it is necessary to do
> >
> >   (uiop:setup-temporary-directory)
> >
> > in an image which has UIOP built into it, when that image is run on a
> > different machine or under a different user account (at least on
> > Windows). Otherwise, the function
> >
> >   (uiop:temporary-directory)
> >
> > returns whatever was the temporary directory as computed in the build
> > environment (in my case it's in the "dcooper8" home directory.
> >
> > So am I correct that it's pretty much a requirement to call
> >
> >   (uiop:setup-temporary-directory)
> >
> > upon startup of an image which contains uiop built into it?
> >
> > Are there any other functions which should be called to initialize uiop?
> >
> > Is there a way to achieve this at image dump time instead of startup
> > time (e.g. clearing the temporary directory entirely so it will be
> > forced to reset when next demanded in the built image)?
> >
> > If I'm missing something from the documentation on this please feel free
> > to slap me in that direction.
>
> I am looking at uiop/image.lisp and it looks like it should do what you
> want out of the box.  At the very bottom of the file I see a call to
> REGISTER-IMAGE-RESTORE-HOOK, and one of the elements of that list is
> setup-temporary-directory.
>
> So it seems like either this call is not happening properly or there's a
> bug in setup-temporary-directory.  Is there any chance you could have
> overwritten UIOP's restore hook?
>
> Would it be possible for you to trace RESTORE-IMAGE and
> SETUP-TEMPORARY-DIRECTORY to see what's happening? I confess to not
> knowing whether TRACE will persist over image dumping....
>
> Thanks,
> r
>
>

-- 
My Best,

Dave Cooper, Genworks Support
david.cooper at genworks.com, dave.genworks.com(skype)
USA: 248-327-3253(o), 1-248-330-2979(mobile)
UK: 0191 645 1699
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mailman.common-lisp.net/pipermail/asdf-devel/attachments/20140617/16cc6ca6/attachment.html>


More information about the asdf-devel mailing list