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

Portable VST3 Windows broken now we moved to a bundle #5825

Closed
baconpaul opened this issue Jan 25, 2022 · 2 comments · Fixed by #5988
Closed

Portable VST3 Windows broken now we moved to a bundle #5825

baconpaul opened this issue Jan 25, 2022 · 2 comments · Fixed by #5988
Labels
Bug Report Item submitted using the Bug Report template Infrastructure Issues related to repository, CI/CD, installers, etc. VST3 VST3 plugin related issues
Milestone

Comments

@baconpaul
Copy link
Collaborator

But I'm fixing this. Just tagging an issue in.

@baconpaul baconpaul added the Bug Report Item submitted using the Bug Report template label Jan 25, 2022
@baconpaul baconpaul added this to the Surge XT 1.1 milestone Jan 25, 2022
@mkruselj mkruselj added Infrastructure Issues related to repository, CI/CD, installers, etc. VST3 VST3 plugin related issues labels Jan 25, 2022
baconpaul added a commit to baconpaul/surge that referenced this issue Jan 25, 2022
- Move the old PATHS stuff to sst-plugininfra
- Rework the SurgeStorage resoultion. Closes surge-synthesizer#5097
- Temporarily modify the abuot screen retaining and
  expanding the 1.0 bug in surge-synthesizer#5825
baconpaul added a commit to baconpaul/surge that referenced this issue Jan 25, 2022
- Move the old PATHS stuff to sst-plugininfra
- Rework the SurgeStorage resoultion. Closes surge-synthesizer#5097
- Temporarily modify the abuot screen retaining and
  expanding the 1.0 bug in surge-synthesizer#5825
baconpaul added a commit that referenced this issue Jan 25, 2022
- Move the old PATHS stuff to sst-plugininfra
- Rework the SurgeStorage resoultion. Closes #5097
- Temporarily modify the abuot screen retaining and
  expanding the 1.0 bug in #5825
@baconpaul
Copy link
Collaborator Author

@mkruselj I know you've been poking about for issues to fix and I think this one is actually pretty easy but requires some windows testing

Right now in SurgeStorage we do code like this

 if (auto path{installPath / L"SurgeXTData"}; fs::is_directory(path))
        {
            datapath = std::move(path);
        }

The problem is installPath is now the DLL path. So that's too low. Two choices

  1. We know we are in a bundle so search installPath.parent_path().parent_path() / L"SurgeXTData". Pro - simple. Con - if people unpack the bundle for old daws it breaks
  2. We could recurse up looking. I like this better. So
auto cp{installPath};
while( datapath.empty() && cp.has_parent_path() && cp != cp.parent_path())
{
    auto portable = cp / L"SurgeXTData";
    // probably want to print portable here
    if (fs::is_directory(portable))
    {
       datapath = std::move(portable);
    }
    cp = cp.parent_path()
}

basically climb up the filesystem looking. You can do the same with the user path also just with different names.

Your option. I can also do it when I'm next in windows. In that case these notes will help me then too.

@mkruselj
Copy link
Collaborator

I will give it a shot, thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Report Item submitted using the Bug Report template Infrastructure Issues related to repository, CI/CD, installers, etc. VST3 VST3 plugin related issues
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants