Win-to-OSX VST wrapper/adapter

DSP, Plug-in and Host development discussion.
RELATED
PRODUCTS
Bryan J
KVRer
23 posts since 25 Jun, 2006

Post Sat Jul 25, 2009 11:21 pm

djanthonyw wrote:Where can I download the binary of Wine from?
lol... I guess that means I gotta get a procedure down, since Dave held up his end!! =)

First of all, this looks like a lot of steps, but it's not at all complicated if you read everything carefully.:

Installing XCode (Necessary to build Wine):

1. First, you'll need to download Xcode from Apple's developer site. In order to do so, you'll first need to register with Apple's developer program. This is free. To do so, click on this link: https://connect.apple.com/cgi-bin/WebOb ... erSite.woa, and click "Join Now", and follow all the steps to fill in the required information to get a username and password for the Apple Developer Program.

2. Once you get your username and password, go here: https://connect.apple.com/cgi-bin/WebOb ... ADCLOG-NEX and log in with your credentials.

3. Once you're logged in, you'll see the member's page. From here you should click on the Downloads link.

4. Next, click on the link on the right that says "Developer Tools"

5. Now, locate "Xcode 3.1.3 Developer DVD (Disk Image)" and click on it to download the Xcode installer.

6. Once it downloads, double click on the .dmg file and then the .pkg file contained within. Follow he instructions and allow it to install. You shouldn't need to customize the installation.

Installing MacPorts, Porticus, and Wine:

7. Click here to download MacPorts: http://svn.macports.org/repository/macp ... eopard.dmg. Once it downloads, double click on the .dmg file and then the .pkg file contained within. Follow he instructions and allow it to install.

8. Next, click here to install Porticus. http://porticus.alittledrop.com/downloa ... _1_6_3.dmg. Once it downloads, double click on the .dmg file and drag Porticus to your apps folder.

9. Open the Porticus app.

10. Click on the folder that says "All Ports". (You should see almost 6000 available.)

11. Type "wine-devel" (without quotes) in the search box in the upper right.

12. Click on "wine-devel" in the main window.

13. Click the green "install" button in the upper left.

14. Click the install button in the confirmation window and enter your admin password for osx. This will automate the entire process needed to download, compile, and install Wine and all it's dependencies. It will take a long time... maybe an hour or more if I remember correctly, so be patient.

Installing XQuartz:

15. Click here to download XQuartz: http://xquartz.macosforge.org/downloads/X11-2.3.3.2.dmg. Once it downloads, double click on the .dmg file and then the .pkg file contained within. Follow he instructions and allow it to install. NOTE: The MIDI related problems I made mention of earlier in this thread might not be XQuartz related, but may instead be due to a known bug in 10.5.7. This is the link to the latest version.

Installing and configuring WACVST:

16. Follow this link to get to the latest version of WACVST and click on the "Download Now!" button to download the binaries: http://sourceforge.net/projects/wacvst/.

17. One the file is downloaded, go ahead and unzip it.

18. Once unzipped, double-click on the wacvst folder to open it.

19. Control-click on the wacvst.vst file and select "Show Package Contents" from the drop down menu. This will open an new window showing the contents of wacvst.vst.

20. Double-click on the "Resources" folder in the new window.

21. Double-click on config.plist. If you've correctly installed Xcode, this should open up easily with the Property List Editor.

22. Change the plugin-name value to be the name of your Windows VST filename *without* the extension. So if your plugin's filename is messiah.dll, then you should change the plugin-name to be "messiah" (without quotations).

23. Change the wine-path to reflect the location in your wine install. By default, this will likely appear as: /usr/local/bin/wine . If you've been following these instructions, then you should change this to: /opt/local/bin/wine

24. Type command-Q to quite the Property List Manager and then click "Save".

25. Drag the Windows VST .ddl file you wish to wrap and any supporting files into the "Resources" folder window that should still be open on your desktop. (If you're not sure about the "supporting files" (which can get pretty involved, depending on the plug-in), then I might recommend that you start off experimenting with some of the more simple freeware plug-ins that only comprise of a simple user interface and a single .dll file. At this point, you can close the "Resources" folder window, but leave the "wacvst-bin" folder open.

26. Double-click on Macintosh HD.

27. Double-click on Library.

28. Double-click on Audio.

29. Double-click on Plug-Ins.

30. Double-click on VST.

31. Drag the wacvst.vst file from the "wacvst" folder to the "VST" folder.

32. Cross your fingers.

33. Open up VST host you like and see if your plug-in shows up.

34. Regardless of whether your plug-in works or doesn't work with wacvst, you should come back here and share your experience with others in this thread so that others can learn from it, so this project can move forward, and to give props to Dave (retroware) for all his hard work and his willingness to donate it to the open source community.

Also... as Dave mentions in the wacvst readme file... "One may need to copy support dlls to wine's windows\system32 directory." This is very similar to Receptor in that some Windows plug-ins rely on features within the Windows libraries that aren't included as a part of Wine by default. I'll add some details regarding how to do this soon, but it should be assumed that any techniques used to "hack" a specific plug-in onto the Receptor (which is using Wine in a similar fashion) would also apply in this case as well.

Additionally, it's also worth mentioning that Wine's registry (similar to the Windows registry) may also need to be edited. In fact, this is frquently the case for commercial plug-ins you've purchased that require a serial number during installation. Again, I'll add additional details soon, but I'd also look toward the forums for the Receptor for techniques regarding specific plugins.

Hopefully this helps a few of you get started with this project. Also, don't hesitate to suggest any edits I can make to this procedure to help clarify the installation.

Thanks,
Bryan J [/b]

jngpng
KVRer
15 posts since 22 Oct, 2005

Post Sun Jul 26, 2009 4:29 am

Fantastic work Dave, and nice write-up Bryan!

I have SQ8L running beautifully in Live 8 now. Receiving MIDI appears to work flawlessly.

I'm not really too up on the VST spec - does each plug-in have a unique identification code like AU? Or would making multiple wrapped plug-ins be simply a case of copying the wacvst bundle and renaming it?

User avatar
djanthonyw
KVRAF
7310 posts since 20 Jul, 2004 from Clearwater

Post Sun Jul 26, 2009 5:44 am

Hey Bryan, thanks for all the steps!
You are currently reading my signature.

douglashorner
KVRer
4 posts since 26 Oct, 2005 from London

Post Sun Jul 26, 2009 7:13 am

Doug
Last edited by douglashorner on Sun Jul 26, 2009 7:47 am, edited 1 time in total.

User avatar
djanthonyw
KVRAF
7310 posts since 20 Jul, 2004 from Clearwater

Post Sun Jul 26, 2009 7:16 am

Wine is building for me right now, the only thing I really want to do is see if z3ta works. That's the only thing I REALLY would like to have that's not already on OS X now.
You are currently reading my signature.

douglashorner
KVRer
4 posts since 26 Oct, 2005 from London

Post Sun Jul 26, 2009 7:38 am

Forget that last post, i worked it out. Novation automap wrapper prevented the plugins from loading. Wacvst succefully wrapped in live and fxpansion vst - au still working on.

douglashorner
KVRer
4 posts since 26 Oct, 2005 from London

Post Sun Jul 26, 2009 7:52 am

jngpng wrote:Fantastic work Dave, and nice write-up Bryan!



I'm not really too up on the VST spec - does each plug-in have a unique identification code like AU? Or would making multiple wrapped plug-ins be simply a case of copying the wacvst bundle and renaming it?

Hi There,

I have made multiple instances of wacvst By
1. changing the plugins name from "wacvst.vst" to "desired name"
2. in info.plist- in package contents; changed all "wacvst" entries to "desired name"
3. and finally the MacOS package from wacvst to "desired name".

Although running more than one instance of the same plugin has not worked for me.

Doug

Gamma-UT
KVRAF
5748 posts since 8 Jun, 2009

Post Sun Jul 26, 2009 11:13 am

I've got it up and running with SQ8L on OS X 10.5.7. The instructions were brilliant.

Live didn't recognise Wacvst with the additional files for SQ8L (a folder containing a .ini file and a readme). Removing those let both Kore and Live recognise the VST and it seems to run fine. The applications seem to have some trouble quitting and attempting to run two instances of the same plug-in causes both to go silent whether the plug-ins are run from Live direct or inside different instances of Kore. However, I'm happy enough to have just one running: I can at least sample the output.

Gamma-UT
KVRAF
5748 posts since 8 Jun, 2009

Post Sun Jul 26, 2009 11:43 am

It's a bit crashy, but it remains a big step forward from having to use network MIDI to talk to a second machine running Windows.

douglashorner
KVRer
4 posts since 26 Oct, 2005 from London

Post Sun Jul 26, 2009 11:49 am

Wow vst - au works.
Projects with drop down pluginshell folders cannot be recalled.

retroware
KVRist
40 posts since 22 Mar, 2007

Post Sun Jul 26, 2009 4:36 pm

A couple of comments from the developer:

First, thanks to Bryan for the documentation.

Second, I wouldn't expect that one could wrap multiple different vsts. There is a hard coded package name in the source code which wacvst uses to find the configuration file. I've yet to come up with a good way of wrapping multiple vsts. Douglas, did your technique work? If so, I'm a bit surprised.

I'm also not surprised that multiple instances of a vst is not working. I'm guessing that there are one or more state variables that are being shared incorrectly.

Wacvst currently supports all of the vst1.0 spec and about 30% of the vst 2.1/2.2 spec. A lot of the un-implemented functionality has to deal with automation and plugin to host midi. Supporting the full spec is basically a matter of some relatively simple but time consuming programming. Once the full spec is implemented, most vsts should work. If you are interested in adding the additional functionality, drop me a pm and I'll add you to the svn access list.

As Bryan mentioned, if one is having problems getting a particular vst working, try adding all of the vsts's support files to wacvst's resource directory and/or adding dlls to the system32 directory.

Has anyone tried getting wacvst working with codeweaver's crossover mac product? This is a commercial version of wine and would negate the need to download and build wine. Maybe when I get the time I'll download codeweaver's demo and give it a try.

Finally, I second Byran's suggestion to post one's experiences with wacvst. It will help move it forward to a useful tool.

Bryan J
KVRer
23 posts since 25 Jun, 2006

Post Mon Jul 27, 2009 2:21 am

Thanks for the positive feedback on the instructions... Writing them was well worth the effort if this continues as it has.

Unfortunately, I sadly have to report that my MacBook HD crashed pretty hardcore this morning (argh)... Not like a "fix it with Disk Warrior" type crash, but rather, the "clicks of death" type crash. As a result, I wasn't able to do as thorough of a test on the new version as I'd wanted... but here's what I was able to find so far before it croaked:

I was able to get Messiah running in Logic with *some* response over MIDI, but it was very intermittent... almost like the behavior that you get from having a bad MIDI cable. If I pressed down on just one key then I usually wouldn't get any response, but if I pressed a bunch of keys simultaniously, then a few notes would get through to Messiah, and most of them would end up being stuck notes. I should also point out that I could clearly see that Logic was receiving all the events. They're just not reaching Messiah... like they were just getting dropped. I also noticed that the the CPU meter was bouncing around quite a bit. This didn't however seem to be the case when I was playing Messiah's keyboard with the mouse.

All this to say Dave, don't spend a bunch of time on this yet... I only want to mention this right now in the event that there might be something glaringly obvious that might be the cause for MIDI events getting dropped. Otherwise, let me get more information... i.e. whether or not Messiah will work with a true VST host through wacdav (rather than being double-wrapped), and also what other plugins work or don't work when they're double-wrapped. Also... I am curious Dave (or anyone else)... since XQuartz and Wine are involved in this solution, is there any way that we can influence the priority of those processes and/or their processor affinity? (Can we even specify processor affinity on a Mac?)

Another observation is that it does appear that program names are indeed being updated correctly in Logic and Logic's program changes are now being received correctly on the plugin. Way cool.

Other than that, I probably won't be of much help until after this coming weekend when I'll have the time to get my computer back in order... but I hope everyone keeps trying this out in the mean time. It's good stuff!! =)

koalaboy
KVRAF
1936 posts since 18 Mar, 2006 from Plymouth, UK

Post Mon Jul 27, 2009 3:55 am

It's probably a very (very) silly question, but I'll risk it anyway :lol:

Is the main reason that Wine is required, due to the GUIs ? I'm assuming (probably very stupidly) that the audio API should be pretty much cross-platform ?

I'm just wondering if things would be simpler with host-generated parameter GUIs, or if the windows runtime DLLs are often referenced a lot from the plugins which is why Wine is required.

Equally, with mention of IPC, has anyone thought about (if it's possible) working with umd to build an AU plugin that acts as an IPC client to a wine-based IPC server ?

Just brain-dumping and probably all highly unfeasible :oops:

mustgroove
KVRian
Topic Starter
572 posts since 23 Jun, 2005

Post Mon Jul 27, 2009 11:50 pm

Wow, haven't checked back on this thread in a while and what do you know, progress!!!

Will check that method out tonight, but hopefully something with Crossover is feasible to avoid all that compilin' ;)

mustgroove
KVRian
Topic Starter
572 posts since 23 Jun, 2005

Post Tue Jul 28, 2009 12:59 am

Also, Bryan J - is there any particular reason why downloading Xcode from ADC is required, or will the copy that comes on the OS X install disc suffice?

Return to “DSP and Plug-in Development”