Blame SOURCES/0051-Support-test-suite-output-files-for-multiple-Java-ve.patch

6d9473
From f805a19f8770bf051fa741558b10928fc612e01b Mon Sep 17 00:00:00 2001
6d9473
From: Jakub Filak <jfilak@redhat.com>
6d9473
Date: Wed, 29 Oct 2014 18:11:29 +0100
6d9473
Subject: [PATCH] Support test suite output files for multiple Java versions
6d9473
6d9473
Related to #42
6d9473
6d9473
Conflicts:
6d9473
	test/CMakeLists.txt
6d9473
---
6d9473
 test/CMakeLists.txt         | 3 +++
6d9473
 test/outputs/CMakeLists.txt | 4 ++++
6d9473
 2 files changed, 7 insertions(+)
6d9473
6d9473
diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt
6d9473
index 5bb2b2d..b7818d6 100644
6d9473
--- a/test/CMakeLists.txt
6d9473
+++ b/test/CMakeLists.txt
6d9473
@@ -5,6 +5,9 @@ set(SERVER_URL "http://localhost")
6d9473
 
6d9473
 find_package(Java REQUIRED)
6d9473
 
6d9473
+set(JAVA_TESTOUTPUT_VER java-${Java_VERSION_MAJOR}.${Java_VERSION_MINOR})
6d9473
+message("Requires testsuite ver: ${JAVA_TESTOUTPUT_VER}")
6d9473
+
6d9473
 subdirs(outputs)
6d9473
 
6d9473
 function(_get_target_names variable)
6d9473
diff --git a/test/outputs/CMakeLists.txt b/test/outputs/CMakeLists.txt
6d9473
index ede3758..0ab44f2 100644
6d9473
--- a/test/outputs/CMakeLists.txt
6d9473
+++ b/test/outputs/CMakeLists.txt
6d9473
@@ -14,5 +14,9 @@ foreach(infileName ${inFiles})
6d9473
         set(infile "${CMAKE_CURRENT_SOURCE_DIR}/${infileName}")
6d9473
     endif()
6d9473
 
6d9473
+    if(EXISTS "${infile}.${JAVA_TESTOUTPUT_VER}")
6d9473
+        set(infile "${infile}.${JAVA_TESTOUTPUT_VER}")
6d9473
+    endif()
6d9473
+
6d9473
     configure_file("${infile}" "${outfile}")
6d9473
 endforeach(infileName)
6d9473
-- 
6d9473
1.8.3.1
6d9473