From: Mark A. Stevens
Subject: CMUCL & the SI Package
Date: 
Message-ID: <5hbdav$k82@ecom7.ecn.bgu.edu>
I'm trying to get a handle on this. I've got CMUCL running on my
Solaris 2.4 machine and I've added the extras, so CLX is there, but it
isn't, the same seems to be true for SI:

% cmucl
CMU Common Lisp 17f, running on uxb1.ecn.bgu.edu
Send bug reports and questions to your local CMU CL maintainer, or to
··········@cs.cmu.edu.
Loaded subsystems:
    Python 1.0, target SPARCstation/Solaris 2
    CLOS based on PCL version:  September 16 92 PCL (f)
    CLX X Library MIT R5.02
    Motif toolkit and graphical debugger 1.0
    Hemlock 3.5
* (in-package 'SI)
Warning:  Old-style IN-PACKAGE.

#<The SI package, 0/9 internal, 0/9 external>
* (si::getenv "DISPLAY")

Warning: This function is undefined:
  GETENV
Invoking debugger...
Leaving debugger.

* (si::chdir ".")

Warning: This function is undefined:
  CHDIR
Invoking debugger...
Leaving debugger.

* 

Someone, anyone, what am I doing wrong?
-- 
Mark A. Stevens                      Phone:    708-235-2204
Systems Programmer/Administrator     Internet: ····@uxa.ecn.bgu.edu
Educational Computing Network        WWW:      http://www.ECNet.Net/users/xmas/
Governors State University           VMSHARE:  ECE/MARK

From: Erik Naggum
Subject: Re: CMUCL & the SI Package
Date: 
Message-ID: <3068377142829264@naggum.no>
* Mark A. Stevens
| Someone, anyone, what am I doing wrong?

first tell us what you expected to be doing right.

#\Erik
-- 
the dirty habits of unmarried hackers, # 19: softwear reuse.
From: Raymond Toy
Subject: Re: CMUCL & the SI Package
Date: 
Message-ID: <4nd8smegzu.fsf@rtp.ericsson.se>
>>>>> "Mark" == Mark A Stevens <····@uxa.ecn.bgu.edu> writes:
    Mark> % cmucl
    Mark> CMU Common Lisp 17f, running on uxb1.ecn.bgu.edu Send bug
    Mark> reports and questions to your local CMU CL maintainer, or to
    Mark> ··········@cs.cmu.edu. Loaded subsystems:
    Mark>     Python 1.0, target SPARCstation/Solaris 2 CLOS based on
    Mark>     PCL version:  September 16 92 PCL (f) CLX X Library MIT
    Mark>     R5.02 Motif toolkit and graphical debugger 1.0 Hemlock
    Mark>     3.5
    Mark> * (in-package 'SI)
    Mark> Warning:  Old-style IN-PACKAGE.

    Mark> #<The SI package, 0/9 internal, 0/9 external>
    Mark> * (si::getenv "DISPLAY")

    Mark> Someone, anyone, what am I doing wrong?

I don't know what you are trying to do, but CMUCL does NOT have a
package named SI:

	CMU Common Lisp 970312 signed-array , running on rcur18
	Send bug reports and questions to your local CMU CL maintainer,
	···@rtp.ericsson.se, or to ··········@cs.cmu.edu.
	Loaded subsystems:
	    Python 1.0, target SPARCstation/Solaris 2
	    CLOS based on PCL version:  September 16 92 PCL (f)
	* (find-package "SI")

	NIL

I think you are getting gcl and CMUCL confused.

If you are trying to get the CLX demo running, you should try to use
version that comes with CMUCL, not the version from gcl.

Ray
From: Martin Cracauer
Subject: Re: CMUCL & the SI Package
Date: 
Message-ID: <1997Mar26.180443.6025@wavehh.hanse.de>
····@uxa.ecn.bgu.edu (Mark A. Stevens) writes:

[...]
>* (in-package 'SI)
>Warning:  Old-style IN-PACKAGE.

[...]
>* (si::getenv "DISPLAY")
>Warning: This function is undefined:
>  GETENV

In CMUCL, use the global variable 
   ext:*environment-list*
to access the environment (it is an association list).

CLX defines a function (getenv <string>) that is based on this. 

To modify the environment for processes called from Lisp, pass a
modified alist to (run-program ...).

>* (si::chdir ".")
>Warning: This function is undefined:
>  CHDIR

The global variable DEFAULT-DIRECTORY in package Lisp does this. It is
setf -able.

>Someone, anyone, what am I doing wrong?

CMUCL does not have a SI package, CLX loaded or not. 

The first thing you did wrong is using the old-style in-package. The
way you used it it creates the package you want to change to if it
doesn't exist. Did you use (in-package "SI"), CMUCL would have raised
an error stating the package does not exist.

Then, you obviously assumed that CMUCL's SI package contains the same
as Franz Allegro's package of the same name. This is not the case,
these functions are non-standard and Lisp vendors didn't agreee on
similar interfaces even where it would be problem-free (like the
examples you gave).

I have to admit that CMUCL's manual doesn't contain information on
these functions. (apropos ...) and (documentation ...) are your
friends. Luckily, the manual is just being reworked :-)

Hope this helps.

Martin
-- 
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
···············@wavehh.hanse.de http://cracauer.cons.org  Fax.: +4940 5228536
"As far as I'm concerned,  if something is so complicated that you can't ex-
 plain it in 10 seconds, then it's probably not worth knowing anyway"- Calvin
From: Mike McDonald
Subject: Re: CMUCL & the SI Package
Date: 
Message-ID: <5help2$2ss@fido.asd.sgi.com>
In article <·····················@wavehh.hanse.de>,
	········@wavehh.hanse.de (Martin Cracauer) writes:
> ····@uxa.ecn.bgu.edu (Mark A. Stevens) writes:

>>* (si::chdir ".")
>>Warning: This function is undefined:
>>  CHDIR
> 
> The global variable DEFAULT-DIRECTORY in package Lisp does this. It is
> setf -able.

  Yuch! Try

* (apropos 'chdir)

UNIX:UNIX-CHDIR (defined)
CHDIR
* (describe 'unix:unix-chdir)

UNIX-CHDIR is an external symbol in the UNIX package.
Function: #<Function UNIX:UNIX-CHDIR {12AB351}>
Function arguments:
  (path)
Function documentation:
  Given a file path string, unix-chdir changes the current working 
   directory to the one specified.
Its defined argument types are:
  (SIMPLE-BASE-STRING)
Its result type is:
  (VALUES (MEMBER T NIL) (SIGNED-BYTE 32))
On Tuesday, 11/1/94 09:16:17 pm PST it was compiled from:
target:code/unix.lisp
  Created: Tuesday, 11/1/94 10:35:20 am PST
  Comment: $Header: unix.lisp,v 1.38 94/10/31 04:11:27 ram Exp $

  Mike McDonald
  ·······@engr.sgi.com
From: Joerg Hoehle
Subject: Re: CMUCL & the SI Package
Date: 
Message-ID: <5i2osp$pd4@omega.gmd.de>
Mike McDonald (·······@engr.sgi.com) wrote:
: In article <·····················@wavehh.hanse.de>,
: 	········@wavehh.hanse.de (Martin Cracauer) writes:

: > The global variable DEFAULT-DIRECTORY in package Lisp does this. It is
: > setf -able.

:   Yuch! Try

: * (describe 'unix:unix-chdir)

: UNIX-CHDIR is an external symbol in the UNIX package.
: Function documentation:
:   Given a file path string, unix-chdir changes the current working 
:    directory to the one specified.

I'd nevertheless recommend using a function from the EXTENSION package
than one from UNIX, for several reasons: The concept of
DEFAULT-DIRECTORY is certain to be known to functions such as LOAD
etc., it's also likely to be present on CMUCL ports to various
operating systems, whereas anything in UNIX is not.  Here's what I'm
using:

(defun ext::cd (&optional new)
  "Sets or returns current directory."
  (when new (setf (ext:default-directory) new))
  (ext:default-directory))

	Jo"rg Ho"hle.
············@gmd.de		http://zeus.gmd.de/~hoehle/amiga-clisp.html
From: Mark A. Stevens
Subject: Re: CMUCL & the SI Package
Date: 
Message-ID: <5ib1ih$fa9@ecom7.ecn.bgu.edu>
In article <··········@omega.gmd.de>, Joerg Hoehle <······@zeus.gmd.de> wrote:
>Mike McDonald (·······@engr.sgi.com) wrote:
>: In article <·····················@wavehh.hanse.de>,
>: 	········@wavehh.hanse.de (Martin Cracauer) writes:
>
>: > The global variable DEFAULT-DIRECTORY in package Lisp does this. It is
>: > setf -able.
>
>:   Yuch! Try
>
>: * (describe 'unix:unix-chdir)
>
>: UNIX-CHDIR is an external symbol in the UNIX package.
>: Function documentation:
>:   Given a file path string, unix-chdir changes the current working 
>:    directory to the one specified.
>
>I'd nevertheless recommend using a function from the EXTENSION package
>than one from UNIX, for several reasons: The concept of
>DEFAULT-DIRECTORY is certain to be known to functions such as LOAD
>etc., it's also likely to be present on CMUCL ports to various
>operating systems, whereas anything in UNIX is not.  Here's what I'm
>using:
>
>(defun ext::cd (&optional new)
>  "Sets or returns current directory."
>  (when new (setf (ext:default-directory) new))
>  (ext:default-directory))

It has been pointed out to me (Thank you all VERY much, as I hadn't a
clue) that SI is a packages for GNU Common LISP (CCL) not CMU Common
LISP. Thanks for the additional help in finding and identifying
functions inside packages.

I finally got CMUCL and GARNET up and running which was my target and
now I'm off to other fires. Thank you all for your help.
-- 
Mark A. Stevens                      Phone:    708-235-2204
Systems Programmer/Administrator     Internet: ····@uxa.ecn.bgu.edu
Educational Computing Network        WWW:      http://www.ECNet.Net/users/xmas/
Governors State University           VMSHARE:  ECE/MARK