Errors while building PHD2 in VC2022

142 views
Skip to first unread message

CaLIGHTs DSO Image Calibration Tool

unread,
Dec 31, 2023, 1:26:03 PM12/31/23
to Open PHD Guiding
I am seeing an error when trying to build PHD2 V2.6.13 in VC2022. I have following the procedure on the PHD2/Wiki. I had previously build v2.6.12 in VS2013 without issue. I followed the steps. I downloaded the latest version of CMAKE and I was able to convert wxWidgets to VS2022. Here is the error messages...

PS C:\users\pmwol\source\repos\phd2> cd tmp
PS C:\users\pmwol\source\repos\phd2\tmp> cmake -G "Visual Studio 17" -A Win32 -DwxWidgets_PREFIX_DIRECTORY=%WXWIN% ..
-- The C compiler identification is MSVC 19.38.33133.0
-- The CXX compiler identification is MSVC 19.38.33133.0
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: C:/Program Files/Microsoft Visual Studio/2022/Community/VC/Tools/MSVC/14.38.33130/bin/Hostx64/x86/cl.exe - skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: C:/Program Files/Microsoft Visual Studio/2022/Community/VC/Tools/MSVC/14.38.33130/bin/Hostx64/x86/cl.exe - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- PHD2 version '2.6.13' (extracted from source)
-- Preparing VCPKG
-- Populating vcpkg
CMake Error at C:/Program Files/CMake/share/cmake-3.27/Modules/ExternalProject.cmake:2851 (message):
  error: could not find git for clone of vcpkg-populate
Call Stack (most recent call first):
  C:/Program Files/CMake/share/cmake-3.27/Modules/ExternalProject.cmake:4345 (_ep_add_download_command)
  CMakeLists.txt:29 (ExternalProject_Add)

-- Configuring incomplete, errors occurred!

CMake Error at C:/Program Files/CMake/share/cmake-3.27/Modules/FetchContent.cmake:1650 (message):
  CMake step for vcpkg failed: 1
Call Stack (most recent call first):
  C:/Program Files/CMake/share/cmake-3.27/Modules/FetchContent.cmake:1802:EVAL:2 (__FetchContent_directPopulate)
  C:/Program Files/CMake/share/cmake-3.27/Modules/FetchContent.cmake:1802 (cmake_language)
  C:/Program Files/CMake/share/cmake-3.27/Modules/FetchContent.cmake:2016 (FetchContent_Populate)
  thirdparty/thirdparty.cmake:86 (FetchContent_MakeAvailable)
  CMakeLists.txt:122 (include)


-- Configuring incomplete, errors occurred!
PS C:\users\pmwol\source\repos\phd2\tmp>

Any help would be greatly appreciated

Peter

CaLIGHTs DSO Image Calibration Tool

unread,
Dec 31, 2023, 3:42:27 PM12/31/23
to Open PHD Guiding
I got everything compiling now.
I had to install Git...I installed Git v2.43.0
I also had to install Python...I installed Python v3.12.1
I also had to change the command line to cmake -G "Visual Studio 17" -A Win32 -DwxWidgets_PREFIX_DIRECTORY="C:\wxWidgets-3.0.5" ..
cmake complained about using   cmake -G "Visual Studio 17" -A Win32 -DwxWidgets_PREFIX_DIRECTORY=%WXWIN% ..
The error message I got was
CMake Error at thirdparty/thirdparty.cmake:532 (message):
  The variable wxWidgets_PREFIX_DIRECTORY should be defined and should point
  to a valid wxWindows installation path.  See the open-phd-guiding wiki for
  more information.

Peter

bw_m...@earthlink.net

unread,
Dec 31, 2023, 6:10:26 PM12/31/23
to open-phd...@googlegroups.com

I don’t think there’s any need to change the command-line for cmake if you have correctly defined the WXWIN environment variable.  The run_cmake.bat file works fine.  When you modify an environment variable, you have to close and re-open any open command-line windows in order to refresh settings.

--
You received this message because you are subscribed to the Google Groups "Open PHD Guiding" group.
To unsubscribe from this group and stop receiving emails from it, send an email to open-phd-guidi...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/open-phd-guiding/deba6856-22d5-4c0c-a475-caf4dee49cb5n%40googlegroups.com.

CaLIGHTs DSO Image Calibration Tool

unread,
Jan 1, 2024, 10:39:47 AM1/1/24
to Open PHD Guiding
The WXWIN environment variable has been present on my computer since the beginning of November, 2023 when I set up VS2013 to build PHD2 V2.6.11. My laptop has been re-booted numerous times since then. At that time the command line worked fine. I have no idea why CMAKE complained when I was moving to VS2022.

As far as the procedure goes...it needs to be modified to include installing Git and Python. Git had a huge number of options to configure during the install...I used the defaults. The wxWidgets v3.0.5 version worked fine as did the updating it to VS2022. I did install a new version of CMAKE which is v3.28.1. It seems that this new version didn't like the command line.

Peter

Reply all
Reply to author
Forward
0 new messages