Commit 0f8c3cfa authored by Julien Malik's avatar Julien Malik

ENH: isolate Curl in UtilitiesAdapters

parent ef5950f0
......@@ -50,6 +50,7 @@ SET(OTB_INCLUDE_DIRS_BUILD_TREE ${OTB_INCLUDE_DIRS_BUILD_TREE}
${OTB_SOURCE_DIR}/Code/SARPolarimetry
${OTB_SOURCE_DIR}/Code/SpatialReasoning
${OTB_SOURCE_DIR}/Code/Testing
${OTB_SOURCE_DIR}/Code/UtilitiesAdapters/CurlAdapters
${OTB_SOURCE_DIR}/Code/UtilitiesAdapters/OssimAdapters
${OTB_SOURCE_DIR}/Code/Visu
${OTB_SOURCE_DIR}/Code/Visualization
......@@ -315,6 +316,7 @@ SET(OTB_INCLUDE_RELATIVE_DIRS ${OTB_INCLUDE_RELATIVE_DIRS}
Fusion
GeospatialAnalysis
Testing
UtilitiesAdapters/CurlAdapters
UtilitiesAdapters/OssimAdapters
OBIA
Fuzzy
......
......@@ -29,7 +29,7 @@ ADD_LIBRARY(OTBIO ${OTBIO_SRCS})
# PROPERTIES
# LINK_INTERFACE_LIBRARIES ""
# )
TARGET_LINK_LIBRARIES (OTBIO ${TIFF_LIBRARY} ${GEOTIFF_LIBRARY} ${GDAL_LIBRARY} ${OGR_LIBRARY} ${JPEG_LIBRARY} OTBCommon OTBBasicFilters)
TARGET_LINK_LIBRARIES (OTBIO ${TIFF_LIBRARY} ${GEOTIFF_LIBRARY} ${GDAL_LIBRARY} ${OGR_LIBRARY} ${JPEG_LIBRARY} OTBCommon OTBBasicFilters OTBCurlAdapters)
TARGET_LINK_LIBRARIES (OTBIO ITKIO ITKCommon otbkml tinyXML)
IF (OTB_USE_LIBLAS)
......@@ -44,9 +44,6 @@ IF( OTB_COMPILE_JPEG2000 )
TARGET_LINK_LIBRARIES (OTBIO otbopenjpeg)
ENDIF( OTB_COMPILE_JPEG2000 )
IF( OTB_USE_CURL )
TARGET_LINK_LIBRARIES (OTBIO ${CURL_LIBRARY})
ENDIF( OTB_USE_CURL )
IF(OTB_LIBRARY_PROPERTIES)
SET_TARGET_PROPERTIES(OTBIO PROPERTIES ${OTB_LIBRARY_PROPERTIES})
ENDIF(OTB_LIBRARY_PROPERTIES)
......
......@@ -54,7 +54,7 @@ bool PlaceNameToLonLat::Evaluate()
std::ostringstream urlStream;
urlStream << "http://maps.google.com/maps?q=";
urlStream << m_PlaceName;
urlStream << "&sll=38.9594, -95.2655&sspn=119.526, 360&output=kml&ie=utf-8&v=2.2&cv=4.2.0180.1134&hl=en";
urlStream << "&sll=38.9594,-95.2655&sspn=119.526,360&output=kml&ie=utf-8&v=2.2&cv=4.2.0180.1134&hl=en";
RetrieveXML(urlStream);
ParseXMLGoogle();
}
......
......@@ -810,7 +810,6 @@ void TileMapImageIO::FillCacheFaults(void* buffer) const
void TileMapImageIO::SetCacheDirectory(const char* _arg)
{
std::cout<<"TileMapImageIO::SetCacheDirectory"<<std::endl;
if (_arg && (_arg == this->m_CacheDirectory))
{
return;
......
......@@ -7,9 +7,7 @@ ENDIF( NOT OTB_USE_CURL )
ADD_LIBRARY(OTBProjections ${OTBProjections_SRCS})
TARGET_LINK_LIBRARIES(OTBProjections OTBIO)
IF( OTB_USE_CURL )
TARGET_LINK_LIBRARIES (OTBProjections ${CURL_LIBRARY} tinyXML)
ENDIF( OTB_USE_CURL )
IF(OTB_LIBRARY_PROPERTIES)
SET_TARGET_PROPERTIES(OTBProjections PROPERTIES ${OTB_LIBRARY_PROPERTIES})
ENDIF(OTB_LIBRARY_PROPERTIES)
......
ADD_SUBDIRECTORY(CurlAdapters)
ADD_SUBDIRECTORY(OssimAdapters)
# Sources of non-templated classes.
FILE(GLOB OTBCurlAdapters_SRCS "*.cxx" )
ADD_LIBRARY(OTBCurlAdapters ${OTBCurlAdapters_SRCS})
TARGET_LINK_LIBRARIES (OTBCurlAdapters ITKCommon ${CURL_LIBRARY})
IF(OTB_LIBRARY_PROPERTIES)
SET_TARGET_PROPERTIES(OTBCurlAdapters PROPERTIES ${OTB_LIBRARY_PROPERTIES})
ENDIF(OTB_LIBRARY_PROPERTIES)
IF(NOT OTB_INSTALL_NO_LIBRARIES)
INSTALL(TARGETS OTBCurlAdapters
RUNTIME DESTINATION ${OTB_INSTALL_BIN_DIR_CM24} COMPONENT RuntimeLibraries
LIBRARY DESTINATION ${OTB_INSTALL_LIB_DIR_CM24} COMPONENT RuntimeLibraries
ARCHIVE DESTINATION ${OTB_INSTALL_LIB_DIR_CM24} COMPONENT Development)
ENDIF(NOT OTB_INSTALL_NO_LIBRARIES)
# Note: no txx allowed here
IF(NOT OTB_INSTALL_NO_DEVELOPMENT)
FILE(GLOB __files1 "${CMAKE_CURRENT_SOURCE_DIR}/*.h")
INSTALL(FILES ${__files1}
DESTINATION ${OTB_INSTALL_INCLUDE_DIR_CM24}/UtilitiesAdapters/CurlAdapters
COMPONENT Development)
ENDIF(NOT OTB_INSTALL_NO_DEVELOPMENT)
......@@ -266,7 +266,7 @@ TARGET_LINK_LIBRARIES(otbIOExamplesTests1 OTBIO OTBCommon OTBTesting)
IF( OTB_USE_CURL )
ADD_EXECUTABLE(otbIOExamplesTests2 otbIOExamplesTests2.cxx)
TARGET_LINK_LIBRARIES(otbIOExamplesTests2 OTBCommon OTBIO ${CURL_LIBRARY} OTBTesting)
TARGET_LINK_LIBRARIES(otbIOExamplesTests2 OTBCommon OTBIO OTBTesting)
ENDIF( OTB_USE_CURL )
IF(OTB_USE_LIBLAS)
......
......@@ -21,10 +21,10 @@ TARGET_LINK_LIBRARIES(OrthoRectificationExample OTBProjections OTBCommon OTBIO)
IF( OTB_USE_CURL )
ADD_EXECUTABLE(PlaceNameToLonLatExample PlaceNameToLonLatExample.cxx )
TARGET_LINK_LIBRARIES(PlaceNameToLonLatExample OTBProjections OTBCommon OTBIO ${CURL_LIBRARY} tinyXML)
TARGET_LINK_LIBRARIES(PlaceNameToLonLatExample OTBProjections OTBCommon OTBIO )
ADD_EXECUTABLE(CoordinateToNameExample CoordinateToNameExample.cxx )
TARGET_LINK_LIBRARIES(CoordinateToNameExample OTBProjections OTBCommon OTBIO ${CURL_LIBRARY} tinyXML)
TARGET_LINK_LIBRARIES(CoordinateToNameExample OTBProjections OTBCommon OTBIO )
ENDIF( OTB_USE_CURL )
......@@ -164,7 +164,7 @@ TARGET_LINK_LIBRARIES(otbProjectionsExamplesTests OTBCommon OTBIO OTBProjections
IF( OTB_USE_CURL )
ADD_EXECUTABLE(otbProjectionsExamplesTests2 otbProjectionsExamplesTests2.cxx)
TARGET_LINK_LIBRARIES(otbProjectionsExamplesTests2 OTBCommon OTBIO OTBProjections ${CURL_LIBRARY} tinyXML OTBTesting)
TARGET_LINK_LIBRARIES(otbProjectionsExamplesTests2 OTBCommon OTBIO OTBProjections OTBTesting)
ENDIF( OTB_USE_CURL )
......
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