From d16760202f2ee03a4c88040fe02bfe51db8fb73b Mon Sep 17 00:00:00 2001
From: Christophe Palmann <christophe.palmann@c-s.fr>
Date: Fri, 20 Mar 2015 09:58:05 +0100
Subject: [PATCH] ENH: OTBModuleHeaderTest.cmake, dummy removed

---
 CMake/OTBModuleHeaderTest.cmake          | 2 +-
 Utilities/Maintenance/BuildHeaderTest.py | 6 +++++-
 2 files changed, 6 insertions(+), 2 deletions(-)

diff --git a/CMake/OTBModuleHeaderTest.cmake b/CMake/OTBModuleHeaderTest.cmake
index 90e9369f0b..484f0a8ff6 100644
--- a/CMake/OTBModuleHeaderTest.cmake
+++ b/CMake/OTBModuleHeaderTest.cmake
@@ -21,7 +21,7 @@ add_custom_target( OTBHeaderTests
 
 
 
-SET(BANNED_HEADERS 'dummy')
+SET(BANNED_HEADERS)
 if(NOT OTB_USE_OPENCV)
 	SET(BANNED_HEADERS "${BANNED_HEADERS} otbDecisionTreeMachineLearningModelFactory.h otbDecisionTreeMachineLearningModel.h otbKNearestNeighborsMachineLearningModelFactory.h otbKNearestNeighborsMachineLearningModel.h otbRandomForestsMachineLearningModelFactory.h otbRandomForestsMachineLearningModel.h otbSVMMachineLearningModelFactory.h otbSVMMachineLearningModel.h otbGradientBoostedTreeMachineLearningModelFactory.h otbGradientBoostedTreeMachineLearningModel.h otbBoostMachineLearningModelFactory.h otbBoostMachineLearningModel.h otbNeuralNetworkMachineLearningModelFactory.h otbNeuralNetworkMachineLearningModel.h otbNormalBayesMachineLearningModelFactory.h otbNormalBayesMachineLearningModel.h otbRequiresOpenCVCheck.h")
 endif()
diff --git a/Utilities/Maintenance/BuildHeaderTest.py b/Utilities/Maintenance/BuildHeaderTest.py
index d98035598c..d71c66c1fc 100644
--- a/Utilities/Maintenance/BuildHeaderTest.py
+++ b/Utilities/Maintenance/BuildHeaderTest.py
@@ -81,7 +81,11 @@ def main():
     module_binary_path = sys.argv[3]
     maximum_number_of_headers = int(sys.argv[4])
     test_num           = int(sys.argv[5])
-    BANNED_HEADERS = sys.argv[6].split(' ')
+
+    if len(sys.argv) == 7:
+        BANNED_HEADERS = sys.argv[6].split(' ')
+    else:
+        BANNED_HEADERS = []
 
     # Get all the header files.
     include_dir = os.path.join(module_source_path, 'include')
-- 
GitLab