# How to make small executables?

**URL:** <https://racket.discourse.group/t/how-to-make-small-executables/2244>\
**Category:** Questions & Answers\
**Created:** [August 24, 2023, 7:28pm UTC](https://racket.discourse.group/t/how-to-make-small-executables/2244 "2023-08-24T19:28:07Z")\
**Posts on this page:** 3\
**Page:** 2

<div class="post-metadata">

**Author:** ![lewisl](https://yyz2.discourse-cdn.com/free1/user_avatar/racket.discourse.group/lewisl/32/1321_2.png) [@lewisl](https://racket.discourse.group/u/lewisl)\
**Post date:** [September 27, 2023, 8:56pm UTC](https://racket.discourse.group/t/how-to-make-small-executables/2244/21 "2023-09-27T20:56:45Z")

</div>

The problem is that Chez Scheme can't really be used in this form. For example, I want to install akku to install some srfi libraries. But, akku needs to know where the lib directory is so that libraries land in the right place. Where is that place for this build of Chez Scheme.

---

<div class="post-metadata">

**Author:** ![LiberalArtist](https://yyz2.discourse-cdn.com/free1/user_avatar/racket.discourse.group/liberalartist/32/151_2.png) [@LiberalArtist](https://racket.discourse.group/u/LiberalArtist)\
**Post date:** [September 28, 2023, 12:40am UTC](https://racket.discourse.group/t/how-to-make-small-executables/2244/22 "2023-09-28T00:40:02Z")

</div>

> [@lewisl](#):
>
> Looking at the make script doesn't help much:
> 
> ```scheme
> run: $(ZUO)
> $(ZUO) $(workarea) run
> 
> ```
> 
> So, where on earth is the workarea? That is not a normal environment variable so I can't expand its definition in any way that I know.

The `workarea` is set by the `configure` script when it creates the top-level `Makefile` from `Makefile.in`:

> <https://github.com/racket/racket/blob/ca0e5f588a0bfa501e5559b5e00059e294cd95d6/racket/src/ChezScheme/configure#L948-L950>

> <https://github.com/racket/racket/blob/ca0e5f588a0bfa501e5559b5e00059e294cd95d6/racket/src/ChezScheme/makefiles/Makefile.in#L1-L2>

Typically it is the Chez machine type you are building for, e.g. `ta6le`. (This keeps things from getting horribly messy when bootstrapping, cross-compiling, etc.) The `make`-level interface for the build system is almost exactly the same as with upstream Chez: the implementation using Zuo primarily makes it work more reliably.

I suggested `make run` as a quick way to get to a running Chez, but it's probably not what you want if you just want to use Chez, rather than develop it. For normal purposes, you would probably instead want to do:

```sh
./configure --prefix=/usr/local # or /opt/chez or ~/chez or ...
make
make install

```

---

<div class="post-metadata">

**Author:** ![lewisl](https://yyz2.discourse-cdn.com/free1/user_avatar/racket.discourse.group/lewisl/32/1321_2.png) [@lewisl](https://racket.discourse.group/u/lewisl)\
**Post date:** [September 28, 2023, 11:45pm UTC](https://racket.discourse.group/t/how-to-make-small-executables/2244/23 "2023-09-28T23:45:18Z")

</div>

Makes sense.

I did uninstall everything so I can try again.

Thanks

[Previous page](https://racket.discourse.group/t/how-to-make-small-executables/2244.md?page=1)
