mirror of
https://github.com/robbert-vdh/yabridge.git
synced 2026-05-07 03:50:11 +02:00
Change prefix detection to be relative to the .dll
This commit is contained in:
@@ -22,6 +22,8 @@ Versioning](https://semver.org/spec/v2.0.0.html).
|
||||
symlinking plugins. Now you can use a symlink to a copy of `libyabridge.so`
|
||||
that's installed for a plugin in another directory. This is not recommended
|
||||
though. Fixes #3.
|
||||
- Changed Wine prefix detection to be relative to the plugin's `.dll` file,
|
||||
rather than the loaded `.so` file.
|
||||
- Clarified the error that appears when we're unable to load the `.dll`.
|
||||
|
||||
### Fixed
|
||||
|
||||
@@ -646,9 +646,10 @@ std::string create_logger_prefix(const fs::path& socket_path) {
|
||||
}
|
||||
|
||||
std::optional<fs::path> find_wineprefix() {
|
||||
// Try to locate the Wine prefix this .so file is located in by finding the
|
||||
// first parent directory that contains a directory named `dosdevices`
|
||||
fs::path wineprefix_path = get_this_file_location().remove_filename();
|
||||
// Try to locate the Wine prefix the plugin's .dll file is located in by
|
||||
// finding the first parent directory that contains a directory named
|
||||
// `dosdevices`
|
||||
fs::path wineprefix_path = find_vst_plugin();
|
||||
while (wineprefix_path != "") {
|
||||
if (fs::is_directory(wineprefix_path / "dosdevices")) {
|
||||
return wineprefix_path;
|
||||
|
||||
Reference in New Issue
Block a user