Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[FEATURE] Allow to overwrite build formats #238

Closed
Bleuzen opened this issue Dec 18, 2021 · 2 comments
Closed

[FEATURE] Allow to overwrite build formats #238

Bleuzen opened this issue Dec 18, 2021 · 2 comments
Assignees
Labels
enhancement New feature or request

Comments

@Bleuzen
Copy link

Bleuzen commented Dec 18, 2021

Is your feature request related to a problem? Please describe.

I want to build only the VST3 and LV2 plugin, not interested in anything else. Can I somehow overwrite the JUCE_FORMATS var to only build those two?

Describe the solution you'd like

Could be an environment variable or cmake configure option to overwrite the formats to build.

Additional context

I try to package this plugin on flathub (linux software repository/app store). There, a package can only either be a desktop application (the standalone) or an extension (for example audio plugin). It is not possible to put both into one package. So for the plugin package, I only want to build VST3 and LV2 and maybe if a separate desktop package will be made later, only Standalone should be built. For that an option to force set build targets / formats would help.

@Bleuzen Bleuzen added the enhancement New feature or request label Dec 18, 2021
@jatinchowdhury18
Copy link
Owner

So with the current CMake setup, when you run the CMake "configure" step (cmake -Bbuild ...), the build system will automatically set up a build target for each plugin format that is available on the that platform. I think I would like to leave this behaviour as-is.

However, when building with CMake, it is possible to specify a single target that you would like to build. For example, to only build the VST3 and LV2 plugins:

cmake --build build --target CHOWTapeModel_VST3 ...
cmake --build build --target CHOWTapeModel_LV2 ...

With most build systems, the second command should run much faster than the first, since any shared dependencies will already have been built.

Or if you only want the standalone plugin:

cmake --build build --target CHOWTapeModel_Standalone ...

Would specifying the desired targets in the build command(s) work for your use case? Or is there a particular reason you would need to include/exclude certain targets at configuration time?

@Bleuzen
Copy link
Author

Bleuzen commented Jan 8, 2022

Thanks, got it working now!

At first it didn't work. Took me some time but turns out that this was caused by flatpak automatically running make install and this leads to all targets being built. With that disabled, the targets work now (even with ninja instead of cmake) :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants