Commit 3783bac9 authored by Rashad Kanavath's avatar Rashad Kanavath
Browse files

SuperBuild: gdal use same dir for src and build because autoconf

parent 2100729c
......@@ -33,18 +33,18 @@ else()
PREFIX GDAL
URL "http://download.osgeo.org/gdal/1.11.2/gdal-1.11.2.tar.gz"
URL_MD5 866a46f72b1feadd60310206439c1a76
BINARY_DIR ${GDAL_SB_BUILD_DIR}
SOURCE_DIR ${GDAL_SB_SRC}
BINARY_DIR ${GDAL_SB_SRC}
INSTALL_DIR ${SB_INSTALL_PREFIX}
DOWNLOAD_DIR ${DOWNLOAD_LOCATION}
DEPENDS ${GDAL_DEPENDENCIES}
PATCH_COMMAND ${CMAKE_COMMAND} -E touch ${GDAL_SB_SRC}/config.rpath
COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_SOURCE_DIR}/patches/GDAL/GNUmakefile ${GDAL_SB_SRC}/swig/python/GNUmakefile
COMMAND ${CMAKE_COMMAND} -E copy_directory ${CMAKE_SOURCE_DIR}/patches/GDAL/S2_patch ${GDAL_SB_SRC}
COMMAND ${CMAKE_COMMAND} -E copy_directory ${GDAL_SB_SRC} ${GDAL_SB_BUILD_DIR}
CONFIGURE_COMMAND
# use 'env' because CTest launcher doesn't perform shell interpretation
${SB_ENV_CONFIGURE_CMD}
${GDAL_SB_BUILD_DIR}/configure
${GDAL_SB_SRC}/configure
--prefix=${SB_INSTALL_PREFIX}
--enable-static=no
--without-ogdi
......@@ -60,8 +60,6 @@ else()
INSTALL_COMMAND $(MAKE) install
)
FIX_RPATH_FOR_AUTOCONF_BUILD(GDAL "libgdal*.dylib")
else(MSVC)
##add libkml
##https://trac.osgeo.org/gdal/ticket/5725
......@@ -77,17 +75,16 @@ else()
URL "http://download.osgeo.org/gdal/1.11.2/gdal-1.11.2.tar.gz"
URL_MD5 866a46f72b1feadd60310206439c1a76
SOURCE_DIR ${GDAL_SB_SRC}
BINARY_DIR ${GDAL_SB_BUILD_DIR}
BINARY_DIR ${GDAL_SB_SRC}
INSTALL_DIR ${SB_INSTALL_PREFIX}
DOWNLOAD_DIR ${DOWNLOAD_LOCATION}
DEPENDS ${GDAL_DEPENDENCIES}
PATCH_COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_SOURCE_DIR}/patches/GDAL/GNUmakefile ${GDAL_SB_SRC}/swig/python/GNUmakefile
COMMAND ${CMAKE_COMMAND} -E copy_directory ${CMAKE_SOURCE_DIR}/patches/GDAL/S2_patch ${GDAL_SB_SRC}
COMMAND ${CMAKE_COMMAND} -E copy_directory ${GDAL_SB_SRC} ${GDAL_SB_BUILD_DIR}
CONFIGURE_COMMAND ${CMAKE_COMMAND} -E copy ${CMAKE_SOURCE_DIR}/patches/GDAL/ogrsqlitevirtualogr.cpp
${GDAL_SB_BUILD_DIR}/ogr/ogrsf_frmts/sqlite/ogrsqlitevirtualogr.cpp
BUILD_COMMAND nmake /f ${GDAL_SB_BUILD_DIR}/makefile.vc MSVC_VER=${MSVC_VERSION} EXT_NMAKE_OPT=${CMAKE_BINARY_DIR}/nmake_gdal_extra.opt
INSTALL_COMMAND nmake /f ${GDAL_SB_BUILD_DIR}/makefile.vc devinstall MSVC_VER=${MSVC_VERSION} EXT_NMAKE_OPT=${CMAKE_BINARY_DIR}/nmake_gdal_extra.opt
${GDAL_SB_SRC}/ogr/ogrsf_frmts/sqlite/ogrsqlitevirtualogr.cpp
BUILD_COMMAND nmake /f ${GDAL_SB_SRC}/makefile.vc MSVC_VER=${MSVC_VERSION} EXT_NMAKE_OPT=${CMAKE_BINARY_DIR}/nmake_gdal_extra.opt
INSTALL_COMMAND nmake /f ${GDAL_SB_SRC}/makefile.vc devinstall MSVC_VER=${MSVC_VERSION} EXT_NMAKE_OPT=${CMAKE_BINARY_DIR}/nmake_gdal_extra.opt
)
endif()
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment