mirror of
https://github.com/wpilibsuite/allwpilib
synced 2026-06-19 00:41:43 +00:00
[build] Fix CMake add_source_jar() OUTPUT_DIR warnings (#8778)
``` CMake Warning (dev) at /usr/share/cmake/Modules/UseJava.cmake:716 (cmake_parse_arguments): The OUTPUT_DIR keyword was followed by an empty string or no value at all. Policy CMP0174 is not set, so cmake_parse_arguments() will unset the _add_jar_OUTPUT_DIR variable rather than setting it to an empty string. Call Stack (most recent call first): cmake/modules/CreateSourceJar.cmake:29:EVAL:1 (add_jar) cmake/modules/CreateSourceJar.cmake:29 (cmake_language) wpiannotations/CMakeLists.txt:29 (add_source_jar) This warning is for project developers. Use -Wno-dev to suppress it. CMake Warning (dev) at /usr/share/cmake/Modules/UseJava.cmake:716 (cmake_parse_arguments): The OUTPUT_DIR keyword was followed by an empty string or no value at all. Policy CMP0174 is not set, so cmake_parse_arguments() will unset the _add_jar_OUTPUT_DIR variable rather than setting it to an empty string. Call Stack (most recent call first): cmake/modules/CreateSourceJar.cmake:29:EVAL:1 (add_jar) cmake/modules/CreateSourceJar.cmake:29 (cmake_language) wpiunits/CMakeLists.txt:25 (add_source_jar) This warning is for project developers. Use -Wno-dev to suppress it. ```
This commit is contained in:
@@ -28,6 +28,7 @@ if(WITH_JAVA_SOURCE)
|
||||
${CMAKE_CURRENT_SOURCE_DIR}/src/main/java
|
||||
${CMAKE_CURRENT_SOURCE_DIR}/src/generated/main/java
|
||||
OUTPUT_NAME wpiunits-sources
|
||||
OUTPUT_DIR ${WPILIB_BINARY_DIR}/${java_lib_dest}
|
||||
)
|
||||
set_property(TARGET wpiunits_src_jar PROPERTY FOLDER "java")
|
||||
|
||||
|
||||
Reference in New Issue
Block a user