build: add makefile, build bin/gash

* bin/gash.in: New file.
* bin/gash: Remove
* makefile: New file.
This commit is contained in:
Jan Nieuwenhuizen 2018-06-29 18:43:58 +02:00
parent df4f7971aa
commit cd4a80d3cb
4 changed files with 18 additions and 1 deletions

3
.gitignore vendored Normal file
View File

@ -0,0 +1,3 @@
*.go
*~
/bin/gash

View File

@ -1 +0,0 @@
guile -L $(dirname $0)/.. -e '(@ (gash gash) main)' -s $(dirname $0)/../gash/gash.scm $*

5
bin/gash.in Normal file
View File

@ -0,0 +1,5 @@
#!@GUILE@ \
-L . --no-auto-compile -s
!#
(setenv "SHELL" ((compose canonicalize-path car command-line)))
((@ (gash gash) main) (command-line))

10
makefile Normal file
View File

@ -0,0 +1,10 @@
all: bin/gash
GUILE = $(shell $(SHELL) -c "command -v guile")
bin/gash: bin/gash.in
sed s,@GUILE@,$(GUILE), $< > $@
chmod +x $@
clean:
rm -f bin/gash