RomanKubiak / ctrlr

Ctrlr
BSD 3-Clause "New" or "Revised" License
511 stars 59 forks source link

`CMakeLists.txt` should not reference user-specific homedir paths #603

Open felipesanches opened 7 months ago

felipesanches commented 7 months ago

I started by trying to build from git and got this error message:

Screenshot from 2024-02-03 12-44-48

Then I noticed the user-specific path /home/kbar. And later I found all of these on CMakeLists.txt as well: Screenshot from 2024-02-03 12-46-41

Ted-juh commented 7 months ago

Weird, I didn't have that problem with CMake. You can change the Vst2 paths in the CMakeLists.txt file to C:/your repository path/Source/Misc/vst2sdk then it should find the right Vst2 folder.

felipesanches commented 7 months ago

You can change the Vst2 paths in the CMakeLists.txt file to C:/your repository

Indeed, I surely can! But the reason I opened this issue was not to look for a quick fix to my build, but instead to have a general fix for everybody. Otherwise, many future users will likely face the same problem again and again.

Ted-juh commented 7 months ago

Good point about that changes should be made for "everybody". The problem is that we don't have access to "this" repository to update it. The altered CMakesLists.txt version should be on another fork.

Please tell me if it builds if you changed the folder names. Because when I compare my CMakeLists.txt to the one in this repository, I'm missing a lot.

Audio plugin settings from this repository:

juce_add_plugin(ctrlr PLUGIN_MANUFACTURER_CODE Atom PLUGIN_CODE Ctrl FORMATS VST3 VST AU Standalone PRODUCT_NAME "ctrlr" ICON_BIG "Source/Resources/Icons/ctrlr_logo.svg" ICON_SMALL "Source/Resources/Icons/ctrlr_logo.svg")

My CMakeLists.txt audio_plugin_settings:

jucer_audio_plugin_settings( PLUGIN_FORMATS "VST3" "AU" "AUv3" "Standalone" "VST (Legacy)" PLUGIN_CHARACTERISTICS "Plugin is a Synth" "Plugin MIDI Input" "Plugin MIDI Output" "MIDI Effect Plugin" "Plugin Editor Requires Keyboard Focus" PLUGIN_NAME "Ctrlr" PLUGIN_DESCRIPTION "Ctrlr" PLUGIN_MANUFACTURER "Instigator" PLUGIN_MANUFACTURER_CODE "inSt" PLUGIN_CODE "cTrl" // PLUGIN_CHANNEL_CONFIGURATIONS PLUGIN_AAX_IDENTIFIER "com.instigator.Ctrlr" PLUGIN_AU_EXPORT_PREFIX "" PLUGIN_AU_MAIN_TYPE "" PLUGIN_VST_NUM_MIDI_INPUTS "16" PLUGIN_VST_NUM_MIDI_OUTPUTS "16" PLUGIN_VST3_CATEGORY "Instrument" "Synth" // PLUGIN_RTAS_CATEGORY PLUGIN_AAX_CATEGORY "AAX_ePlugInCategory_Dynamics" PLUGIN_VST_LEGACY_CATEGORY "kPlugCategSynth" )

I made my CMakeListst.txt with a project called FRUT. That project was started before Juce came with its CMake API, keep in mind that it's far from an "official" way to make a CMakeLists.txt file. But it builds the build folder, generates .sln files for Visual Studio, and compiles the project like it should, you don't hear me complain.

2nd thought. The CMakeLists.txt file in this repository also precedes Juce's CMake API. I tried to make a CMakeLists.txt file according to that API but it's Juce. Complicated, we give you three sentences, figure out the rest of the three-page manual yourself.