Binary locations misunderstood (winVS2017)

Hi, was having difficulty with the VST binary location names

$(ProgramW6432)\vstplugins appears to work fine for me

NOT the given %commonProgramW6432% as VS has no idea what that is.

Are you talking about the default copy locations in the Projucer? It uses ProgramW6432 as the root default, are you perhaps using an older version of JUCE?

I’m using Juce 5.2.0 (25th Oct 2017) When I click it, it all disappears rather than letting me edit that text. It appears the AAX has common and vst has the other, either way the %% make no sense.

The surrounding % indicates that it’s an expandable environment variable - VS will expand %ProgramW6432% to C:\Program Files and %CommonProgramW6432% to C:\Program Files\Common Files and it will work on 32- and 64-bit architectures. These are the default locations that VST and AAX plug-ins should go in but you can edit it to use a custom location.

It doesn’t expand on my system, probably for some mad reason.
$(ProgramW6432) does work though, like I said.

Are you using XP? It should be supported from Windows 7 onward…

Windows 10.

OK %ProgramW6432% only depends on the current machine, it never changes if you use a different target. So a win32 it will overwrite the 64 bit plug-in.

Can the Projucer be made to target both 32 and 64 bit builds with different target locations in the future please? Current we only have the choice of one!

Yes, I’ll make it so that the default copy locations correspond to the target architecture.

Bu then if I wanted to make a 32 bit version, I have to be careful as it will overwrite the 64 bit version. Plus every time I use the Projucer I have to make the 32 bit version again in the Configuration Manager. This is a pain, and mistakes will happen, also, I wonder why it’s not part of the Producer setup.

No, this will ensure that the copy location matches the target architecture for the build configuration - so if you are building your plugin for 32-bit architecture it will be copied to Program Files (x86) and if you are building for 64-bit it will be copied to Program Files.

At the end of the day the default plugin binary copy locations are just that - default - you can override them and copy your plugin binaries to wherever you like if you want more customisation.

The build architecture is based on the machine it’s compiling on, not any settings. I’m not using a Mac with an emulator that can change architecture.
The file WILL be copied to the 64 bit location no matter what I set the compiler to.
That’s why I’m asking for the Projucer to provide different options.

This change ensures that the copy location corresponds to the target architecture of your build config, set in the Projucer with this option:

Is this not what you meant?

It does not do that, the environment variable stays the same when using Win32. So the file ALWAYS gets copied to the 64 bit location.
Type ‘echo %ProgramW6432%’ in a command prompt and you’ll see the location as “C:\Program Files”.

If you rebuild the Projucer with after pulling in the changes that I posted above and then change the architecture of your build configuration in the Projucer as shown above you will see that the default prefix changes from %ProgramW6432%/%CommonProgramW6432% for 64-bit arch to %programfiles(x86)%/%CommonProgramFiles(x86)% for 32-bit arch. This will expand to Program Files and Program Files (x86) respectively on a 64-bit machine.

So this is wrong is it? I have to put the word ‘Steinberg’ in there do I?

Only the default setting will change with the architecture. I can see from the screenshot that you have overridden the VST Binary Location setting with %ProgramW6432%\vstplugins so it won’t change. Try deleting the text and it will be greyed out like so:

This means that the default setting is being used which will now change with the target architecture.

Oh, but it implies that you search for the string %ProgramW6432% and replace it with the correct folder. Can you do that please? Unsurprisingly I don’t want them to go in a Steinberg folder, like many people I don’t use Cubase et al.
You provided the choice and took away any convenience it holds.
edit - it’s also very confusing.

No, the environment variables will be expanded by Visual Studio, not the Projucer. And the default VST copy location uses the Steinberg folder because this is the recommended location for VST plugins that pretty much all DAWs will use when searching for VSTs. If you want to use a folder other than the default, then you can just override the setting.