From 065d46ab275674a9c7a4b8df5dc9ea46c1291fdb Mon Sep 17 00:00:00 2001 From: Luca Weiss Date: Wed, 17 Jul 2019 19:14:38 +0200 Subject: [PATCH] Add Windows (msbuild & cygwin) CI (#37) * Upgrade Windows projects to VS2015 * add MSVC x64 configuration --- .appveyor.yml | 33 +++++++ windows/.gitignore | 2 + windows/hidapi.sln | 26 ++++-- windows/hidapi.vcxproj | 160 ++++++++++++++++++++++++++++++++ windows/hidapi.vcxproj.filters | 27 ++++++ windows/hidtest.vcxproj | 156 +++++++++++++++++++++++++++++++ windows/hidtest.vcxproj.filters | 22 +++++ 7 files changed, 419 insertions(+), 7 deletions(-) create mode 100644 .appveyor.yml create mode 100644 windows/hidapi.vcxproj create mode 100644 windows/hidapi.vcxproj.filters create mode 100644 windows/hidtest.vcxproj create mode 100644 windows/hidtest.vcxproj.filters diff --git a/.appveyor.yml b/.appveyor.yml new file mode 100644 index 0000000..b7e21c7 --- /dev/null +++ b/.appveyor.yml @@ -0,0 +1,33 @@ +os: Visual Studio 2015 + +environment: + matrix: + - BUILD_ENV: msbuild + arch: x64 + - BUILD_ENV: msbuild + arch: Win32 + - BUILD_ENV: cygwin + +install: + - cmd: if %BUILD_ENV%==cygwin ( + C:\cygwin64\setup-x86_64.exe --quiet-mode --no-shortcuts --upgrade-also --packages autoconf,automake ) + +build_script: + - cmd: if %BUILD_ENV%==msbuild ( + msbuild .\windows\hidapi.sln /p:Configuration=Release /p:Platform=%arch% /logger:"C:\Program Files\AppVeyor\BuildAgent\Appveyor.MSBuildLogger.dll" ) + - cmd: if %BUILD_ENV%==cygwin ( + C:\cygwin64\bin\bash -exlc "cd $APPVEYOR_BUILD_FOLDER; ./bootstrap; ./configure; make" ) + +artifacts: + # Win32 artifacts + - path: .\windows\Release\hidapi.dll + - path: .\windows\Release\hidapi.lib + - path: .\windows\Release\hidapi.pdb + - path: .\windows\Release\hidtest.exe + - path: .\windows\Release\hidtest.pdb + # x64 artifacts + - path: .\windows\x64\Release\hidapi.dll + - path: .\windows\x64\Release\hidapi.lib + - path: .\windows\x64\Release\hidapi.pdb + - path: .\windows\x64\Release\hidtest.exe + - path: .\windows\x64\Release\hidtest.pdb diff --git a/windows/.gitignore b/windows/.gitignore index a3f6d87..c2ad395 100644 --- a/windows/.gitignore +++ b/windows/.gitignore @@ -1,10 +1,12 @@ Debug Release +.vs/ *.exp *.ilk *.lib *.suo *.vcproj.* +*.vcxproj.* *.ncb *.suo *.dll diff --git a/windows/hidapi.sln b/windows/hidapi.sln index d45c397..aeb2660 100644 --- a/windows/hidapi.sln +++ b/windows/hidapi.sln @@ -1,29 +1,41 @@  -Microsoft Visual Studio Solution File, Format Version 10.00 -# Visual C++ Express 2008 -Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "hidapi", "hidapi.vcproj", "{A107C21C-418A-4697-BB10-20C3AA60E2E4}" +Microsoft Visual Studio Solution File, Format Version 12.00 +# Visual Studio 15 +VisualStudioVersion = 15.0.28307.136 +MinimumVisualStudioVersion = 10.0.40219.1 +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "hidapi", "hidapi.vcxproj", "{A107C21C-418A-4697-BB10-20C3AA60E2E4}" EndProject -Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "hidtest", "hidtest.vcproj", "{23E9FF6A-49D1-4993-B2B5-BBB992C6C712}" - ProjectSection(ProjectDependencies) = postProject - {A107C21C-418A-4697-BB10-20C3AA60E2E4} = {A107C21C-418A-4697-BB10-20C3AA60E2E4} - EndProjectSection +Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "hidtest", "hidtest.vcxproj", "{23E9FF6A-49D1-4993-B2B5-BBB992C6C712}" EndProject Global GlobalSection(SolutionConfigurationPlatforms) = preSolution Debug|Win32 = Debug|Win32 + Debug|x64 = Debug|x64 Release|Win32 = Release|Win32 + Release|x64 = Release|x64 EndGlobalSection GlobalSection(ProjectConfigurationPlatforms) = postSolution {A107C21C-418A-4697-BB10-20C3AA60E2E4}.Debug|Win32.ActiveCfg = Debug|Win32 {A107C21C-418A-4697-BB10-20C3AA60E2E4}.Debug|Win32.Build.0 = Debug|Win32 + {A107C21C-418A-4697-BB10-20C3AA60E2E4}.Debug|x64.ActiveCfg = Debug|x64 + {A107C21C-418A-4697-BB10-20C3AA60E2E4}.Debug|x64.Build.0 = Debug|x64 {A107C21C-418A-4697-BB10-20C3AA60E2E4}.Release|Win32.ActiveCfg = Release|Win32 {A107C21C-418A-4697-BB10-20C3AA60E2E4}.Release|Win32.Build.0 = Release|Win32 + {A107C21C-418A-4697-BB10-20C3AA60E2E4}.Release|x64.ActiveCfg = Release|x64 + {A107C21C-418A-4697-BB10-20C3AA60E2E4}.Release|x64.Build.0 = Release|x64 {23E9FF6A-49D1-4993-B2B5-BBB992C6C712}.Debug|Win32.ActiveCfg = Debug|Win32 {23E9FF6A-49D1-4993-B2B5-BBB992C6C712}.Debug|Win32.Build.0 = Debug|Win32 + {23E9FF6A-49D1-4993-B2B5-BBB992C6C712}.Debug|x64.ActiveCfg = Debug|x64 + {23E9FF6A-49D1-4993-B2B5-BBB992C6C712}.Debug|x64.Build.0 = Debug|x64 {23E9FF6A-49D1-4993-B2B5-BBB992C6C712}.Release|Win32.ActiveCfg = Release|Win32 {23E9FF6A-49D1-4993-B2B5-BBB992C6C712}.Release|Win32.Build.0 = Release|Win32 + {23E9FF6A-49D1-4993-B2B5-BBB992C6C712}.Release|x64.ActiveCfg = Release|x64 + {23E9FF6A-49D1-4993-B2B5-BBB992C6C712}.Release|x64.Build.0 = Release|x64 EndGlobalSection GlobalSection(SolutionProperties) = preSolution HideSolutionNode = FALSE EndGlobalSection + GlobalSection(ExtensibilityGlobals) = postSolution + SolutionGuid = {8749E535-9C65-4A89-840E-78D7578C7866} + EndGlobalSection EndGlobal diff --git a/windows/hidapi.vcxproj b/windows/hidapi.vcxproj new file mode 100644 index 0000000..c793017 --- /dev/null +++ b/windows/hidapi.vcxproj @@ -0,0 +1,160 @@ + + + + + Debug + Win32 + + + Debug + x64 + + + Release + Win32 + + + Release + x64 + + + + {A107C21C-418A-4697-BB10-20C3AA60E2E4} + hidapi + Win32Proj + + + + DynamicLibrary + v140 + Unicode + true + + + DynamicLibrary + v140 + Unicode + true + + + DynamicLibrary + v140 + Unicode + + + DynamicLibrary + v140 + Unicode + + + + + + + + + + + + + + + + + + + <_ProjectFileVersion>14.0.25431.1 + + + + + + + + Disabled + ..\hidapi;%(AdditionalIncludeDirectories) + WIN32;_DEBUG;_WINDOWS;_USRDLL;HIDAPI_EXPORTS;%(PreprocessorDefinitions) + true + EnableFastChecks + MultiThreadedDebugDLL + + Level3 + EditAndContinue + + + setupapi.lib;%(AdditionalDependencies) + true + Windows + MachineX86 + + + + + Disabled + ..\hidapi;%(AdditionalIncludeDirectories) + WIN32;_DEBUG;_WINDOWS;_USRDLL;HIDAPI_EXPORTS;%(PreprocessorDefinitions) + EnableFastChecks + MultiThreadedDebugDLL + + + Level3 + EditAndContinue + + + setupapi.lib;%(AdditionalDependencies) + true + Windows + + + + + MaxSpeed + true + ..\hidapi;%(AdditionalIncludeDirectories) + WIN32;NDEBUG;_WINDOWS;_USRDLL;HIDAPI_EXPORTS;%(PreprocessorDefinitions) + MultiThreaded + true + + Level3 + ProgramDatabase + + + setupapi.lib;%(AdditionalDependencies) + true + Windows + true + true + MachineX86 + + + + + MaxSpeed + true + ..\hidapi;%(AdditionalIncludeDirectories) + WIN32;NDEBUG;_WINDOWS;_USRDLL;HIDAPI_EXPORTS;%(PreprocessorDefinitions) + MultiThreaded + true + + + Level3 + ProgramDatabase + + + setupapi.lib;%(AdditionalDependencies) + true + Windows + true + true + + + + + + + + + + + + diff --git a/windows/hidapi.vcxproj.filters b/windows/hidapi.vcxproj.filters new file mode 100644 index 0000000..af3a78a --- /dev/null +++ b/windows/hidapi.vcxproj.filters @@ -0,0 +1,27 @@ + + + + + {4FC737F1-C7A5-4376-A066-2A32D752A2FF} + cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx + + + {93995380-89BD-4b04-88EB-625FBE52EBFB} + h;hpp;hxx;hm;inl;inc;xsd + + + {67DA6AB6-F800-4c08-8B7A-83BB121AAD01} + rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav + + + + + Source Files + + + + + Header Files + + + \ No newline at end of file diff --git a/windows/hidtest.vcxproj b/windows/hidtest.vcxproj new file mode 100644 index 0000000..e792e57 --- /dev/null +++ b/windows/hidtest.vcxproj @@ -0,0 +1,156 @@ + + + + + Debug + Win32 + + + Debug + x64 + + + Release + Win32 + + + Release + x64 + + + + {23E9FF6A-49D1-4993-B2B5-BBB992C6C712} + hidtest + + + + Application + v140 + MultiByte + true + + + Application + v140 + MultiByte + true + + + Application + v140 + MultiByte + + + Application + v140 + MultiByte + + + + + + + + + + + + + + + + + + + <_ProjectFileVersion>14.0.25431.1 + + + + + + + + Disabled + ..\hidapi;%(AdditionalIncludeDirectories) + true + EnableFastChecks + MultiThreadedDebugDLL + Level3 + EditAndContinue + + + hidapi.lib;%(AdditionalDependencies) + $(SolutionDir)$(Configuration);%(AdditionalLibraryDirectories) + true + Console + MachineX86 + + + + + Disabled + ..\hidapi;%(AdditionalIncludeDirectories) + EnableFastChecks + MultiThreadedDebugDLL + Level3 + EditAndContinue + + + hidapi.lib;%(AdditionalDependencies) + $(SolutionDir)$(Platform)\$(Configuration);%(AdditionalLibraryDirectories) + true + Console + + + + + MaxSpeed + true + ..\hidapi;%(AdditionalIncludeDirectories) + MultiThreaded + true + Level3 + ProgramDatabase + + + hidapi.lib;%(AdditionalDependencies) + $(SolutionDir)$(Configuration);%(AdditionalLibraryDirectories) + true + Console + true + true + MachineX86 + + + + + MaxSpeed + true + ..\hidapi;%(AdditionalIncludeDirectories) + MultiThreaded + true + Level3 + ProgramDatabase + + + hidapi.lib;%(AdditionalDependencies) + $(SolutionDir)$(Platform)\$(Configuration);%(AdditionalLibraryDirectories) + true + Console + true + true + + + + + + + + {a107c21c-418a-4697-bb10-20c3aa60e2e4} + false + + + + + + diff --git a/windows/hidtest.vcxproj.filters b/windows/hidtest.vcxproj.filters new file mode 100644 index 0000000..98b7e73 --- /dev/null +++ b/windows/hidtest.vcxproj.filters @@ -0,0 +1,22 @@ + + + + + {4FC737F1-C7A5-4376-A066-2A32D752A2FF} + cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx + + + {93995380-89BD-4b04-88EB-625FBE52EBFB} + h;hpp;hxx;hm;inl;inc;xsd + + + {67DA6AB6-F800-4c08-8B7A-83BB121AAD01} + rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav + + + + + Source Files + + +