Subject: [clisp-list] environment dependencies

From: [email-masked] (Don Cohen)
Date: Tue Jan 7 09:27:08 2003

I think this is a serious issue.  The daemontools do provide a way
to control the environment.  What's still missing is a way to find
out what needs to be controlled, or, better yet, to eliminate these
dependencies.

Some initial ideas:
- There should be a global variable containing a list of strings,
which are the names of environment variables used by the distributed
code.
- The distributed code should record in another global variable
the set of values it has read (and is now using) for environment
variables.
- The distributed code should use that variable as a cache and avoid
reading the same variable from the environment twice.
- There should be a setf method for CHANGING the value being used
(or setting a value not yet used).

I hope the first one at least is relatively easy to provide.
That would at least allow me to build something that I'd expect
to work in another environment.
Does anyone know how to find out what environment a clisp version
uses?

---

From: Sam Steingold <[email-masked]>
Date: Tue Jan 7 12:13:07 2003

> * In message <[email-masked]>
> * On the subject of "environment dependencies"
> * Sent on Tue, 7 Jan 2003 09:29:18 -0800
> * Honorable [email-masked] (Don Cohen) writes:
>

what is distributed code?

> reading the same variable from the environment twice.

getenv is cheaper than the cache.

> (or setting a value not yet used).

in CLISP, GETENV is SETF-able.

> I hope the first one at least is relatively easy to provide.

I am not sure whether we really need that.

> to work in another environment.

Just pass -E utf-8 and all those encodings will use unicode.
the other environment variables should not matter for batch processing.

alternatively, you can set the -encoding* places in ~/.clisprc
alternatively, you can make the init function of your image set them

> Does anyone know how to find out what environment a clisp version

search the manual and the impnotes for "environment var" or
search the sources for getenv.

in general, you can find out what libc calls are performed using ltrace(1).

-- 
Sam Steingold (http://www.podval.org/~sds) running RedHat8 GNU/Linux
<http://www.camera.org> <http://www.iris.org.il> <http://www.memri.org/>
<http://www.mideasttruth.com/> <http://www.palestine-central.com/links.html>
Do not tell me what to do and I will not tell you where to go.