Updated Build system
This commit is contained in:
parent
9a4e537294
commit
a3049d3355
3 changed files with 123 additions and 17 deletions
22
Makefile
22
Makefile
|
@ -1,20 +1,32 @@
|
|||
# Variables
|
||||
CONFIG ?= release
|
||||
DEFAULT_CONFIG ?= release
|
||||
LOG_LEVEL = debug
|
||||
OUTDIR = build/$(CONFIG)
|
||||
PACKAGE = $(OUTDIR)/net.nosial.tgbotlib.ncc
|
||||
PACKAGE = build/$(CONFIG)/net.nosial.tgbotlib.ncc
|
||||
|
||||
# Default Target
|
||||
all: build
|
||||
|
||||
# Build Steps
|
||||
build:
|
||||
ncc build --config=$(CONFIG) --log-level $(LOG_LEVEL)
|
||||
release:
|
||||
ncc build --config=release --log-level $(LOG_LEVEL)
|
||||
release-compressed:
|
||||
ncc build --config=release-compressed --log-level $(LOG_LEVEL)
|
||||
release-executable:
|
||||
ncc build --config=release-executable --log-level $(LOG_LEVEL)
|
||||
release-executable-compressed:
|
||||
ncc build --config=release-executable-compressed --log-level $(LOG_LEVEL)
|
||||
debug:
|
||||
ncc build --config=debug --log-level $(LOG_LEVEL)
|
||||
debug-compressed:
|
||||
ncc build --config=debug-compressed --log-level $(LOG_LEVEL)
|
||||
|
||||
build: release release-compressed release-executable release-executable-compressed debug debug-compressed
|
||||
|
||||
install: build
|
||||
ncc package install --package=$(PACKAGE) --skip-dependencies --build-source --reinstall -y --log-level $(LOG_LEVEL)
|
||||
|
||||
test: build
|
||||
[ -f phpunit.xml ] || { echo "phpunit.xml not found"; exit 1; }
|
||||
phpunit
|
||||
|
||||
clean:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue