Updates to main Makefile (and added spinsult Makefile)

This commit is contained in:
Russ Magee 2018-07-04 23:07:09 -07:00
parent 9edcc5110c
commit 94e06abbcb
2 changed files with 38 additions and 10 deletions

View file

@ -1,9 +1,10 @@
.PHONY: info clean lib client server passwd
.PHONY: info clean common client server passwd subpkgs
SUBDIRS = hkexnet herradurakex hkexpasswd hkexsh hkexshd
LIBS = hkexnet herradurakex
SUBPKGS = spinsult hkexnet herradurakex
TOOLS = hkexpasswd hkexsh hkexshd
SUBDIRS = $(LIBS) $(TOOLS)
all: lib client server passwd
all: common client server passwd
clean:
go clean .
@ -11,20 +12,30 @@ clean:
$(MAKE) -C $$d clean;\
done
lib:
subpkgs:
for d in $(SUBPKGS); do\
$(MAKE) -C $$d all;\
done
tools:
for d in $(TOOLS); do\
$(MAKE) -C $$d all;\
done
common:
go install .
client: lib
client: common
$(MAKE) -C hkexsh
ifneq ($(MSYSTEM),)
server: lib
echo "hkexshd server not supported on Windows (yet)"
server: common
echo "hkexshd server not (yet) supported on Windows"
else
server: lib
server: common
$(MAKE) -C hkexshd
endif
passwd: lib
passwd: common
$(MAKE) -C hkexpasswd

17
spinsult/Makefile Normal file
View file

@ -0,0 +1,17 @@
.PHONY: info clean lib
all: lib
clean:
go clean .
lib: info
go install .
ifneq ($(MSYSTEM),)
info:
@echo "Building for Windows (MSYS)"
else
info:
@echo "Building for Linux"
endif