View Issue Details [ Jump to Notes ] | [ Print ] |
ID | Project | Category | View Status | Date Submitted | Last Update |
0015206 | CMake | CMake | public | 2014-10-14 02:28 | 2015-04-06 09:07 |
|
Reporter | Lorenz Witte | |
Assigned To | Brad King | |
Priority | normal | Severity | major | Reproducibility | always |
Status | closed | Resolution | fixed | |
Platform | | OS | Windows | OS Version | |
Product Version | CMake 3.0.2 | |
Target Version | CMake 3.2 | Fixed in Version | CMake 3.2 | |
|
Summary | 0015206: add_jar() in UseJava.cmake uses wrong classpath seperator when cross-compiling under Windows |
Description | The condition to use ";" as classpath separator includes a check for the switch "WIN32" which is a target switch. When cross-compiling for a non-windows target, this switch is not present and the separator defaults to ":".
I think it should rather check for "CMAKE_HOST_WIN32" instead. |
Steps To Reproduce | Call add_jar() during a cross-compilation on a Windows host. |
Tags | No tags attached. |
|
Attached Files | 0001-fixed-classpath-separator-on-WIN32-cross-compilation.patch [^] (891 bytes) 2014-10-14 02:28 [Show Content] [Hide Content]From e25c14717528f86b842497831d3e76e3ac98feb6 Mon Sep 17 00:00:00 2001
From: Lorenz Witte <lorenz.witte@de.neusoft.com>
Date: Tue, 14 Oct 2014 08:15:39 +0200
Subject: [PATCH] fixed classpath separator on WIN32 cross compilation
Change-Id: Ia71475f84c4a1298f63760144e27d8c7f8c9ced3
---
Modules/UseJava.cmake | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/Modules/UseJava.cmake b/Modules/UseJava.cmake
index 127012f..3a6acd8 100644
--- a/Modules/UseJava.cmake
+++ b/Modules/UseJava.cmake
@@ -398,7 +398,7 @@ function(add_jar _TARGET_NAME)
${CMAKE_JAVA_LIBRARY_OUTPUT_PATH}
)
- if (WIN32 AND NOT CYGWIN AND CMAKE_HOST_SYSTEM_NAME MATCHES "Windows")
+ if (CMAKE_HOST_WIN32 AND NOT CYGWIN AND CMAKE_HOST_SYSTEM_NAME MATCHES "Windows")
set(CMAKE_JAVA_INCLUDE_FLAG_SEP ";")
else ()
set(CMAKE_JAVA_INCLUDE_FLAG_SEP ":")
--
1.9.1
|
|