From 0466fbbfc3e08bc8a1b6679bef607852682d4233 Mon Sep 17 00:00:00 2001 From: reuk Date: Wed, 30 Aug 2023 16:00:29 +0100 Subject: [PATCH] CMake: Add missing docs for LV2URI argument --- docs/CMake API.md | 11 +++++++++++ extras/Build/CMake/JUCEUtils.cmake | 4 ++-- 2 files changed, 13 insertions(+), 2 deletions(-) diff --git a/docs/CMake API.md b/docs/CMake API.md index 2bd1d8f854..d8e581b6de 100644 --- a/docs/CMake API.md +++ b/docs/CMake API.md @@ -508,6 +508,17 @@ attributes directly to these creation functions, rather than adding them later. `AAX_IDENTIFIER` - The bundle ID for the AAX plugin target. Matches the `BUNDLE_ID` by default. +`LV2URI` +- This is a string that acts as a unique identifier for an LV2 plugin. If you make any incompatible + changes to your plugin (remove parameters, reorder parameters, change preset format etc.) you MUST + change this value. LV2 hosts will assume that any plugins with the same URI are interchangeable. + By default, the value of this property will be generated based on the COMPANY_WEBSITE and + PLUGIN_NAME. However, in some circumstances, such as the following, you'll need to override the + default: + - The plugin name contains characters such as spaces that are invalid in a URI; or + - The COMPANY_WEBSITE omits the leading scheme identifier (http://); or + - There's no website associated with the plugin, so you want to use a 'urn:' identifier instead. + `VST_NUM_MIDI_INS` - For VST2 and VST3 plugins that accept midi, this allows you to configure the number of inputs. diff --git a/extras/Build/CMake/JUCEUtils.cmake b/extras/Build/CMake/JUCEUtils.cmake index 8edb0a1e56..16fb97fb38 100644 --- a/extras/Build/CMake/JUCEUtils.cmake +++ b/extras/Build/CMake/JUCEUtils.cmake @@ -1180,9 +1180,9 @@ function(_juce_set_plugin_target_properties shared_code_target kind) get_target_property(JUCE_LV2URI "${shared_code_target}" JUCE_LV2URI) - if(NOT JUCE_LV2URI MATCHES "https?://.*") + if(NOT JUCE_LV2URI MATCHES "https?://.*|urn:.*") message(WARNING - "LV2URI should be well-formed with an 'http' prefix. " + "LV2URI should be well-formed with an 'http' or 'urn' prefix. " "Check the LV2URI argument to juce_add_plugin.") endif()