Build my plugin with GDAL
Posted: Mon Dec 07, 2020 3:42 pm
Hi Daniel,
I'm trying to rebuild my older plugin for new CC 2.12.alpha. I need GDAL for raster calculations in my plugin.
I can't build it when CMake OPTION_USE_GDAL is enabled.
Without GDAL other parts of the plugin can be built.
I set GDAL paths (bin, include, library) on my GDAL 2.1.3 directory:
GDAL_BIN_DIR: G:/cc/gdal_2_1_3/include/../bin
GDAL_INCLUDE_DIR: G:/cc/gdal_2_1_3/include
GDAL_LIBRARY: G:/cc/gdal_2_1_3/lib/gdal_i.lib
(I have only "include" and "lib" directories. "Bin" directory set automatically, but this directory is not on the disk.)
Please, can you advise me where the mistake might be?
Maybe the wrong version of GDAL? (BIN directory is missing.)
Where can I download right version of compiled GDAL?
I can't find it.
I'm testing it with VS2017, I have build CC 2.12.alpha from VS project INSTALL.
If I want build INSTALL project with GDAL support, I have this error:
I'm trying to rebuild my older plugin for new CC 2.12.alpha. I need GDAL for raster calculations in my plugin.
I can't build it when CMake OPTION_USE_GDAL is enabled.
Without GDAL other parts of the plugin can be built.
I set GDAL paths (bin, include, library) on my GDAL 2.1.3 directory:
GDAL_BIN_DIR: G:/cc/gdal_2_1_3/include/../bin
GDAL_INCLUDE_DIR: G:/cc/gdal_2_1_3/include
GDAL_LIBRARY: G:/cc/gdal_2_1_3/lib/gdal_i.lib
(I have only "include" and "lib" directories. "Bin" directory set automatically, but this directory is not on the disk.)
Please, can you advise me where the mistake might be?
Maybe the wrong version of GDAL? (BIN directory is missing.)
Where can I download right version of compiled GDAL?
I can't find it.
I'm testing it with VS2017, I have build CC 2.12.alpha from VS project INSTALL.
If I want build INSTALL project with GDAL support, I have this error:
Code: Select all
MSB3073 The command setlocal:
"C:\Program Files\CMake\bin\cmake.exe" -DBUILD_TYPE=Release -P cmake_install.cmake
if %errorlevel% neq 0 goto :cmEnd
:cmEnd
endlocal & call :cmErrorLevel %errorlevel% & goto :cmDone
:cmErrorLevel
exit /b %1
:cmDone
if %errorlevel% neq 0 goto :VCEnd
:VCEnd byl ukončen s kódem 1.
INSTALL C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\Common7\IDE\VC\VCTargets\Microsoft.CppCommon.targets 138