mirror of
https://github.com/RPCS3/rpcs3.git
synced 2024-11-24 11:43:05 +01:00
Refactor hidapi submodule (#10346)
Co-authored-by: Megamouse <studienricky89@googlemail.com>
This commit is contained in:
parent
83d3658ef0
commit
177933e212
2
.gitmodules
vendored
2
.gitmodules
vendored
@ -32,7 +32,7 @@
|
|||||||
url = https://github.com/madler/zlib
|
url = https://github.com/madler/zlib
|
||||||
ignore = dirty
|
ignore = dirty
|
||||||
[submodule "3rdparty/hidapi"]
|
[submodule "3rdparty/hidapi"]
|
||||||
path = 3rdparty/hidapi
|
path = 3rdparty/hidapi/hidapi
|
||||||
url = https://github.com/RPCS3/hidapi
|
url = https://github.com/RPCS3/hidapi
|
||||||
branch = master
|
branch = master
|
||||||
ignore = dirty
|
ignore = dirty
|
||||||
|
26
3rdparty/CMakeLists.txt
vendored
26
3rdparty/CMakeLists.txt
vendored
@ -79,31 +79,7 @@ endif()
|
|||||||
|
|
||||||
|
|
||||||
# hidapi
|
# hidapi
|
||||||
add_library(3rdparty_hidapi INTERFACE)
|
add_subdirectory(hidapi)
|
||||||
target_include_directories(3rdparty_hidapi INTERFACE hidapi/hidapi)
|
|
||||||
|
|
||||||
if(APPLE)
|
|
||||||
add_subdirectory(hidapi/mac EXCLUDE_FROM_ALL)
|
|
||||||
target_include_directories(hidapi-mac PUBLIC hidapi/hidapi)
|
|
||||||
|
|
||||||
target_link_libraries(3rdparty_hidapi INTERFACE hidapi-mac "-framework CoreFoundation" "-framework IOKit")
|
|
||||||
elseif(CMAKE_SYSTEM MATCHES "Linux")
|
|
||||||
add_subdirectory(hidapi/linux EXCLUDE_FROM_ALL)
|
|
||||||
target_include_directories(hidapi-hidraw PUBLIC hidapi/hidapi)
|
|
||||||
|
|
||||||
target_link_libraries(3rdparty_hidapi INTERFACE hidapi-hidraw udev)
|
|
||||||
elseif(WIN32)
|
|
||||||
add_subdirectory(hidapi/windows EXCLUDE_FROM_ALL)
|
|
||||||
target_include_directories(hidapi-hid PUBLIC hidapi/hidapi)
|
|
||||||
|
|
||||||
target_link_libraries(3rdparty_hidapi INTERFACE hidapi-hid Shlwapi.lib)
|
|
||||||
else()
|
|
||||||
add_subdirectory(hidapi/libusb EXCLUDE_FROM_ALL)
|
|
||||||
target_include_directories(hidapi-libusb PUBLIC hidapi/hidapi)
|
|
||||||
|
|
||||||
target_link_libraries(3rdparty_hidapi INTERFACE hidapi-libusb usb)
|
|
||||||
endif()
|
|
||||||
|
|
||||||
|
|
||||||
# yaml-cpp
|
# yaml-cpp
|
||||||
# We don't want to install yaml-cpp but its cmake file doesn't have option
|
# We don't want to install yaml-cpp but its cmake file doesn't have option
|
||||||
|
25
3rdparty/hidapi/CMakeLists.txt
vendored
Normal file
25
3rdparty/hidapi/CMakeLists.txt
vendored
Normal file
@ -0,0 +1,25 @@
|
|||||||
|
# hidapi
|
||||||
|
add_library(3rdparty_hidapi INTERFACE)
|
||||||
|
target_include_directories(3rdparty_hidapi INTERFACE hidapi/hidapi)
|
||||||
|
|
||||||
|
if(APPLE)
|
||||||
|
add_subdirectory(hidapi/mac EXCLUDE_FROM_ALL)
|
||||||
|
target_include_directories(hidapi-mac PUBLIC hidapi/hidapi)
|
||||||
|
|
||||||
|
target_link_libraries(3rdparty_hidapi INTERFACE hidapi-mac "-framework CoreFoundation" "-framework IOKit")
|
||||||
|
elseif(CMAKE_SYSTEM MATCHES "Linux")
|
||||||
|
add_subdirectory(hidapi/linux EXCLUDE_FROM_ALL)
|
||||||
|
target_include_directories(hidapi-hidraw PUBLIC hidapi/hidapi)
|
||||||
|
|
||||||
|
target_link_libraries(3rdparty_hidapi INTERFACE hidapi-hidraw udev)
|
||||||
|
elseif(WIN32)
|
||||||
|
add_subdirectory(hidapi/windows EXCLUDE_FROM_ALL)
|
||||||
|
target_include_directories(hidapi-hid PUBLIC hidapi/hidapi)
|
||||||
|
|
||||||
|
target_link_libraries(3rdparty_hidapi INTERFACE hidapi-hid Shlwapi.lib)
|
||||||
|
else()
|
||||||
|
add_subdirectory(hidapi/libusb EXCLUDE_FROM_ALL)
|
||||||
|
target_include_directories(hidapi-libusb PUBLIC hidapi/hidapi)
|
||||||
|
|
||||||
|
target_link_libraries(3rdparty_hidapi INTERFACE hidapi-libusb usb)
|
||||||
|
endif()
|
@ -58,7 +58,7 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "rpcs3", "rpcs3\rpcs3.vcxpro
|
|||||||
{349EE8F9-7D25-4909-AAF5-FF3FADE72187} = {349EE8F9-7D25-4909-AAF5-FF3FADE72187}
|
{349EE8F9-7D25-4909-AAF5-FF3FADE72187} = {349EE8F9-7D25-4909-AAF5-FF3FADE72187}
|
||||||
EndProjectSection
|
EndProjectSection
|
||||||
EndProject
|
EndProject
|
||||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "hidapi", "3rdparty\hidapi.vcxproj", "{A107C21C-418A-4697-BB10-20C3AA60E2E4}"
|
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "hidapi", "3rdparty\hidapi\hidapi.vcxproj", "{A107C21C-418A-4697-BB10-20C3AA60E2E4}"
|
||||||
EndProject
|
EndProject
|
||||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "xxhash", "3rdparty\xxhash.vcxproj", "{939FE206-1182-ABC3-1234-FEAB88E98404}"
|
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "xxhash", "3rdparty\xxhash.vcxproj", "{939FE206-1182-ABC3-1234-FEAB88E98404}"
|
||||||
EndProject
|
EndProject
|
||||||
|
@ -62,12 +62,12 @@
|
|||||||
<IgnoreImportLibrary Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</IgnoreImportLibrary>
|
<IgnoreImportLibrary Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">true</IgnoreImportLibrary>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
|
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
|
||||||
<IncludePath>..\3rdparty\7z\src;..\3rdparty\hidapi\hidapi;.\;..\;..\3rdparty\asmjit\asmjit\src;..\3rdparty\yaml-cpp\include;..\3rdparty\ffmpeg\include;..\3rdparty\cereal\include;$(VC_IncludePath);$(WindowsSDK_IncludePath);$(UniversalCRT_IncludePath);..\3rdparty\XAudio2Redist\include;..\3rdparty\span\include;..\3rdparty\libpng\libpng;..\3rdparty\GL;..\3rdparty\stblib\include;..\3rdparty\OpenAL\include;..\3rdparty\pugixml\src;..\3rdparty\Optional;..\3rdparty\discord-rpc\include;..\3rdparty\zlib</IncludePath>
|
<IncludePath>..\3rdparty\7z\src;..\3rdparty\hidapi\hidapi\hidapi;.\;..\;..\3rdparty\asmjit\asmjit\src;..\3rdparty\yaml-cpp\include;..\3rdparty\ffmpeg\include;..\3rdparty\cereal\include;$(VC_IncludePath);$(WindowsSDK_IncludePath);$(UniversalCRT_IncludePath);..\3rdparty\XAudio2Redist\include;..\3rdparty\span\include;..\3rdparty\libpng\libpng;..\3rdparty\GL;..\3rdparty\stblib\include;..\3rdparty\OpenAL\include;..\3rdparty\pugixml\src;..\3rdparty\Optional;..\3rdparty\discord-rpc\include;..\3rdparty\zlib</IncludePath>
|
||||||
<LibraryPath>$(SolutionDir)lib\$(Configuration)-$(Platform)\;$(UniversalCRT_LibraryPath_x64);$(LibraryPath)</LibraryPath>
|
<LibraryPath>$(SolutionDir)lib\$(Configuration)-$(Platform)\;$(UniversalCRT_LibraryPath_x64);$(LibraryPath)</LibraryPath>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||||
<LibraryPath>$(SolutionDir)lib\$(Configuration)-$(Platform)\;$(UniversalCRT_LibraryPath_x64);$(LibraryPath)</LibraryPath>
|
<LibraryPath>$(SolutionDir)lib\$(Configuration)-$(Platform)\;$(UniversalCRT_LibraryPath_x64);$(LibraryPath)</LibraryPath>
|
||||||
<IncludePath>..\3rdparty\7z\src;..\3rdparty\hidapi\hidapi;.\;..\;..\3rdparty\asmjit\asmjit\src;..\3rdparty\yaml-cpp\include;..\3rdparty\ffmpeg\include;..\3rdparty\cereal\include;$(VC_IncludePath);$(WindowsSDK_IncludePath);$(UniversalCRT_IncludePath);..\3rdparty\XAudio2Redist\include;..\3rdparty\span\include;..\3rdparty\libpng\libpng;..\3rdparty\GL;..\3rdparty\stblib\include;..\3rdparty\OpenAL\include;..\3rdparty\pugixml\src;..\3rdparty\Optional;..\3rdparty\discord-rpc\include;..\3rdparty\zlib</IncludePath>
|
<IncludePath>..\3rdparty\7z\src;..\3rdparty\hidapi\hidapi\hidapi;.\;..\;..\3rdparty\asmjit\asmjit\src;..\3rdparty\yaml-cpp\include;..\3rdparty\ffmpeg\include;..\3rdparty\cereal\include;$(VC_IncludePath);$(WindowsSDK_IncludePath);$(UniversalCRT_IncludePath);..\3rdparty\XAudio2Redist\include;..\3rdparty\span\include;..\3rdparty\libpng\libpng;..\3rdparty\GL;..\3rdparty\stblib\include;..\3rdparty\OpenAL\include;..\3rdparty\pugixml\src;..\3rdparty\Optional;..\3rdparty\discord-rpc\include;..\3rdparty\zlib</IncludePath>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
|
||||||
<ClCompile>
|
<ClCompile>
|
||||||
|
Loading…
Reference in New Issue
Block a user