Python Forum

Full Version: Replace Meson with PIP
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
I have a Flatpak which uses Meson to install the main Python program. There is a meson.build file which finds appropriate directory names and does things like this:
bindir = get_option(‘bindir’)
datadir = get_option(‘datadir’)
pkgdatadir = join_paths(get_option(‘prefix’), get_option(‘datadir’), ‘myapp’)
conf = configuration_data()
conf.set(‘pkgdatadir’, pkgdatadir)
install_data(file, install_dir: pkgdatadir)
All this appears to be to be doing is finding out appropriate directories, then copying files into them. It also does install_data() whatever that is. Is there anything special about any of this or could it be done by using PIP statements within the Flatpak - thus eliminating the complication of another technology and an extra file? This isn't an urgent problem as the current method works, I'm just looking for opinions on whether it could be recommended as a way of keeping things simple.
In order to use pip, the author must place package in PyPi.org
(Sep-23-2022, 06:28 PM)ChrisOfBristol Wrote: [ -> ]I have a Flatpak which uses Meson to install the main Python program.
Why you need to use Flatpak or Menson?
Python has it own way to build stuff look at this post
So making a Wheel(.whl) file that can share with others,if also upload to PyPi it will be available to all that has Python and pip eg pip install my_package.
(Sep-23-2022, 09:35 PM)Larz60+ Wrote: [ -> ]In order to use pip, the author must place package in PyPi.org
Well that's a simple answer - the Python element isn't standalone, so it couldn't be put on PyPI.
(Sep-24-2022, 02:38 PM)snippsat Wrote: [ -> ]Why you need to use Flatpak?
This package involves many dependencies written in C.
(Sep-24-2022, 02:38 PM)snippsat Wrote: [ -> ]Why you need to use Menson?
I don't know whether it would be possible to use a Wheel, but it would be another technology to learn, so I'd prefer to stick with Meson, unless I could just use a shell script.