From 27336792283e9a5498ac4f722eb270e462533731 Mon Sep 17 00:00:00 2001 From: Dengke Tang Date: Mon, 7 Nov 2022 17:02:49 -0800 Subject: [PATCH] try to manually install composer --- .github/workflows/ci.yml | 6 +++--- Makefile.frag.w32 | 8 +++++--- 2 files changed, 8 insertions(+), 6 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 3e0435e..95633b5 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -115,9 +115,9 @@ jobs: extensions: pecl_http - name: Build ${{ env.PACKAGE_NAME }} + consumers run: | - php -r "copy('https://getcomposer.org/installer', 'composer-setup.php');" - php .\composer-setup.php - ls + cd ..\ + git clone https://github.com/Microsoft/php-sdk-binary-tools.git php-sdk + .\php-sdk\phpsdk-vs16-x64.bat -t .\aws-crt-php\win_build.bat --task-args %CD%\aws-crt-php # macos: diff --git a/Makefile.frag.w32 b/Makefile.frag.w32 index f994de6..6f0ff1b 100644 --- a/Makefile.frag.w32 +++ b/Makefile.frag.w32 @@ -29,7 +29,9 @@ $(AWSCRT_DIR)\src\api.h: $(AWSCRT_DIR)\crt\aws-crt-ffi\src\api.h $(AWSCRT_DIR)\ext\api.h : $(AWSCRT_DIR)\src\api.h copy $(AWSCRT_DIR)\src\api.h $(AWSCRT_DIR)\ext\api.h -# Use PHPUnit to run tests +# Use PHPUnit and composer to run tests test-awscrt: install $(AWSCRT_DIR)\src\api.h $(BUILD_DIR)\php_awscrt.dll - $(PHP_BINARY) -c $(AWSCRT_DIR)\php-win.ini composer.phar --working-dir=$(AWSCRT_DIR) update - $(PHP_BINARY) -c $(AWSCRT_DIR)\php-win.ini composer.phar --working-dir=$(AWSCRT_DIR) run test-win + $(PHP_BINARY) -r "copy('https://getcomposer.org/installer', 'composer-setup.php');" + $(PHP_BINARY) .\composer-setup.php + $(PHP_BINARY) -c $(AWSCRT_DIR)\php-win.ini .\composer.phar --working-dir=$(AWSCRT_DIR) update + $(PHP_BINARY) -c $(AWSCRT_DIR)\php-win.ini .\composer.phar --working-dir=$(AWSCRT_DIR) run test-win