所以我有这个非常简单的脚本,只是尝试创建一个文本文件,然后阅读它。
version: 1.0.{build}-{branch}
shallow_clone: true
environment:
matrix:
- APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2017
TOOLSET: msvc-14.1
ARCH: x86_64
- APPVEYOR_BUILD_WORKER_IMAGE: Visual Studio 2017
TOOLSET: msvc-14.1
ARCH: x86
install:
- if %ARCH% == x86 ( set TRIPLET=x86-windows ) else ( set TRIPLET=x64-windows )
- if %ARCH% == x86 ( set AM=32 ) else ( set AM=64 )
- git clone -b master --depth 1 https://github.com/boostorg/boost.git boost-root
- cd boost-root
build: off
test_script:
- set PATH=%ADDPATH%%PATH%
- |-
set VCPKG=%APPVEYOR_BUILD_FOLDER%\..\vcpkg\installed\%TRIPLET%
set "CHUNK=^<include^>%VCPKG%\include ^<search^>%VCPKG%\lib"
echo using zlib : : %CHUNK% ; > config.jam
echo using libjpeg : : %CHUNK% ; >> config.jam
echo using libpng : : ^<name^>libpng16 %CHUNK% ; >> config.jam
echo using libtiff : : %CHUNK% ; >> config.jam
more config.jam
当我运行它时,我收到以下错误:
Cannot access file C:\projects\gil\boost-root\config.jam
Command exited with code 1
我有什么明显的错误吗?
答案 0 :(得分:0)
我认为set "CHUNK=^<include^>%VCPKG%\include ^<search^>%VCPKG%\lib"
打破了环境变量中的某些内容。尝试在"
之后移动=
,例如set CHUNK="^<include^>%VCPKG%\include ^<search^>%VCPKG%\lib"
。