Updated Build System
This commit is contained in:
parent
fdb752cfe0
commit
d6e1292f45
4 changed files with 201 additions and 30 deletions
22
Makefile
22
Makefile
|
@ -1,23 +1,25 @@
|
|||
# Variables
|
||||
CONFIG ?= release
|
||||
DEFAULT_CONFIGURATION ?= release
|
||||
LOG_LEVEL = debug
|
||||
OUTDIR = build/$(CONFIG)
|
||||
PACKAGE = $(OUTDIR)/net.nosial.optslib.ncc
|
||||
|
||||
# Default Target
|
||||
all: build
|
||||
all: release release-executable
|
||||
|
||||
# Build Steps
|
||||
build:
|
||||
ncc build --config=$(CONFIG) --log-level $(LOG_LEVEL)
|
||||
release:
|
||||
ncc build --config=release --log-level $(LOG_LEVEL)
|
||||
release-executable:
|
||||
ncc build --config=release-executable --log-level $(LOG_LEVEL)
|
||||
|
||||
install: build
|
||||
ncc package install --package=$(PACKAGE) --skip-dependencies --build-source --reinstall -y --log-level $(LOG_LEVEL)
|
||||
|
||||
test: build
|
||||
install: release
|
||||
ncc package install --package=build/release/net.nosial.optslib.ncc --skip-dependencies --build-source --reinstall -y --log-level $(LOG_LEVEL)
|
||||
|
||||
test: release
|
||||
[ -f phpunit.xml ] || { echo "phpunit.xml not found"; exit 1; }
|
||||
phpunit
|
||||
|
||||
clean:
|
||||
rm -rf build
|
||||
|
||||
.PHONY: all build install test clean
|
||||
.PHONY: all install test clean release release-executable
|
Loading…
Add table
Add a link
Reference in a new issue