2026-05-02 15:22:36 +02:00
|
|
|
# php-qml — Todo example app — Make targets.
|
|
|
|
|
|
|
|
|
|
.DEFAULT_GOAL := help
|
|
|
|
|
|
|
|
|
|
SYMFONY_DIR := symfony
|
|
|
|
|
QML_SRC_DIR := qml
|
|
|
|
|
BUILD_DIR := build/qml
|
|
|
|
|
QT_BIN := $(BUILD_DIR)/todo
|
|
|
|
|
|
|
|
|
|
.PHONY: help
|
|
|
|
|
help: ## Show available targets
|
|
|
|
|
@awk 'BEGIN {FS = ":.*?## "} /^[a-zA-Z_-]+:.*?## / {printf " %-12s %s\n", $$1, $$2}' $(MAKEFILE_LIST)
|
|
|
|
|
|
|
|
|
|
.PHONY: install
|
|
|
|
|
install: ## Install Composer dependencies for the Symfony app
|
|
|
|
|
cd $(SYMFONY_DIR) && composer install
|
|
|
|
|
|
|
|
|
|
.PHONY: build
|
|
|
|
|
build: ## Build the Qt host
|
|
|
|
|
cmake -S $(QML_SRC_DIR) -B $(BUILD_DIR) -DCMAKE_BUILD_TYPE=Debug
|
|
|
|
|
cmake --build $(BUILD_DIR) --parallel
|
|
|
|
|
|
|
|
|
|
.PHONY: dev
|
|
|
|
|
dev: build ## Run the todo app in dev mode (FrankenPHP --watch + Qt host)
|
|
|
|
|
./scripts/dev.sh
|
|
|
|
|
|
|
|
|
|
.PHONY: doctor
|
|
|
|
|
doctor: ## Run bridge:doctor inside the Symfony app
|
|
|
|
|
cd $(SYMFONY_DIR) && bin/console bridge:doctor
|
|
|
|
|
|
|
|
|
|
.PHONY: doctor-connect
|
|
|
|
|
doctor-connect: ## Run bridge:doctor with backend connectivity probe
|
|
|
|
|
cd $(SYMFONY_DIR) && bin/console bridge:doctor --connect
|
|
|
|
|
|
|
|
|
|
.PHONY: clean
|
|
|
|
|
clean: ## Remove build artefacts
|
|
|
|
|
rm -rf $(BUILD_DIR)
|
|
|
|
|
|
2026-05-02 15:50:03 +02:00
|
|
|
.PHONY: integration
|
|
|
|
|
integration: ## Run the bridge-integration test (FrankenPHP boot + HTTP/SSE round-trip + crash-recover)
|
|
|
|
|
./tests/integration.sh
|
|
|
|
|
|
2026-05-02 15:22:36 +02:00
|
|
|
.PHONY: quality
|
2026-05-02 15:50:03 +02:00
|
|
|
quality: build ## Run PHPStan, php-cs-fixer (check), PHPUnit, qmllint, integration
|
|
|
|
|
cd ../../framework/php && composer quality
|
2026-05-02 15:22:36 +02:00
|
|
|
cmake --build $(BUILD_DIR) --target all_qmllint
|
2026-05-02 15:50:03 +02:00
|
|
|
./tests/integration.sh
|