Hi folks,
I've experienced issues with the (current?) irrklang dependency with CMake:
It seems that the zip file that is downloaded for the 64bit builds is not correctly unzipped...I think.
It looks like the
irrKlang-64bit-1.6.0.zip
has a subfolder "
irrKlang-64bit-1.6.0/
" that is not handles correct in
\Sound\XRSound\CMakeLists.txt
If I understand that file correctly, this part
Code:
# ...
if(BUILD64)
set(IRRKLANG_BIN_DIR ${IRRKLANG_DIR}/bin/winx64-visualStudio)
set(IRRKLANG_LIB_DIR ${IRRKLANG_DIR}/lib/Winx64-visualStudio)
else()
# because of a bug in the 32bit version of irrKlang (it has hidden "__MACOSX" dir),
# CMake does not strip the top-level directory
string(APPEND IRRKLANG_DIR /irrKlang-1.6.0)
set(IRRKLANG_BIN_DIR ${IRRKLANG_DIR}/bin/win32-visualStudio)
set(IRRKLANG_LIB_DIR ${IRRKLANG_DIR}/lib/Win32-visualStudio)
endif()
set(IRRKLANG_LIB ${IRRKLANG_LIB_DIR}/irrKlang.lib)
# ...
handles that for the 32bit version, but (lately?) the 64bit ZIP has this sub-directory too, so shouldn't it be handled there as well?
Like:
Code:
# ...
if(BUILD64)
# CMake does not strip the top-level directory
string(APPEND IRRKLANG_DIR /irrKlang-64bit-1.6.0)
set(IRRKLANG_BIN_DIR ${IRRKLANG_DIR}/bin/winx64-visualStudio)
set(IRRKLANG_LIB_DIR ${IRRKLANG_DIR}/lib/Winx64-visualStudio)
else()
# because of a bug in the 32bit version of irrKlang (it has hidden "__MACOSX" dir),
# CMake does not strip the top-level directory
string(APPEND IRRKLANG_DIR /irrKlang-1.6.0)
set(IRRKLANG_BIN_DIR ${IRRKLANG_DIR}/bin/win32-visualStudio)
set(IRRKLANG_LIB_DIR ${IRRKLANG_DIR}/lib/Win32-visualStudio)
endif()
set(IRRKLANG_LIB ${IRRKLANG_LIB_DIR}/irrKlang.lib)
# ...
But this does not seem to do the job
When I manually extract the ZIP contents into
\Extern\irrKlang\x64\
it does compile however!
By the way, this is the CMake error I get all the time:
Code:
1> [CMake] Downloading irrKlang from https://www.ambiera.at/downloads/irrKlang-64bit-1.6.0.zip ...
1> [CMake] CMake Error at C:/Program Files (x86)/Microsoft Visual Studio/2019/Community/Common7/IDE/CommonExtensions/Microsoft/CMake/CMake/share/cmake-3.20/Modules/ExternalProject.cmake:2771 (message):
1> [CMake] At least one entry of URL is a path (invalid in a list)
1> [CMake] Call Stack (most recent call first):
1> [CMake] C:/Program Files (x86)/Microsoft Visual Studio/2019/Community/Common7/IDE/CommonExtensions/Microsoft/CMake/CMake/share/cmake-3.20/Modules/ExternalProject.cmake:3681 (_ep_add_download_command)
1> [CMake] CMakeLists.txt:15 (ExternalProject_Add)
1> [CMake] -- Configuring incomplete, errors occurred!
1> [CMake] See also "D:/Programme/Orbiter/orbiter-git-schnepe2/out/build/windows-x64-debug/_deps/irrklang-subbuild/CMakeFiles/CMakeOutput.log".
1> [CMake]
1> [CMake] CMake Error at C:/Program Files (x86)/Microsoft Visual Studio/2019/Community/Common7/IDE/CommonExtensions/Microsoft/CMake/CMake/share/cmake-3.20/Modules/FetchContent.cmake:1000 (message):
1> [CMake] CMake step for irrklang failed: 1
1> [CMake] Call Stack (most recent call first):
1> [CMake] C:/Program Files (x86)/Microsoft Visual Studio/2019/Community/Common7/IDE/CommonExtensions/Microsoft/CMake/CMake/share/cmake-3.20/Modules/FetchContent.cmake:1141:EVAL:2 (__FetchContent_directPopulate)
1> [CMake] C:/Program Files (x86)/Microsoft Visual Studio/2019/Community/Common7/IDE/CommonExtensions/Microsoft/CMake/CMake/share/cmake-3.20/Modules/FetchContent.cmake:1141 (cmake_language)
1> [CMake] C:/Program Files (x86)/Microsoft Visual Studio/2019/Community/Common7/IDE/CommonExtensions/Microsoft/CMake/CMake/share/cmake-3.20/Modules/FetchContent.cmake:1184 (FetchContent_Populate)
1> [CMake] Sound/XRSound/CMakeLists.txt:20 (FetchContent_MakeAvailable)
1> [CMake] -- Configuring incomplete, errors occurred!