ENH: use correct args for test of java
This commit is contained in:
parent
74b3924edd
commit
dfd275b8f9
|
@ -659,7 +659,7 @@ IF(BUILD_TESTING)
|
||||||
|
|
||||||
INCLUDE(FindJava)
|
INCLUDE(FindJava)
|
||||||
IF(JAVA_COMPILE AND JAVA_RUNTIME AND JAVA_ARCHIVE)
|
IF(JAVA_COMPILE AND JAVA_RUNTIME AND JAVA_ARCHIVE)
|
||||||
EXEC_PROGRAM(${CMAKE_Java_COMPILER} -version OUTPUT_VARIABLE OUT)
|
EXEC_PROGRAM(${JAVA_COMPILE} ARGS -version OUTPUT_VARIABLE OUT)
|
||||||
IF(OUT MATCHES "invalid flag")
|
IF(OUT MATCHES "invalid flag")
|
||||||
MESSAGE("This java does not even know what version it is!")
|
MESSAGE("This java does not even know what version it is!")
|
||||||
ELSE(OUT MATCHES "invalid flag")
|
ELSE(OUT MATCHES "invalid flag")
|
||||||
|
|
Loading…
Reference in New Issue