Skip to content

Commit

Permalink
Appveyor build for VC15
Browse files Browse the repository at this point in the history
1. use toolset vs141
2. fixed some problems/inconsistencies in vcxproj file for libcurl
3. use multiprocessor compilation
4. see https://ci.appveyor.com/project/chcg/wingup/builds/41432126

Close #41
  • Loading branch information
chcg authored and donho committed Nov 7, 2021
1 parent 230ad65 commit 3d14e31
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 39 deletions.
42 changes: 6 additions & 36 deletions appveyor.yml
Original file line number Diff line number Diff line change
@@ -1,11 +1,10 @@
version: 4.1.{build}
version: 4.2.{build}
image: Visual Studio 2017


environment:
matrix:
- PlatformToolset: v140_xp
- PlatformToolset: v141_xp
- PlatformToolset: v141

platform:
- x64
Expand All @@ -22,15 +21,14 @@ install:
- if "%platform%"=="Win32" set archi=x86
- if "%platform%"=="Win32" set platform_input=Win32

- if "%PlatformToolset%"=="v140_xp" call "C:\Program Files (x86)\Microsoft Visual Studio 14.0\VC\vcvarsall.bat" %archi%
- if "%PlatformToolset%"=="v141_xp" call "C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Auxiliary\Build\vcvarsall.bat" %archi%
- if "%PlatformToolset%"=="v141" call "C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Auxiliary\Build\vcvarsall.bat" %archi%


build_script:
- cd "%APPVEYOR_BUILD_FOLDER%"\curl\winbuild
- if "%configuration%"=="Debug" set debugflag=yes
- if "%configuration%"=="Release" set debugflag=no
- nmake /f Makefile.vc mode=dll vc=14 RTLIBCFG=static DEBUG="%debugflag%"
- nmake /f Makefile.vc mode=dll vc=15 RTLIBCFG=static DEBUG="%debugflag%"

- cd "%APPVEYOR_BUILD_FOLDER%"\vcproj
- msbuild GUP.vcxproj /m /p:configuration="%configuration%" /p:platform="%platform_input%" /p:PlatformToolset="%PlatformToolset%" /logger:"C:\Program Files\AppVeyor\BuildAgent\Appveyor.MSBuildLogger.dll"
Expand All @@ -41,39 +39,11 @@ after_build:
if ($env:PLATFORM_INPUT -eq "x64" -and $env:CONFIGURATION -eq "Release") {
Push-AppveyorArtifact "bin64\GUP.exe" -FileName GUP.exe
Push-AppveyorArtifact curl\builds\libcurl-vc14-x64-release-dll-ipv6-sspi-winssl\bin\libcurl.dll -FileName libcurl.dll
Push-AppveyorArtifact curl\builds\libcurl-vc15-x64-release-dll-ipv6-sspi-schannel\bin\libcurl.dll -FileName libcurl.dll
}
if ($env:PLATFORM_INPUT -eq "Win32" -and $env:CONFIGURATION -eq "Release") {
Push-AppveyorArtifact "bin\GUP.exe" -FileName GUP.exe
Push-AppveyorArtifact curl\builds\libcurl-vc14-x86-release-dll-ipv6-sspi-winssl\bin\libcurl.dll -FileName libcurl.dll
Push-AppveyorArtifact curl\builds\libcurl-vc15-x86-release-dll-ipv6-sspi-schannel\bin\libcurl.dll -FileName libcurl.dll
}
if ($($env:APPVEYOR_REPO_TAG) -eq "true" -and $env:CONFIGURATION -eq "Release" -and $env:PLATFORMTOOLSET -eq "v140_xp") {
if($env:PLATFORM_INPUT -eq "x64"){
$ZipFileName = "wingup.$($env:APPVEYOR_REPO_TAG_NAME).bin.x64.zip"
7z a $ZipFileName bin64\*
}
if($env:PLATFORM_INPUT -eq "Win32"){
$ZipFileName = "wingup.$($env:APPVEYOR_REPO_TAG_NAME).bin.zip"
7z a $ZipFileName bin\*
}
}
artifacts:
- path: wingup_*.zip
name: releases

deploy:
provider: GitHub
auth_token:
secure: !!TODO, see https://www.appveyor.com/docs/deployment/github/#provider-settings!!
artifact: releases
draft: false
prerelease: false
force_update: true
on:
appveyor_repo_tag: true
PlatformToolset: v140_xp
configuration: Release

14 changes: 11 additions & 3 deletions vcproj/GUP.vcxproj
Original file line number Diff line number Diff line change
Expand Up @@ -88,18 +88,20 @@
<Optimization>Disabled</Optimization>
<AdditionalIncludeDirectories>..\src\libcurl\include;..\src\TinyXml;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<PreprocessorDefinitions>WIN32;_DEBUG;_WINDOWS;_CRT_SECURE_NO_WARNINGS;_CRT_NONSTDC_NO_DEPRECATE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<MinimalRebuild>true</MinimalRebuild>
<MinimalRebuild>false</MinimalRebuild>
<BasicRuntimeChecks>EnableFastChecks</BasicRuntimeChecks>
<RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>
<PrecompiledHeader />
<WarningLevel>Level4</WarningLevel>
<DebugInformationFormat>EditAndContinue</DebugInformationFormat>
<TreatWarningAsError>true</TreatWarningAsError>
<EnableEnhancedInstructionSet>NoExtensions</EnableEnhancedInstructionSet>
<SDLCheck>true</SDLCheck>
<MultiProcessorCompilation>true</MultiProcessorCompilation>
</ClCompile>
<Link>
<AdditionalDependencies>libcurl_debug.lib;comctl32.lib;shlwapi.lib;%(AdditionalDependencies)</AdditionalDependencies>
<AdditionalLibraryDirectories>..\curl\builds\libcurl-vc14-x86-debug-dll-ipv6-sspi-winssl\lib;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
<AdditionalLibraryDirectories>..\curl\builds\libcurl-vc15-x86-debug-dll-ipv6-sspi-schannel\lib;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
<GenerateDebugInformation>true</GenerateDebugInformation>
<SubSystem>Windows</SubSystem>
<TargetMachine>MachineX86</TargetMachine>
Expand All @@ -121,10 +123,12 @@
<WarningLevel>Level4</WarningLevel>
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
<TreatWarningAsError>true</TreatWarningAsError>
<SDLCheck>true</SDLCheck>
<MultiProcessorCompilation>true</MultiProcessorCompilation>
</ClCompile>
<Link>
<AdditionalDependencies>libcurl_debug.lib;comctl32.lib;shlwapi.lib;%(AdditionalDependencies)</AdditionalDependencies>
<AdditionalLibraryDirectories>..\curl\builds\libcurl-vc14-x64-debug-dll-ipv6-sspi-winssl\lib;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
<AdditionalLibraryDirectories>..\curl\builds\libcurl-vc15-x64-debug-dll-ipv6-sspi-schannel\lib;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
<GenerateDebugInformation>true</GenerateDebugInformation>
<SubSystem>Windows</SubSystem>
</Link>
Expand All @@ -147,6 +151,8 @@
<DebugInformationFormat>None</DebugInformationFormat>
<TreatWarningAsError>true</TreatWarningAsError>
<EnableEnhancedInstructionSet>NoExtensions</EnableEnhancedInstructionSet>
<SDLCheck>true</SDLCheck>
<MultiProcessorCompilation>true</MultiProcessorCompilation>
</ClCompile>
<Link>
<AdditionalDependencies>libcurl.lib;comctl32.lib;shlwapi.lib;%(AdditionalDependencies)</AdditionalDependencies>
Expand Down Expand Up @@ -188,6 +194,8 @@ del ..\bin\GUP.ipdb</Command>
<WarningLevel>Level4</WarningLevel>
<DebugInformationFormat>None</DebugInformationFormat>
<TreatWarningAsError>true</TreatWarningAsError>
<SDLCheck>true</SDLCheck>
<MultiProcessorCompilation>true</MultiProcessorCompilation>
</ClCompile>
<Link>
<AdditionalDependencies>libcurl.lib;comctl32.lib;shlwapi.lib;%(AdditionalDependencies)</AdditionalDependencies>
Expand Down

0 comments on commit 3d14e31

Please sign in to comment.