# Shouldn't bundle identifier be unique per plug-in format?

**URL:** <https://forum.juce.com/t/shouldnt-bundle-identifier-be-unique-per-plug-in-format/19183>\
**Category:** Audio Plugins\
**Created:** [September 21, 2016, 9:57am UTC](https://forum.juce.com/t/shouldnt-bundle-identifier-be-unique-per-plug-in-format/19183 "2016-09-21T09:57:29Z")\
**Posts on this page:** 10\
**Page:** 1

<div class="post-metadata">

**Author:** ![ans](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/ans/32/617_2.png) [@ans](https://forum.juce.com/u/ans)\
**Post date:** [September 21, 2016, 9:57am UTC](https://forum.juce.com/t/shouldnt-bundle-identifier-be-unique-per-plug-in-format/19183/1 "2016-09-21T09:57:30Z")

</div>

If a plug-in project compiles to different formats (AU, VST, …) wouldn’t it be advisable to use a unique bundle identifier per format?

com.company.plugin.vst  
com.company.plugin.vst3  
[com.company.plugin.au](http://com.company.plugin.au)

If the id was used only at the highest application layer (preferences, last used files, etc), a single id would make sense. If it’s used to identify a particular bundle at the system level however, it might be advisable to use unique ids.

Ans insights?

---

<div class="post-metadata">

**Author:** ![pizzafilms](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/pizzafilms/32/562_2.png) [@pizzafilms](https://forum.juce.com/u/pizzafilms)\
**Post date:** [March 3, 2020, 8:59pm UTC](https://forum.juce.com/t/shouldnt-bundle-identifier-be-unique-per-plug-in-format/19183/2 "2020-03-03T20:59:27Z")

</div>

I know this is an old topic, but this would be a great idea. It would certainly help debugging a user’s crash since half the time they have no idea which format they loaded.

---

<div class="post-metadata">

**Author:** ![luzifer](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/luzifer/32/60_2.png) [@luzifer](https://forum.juce.com/u/luzifer)\
**Post date:** [March 3, 2020, 9:05pm UTC](https://forum.juce.com/t/shouldnt-bundle-identifier-be-unique-per-plug-in-format/19183/3 "2020-03-03T21:05:17Z")

</div>

While we are at it: Optionally separate bundle identifiers (and plugin names) for development and release builds would be great too. This way we can actually use our own products for making music.

---

<div class="post-metadata">

**Author:** ![ImJimmi](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/imjimmi/32/10843_2.png) [@ImJimmi](https://forum.juce.com/u/ImJimmi)\
**Post date:** [October 11, 2023, 4:12pm UTC](https://forum.juce.com/t/shouldnt-bundle-identifier-be-unique-per-plug-in-format/19183/4 "2023-10-11T16:12:28Z")

</div>

Is this at all possible now, using CMake?

We’re migrating some old plugins over to JUCE and setting the `BUNDLE_ID` property in CMake, but similar to @ans’s suggestion, the original plugins (not made in JUCE) use a different ID per format. This means when upgrading from the old version to the new version, hosts aren’t recognising it as the same plugin and so users’ projects will break.

I guess a workaround would be to just manually change the `info.plist` entry after they’re built… would that work?

---

<div class="post-metadata">

**Author:** ![anthony-nicholls](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/anthony-nicholls/32/1246_2.png) [@anthony-nicholls](https://forum.juce.com/u/anthony-nicholls)\
**Post date:** [October 11, 2023, 5:04pm UTC](https://forum.juce.com/t/shouldnt-bundle-identifier-be-unique-per-plug-in-format/19183/5 "2023-10-11T17:04:50Z")

</div>

If I search through the AudioPluginDemo Xcode project for “com.JUCE.AudioPluginDemo” I find it is used for the following…

`#define JucePlugin_CFBundleIdentifier`

- The only place I can find where this is used in the codebase is in CoreMidi for creating a new device with a unique ID, I can’t see any reason this needs to be exactly same as the actual bundle ID.

`#define JucePlugin_AAXIdentifier`

- The is required for AAX plugins and is used to give your AAX plugin a unique identifier, you can set this manually using `AAX_IDENTIFIER` in the `juce_add_plugin` CMake function.

`#define JucePlugin_ARAFactoryID` and `#define JucePlugin_ARADocumentArchiveID`

- These appear to be required for ARA plugins, but again you can control these to a degree by setting `ARA_FACTORY_ID` in the `juce_add_plugin` CMake function.

The rest are just the info.plist files.

You might find you can set these using the CMake Property `MACOSX_BUNDLE_GUI_IDENTIFIER`? Alternatively you could try setting the Xcode attribute `PRODUCT_BUNDLE_IDENTIFER` for each of the targets? If this still doesn’t work you could try setting `BUNDLE_ID` to `${PRODUCT_BUNDLE_IDENTIFER}`.

---

<div class="post-metadata">

**Author:** ![ImJimmi](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/imjimmi/32/10843_2.png) [@ImJimmi](https://forum.juce.com/u/ImJimmi)\
**Post date:** [October 12, 2023, 2:23pm UTC](https://forum.juce.com/t/shouldnt-bundle-identifier-be-unique-per-plug-in-format/19183/6 "2023-10-12T14:23:08Z")

</div>

Thanks for the pointers! Sadly this turns out to not be an issue with the bundle IDs - even when I set the BUNDLE\_ID in `juce_add_plugin` to the one used by the legacy plugins they still don’t load.

Digging a little deeper using the Audio Plugin Host example, it appears to fail to load the updated plugins due to [the unique ID’s](https://github.com/juce-framework/JUCE/blob/22df0d2266007bccb25d6ed52b9907f60d04e971/modules/juce_audio_processors/format_types/juce_VST3PluginFormat.cpp#L1412) being different. The JUCE-made plugins include the plugin manufacterer and plugin codes in `info.cid`, but the iPlug-made plugins seem to contain contain something completely different.

---

<div class="post-metadata">

**Author:** ![anthony-nicholls](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/anthony-nicholls/32/1246_2.png) [@anthony-nicholls](https://forum.juce.com/u/anthony-nicholls)\
**Post date:** [October 12, 2023, 2:38pm UTC](https://forum.juce.com/t/shouldnt-bundle-identifier-be-unique-per-plug-in-format/19183/7 "2023-10-12T14:38:43Z")

</div>

Hmm I might be wrong but I think VST3 might possibly have a way to declare old plugins that should be replaced by the new plugin 🤔

---

<div class="post-metadata">

**Author:** ![anthony-nicholls](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/anthony-nicholls/32/1246_2.png) [@anthony-nicholls](https://forum.juce.com/u/anthony-nicholls)\
**Post date:** [October 12, 2023, 2:41pm UTC](https://forum.juce.com/t/shouldnt-bundle-identifier-be-unique-per-plug-in-format/19183/8 "2023-10-12T14:41:46Z")

</div>

Ah what I was thinking of was for replacing VST2 plugins see [`VST3ClientExtensions::getCompatibleClasses()`](https://docs.juce.com/master/structVST3ClientExtensions.html#a6aff4e420cb8536252d02bb3de107d0c) not sure if that can be used to achieve the same result? probably not but that might be a nice quick fix if it can be used.

---

<div class="post-metadata">

**Author:** ![ImJimmi](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/imjimmi/32/10843_2.png) [@ImJimmi](https://forum.juce.com/u/ImJimmi)\
**Post date:** [October 13, 2023, 3:28pm UTC](https://forum.juce.com/t/shouldnt-bundle-identifier-be-unique-per-plug-in-format/19183/9 "2023-10-13T15:28:07Z")

</div>

Yeah sadly that doesn’t seem to work either!

I did find this thread from someone who seemed to be able to fix the problem but annoyingly they never posted what their solution was! [[Solved] How to set unique ID of VST3 plugin dynamically? - VST 3 SDK - Steinberg Forums](https://forums.steinberg.net/t/solved-how-to-set-unique-id-of-vst3-plugin-dynamically/202044)

There was some mention about editing the `DEF_CLASS_IID` macro but I don’t see an obvious way that JUCE expects that so I assume it’s not at all recommended, or even possible?

The FUID appears to be defined here: [https://github.com/juce-framework/JUCE/blob/22df0d2266007bccb25d6ed52b9907f60d04e971/modules/juce\_audio\_plugin\_client/juce\_audio\_plugin\_client\_VST3.cpp#L2487](https://github.com/juce-framework/JUCE/blob/22df0d2266007bccb25d6ed52b9907f60d04e971/modules/juce_audio_plugin_client/juce_audio_plugin_client_VST3.cpp#L2487) which also doesn’t appear to have any way of providing a custom one, it’s very much fixed.

I guess the safest approach at this point would be to install the updated JUCE plugins alongside the existing iPlug ones and just inform users to manually migrate their projects across.

---

<div class="post-metadata">

**Author:** ![anthony-nicholls](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/anthony-nicholls/32/1246_2.png) [@anthony-nicholls](https://forum.juce.com/u/anthony-nicholls)\
**Post date:** [October 13, 2023, 3:36pm UTC](https://forum.juce.com/t/shouldnt-bundle-identifier-be-unique-per-plug-in-format/19183/10 "2023-10-13T15:36:22Z")

</div>

> [@ImJimmi](#):
>
> I guess the safest approach at this point would be to install the updated JUCE plugins alongside the existing iPlug ones and just inform users to manually migrate their projects across.

That might be a tough ask for some customers. You could try hacking JUCE to get there first just to figure out what is absolutely needed then report back and maybe we can see what we might be able to support in the library - no guarantees obviously.

You’ll also need to test in a lot of DAWs. I recall WaveLab used to ignore all the identifiers and just use the filename to recognise if the plugin was the same!
