Skip to content

Commit 1b75944

Browse files
committed
Fixed compiler script when SECD code is not installed.
Successfully attempted instructions in README.
1 parent c393c69 commit 1b75944

File tree

3 files changed

+10
-5
lines changed

3 files changed

+10
-5
lines changed

Makefile

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,8 @@ install: $(BIN) $(BIN)c
4949
install -v $(COMPILER_BIN) $(PREFIX)/share/lispkit
5050

5151
$(BIN)c: $(BIN)c.in
52-
sed "s|COMPILER=|COMPILER=$(PREFIX)/share/lispkit/$(COMPILER_BIN)|" lispkitc.in > $@
52+
sed "s|__COMPILER__=|COMPILER=$(PREFIX)/share/lispkit/$(COMPILER_BIN)|" lispkitc.in > $@
53+
chmod +x $@
5354

5455
uninstall:
5556
rm -vf $(PREFIX)/bin/$(BIN)

README

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11

22
This program is an implementation of the Lispkit described in the
33
book "FUNCTIONAL PROGRAMMING: Application and Implementation", by
4-
Peter Henderson, ISBN 0-13-331579-7.
4+
Peter Henderson, ISBN 0-13-331579-7, Prentice-Hall International, 1980.
55

66
If you have a C compiler and make, like gcc and gmake, you can
77
build the program with:
@@ -36,7 +36,7 @@ To compile a lispkit program, use the lispkitc script:
3636

3737
For example:
3838

39-
lispkitc examples/square.lisp square.bin
39+
./lispkitc examples/square.lisp square.bin
4040

4141

4242
To run a lispkit program:
@@ -49,7 +49,7 @@ If no argument file is given, lispkit will read from stdin.
4949

5050
For example:
5151

52-
echo 16 | lispkit square.bin
52+
echo 16 | ./lispkit square.bin
5353

5454

5555

lispkitc.in

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,10 @@
11
#!/bin/sh
22

3-
COMPILER=
3+
__COMPILER__=
4+
5+
if [[ ! -f $COMPILER ]]; then
6+
COMPILER=compiler.secd
7+
fi
48

59
LISPKIT=$(which lispkit)
610

0 commit comments

Comments
 (0)