diff --git a/Makefile b/Makefile index 6cc2e48c9..6e9f9351b 100644 --- a/Makefile +++ b/Makefile @@ -207,12 +207,7 @@ build-launcher: @echo "Building picoclaw-launcher for $(PLATFORM)/$(ARCH)..." ifeq ($(OS),Windows_NT) @$(POWERSHELL) "New-Item -ItemType Directory -Force -Path '$(BUILD_DIR)' | Out-Null" - @$(MAKE) -C web build \ - PLATFORM="$(PLATFORM)" \ - ARCH="$(ARCH)" \ - EXT="$(EXT)" \ - OUTPUT="$(CURDIR)/$(BUILD_DIR)/picoclaw-launcher-$(PLATFORM)-$(ARCH)$(EXT)" \ - GO_BUILD_TAGS="$(GO_BUILD_TAGS)" + @$(MAKE) -C web build PLATFORM="$(PLATFORM)" ARCH="$(ARCH)" EXT="$(EXT)" OUTPUT="$(CURDIR)/$(BUILD_DIR)/picoclaw-launcher-$(PLATFORM)-$(ARCH)$(EXT)" GO_BUILD_TAGS="$(GO_BUILD_TAGS)" @$(POWERSHELL) "Copy-Item -LiteralPath '$(BUILD_DIR)/picoclaw-launcher-$(PLATFORM)-$(ARCH)$(EXT)' -Destination '$(BUILD_DIR)/picoclaw-launcher$(EXT)' -Force" else @mkdir -p $(BUILD_DIR) diff --git a/web/Makefile b/web/Makefile index b91c75c61..2e338f2ca 100644 --- a/web/Makefile +++ b/web/Makefile @@ -163,7 +163,7 @@ endif build-frontend: ifeq ($(OS),Windows_NT) - @if not exist "$(FRONTEND_DIR)\node_modules" (echo Installing frontend dependencies... && cd $(FRONTEND_DIR) && pnpm install --frozen-lockfile --store-dir .pnpm-store) else echo Frontend dependencies already installed. + @$(POWERSHELL) "$$frontend='$(FRONTEND_DIR)'; if (-not (Test-Path -LiteralPath ($$frontend + '/node_modules'))) { Write-Host 'Installing frontend dependencies...'; Push-Location $$frontend; try { pnpm install --frozen-lockfile --store-dir .pnpm-store } finally { Pop-Location } } else { Write-Host 'Frontend dependencies already installed.' }" else @if [ ! -d $(FRONTEND_DIR)/node_modules ] || \ [ $(FRONTEND_DIR)/package.json -nt $(FRONTEND_DIR)/node_modules ] || \