From c2d528810e9878b886c7631a248a3d3de41caaee Mon Sep 17 00:00:00 2001
From: Emmanuel Christophe <emmanuel.christophe@orfeo-toolbox.org>
Date: Fri, 13 Feb 2009 17:11:48 +0800
Subject: [PATCH] COMP: clearing up gdal mess

---
 Examples/FeatureExtraction/CMakeLists.txt | 16 ++++++++--------
 Examples/Learning/CMakeLists.txt          | 22 +++++++++++-----------
 Testing/Code/IO/CMakeLists.txt            |  9 ++++-----
 Testing/Fa/CMakeLists.txt                 |  6 +++---
 4 files changed, 26 insertions(+), 27 deletions(-)

diff --git a/Examples/FeatureExtraction/CMakeLists.txt b/Examples/FeatureExtraction/CMakeLists.txt
index 8ad48228d1..ad2591dd19 100644
--- a/Examples/FeatureExtraction/CMakeLists.txt
+++ b/Examples/FeatureExtraction/CMakeLists.txt
@@ -34,7 +34,7 @@ AssymmetricFusionOfLineDetectorExample.cxx)
 TARGET_LINK_LIBRARIES(AssymmetricFusionOfLineDetectorExample OTBFeatureExtraction OTBCommon OTBIO ITKCommon ITKIO)
 
 ADD_EXECUTABLE(LocalHoughExample LocalHoughExample.cxx )
-TARGET_LINK_LIBRARIES(LocalHoughExample ITKIO OTBIO OTBFeatureExtraction OTBCommon ITKCommon ${GDAL_LIBRARY})
+TARGET_LINK_LIBRARIES(LocalHoughExample ITKIO OTBIO OTBFeatureExtraction OTBCommon ITKCommon)
 
 
 ADD_EXECUTABLE(ExtractSegmentsByStepsExample
@@ -111,7 +111,7 @@ ADD_TEST(CorrelationLineDetectorExampleTest ${EXE_TESTS1}
 	${INPUTDATA}/amst.png
 	${TEMP}/amstLineCorrelations.png
 	${TEMP}/amstLineCorrelationDirections.png
-    5 1 
+    5 1
 )
 
 # ------- LocalHoughExampleTest----------
@@ -150,7 +150,7 @@ ADD_TEST(TouziEdgeDetectorExampleTest ${EXE_TESTS1}
 	${INPUTDATA}/amst.png
 	${TEMP}/amstTouziEdges.png
 	${TEMP}/amstTouziDirections.png
-    3 
+    3
 )
 
 # ------- ExtractSegmentsByStepsExampleTest----------
@@ -174,7 +174,7 @@ ADD_TEST(AssymmetricFusionOfLineDetectorExampleTest ${EXE_TESTS1}
 	AssymmetricFusionOfLineDetectorExampleTest
 	${INPUTDATA}/amst.png
 	${TEMP}/amstLineFusion.png
-    5 1 
+    5 1
 )
 
 # ------- ExtractSegmentsExampleTest----------
@@ -201,7 +201,7 @@ ADD_TEST(RatioLineDetectorExampleTest ${EXE_TESTS1}
 	${INPUTDATA}/amst.png
 	${TEMP}/amstLineRatios.png
 	${TEMP}/amstLineRatioDirections.png
-    5 1 
+    5 1
 )
 
 # ------- AlignmentsExampleTest----------
@@ -285,14 +285,14 @@ ADD_TEST(ScaleInvariantFeatureImageFilterTest ${EXE_TESTS2}
         ${TEMP}/ScaleInvariantFeatureImageFilterOutputKeys1.png
 	${BASELINE}/ScaleInvariantFeatureImageFilterOutputKeys2.png
         ${TEMP}/ScaleInvariantFeatureImageFilterOutputKeys2.png
-	
+
         ScaleInvariantFeatureImageFilterTest
-	
+
         ${INPUTDATA}/Scene.png
         ${TEMP}/ScaleInvariantFeatureImageFilterOutput1.png
         ${TEMP}/ScaleInvariantFeatureImageFilterOutput2.png
         ${TEMP}/ScaleInvariantFeatureImageFilterOutputKeys1.png
-        ${TEMP}/ScaleInvariantFeatureImageFilterOutputKeys2.png	
+        ${TEMP}/ScaleInvariantFeatureImageFilterOutputKeys2.png
 	1 10 0.5 0
 )
 
diff --git a/Examples/Learning/CMakeLists.txt b/Examples/Learning/CMakeLists.txt
index ee7bce2825..9b0e93cf49 100644
--- a/Examples/Learning/CMakeLists.txt
+++ b/Examples/Learning/CMakeLists.txt
@@ -6,37 +6,37 @@ TARGET_LINK_LIBRARIES(GenerateTrainingImageExample OTBCommon OTBIO OTBLearning I
 
 ADD_EXECUTABLE(SVMPointSetExample SVMPointSetExample.cxx )
 TARGET_LINK_LIBRARIES(SVMPointSetExample ITKIO OTBIO OTBCommon
-ITKCommon  OTBLearning  ${GDAL_LIBRARY})
+ITKCommon  OTBLearning)
 
 
 ADD_EXECUTABLE(SVMPointSetModelEstimatorExample SVMPointSetModelEstimatorExample.cxx )
 TARGET_LINK_LIBRARIES(SVMPointSetModelEstimatorExample ITKIO OTBIO
-OTBCommon ITKCommon  OTBLearning  ${GDAL_LIBRARY})
+OTBCommon ITKCommon  OTBLearning)
 
 ADD_EXECUTABLE(SVMImageModelEstimatorExample SVMImageModelEstimatorExample.cxx )
 TARGET_LINK_LIBRARIES(SVMImageModelEstimatorExample ITKIO OTBIO
-OTBCommon ITKCommon  OTBLearning  ${GDAL_LIBRARY})
+OTBCommon ITKCommon  OTBLearning)
 
 ADD_EXECUTABLE(SVMPointSetClassificationExample SVMPointSetClassificationExample.cxx )
 TARGET_LINK_LIBRARIES(SVMPointSetClassificationExample ITKIO OTBIO
-OTBCommon ITKCommon  OTBLearning  ${GDAL_LIBRARY})
+OTBCommon ITKCommon  OTBLearning)
 
 ADD_EXECUTABLE(SVMImageClassificationExample SVMImageClassificationExample.cxx )
 TARGET_LINK_LIBRARIES(SVMImageClassificationExample ITKIO OTBIO
-OTBCommon ITKCommon  OTBLearning  ${GDAL_LIBRARY})
+OTBCommon ITKCommon  OTBLearning)
 
 ADD_EXECUTABLE(SVMImageEstimatorClassificationMultiExample SVMImageEstimatorClassificationMultiExample.cxx )
 TARGET_LINK_LIBRARIES(SVMImageEstimatorClassificationMultiExample ITKIO OTBIO
-OTBCommon ITKCommon  OTBLearning  ${GDAL_LIBRARY})
+OTBCommon ITKCommon  OTBLearning)
 
 ADD_EXECUTABLE(SOMExample SOMExample.cxx )
-TARGET_LINK_LIBRARIES(SOMExample ITKIO OTBIO OTBCommon ITKCommon  OTBLearning  ${GDAL_LIBRARY})
+TARGET_LINK_LIBRARIES(SOMExample ITKIO OTBIO OTBCommon ITKCommon  OTBLearning)
 
 ADD_EXECUTABLE(SOMClassifierExample SOMClassifierExample.cxx )
-TARGET_LINK_LIBRARIES(SOMClassifierExample ITKIO OTBIO OTBCommon ITKCommon  OTBLearning  ${GDAL_LIBRARY})
+TARGET_LINK_LIBRARIES(SOMClassifierExample ITKIO OTBIO OTBCommon ITKCommon  OTBLearning)
 
 ADD_EXECUTABLE(SEMModelEstimatorExample SEMModelEstimatorExample.cxx )
-TARGET_LINK_LIBRARIES(SEMModelEstimatorExample ITKIO OTBIO OTBCommon ITKCommon  OTBLearning  ${GDAL_LIBRARY})
+TARGET_LINK_LIBRARIES(SEMModelEstimatorExample ITKIO OTBIO OTBCommon ITKCommon  OTBLearning)
 
 ADD_EXECUTABLE(SVMGenericKernelImageModelEstimatorExample SVMGenericKernelImageModelEstimatorExample.cxx)
 TARGET_LINK_LIBRARIES(SVMGenericKernelImageModelEstimatorExample OTBLearning OTBCommon OTBIO ITKCommon)
@@ -127,7 +127,7 @@ ADD_TEST(SOMExampleTest ${EXE_TESTS}
 # ------- SOMClassifierExampleTest----------
 
 ADD_TEST(SOMClassifierExampleTest ${EXE_TESTS}
-	--compare-image ${TOL} 
+	--compare-image ${TOL}
 	${BASELINE}/ROI_QB_MUL_extractSOMCLASS.tif
 	${TEMP}/ROI_QB_MUL_extractSOMCLASS.tif
 	SOMClassifierExampleTest
@@ -139,7 +139,7 @@ ADD_TEST(SOMClassifierExampleTest ${EXE_TESTS}
 # ------- SEMModelEstimatorExampleTest----------
 
 ADD_TEST(SEMModelEstimatorExampleTest ${EXE_TESTS}
-#	--compare-image ${TOL} 
+#	--compare-image ${TOL}
 #	${BASELINE}/ROI_QB_MUL_SEMMODEL_ESTIMATOR.png
 #	${TEMP}/ROI_QB_MUL_SEMMODEL_ESTIMATOR.png
 	SEMModelEstimatorExampleTest
diff --git a/Testing/Code/IO/CMakeLists.txt b/Testing/Code/IO/CMakeLists.txt
index 618a99db2b..5443792110 100755
--- a/Testing/Code/IO/CMakeLists.txt
+++ b/Testing/Code/IO/CMakeLists.txt
@@ -1,4 +1,3 @@
-# $Id: CMakeLists.txt 4312 2008-09-26 13:46:16Z guillaume $
 
 IF( NOT OTB_DISABLE_CXX_TESTING AND BUILD_TESTING )
 
@@ -1136,7 +1135,7 @@ ADD_TEST(ioTvImageMetadataWriterTest_TIF ${IO_TESTS11}
         )
 
 
-# Commented because ${GDAL_LIBRARY} does not seems to write the metadata the same way in both formats
+# Commented because gdal does not seems to write the metadata the same way in both formats
 #ADD_TEST(ioTvImageMetadataWriterTest_HFA2TIFF ${IO_TESTS11}
 #   --compare-metadata ${TOL}
 #		      ${INPUTDATA}/HFAGeoreferenced.img
@@ -1146,7 +1145,7 @@ ADD_TEST(ioTvImageMetadataWriterTest_TIF ${IO_TESTS11}
 #	${TEMP}/temp.tif
 #        )
 
-# Commented because ${GDAL_LIBRARY} does not seems to write the metadata the same way in both formats
+# Commented because gdal does not seems to write the metadata the same way in both formats
 #ADD_TEST(ioTvImageMetadataWriterTest_TIFF2HFA ${IO_TESTS11}
 #   --compare-metadata ${TOL}
 #		      ${INPUTDATA}/spot5SubWithGcps.tif
@@ -1175,7 +1174,7 @@ ADD_TEST(ioTvImageMetadataStreamingWriterTest_TIF ${IO_TESTS11}
 	${TEMP}/temp.tif
         )
 
-# Commented because ${GDAL_LIBRARY} does not seems to write the metadata the same way in both formats
+# Commented because gdal does not seems to write the metadata the same way in both formats
 #ADD_TEST(ioTvImageMetadataStreamingWriterTest_HFA2TIFF ${IO_TESTS11}
 #   --compare-metadata ${TOL}
 #		      ${INPUTDATA}/HFAGeoreferenced.img
@@ -1185,7 +1184,7 @@ ADD_TEST(ioTvImageMetadataStreamingWriterTest_TIF ${IO_TESTS11}
 #	${TEMP}/temp.tif
 #        )
 
-# Commented because ${GDAL_LIBRARY} does not seems to write the metadata the same way in both formats
+# Commented because gdal does not seems to write the metadata the same way in both formats
 #ADD_TEST(ioTvImageMetadataStreamingWriterTest_TIFF2HFA ${IO_TESTS11}
 #   --compare-metadata ${TOL}
 #		      ${INPUTDATA}/spot5SubWithGcps.tif
diff --git a/Testing/Fa/CMakeLists.txt b/Testing/Fa/CMakeLists.txt
index 174ac0facd..ec9f545dab 100644
--- a/Testing/Fa/CMakeLists.txt
+++ b/Testing/Fa/CMakeLists.txt
@@ -216,13 +216,13 @@ ADD_TEST(FA-0000041-mean_shift2 ${CXX_TEST_PATH}/0000041-mean_shift
 	)
 
 ADD_EXECUTABLE(AlignementsQB  AlignementsQB.cxx)
-TARGET_LINK_LIBRARIES(AlignementsQB OTBFeatureExtraction OTBIO OTBCommon ${GDAL_LIBRARY} ITKIO ITKCommon)
+TARGET_LINK_LIBRARIES(AlignementsQB OTBFeatureExtraction OTBIO OTBCommon ITKIO ITKCommon)
 
 ADD_EXECUTABLE(MapActivation  MapActivation.cxx)
-TARGET_LINK_LIBRARIES(MapActivation OTBFeatureExtraction OTBIO OTBCommon ${GDAL_LIBRARY} ITKIO ITKCommon)
+TARGET_LINK_LIBRARIES(MapActivation OTBFeatureExtraction OTBIO OTBCommon ITKIO ITKCommon)
 
 ADD_EXECUTABLE(StreamingStat  StreamingStat.cxx)
-TARGET_LINK_LIBRARIES(StreamingStat OTBFeatureExtraction OTBIO OTBCommon ${GDAL_LIBRARY} ITKIO ITKCommon)
+TARGET_LINK_LIBRARIES(StreamingStat OTBFeatureExtraction OTBIO OTBCommon ITKIO ITKCommon)
 
 ADD_EXECUTABLE(0000041-mean_shift  0000041-mean_shift.cxx)
 TARGET_LINK_LIBRARIES(0000041-mean_shift OTBIO OTBCommon OTBBasicFilters)
-- 
GitLab