I built a package, need help with next steps

Good day,

In July 2019 I tested Manuskript application on Haiku, and it ran (with the help of @extrowerk). So next step was making a package that would integrate the software in Haiku’s Deskbar and system.

Finally, on May 29th 2020, almost a year after, I was able to create a first package of this application that shows properly in the Deskbar. It was created with the package command, and still needs some improvement, I know that.

So now I need some hints on how to go to the next steps, I mean:

  • How to properly identify Manuskript files with the application (double click on file should open application?)
  • Set a specific icon for Manuskript files and let Haiku be aware of it
  • Managing the requirements (I have doubts on how to tell the .PackageInfo file what are the requirements for the software to run, which I presume will apply to Haikuporter) For this package I just set the requirements as the name of the packages themselves:
    (zlib, pyqt_python3…)
    Without any version, nada. (a single line for each requirement) Is this correct?

In the next packaging, maybe next week I will try to change the package folder structure, as I set the Python C++ Wrapper in /boot/system/apps and the Python code in /boot/system/data. Should it be more proper to set everything in /boot/system/apps? I mean, the C++ simple wrapper along the Python code, like BePDF, Paladin, Pe… who have folders in /boot/system/apps.

I need to solve some small warning that appeared when building the application, but have to wait for an update that fixes “Paladin love for KDL”, as each time I launch Paladin I end up in KDL and rebooting (no save-report available - already filed bug).

Later on I should move the package to Haikuporter, when I do understand how it works.

Thanks in advance for any hint.

Hi roiredxsoto,

First point: you add application/x-… (please habe a look at the yab-ide packages.

Second point:
You can add with addiontal files an Icon please look At yab-ide package.
Third point: please look At github.com/haikuports
Regards lorglas
answer from on the way

Never build a package outside of haikuporter myself, but seeing you already have the needed requirements it shouldn’t be to hard to add them into a recipe, I gather you are working on x86_64 so would be nice if you could add a secondary architecture for the recipe too (presuming it won’t build with gcc2), for zlib for instance you would need “lib:libz$secondaryArchSuffix” in REQUIRES and “devel:libz$secondaryArchSuffix” in REQUIRES_devel …
Not sure what is needed for the build as I haven’t checked the source, but if you need help at the end on getting it into haikuports I’ll try to ship in where I can :slight_smile:

For your files to open with Manuskript automatically, you have to create a filetype for them with FileTypes (calling it by Preferences menu). Check before if your filetype is a derivative of another. ie. if your files are basically text files.
During creation you can drop an icon for them.
Some files can be recognized by their extension but you will probably need to add a sniffing rule too. (I don’t know how.)
After that, in same place, you also have to go in menu application and associate your app with the fyletype created.
Once you have something that work, you will need to find what these settings have created in ~/config/settings/mime_db/* so you can include them in your package at the right place.
Good luck

It’s good to see more applications coming to Haiku. As an ocasional Haiku user, thanks for you effort and for you work.

If I understand it well, this is a Python/Qt application, right. I think it would be great to identify the best way to package it, and then make those instructions public available somewhere for other users in a nice tutorial :wink:

Bom día @victordomingos,
I already did that before attempting the Manuskript packaging :wink: :


And posted here:

There are some things that need improvement though, and I’m working on it, hopefully it won’t take another year to get there as it took from the first run of Manuskript to the package… :rofl::rofl::rofl:

Nonetheless, you can be sure I will write everything down, first, for me to remember what and how I’ve done it, and second, for others to follow and improve the method.


1 Like

Good day,

@lorglas, @Begasus, @Starcrasher, will do. Hopefully will start this week with that, in order to increase the “integration” of the software, and report improvements, if any.

@Begasus, yes, I only do 64. Nonetheless, I presume it wouldn’t be a big issue to add a second arch, the python code is left untouched, and the C++ wrapper is so simple that I doubt there will be any trouble. Once I have the package behaving properly, adding what @lorglas and @Starcrasher pointed out, then I’ll move to the haikuporter way.:wink:

Thanks you all. Once this “project” is complete it will deserve a full tutorial. Extending the one I’ve already written for the first stage (check down below), that might need some tweaking.