Commit Graph

1707 Commits

Author SHA1 Message Date
Robbert van der Helm 89378e8862 Handle dlsym() failures in chainloaders better
If these ever fail (because the function names change, not that that
should happen anytime soon) then you'll now get the expected logging
output instead of it just printing an assertion failure to the terminal.
2022-04-21 14:21:26 +02:00
Robbert van der Helm 3970bc7f52 [yabridgectl] Set up in ~/.vst/yabridge by default
Instead of creating `.so` files next to the VST2 plugin's `.dll` files.
This behavior is still available as an option. #123
2022-04-17 20:27:47 +02:00
Robbert van der Helm ffddb06b28 Actually add the new merged host.cpp file
Kinda useful.
2022-04-16 23:29:57 +02:00
Robbert van der Helm b3efcf4e06 Merge yabridge-group.exe and yabridge-host.exe
They were 95% the same, so this makes a lot more sense this way. When
group host processes were introduced yabridge only did VST2 bridging,
but we already have a plugin type argument anyways so might as well
reuse that for group hosts.
2022-04-16 23:26:24 +02:00
Robbert van der Helm 4d9e865dd3 Define plugin and chainloader deps in own dir
Just like we already did for the plugin host.
2022-04-16 23:00:25 +02:00
Robbert van der Helm 470f4dfaaa Remove the with- prefix from the build options 2022-04-16 21:13:46 +02:00
Robbert van der Helm 773b101cd4 Update error messages for chainloading changes 2022-04-16 20:37:11 +02:00
Robbert van der Helm 8710b6d63d Add one last Hail Mary search to the chainloader 2022-04-16 20:37:11 +02:00
Robbert van der Helm 6f16eb5c76 Print library path in the initialization message
This is useful when chainloading, since it now tells you where eactly
it's loading the library from.
2022-04-16 20:37:11 +02:00
Robbert van der Helm d73a0041eb Find the correct library file from the chainloader
Instead of using this hardcdoed path.
2022-04-16 20:37:11 +02:00
Robbert van der Helm 85989f4c1d Also add a way to use logging library without Asio 2022-04-16 20:37:11 +02:00
Robbert van der Helm d63b4d2da5 Add the plugin library names to config.h.in 2022-04-16 20:37:11 +02:00
Robbert van der Helm 3cad93cb65 Move get_augmented_search_path to process library
We'll need this for the chainloader.
2022-04-16 20:37:11 +02:00
Robbert van der Helm c2794831da Add (for now, hardcoded) chainloader libraries 2022-04-16 20:37:11 +02:00
Robbert van der Helm 0487947d91 Export chainloader functions in the plugin libs
These can be called from the new chainlaoder libraries to use yabridge
without needing copies of the full fat `libyabridge-{vst2,vst3}.so`
libraries.
2022-04-16 20:37:11 +02:00
Robbert van der Helm d79663bdc1 Remove spurious underscores from socket files 2022-04-16 20:37:11 +02:00
Robbert van der Helm 0ba0dab675 Add missing extern "C" to GetPluginFactory 2022-04-16 20:37:11 +02:00
Robbert van der Helm 6773305646 Allow including process.h without Asio support 2022-04-16 20:37:11 +02:00
Robbert van der Helm 46af07748b Move desktop notifications to its own header
We'll need to use this from the chainloader.
2022-04-16 20:37:10 +02:00
Robbert van der Helm fde90d7bc3 Pass plugin path around instead of redetecting
This is now set only once at the top level. This is needed for the
chainloading to work because we'll need to set the path when we create
the bridge.
2022-04-16 20:37:10 +02:00
Robbert van der Helm 1fec4c8860 Change the description in the GPL header 2022-04-16 20:37:10 +02:00
Robbert van der Helm 88ac466501 Remove all references to Boost
Since we no longer depend on any of it.
2022-04-16 20:37:10 +02:00
Robbert van der Helm 7b3afa4043 Replace Boost.Dll with our own function
Now we no longer rely on anything from Boost. Later we'll move the path
detection to the very beginning of the plugin bridge initialization so
it can be set from the coming chainloader libraries.
2022-04-16 20:37:10 +02:00
Robbert van der Helm b2ffbb8b4d Also consider empty dirs for find_dominating_file
Just in case.
2022-04-16 20:37:10 +02:00
Robbert van der Helm c2de0cce2e Use our own export macro 2022-04-16 20:37:10 +02:00
Robbert van der Helm 6e2fff5710 Add size field in AudioShm move constructors 2022-04-16 20:37:10 +02:00
Robbert van der Helm 4e99afd53d Add a note on case sensitive extension matching 2022-04-16 20:37:10 +02:00
Robbert van der Helm b2a15620f3 Swap Boost.Container's small_vector out for LLVM's
This implementation misses a shrink to fit function, but reassigning the
vector with a fresh one should be equivalent.
2022-04-16 20:37:10 +02:00
Robbert van der Helm fd25010aca Replace Boost.Interprocess for audio-shm 2022-04-16 20:37:10 +02:00
Robbert van der Helm b2b6a606ea Silence -Wunused-result warnings 2022-04-16 20:37:10 +02:00
Robbert van der Helm 25f298636a Add now missing include 2022-04-16 20:37:10 +02:00
Robbert van der Helm 03dfc66e30 Remove obselete boost-fix header 2022-04-16 20:37:10 +02:00
Robbert van der Helm c8bbdc4f54 Get rid of the last uses of Boost.Process 2022-04-16 20:37:10 +02:00
Robbert van der Helm 037d6ad5aa Replace Boost.Process for the Wine plugin host
Now we use our own library for this, so we can drop the Boost.Filesystem
dependency after a couple more changes.
2022-04-16 20:37:10 +02:00
Robbert van der Helm f79b0fd146 Fix Process file redirection 2022-04-16 20:37:10 +02:00
Robbert van der Helm 642c341d26 Handle waiting on a dead process 2022-04-16 20:37:10 +02:00
Robbert van der Helm b6e63ea0d5 Add a function for searching through PATH 2022-04-16 20:37:10 +02:00
Robbert van der Helm 33b49dd7a5 Make the process building functions chainable 2022-04-16 20:37:10 +02:00
Robbert van der Helm 8d40341ade Add a function for splitting search paths 2022-04-16 20:37:10 +02:00
Robbert van der Helm a5ded46f27 Add a detach function to the process handles 2022-04-16 20:37:10 +02:00
Robbert van der Helm 75b3cf266d Add Process functions for detached spawning 2022-04-16 20:37:10 +02:00
Robbert van der Helm 1df7abfb2c Terminate handles when they get dropped 2022-04-14 23:42:12 +02:00
Robbert van der Helm 1641fb2996 Fix find_dominating_file() for ghc::filesystem
"/".parent() now is "/" instead of "" (which does make more sense)
2022-04-14 23:42:12 +02:00
Robbert van der Helm a324042695 Use custom process library for notifications
Instead of using Boost.Process here. Last usage of Boost.Process is for
launching the child process.
2022-04-14 23:42:12 +02:00
Robbert van der Helm b80a30ba2a Redirect STDERR to /dev/null in process spawn 2022-04-14 23:42:12 +02:00
Robbert van der Helm 006cc6f52a Read the Wine version without Boost.Process
By spawning the process using posix_spawn and manually reading from a
pipe.
2022-04-14 23:42:12 +02:00
Robbert van der Helm 60e4619ef1 Move pid_running() to process.h 2022-04-14 23:42:12 +02:00
Robbert van der Helm 0d6738093c Add a Boost.Process-like environment builder
We can use this with the `exec*e()` family of functions.
2022-04-14 23:42:12 +02:00
Robbert van der Helm 556b0e38f9 Replace Boost.Asio with standalone Asio library
We had to add an even hackier hack now to get Boost.Process to
interoperate with Asio's IO contexts. This will be replaced later when
we replace Boost.Process.
2022-04-14 23:42:12 +02:00
Robbert van der Helm d2d4cf4ea9 Replace most uses of Boost.{Filesystem,Process}
With the `ghc::filesystem` dependency from the previous commit. If we
can replace the rest of the Boost.Filesystem dependency then we can get
rid the one nasty runtime dependency we have, and it will make
implementing the chainloading simpler since can reuse more code without
bringing in Boost.
2022-04-14 23:42:12 +02:00