- Notifications
You must be signed in to change notification settings - Fork3
Python bindings for the Haiku API
License
coolcoder613eb/Haiku-PyAPI
Folders and files
| Name | Name | Last commit message | Last commit date | |
|---|---|---|---|---|
Repository files navigation
Python bindings for the Haiku API.
This lets you build apps for Haiku using the Haiku API directly from Python.
For the most part, Haiku-PyAPI tries to copy the C++ API. There are some placeswhere we have had to deviate from the C++ API, however.
Currently, Haiku-PyAPI is best suited to scripts and small, simpleapplications.
Almost everything in the app and interface kits have been ported. The storagekit has mostly been ported. The support kit has only partially been ported.The other kits haven't been ported yet.
Of the kits that have been ported, many of the functions haven't been testedyet. You should, therefore, expect to encounter problems occasionally. Besidesthis, you can expect memory leaks, as little work has been done on gettingmemory freed correctly once it is no longer needed.
Installation on Haiku is easy, just run
pkgman install haiku_pyapi_python310or
pkgman install haiku_pyapi_python39If you need the latest widgets and bugfixes, then you should compile from source, see below.
First, clone the source code, with submodules:
git clone https://github.com/coolcder613eb/Haiku-PyAPI --recursiveThe basic build command to build using all CPU cores is
jam -j$(nproc)Extra build parameters can be specified, as discussed below.
Finally, to install, simply run
jam installHaiku-PyAPI should now be installed and ready to use.
The build parameters can be used to change how the build is done. This can beused to, for example, specify a different verson of python to build for. Tospecify a build parameter, add-sPARAMETER=VALUE to the build command line.
| Parameter | Description |
|---|---|
| python_version | Version of python to build for. Default: 3.10 |
| py | Alias ofpython_version |
| type | Debug or release build. Default: release |
| build_location | Location to put build files. Default: build/python$(python_version)_$(type) |
| install_location | Where to install build files to. Default: /boot/system/non-packaged/lib/python$(python_version)/site-packages |
This repository containstest.py, which is a simple "Hello world" program.The matching gameBeMatchedprovides another example of the library in use.
About
Python bindings for the Haiku API
Resources
License
Uh oh!
There was an error while loading.Please reload this page.
Stars
Watchers
Forks
Packages0
Contributors4
Uh oh!
There was an error while loading.Please reload this page.