Well, before going further with Manuskript, I was trying to replicate the C++ Wrapper with another software to verify its validity as a multipurpose solution. It turns out that as my Python knowledge is low, as well as my Haiku knowlegde is also low, I wasn’t able to get the wrapper working with GitCola (yet).
Nonetheless, it is another software, written in Python and Qt that also works on Haiku:
I still need to study more about Python, the Python C API and Haiku in order to get the wrapper usable in any case.
For GitCola, besides, I should learn how to use Git too.
Nonetheless, GitCola works with Python 2.7 as well as 3.7.
I’ll keep researching and studying in order to get the wrapper usable in any situation.
I already wondered in the other thread, but what exactly is the wrapper needed for? If it is written with Python and Qt5 it should work without the need for this wrapper already.
I see. Actually you can do these things also without a wrapper using just the normal Python launch script provided by the application. Icon and file type associations can be set in a resource file and added as a file system attribute to the launch script. The deskbar symlink can be set with addAppDeskbarSymlink.
The launch script itself is getting installed at $appsDir/Picard and is just this small Python file. The only thing that is a bit of a hack here is the call to settype -t application/x-vnd.Be-elfexecutable, because obviously the launch script is just a Python script and not a Be ELF executable. But it is needed for some reason.
What I’m not sure about your feature list is the file type icon, as I have never done that. But this probably involves installing a file for the mime database and likely can also be done.
Yep, this would work, but this provides no way to customize the icon of the running program (it gets the standard executable icon) and the name (Python) in the Deskbar, AFAIK.
Ha, sorry Actually my knowledge of Haiku is rather limited. I just assumed I would miss something essential, even though I wondered why my app and others in HaikuDepot work without such a wrapper. Actually I have just stolen this packaging procedure from some other PyQt based app, just forgot which one.
In this case it should be fine. Qt5 in Haiku will set the signature on the BApplication by reading it from the executed file. In the example of Picard above this will then work fine. The signature is set on the launch script from the resource file, Qt5 reads this and initializes the BApplication from it.
So this should all work fine if PyQt 5 is being used. If the Python application would initialize BApplication itself (e.g. using some Python bindings to libbe) it would need to ensure itself to set the proper signature I guess.