1
0
Fork 0
mirror of https://github.com/juce-framework/JUCE.git synced 2026-01-10 23:44:24 +00:00

CMake: Fix warnings when configuring with --warn-uninitialized

This commit is contained in:
reuk 2024-08-15 13:37:46 +01:00
parent 1f024f9c08
commit cff48fdc63
No known key found for this signature in database
GPG key ID: FCB43929F012EE5C
4 changed files with 14 additions and 5 deletions

View file

@ -159,7 +159,9 @@ endfunction()
function(_juce_get_metadata target key out_var)
get_target_property(content "${target}" "INTERFACE_JUCE_${key}")
if(NOT "${content}" STREQUAL "content-NOTFOUND")
if("${content}" STREQUAL "content-NOTFOUND")
set(${out_var} PARENT_SCOPE)
else()
set(${out_var} "${content}" PARENT_SCOPE)
endif()
endfunction()
@ -450,6 +452,8 @@ function(juce_add_module module_path)
_juce_module_sources("${module_path}" "${base_path}" globbed_sources headers)
set(all_module_sources)
if(${module_name} STREQUAL "juce_audio_plugin_client")
list(REMOVE_ITEM headers
"${module_path}/LV2/juce_LV2ManifestHelper.cpp"

View file

@ -316,7 +316,14 @@ endfunction()
function(_juce_append_record output key)
string(ASCII 30 RS)
string(ASCII 31 US)
set(${output} "${${output}}${key}${US}${ARGN}${RS}" PARENT_SCOPE)
set(prev)
if(DEFINED "${output}")
set(prev "${${output}}")
endif()
set(${output} "${prev}${key}${US}${ARGN}${RS}" PARENT_SCOPE)
endfunction()
function(_juce_append_target_property output key target property)

View file

@ -120,7 +120,6 @@ else()
"-DCMAKE_BUILD_TYPE=Debug"
"-DJUCE_BUILD_HELPER_TOOLS=ON"
"-DCMAKE_INSTALL_PREFIX=${CMAKE_INSTALL_PREFIX}"
${extra_compiler_flag_arguments}
WORKING_DIRECTORY "${JUCE_SOURCE_DIR}"
OUTPUT_VARIABLE command_output
ERROR_VARIABLE command_output