# Building VST/AU/AAX in the same project

**URL:** <https://forum.juce.com/t/building-vst-au-aax-in-the-same-project/22698>\
**Category:** Audio Plugins\
**Created:** [May 31, 2017, 11:24am UTC](https://forum.juce.com/t/building-vst-au-aax-in-the-same-project/22698 "2017-05-31T11:24:01Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![FadiBitar](https://avatars.discourse-cdn.com/v4/letter/f/3da27b/32.png) [@FadiBitar](https://forum.juce.com/u/FadiBitar)\
**Post date:** [May 31, 2017, 11:24am UTC](https://forum.juce.com/t/building-vst-au-aax-in-the-same-project/22698/1 "2017-05-31T11:24:01Z")

</div>

Hi,

I’m trying to port over my plugin code from JUCE 2 to JUCE 5.  
My VS solution is set up such that my code is in a single project which builds a single DLL (with all three formats), followed by a post-build event that creates the AAX packages and copies is to a file with the aaxplugin extension.  
The build fails (only when requesting AAX) with a “DllMain already defined” error.

As a test of sorts, I took a stab at modifying the Audio Plugin Demo (from the provided examples) to build AAX (which it doesn’t do by default), and noticed that the Projucer adds a separate project to the solution which is meant solely for building the AAX plugin, while the JuceDemoPlugin\_VST project builds the VST/AU formats.

Am I to conclude that JUCE now makes it a requirement to set up a separate project to build the AAX format plugin, or is there a way to build all three formats out of a single VS project?

Cheers!  
/Fadi

---

<div class="post-metadata">

**Author:** ![fr810](https://sea2.discourse-cdn.com/flex026/user_avatar/forum.juce.com/fr810/32/841_2.png) [@fr810](https://forum.juce.com/u/fr810)\
**Post date:** [May 31, 2017, 11:52am UTC](https://forum.juce.com/t/building-vst-au-aax-in-the-same-project/22698/2 "2017-05-31T11:52:53Z")

</div>

Hi @FadiBitar,

JUCE now adds a separate VS project for each plug-in type. So if you are building VST/VST3/AAX then there will be three plug-in projects in your solution (for the VST/VST3/AAX specific plug-in code) and a “SharedCode” project which is all the code that is not plug-in specific.

This kind of setup is needed as plug-in formats are not necessarily simple dlls anymore. For example, AUv3 is an app extension which is basically a special type of executable. This also allowed us to add a handy “Standalone” plug-in format, which builds your plug-in as a standalone application.

> [@FadiBitar](#):
>
> Am I to conclude that JUCE now makes it a requirement to set up a separate project to build the AAX format plugin, or is there a way to build all three formats out of a single VS project?

Yes, you are right. However, the Projucer should do that work for you: it will automatically create a solution containing the necessary projects.

Fabian

---

<div class="post-metadata">

**Author:** ![FadiBitar](https://avatars.discourse-cdn.com/v4/letter/f/3da27b/32.png) [@FadiBitar](https://forum.juce.com/u/FadiBitar)\
**Post date:** [May 31, 2017, 12:28pm UTC](https://forum.juce.com/t/building-vst-au-aax-in-the-same-project/22698/3 "2017-05-31T12:28:18Z")

</div>

Thanks for the help! I’ll get to it then!
