Replace Autotools with Meson#186
Conversation
39b21b6 to
ea0e581
Compare
|
Hi. First of all, great work! I had some thoughts about that too... When replacing the Autotools with something else, wouldn't it make sense to go for something like CMake, which is widely supported by most IDEs? Being able to easily import the project into any preferred IDE would definitely be a big plus. Please note that CMake has integrations for Ninja and ccache too, so the build performance would be optimal too (though the synaptic project is relatively small, thus the build time is not so critical (though faster is always nice)). |
|
My take is: CMake is more C/C++ centric while Meson is general purpose and is widely used in Gtk/Gnome applications. |
edd66a9 to
4c46edb
Compare
|
Hi. I'm trying out your branch. Here's my findings so far: EclipseOpening the project on
Qt CreatorOpening and building the project on However General buildingBuilding failed on my environment trying to localize the com.ubuntu.pkexec.synaptic.policy file, due to the /usr/share/gettext/its/polkit.its and polkit.loc files not being installed on the system. To fix that I've installed the libpolkit-gobject-1-dev package and added the following to the root meson.build file (so that there's a clear error in case the dependency is missing): |
|
@amaa-99 Thanks for testing this! I use Gnome Builder and it works w/o any issues. I've just tried to build and run tests in VS Code and it has no issues either.
Side note: if you haven't had it on your system, then how did autotools work for you? (or how does it work on github actions?) 😄 |
|
I've tried VS Code too, and it seems to be the only IDE so far that was able to interpret the meson project decently enough. The Gnome Builder is also one of the few that handles the autotools nicely. About the implicit_include_directories, I guess the parsers on the project import plugins of the IDEs don't take the default values into account. On Eclipse not even that did the job. |
3296d42 to
656ff29
Compare
f06d9c4 to
007e267
Compare
mvo5
left a comment
There was a problem hiding this comment.
I like it, nice to see us moving into the more modern meson world!
I notied some things:
- pre-build.sh wants to change configure.ac for version number - that needs an update (to test just run "gpb buildpackae")
- Related to the above - the version: '1' is display in the about dialog. we need to somehow ensure that the version in the debian/changelog and the version in meson.build stay consistent. maybe even just extracting the changelog version into meson.build?
- I think we merged some changes to autotools (like -DGDK_PIXBUF_DISABLE_DEPRECATED and -DG_DISABLE_DEPRECATED) that need to be ported over
- we probably still need xmlto in the build-deps, I guess that is the reason for the if fs.exists("doc/html/C/index.html") - we want to still ship the docs :)
Lots to like otherwise, thanks for working on this!
| vector<DepInformation> deps = pkg->enumDeps(); | ||
| for(unsigned int i=0;i<deps.size();i++) { | ||
| cerr << "deps: " << deps[i].name << endl; | ||
| RPackage *pkg = lister->getPackage("build-essential"); |
There was a problem hiding this comment.
It would be nice to know (maybe in the commit message) why this test fix is part this PR - did something with the meson conversion break the test? Or unrelated?
There was a problem hiding this comment.
These test are not run by Github Actions. There is just no such action in autotools. The change to Meson actually makes them run (and fail).
| ), | ||
| install_dir: join_paths(get_option('datadir'), 'synaptic', 'html', 'figures'), | ||
| ) | ||
| if fs.exists('doc/html/C/index.html') |
There was a problem hiding this comment.
Actually that's not needed at all. Removed.
| dh_auto_build $(DHFLAGS) | ||
| # ubuntu specific for universe langpacks but will not do any | ||
| # harm on debian | ||
| make -C po synaptic.pot |
There was a problem hiding this comment.
IIRC we had this because in ubuntu the language packs extract ".pot" files and then feed it into their rosetta system. I wonder if we can somehow keep the behavior of generating the pot file during the build (or is that done already automatically by meson?).
There was a problem hiding this comment.
It's done by Meson's i18n module https://mesonbuild.com/i18n-module.html
I was not aware of this script.
Version is fixed. But shouldn't this be vise versa? Changelog should be base on the code and version, not opposite,
GgkPixbuf is deprecated itself. So it will be reported anyway.
Actually no. There is nothing to ship. |
No description provided.