Building .deb package with Meson/Ninja
Building .deb package with Meson/Ninja
I have seen a lot of guides/How-Tos on building .deb packages using the traditional configure & make method, and those work out great.
However, I am not seeing anything on building packages based on the Meson & Ninja build setup.
Not even Debian's own guide mentions anything on this.
Can anyone point me to something?
Thanks!
However, I am not seeing anything on building packages based on the Meson & Ninja build setup.
Not even Debian's own guide mentions anything on this.
Can anyone point me to something?
Thanks!
- Head_on_a_Stick
- Posts: 14114
- Joined: 2014-06-01 17:46
- Location: London, England
- Has thanked: 81 times
- Been thanked: 135 times
Re: Building .deb package with Meson/Ninja
I'm pretty sure debhelper can handle them automagically with dh_auto_configure & dh_auto_build.
What have you actually tried so far?
What have you actually tried so far?
deadbang
Re: Building .deb package with Meson/Ninja
Thanks for taking the time to respond, but those you listed are for the traditional configure and make, not for Meson and Ninja.
That is why I am asking as I previously mentioned, I cannot find anything about building for Meson & Ninja
That is why I am asking as I previously mentioned, I cannot find anything about building for Meson & Ninja
- Head_on_a_Stick
- Posts: 14114
- Joined: 2014-06-01 17:46
- Location: London, England
- Has thanked: 81 times
- Been thanked: 135 times
Re: Building .deb package with Meson/Ninja
Well the man page says:KNERD wrote:those you listed are for the traditional configure and make, not for Meson and Ninja
And this bug report is marked "fixed" for debhelper >10.3:dh_auto_build(1) wrote: dh_auto_build is a debhelper program that tries to automatically build
a package. It does so by running the appropriate command for the build
system it detects the package uses. For example, if a Makefile is
found, this is done by running make (or MAKE, if the environment
variable is set). If there's a setup.py, or Build.PL, it is run to
build the package.
This is intended to work for about 90% of packages. If it doesn't work,
you're encouraged to skip using dh_auto_build at all, and just run the
build process manually.
https://bugs.debian.org/cgi-bin/bugrepo ... bug=795253
So I ask again: what have you actually tried so far?
Or if you haven't tried anything then how about supplying a link to the software you are trying to package?
If debhelper doesn't work then you can over-ride the automation as outlined here:
https://lists.debian.org/debian-devel/2 ... 00348.html
deadbang
Re: Building .deb package with Meson/Ninja
Exactly my point, dh_auto_build is calling configure and make. It does not seem work with this, that is why I keep mentioned Meson & Ninja
I have also tried dh_make
I am trying to build Mutter. https://github.com/GNOME/mutter
Using dh_auto_build returns:
I have also tried dh_make
I am trying to build Mutter. https://github.com/GNOME/mutter
Using dh_auto_build returns:
dh_auto_configure: Package-field must be a valid package name, got: "mutterBROKEN", should match "(?^:^(?^:[a-z0-9][-+\.a-z0-9]+)$)"
Compilation failed in require at /usr/bin/dh_auto_configure line 12.
- Head_on_a_Stick
- Posts: 14114
- Joined: 2014-06-01 17:46
- Location: London, England
- Has thanked: 81 times
- Been thanked: 135 times
Re: Building .deb package with Meson/Ninja
Only if it finds the relevant build files. If Meson & Ninja are used as a build system then debhelper should invoke those automatically. Please read my links.KNERD wrote:dh_auto_build is calling configure and make
Why? That is already available in Debian's official repositories. And debian/rules for that package seems to rely on dh_auto_build with only a few options added to dh_auto_configure.KNERD wrote:I am trying to build Mutter.
Would it not be easier to download the Debian source and patch that? What is the actual problem you are trying to solve here? This is starting to look like an XY-problem.
deadbang
Re: Building .deb package with Meson/Ninja
The version in Debian 10 is 3.30.2, plus I am trying to learn how to build different packages.
I need version 3.34,
Which option are needed for dh_auto_build?
I need version 3.34,
Which option are needed for dh_auto_build?
- stevepusser
- Posts: 13027
- Joined: 2009-10-06 05:53
- Has thanked: 45 times
- Been thanked: 92 times
Re: Building .deb package with Meson/Ninja
You merely need to use
in debian/rules to invoke the newer debhelper's built-in Meson support, but I'm looking at Bullseye's rules file for their 3.34.3 build, and they go at it manually instead.
I hate to break it to you, but compiling packages isn't all "configure, make, sudo make install". Many times it's terribly more complicated than that. Since testing already has that version, I assume you're trying to build the new Mutter on Buster or even older. That's pretty much impossible without backporting all of the rest of GNOME 3.33+ along with it.
I have backported packages that needed even newer versions of Meson than Buster has, and even packaged from scratch some packages use meson builds, (i.e. Foliate) so I know something about I'm talking about. If you need that version of Mutter, the best advice it to run Testing or Sid.
Code: Select all
%:
dh $@ --with meson
I hate to break it to you, but compiling packages isn't all "configure, make, sudo make install". Many times it's terribly more complicated than that. Since testing already has that version, I assume you're trying to build the new Mutter on Buster or even older. That's pretty much impossible without backporting all of the rest of GNOME 3.33+ along with it.
I have backported packages that needed even newer versions of Meson than Buster has, and even packaged from scratch some packages use meson builds, (i.e. Foliate) so I know something about I'm talking about. If you need that version of Mutter, the best advice it to run Testing or Sid.
MX Linux packager and developer
Re: Building .deb package with Meson/Ninja
Thanks for all this helpful information.
This does lead me to more questions though. My end result is to try to learn to build the Budgie Desktop as a package.
I see Debian 10 Buster already has version 10.5.1 built. Which is the same version I am trying to at least just straight compile for now. So this leads me to ask how was it even build for Buster if is a there version issue with various Mutter?
It wants Mutter >=3.43 which I was able to get installed from your advice.
Now from the Git source, I see it wants Glib >=2.62 meanwhile 2.58.2 is on Buster.
Not having Glib issue with the Oct 2019 release package.
This does lead me to more questions though. My end result is to try to learn to build the Budgie Desktop as a package.
I see Debian 10 Buster already has version 10.5.1 built. Which is the same version I am trying to at least just straight compile for now. So this leads me to ask how was it even build for Buster if is a there version issue with various Mutter?
It wants Mutter >=3.43 which I was able to get installed from your advice.
Now from the Git source, I see it wants Glib >=2.62 meanwhile 2.58.2 is on Buster.
Not having Glib issue with the Oct 2019 release package.
- stevepusser
- Posts: 13027
- Joined: 2009-10-06 05:53
- Has thanked: 45 times
- Been thanked: 92 times
Re: Building .deb package with Meson/Ninja
Buster has Budgie 10.5, not 10.5.1. The "-1" as the end of Buster's 10.5-1 is a Debian build version, not part of the release version number. That's no doubt why you're getting the confusion about dependencies for the newer version. Debian testing has 10.5.1-3, though.
MX Linux packager and developer
Re: Building .deb package with Meson/Ninja
I found the source online that Debian is using.
I see there was some patch files making it compatible with the older version of Glib.
However, when trying to enter your suggested command, " dh $@ --with meson" it is returning "dh: error: Unknown sequence --buildsystem=meson (options should not come before the sequence)"
I see there was some patch files making it compatible with the older version of Glib.
However, when trying to enter your suggested command, " dh $@ --with meson" it is returning "dh: error: Unknown sequence --buildsystem=meson (options should not come before the sequence)"
- stevepusser
- Posts: 13027
- Joined: 2009-10-06 05:53
- Has thanked: 45 times
- Been thanked: 92 times
Re: Building .deb package with Meson/Ninja
Hmmm---is that line indented with a tab?
Is this Budgie or Mutter that you're trying to build now? I still don't think it's compatible with Buster's GTK 3...
Is this Budgie or Mutter that you're trying to build now? I still don't think it's compatible with Buster's GTK 3...
MX Linux packager and developer
- stevepusser
- Posts: 13027
- Joined: 2009-10-06 05:53
- Has thanked: 45 times
- Been thanked: 92 times
Re: Building .deb package with Meson/Ninja
I'm trying to backport upstream's Budgie, but the tweaked version still fails about a third of the way through with what may be a valac error. There's a newer version of valac in buster-backports, though...
MX Linux packager and developer