Good day fellow devs,
I'm working on a pretty complex closed source python plugin for C4D.
The time has come to think about the distribution.
More often than not I encounter .xdl64 bundles, that are easy to install and use.
I would like to:
- provide a simple launcher via a single .xdl64 file (or a .zip with all the code neatly contained in a protected container-file) that anybody can place in the Plugins folder.
- have that launcher be written in native Cinema4D way, so it has the best chance of running on different Cinema4D versions.
- the launcher figures out runtime versions and downloads python-based solution for the current version.
- the launcher also launches the main plugin.
Benefits of this approach are:
- Launcher is python independent.
- Rare updates are necessary for the launcher itself.
- Control over update process for the main plugin.
- Source code is hidden from easy access.
So, while I'm not proficient in C or C++, walking that route offers the best results so far.
Could you please point me in the right direction and point our tough spots or hidden dangers of this approach?
Side questions:
- Can there be a mixed plugin, that starts as C++ plugin, and calls on previously downloaded python libs at some point?
- Can such a C++ launcher load, unload, reload a python plugin in runtime?
- Can I pack a python plugin into .xdl64 file?
- How would you approach a question of keeping your source code private, with python being an open book?
So far the best way I know of is - Cython everything down to C and have that compiled to .pyd libraries.
Thank you.