Generating plugin dll in linux development environment?

Hi, I’ve been playing around with the SDK. My main system uses Windows 10 but I’ve been trying out the Rack-SDK on my virtual Ubuntu (vmware). I followed the tutorial on VCV Rack website and managed to get a working module. I noticed the modules under linux do have “so” as extension. I’m wondering if it’s possible to generate a “dll” from within the linux environment? Or do I need to install a windows environment (MSYS2) and make the plugin there?

you should install all the dependences especified in the manual for linux (cmake, git and so on ) and build following the manual

Get the plug-in tool chain. It’s how the library builds things. Can build for all three systems under Linux.

1 Like

Thanks both for your replies, they’re helpful as they give me some more insight into this (it’s all a bit new to me). My main goal now is just to have a dll, so I can test my module on my windows system… Unless I’m getting this all wrong, the plugin tool chain involves installing all the mac dependencies seems like involving a lot of steps + I understand I would need access to a mac (which I don’t). What would I need to do if I just want to compile the DLL (in ubuntu)?

@David I followed all these instructions/tutorials, but they’re about setting up the work/development environments. They don’t explain how to cross-compile. In this case from Linux to Windows.

I did not install the Mac parts of the tool chain, in fact I only did the windows part. Partial installs are fully supported.

1 Like

I’m slowly making progress. I’m running into an issue now when making the toolchain. I use the command make toolchain-win. It starts doing its thing but then it crashes when installing zlib for host.

[INFO ]  Installing zlib for host
[EXTRA]    Configuring zlib
[EXTRA]    Building zlib
[ERROR]    collect2: error: ld returned 1 exit status
[ERROR]    make[2]: *** [Makefile:289: example] Error 1
[ERROR]    make[2]: *** Waiting for unfinished jobs....
[ERROR]    collect2: error: ld returned 1 exit status
[ERROR]    make[2]: *** [Makefile:292: minigzip] Error 1
[ERROR]  >>
[ERROR]  >>  Build failed in step 'Installing zlib for host'
[ERROR]  >>        called in step '(top-level)'
[ERROR]  >>
[ERROR]  >>  Error happened in: CT_DoExecLog[scripts/functions@376]
[ERROR]  >>        called from: do_zlib_backend[scripts/build/companion_libs/]
[ERROR]  >>        called from: do_zlib_for_host[scripts/build/companion_libs/]

Not sure where to go from here. I tried reinstalling the zlib and zlib-dev. But it’s still the same after.

A fresh install works for me (on debian, should be similar) EDIT: works on ubuntu server 21.04 too.

Here’s how i install the rack-plugin-toolchain and crosscompile a plugin for windows.

sudo apt install build-essential git
cd ~
mkdir projects
cd projects
git clone
cd rack-plugin-toolchain/

sudo make dep-ubuntu
make rack-sdk
make toolchain-win

mkdir plugins
cd plugins
git clone
cd ..

make plugin-build-win PLUGIN_DIR=./plugins/Fundamental/
ls -l plugin-build/

total 1952
-rw-r--r-- 1 jpn jpn 1997900 Aug 17 00:40

1 Like

The tool chain also supports a Docker-based environment. This decouples the host OS from the build environment.

That’s great, but I can’t install it - I don’t have a Mac to make MacOSC10.13.sdk.tar

sudo apt install acl
sudo setfacl --modify user:<user name or ID>:rw /var/run/docker.sock
git clone
cd rack-plugin-toolchain/
make docker-build

Step 15/20 : COPY MacOSX10.13.sdk.tar.* /home/build/rack-plugin-toolchain/
COPY failed: no source files were specified
make: *** [Makefile:187: docker-build] Error 1

Edit the Dockerfile to comment out the COPY statement (line 26) and the macOS build (line 29).

I would have gone docker, but I’m pretty sure my free version of VMWare doesn’t host dockers?

If you have a virtualized environment already, there is no need to run Docker. Just create a fresh Ubuntu VM and install the tool chain directly. I don’t want the overhead of the VM for the build process, so there is the Docker solution for that.


well, it would be handy to grab something that is all set up, but making Ubuntu does work fine, so I can deal.

Thanks it’s working now! I had to reinstall ubuntu 20.04 (desktop edition). I don’t know what happened because my previous install was also very recent. Only thing I did was compiling VCV rack (which as I would learn later was not necessary)

I followed all your commands and it works fine. It also clarified how to structure the working directories. Wasn’t sure here to put my plugin directory, etc…

1 Like

Might try the Docker way later on. I’m happy it already works in VM now :slight_smile:

Not possible due to the macOS licensing restrictions and also a question of bandwidth and space. This is the most flexible solution for everyone, but it requires everyone to learn how the tool chain is structured and make adjustments per their own use case, e.g. commenting out the macOS build.

1 Like