diff options
| author | xengineering <mail2xengineering@protonmail.com> | 2021-05-30 12:41:12 +0200 | 
|---|---|---|
| committer | xengineering <mail2xengineering@protonmail.com> | 2021-05-30 12:41:12 +0200 | 
| commit | 47ef2d48af8d9efc23b65f13546528e061bad13d (patch) | |
| tree | 0463577add1d42483333d81bfba6a23077f1e0aa | |
| parent | ed894323a5770449d9cccf32ddd3eb9cff4aec45 (diff) | |
| download | stlscope-653190ba196df368c540c5ad307a41df9d21b203.tar stlscope-653190ba196df368c540c5ad307a41df9d21b203.tar.zst stlscope-653190ba196df368c540c5ad307a41df9d21b203.zip | |
Update Makefile with complete Installation Instructions0.2.1
| -rw-r--r-- | Makefile | 19 | 
1 files changed, 15 insertions, 4 deletions
| @@ -1,8 +1,16 @@  # vim: shiftwidth=4 tabstop=4 noexpandtab -PREFIX=/usr +DESTDIR=""  # leave empty for the current system or provide a fakeroot here +PREFIX="/usr"  all: +	# some recommended options for Go building (https://wiki.archlinux.org/title/Go_package_guidelines) +	export CGO_CPPFLAGS="${CPPFLAGS}" +	export CGO_CFLAGS="${CFLAGS}" +	export CGO_CXXFLAGS="${CXXFLAGS}" +	export CGO_LDFLAGS="${LDFLAGS}" +	export GOFLAGS="-buildmode=pie -trimpath -ldflags=-linkmode=external -mod=readonly -modcacherw" +	  	mkdir -p build  	go build -o build/stlscope ./... @@ -13,8 +21,11 @@ debug:  	go run ./... data/L.stl  install: all -	mkdir -p $(PREFIX)/bin -	install -m 755 build/stlscope $(PREFIX)/bin +	mkdir -p $(DESTDIR)$(PREFIX)/bin +	install -m 755 build/stlscope $(DESTDIR)$(PREFIX)/bin -.PHONY: all clean debug install +tests: all +	go test ./... + +.PHONY: all clean debug install tests | 
