-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathMakefile
34 lines (23 loc) · 1.04 KB
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
# HELP
# This will output the help for each task
# thanks to https://marmelab.com/blog/2016/02/29/auto-documented-makefile.html
.PHONY: help
help: ## This help
@awk 'BEGIN {FS = ":.*?## "} /^[a-zA-Z_-]+:.*?## / {printf "\033[36m%-20s\033[0m %s\n", $$1, $$2}' $(MAKEFILE_LIST)
.DEFAULT_GOAL := help
clean: ## Clean all dev data
@echo "Removing dev data..."
@rm -rf python
build_go: ## Build the Go library from protos
@echo "Building Go API libraries..."
bash protobuf/build.sh -f -t go -d .
build_python: ## Build the Python library from protos
@echo "Building Python API libraries..."
bash protobuf/build.sh -f -t python
update_scanoss_py: ## Copy the latest Python API code to scanoss.py
@echo "Copying Python API to scanoss.py..."
bash protobuf/copy_python.sh -f -s python -t ../../scanoss.py/src
python_all: clean build_python update_scanoss_py ## Execute all Python actions
build_js: ## Build the Javascript library with Typescript definitions from protos
@echo "Building Javascript API libraries..."
bash protobuf/build.sh -f -t js