# Copyright 2026 Stephen Bouche
# SPDX-License-Identifier: GPL-3.0-or-later
VESC_TOOL ?= vesc_tool

all: cppm_input.vescpkg

cppm_input.vescpkg: c_lib cppm_input.lisp README.md pkgdesc.qml ui.qml
	$(VESC_TOOL) --buildPkgFromDesc pkgdesc.qml --testPkgDesc 'vesc:test'

c_lib:
	$(MAKE) -C $@

test:
	./test/run.sh

clean:
	rm -f cppm_input.vescpkg
	$(MAKE) -C c_lib clean

.PHONY: all clean test c_lib
