Arc Forumnew | comments | leaders | submitlogin
1 point by almkglor 5674 days ago | link | parent

It's a dependency on ./

Specifically, sets the environment variable "arc_dir" to the installation directory.

I would suggest making a batch file which sets the environment variable arc_dir properly before launching mzscheme -af as.scm ^^

Should probably be done correctly by providing an arc.bat I suppose, although the problem is always figuring out the installation directory... haven't hacked MSDOS batch files in a long time ^^

3 points by eds 5673 days ago | link

Ok, I got arc3f to work with the following:

  C:\User\Programming\Arc\arc3f\arc-f>set arc_dir=C:\User\Programming\Arc\arc3f\arc-f

  C:\User\Programming\Arc\arc3f\arc-f>mzscheme -mf as.scm
  Compiling arc.arc...
  Use (quit) to quit, (tl) to return here after an interrupt.
Unfortunately, (having learned Unix shell scripting), I never bothered to learn Windows batch files.

Also of note, doesn't work in Cygwin:

  $ sh
  > default-load-handler: cannot open input file: "c:/cygdrive/c/User/Programming/Arc/arc3f/arc-f/as.scm" (The system cannot find the path specified.; errno=3)


2 points by almkglor 5673 days ago | link

I pushed an untested arc.bat launcher on the anarki arc-f recently, although now that I've reviewed it it seems I used the wrong flag in the mzscheme invocation (-af instead of -mf). Could I ask you to check it out, and if so, could you check it out?

As for the cygwin stuff.... hmm. Maybe I should fix my broken WinXP machine...


1 point by bOR_ 5671 days ago | link

   @echo off
   set arc_dir=C:\Program Files\ARCF
   mzscheme -mf "%arc_dir%\as.scm"
This one worked for me. I'm not sure if removing the [][]'s from the file and making it windows line breaks mattered, but at least I had to move some ""'s around to get it to work.

Now just trying to get the launch-an-arc-script script working (from outside the repl). The script that is elsewhere on the website works on linux, but not windows ;). Damn pipes.


1 point by bOR_ 5670 days ago | link

  Use (quit) to quit, (tl) to return here after an interrupt.
  <User>tl: (load "arc-life.arc")
  Error: "reference to undefined identifier: __<arc>car_"

Hmm. I might be doing something wrong with trying to load an arc file in ARCF.


2 points by almkglor 5670 days ago | link

Hmm. Looks like a bug in some macro in Arc-F. Will find. Off the top, I can't seem to find any problems; a file like this:

  (prn "foo")
...loads fine:

  Use (quit) to quit, (tl) to return here after an interrupt.
  <User>tl: (load "test.arc")
care to send me the source you have?


1 point by eds 5671 days ago | link

That batch file works, thanks!


1 point by almkglor 5670 days ago | link

Out of curiousity: does it work even if you're on a different hard drive/directory as the installation drive/directory? The intent of that batch file is to allow you to launch Arc from anywhere, while still (1) able to access the current directory and (2) able to load library files from the arc installation directory


1 point by eds 5670 days ago | link

Yes, the batch file loads fine from another drive letter.

  Use (quit) to quit, (tl) to return here after an interrupt.
That said, I am not sure how to test that it can load files in both directories... especially with the new behavior of 'using.


1 point by almkglor 5670 days ago | link

Try on different directory:

  E:\> copy con tmp.arc
  (prn "hello world!")
  ^Z                       <---- that's a control-Z
  E:\> "C:\User\Programming\Arc\arc3f\arc-f\arc.bat"
  Use (quit) to quit, (tl) to return here after an interrupt.
  <User>tl: (using <files>v1)
  <User>tl: (ls)
  ("tmp.arc")       <--- you should get a list of files and stuff in the current directory, including tmp.arc
  <User>tl: (load "tmp.arc")
  hello world!


1 point by eds 5662 days ago | link

Works perfectly :-)