summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStefano Facchini <stefano.facchini@gmail.com>2017-09-02 23:31:40 +0200
committerStefano Facchini <stefano.facchini@gmail.com>2017-09-03 10:22:49 +0200
commit88081d711456fef3a97d0d5bf8f003dbbd24ead5 (patch)
treefa3c1247b449d70e0db9d464e82bb786bf577ff9
parent68d94b6dc187a02cb9256ebe43b73ab246482c32 (diff)
downloadbaobab-wip/meson-2.tar.gz
Port to mesonwip/meson-2
-rw-r--r--.gitignore2
-rw-r--r--Makefile.am29
-rwxr-xr-xautogen.sh28
-rwxr-xr-xbuild-aux/post-install.py19
-rw-r--r--configure.ac66
-rw-r--r--data/Makefile.am52
-rw-r--r--data/icons/Makefile.am (renamed from pixmaps/Makefile.am)0
-rw-r--r--data/icons/baobab.svg (renamed from pixmaps/baobab.svg)0
-rw-r--r--data/icons/hicolor/16x16/apps/baobab.png (renamed from pixmaps/hicolor_apps_16x16_baobab.png)bin768 -> 768 bytes
-rw-r--r--data/icons/hicolor/22x22/apps/baobab.png (renamed from pixmaps/hicolor_apps_22x22_baobab.png)bin1108 -> 1108 bytes
-rw-r--r--data/icons/hicolor/24x24/apps/baobab.png (renamed from pixmaps/hicolor_apps_24x24_baobab.png)bin1149 -> 1149 bytes
-rw-r--r--data/icons/hicolor/256x256/apps/baobab.png (renamed from pixmaps/hicolor_apps_256x256_baobab.png)bin56172 -> 56172 bytes
-rw-r--r--data/icons/hicolor/32x32/apps/baobab.png (renamed from pixmaps/hicolor_apps_32x32_baobab.png)bin1577 -> 1577 bytes
-rw-r--r--data/icons/hicolor/48x48/apps/baobab.png (renamed from pixmaps/hicolor_apps_48x48_baobab.png)bin2556 -> 2556 bytes
-rw-r--r--data/icons/hicolor/symbolic/apps/baobab-symbolic.svg (renamed from pixmaps/hicolor_apps_scalable_baobab-symbolic.svg)0
-rw-r--r--data/meson.build31
-rw-r--r--data/org.gnome.baobab.desktop.in (renamed from data/org.gnome.baobab.desktop.in.in)4
-rw-r--r--data/org.gnome.baobab.gschema.xml.in2
-rw-r--r--git.mk350
-rw-r--r--help/Makefile.am27
-rw-r--r--help/meson.build48
-rw-r--r--meson.build34
-rw-r--r--po/meson.build2
-rw-r--r--src/Makefile.am67
-rw-r--r--src/meson.build57
25 files changed, 194 insertions, 624 deletions
diff --git a/.gitignore b/.gitignore
new file mode 100644
index 0000000..89efb0f
--- /dev/null
+++ b/.gitignore
@@ -0,0 +1,2 @@
+build
+*.swp
diff --git a/Makefile.am b/Makefile.am
deleted file mode 100644
index 6bb4c84..0000000
--- a/Makefile.am
+++ /dev/null
@@ -1,29 +0,0 @@
-ACLOCAL_AMFLAGS = -I m4 ${ACLOCAL_FLAGS}
-NULL =
-
-SUBDIRS = src data pixmaps help po
-
-EXTRA_DIST = \
- COPYING.docs
-
-MAINTAINERCLEANFILES = \
- $(GITIGNORE_MAINTAINERCLEANFILES_TOPLEVEL) \
- $(GITIGNORE_MAINTAINERCLEANFILES_MAKEFILE_IN) \
- m4 \
- $(NULL)
-
-dist-hook:
- @if test -d "$(srcdir)/.git"; \
- then \
- echo Creating ChangeLog && \
- (GIT_DIR=$(top_srcdir)/.git \
- ./missing --run git log --stat -M -C --name-status --date=short --no-color) | \
- fmt --split-only > ChangeLog.tmp \
- && mv -f ChangeLog.tmp $(top_distdir)/ChangeLog \
- || ( rm -f ChangeLog.tmp ; \
- echo Failed to generate ChangeLog >&2 ); \
- else \
- echo A git clone is required to generate a ChangeLog >&2; \
- fi
-
--include $(top_srcdir)/git.mk
diff --git a/autogen.sh b/autogen.sh
deleted file mode 100755
index edfaf1f..0000000
--- a/autogen.sh
+++ /dev/null
@@ -1,28 +0,0 @@
-#!/bin/sh
-# Run this to generate all the initial makefiles, etc.
-
-test -n "$srcdir" || srcdir=`dirname "$0"`
-test -n "$srcdir" || srcdir=.
-
-OLDDIR=`pwd`
-cd $srcdir
-
-AUTORECONF=`which autoreconf`
-if test -z $AUTORECONF; then
- echo "*** No autoreconf found, please install it ***"
- exit 1
-fi
-
-GNOMEDOC=`which yelp-build`
-if test -z $GNOMEDOC; then
- echo "*** The tools to build the documentation are not found,"
- echo " please install the yelp-tools package ***"
- exit 1
-fi
-
-autopoint --force || exit $?
-autoreconf --force --install --verbose
-
-cd $OLDDIR
-test -n "$NOCONFIGURE" || "$srcdir/configure" "$@"
-
diff --git a/build-aux/post-install.py b/build-aux/post-install.py
new file mode 100755
index 0000000..c1faf09
--- /dev/null
+++ b/build-aux/post-install.py
@@ -0,0 +1,19 @@
+#!/usr/bin/python3
+
+import os
+import pathlib
+import subprocess
+
+prefix = pathlib.Path(os.environ.get('MESON_INSTALL_PREFIX', '/usr/local'))
+datadir = prefix / 'share'
+destdir = os.environ.get('DESTDIR', '')
+
+if not destdir:
+ print('Compiling gsettings schemas...')
+ subprocess.call(['glib-compile-schemas', str(datadir / 'glib-2.0' / 'schemas')])
+
+ print('Updating icon cache...')
+ subprocess.call(['gtk-update-icon-cache', '-qtf', str(datadir / 'icons' / 'hicolor')])
+
+ print('Updating desktop database...')
+ subprocess.call(['update-desktop-database', '-q', str(datadir / 'applications')])
diff --git a/configure.ac b/configure.ac
deleted file mode 100644
index a056c1e..0000000
--- a/configure.ac
+++ /dev/null
@@ -1,66 +0,0 @@
-dnl -*- mode: m4 -*-
-AC_PREREQ(2.63)
-
-AC_INIT([baobab],
- [3.24.0],
- [http://bugzilla.gnome.org/enter_bug.cgi?product=baobab],
- [baobab])
-
-AC_CONFIG_HEADERS(config.h)
-AC_CONFIG_SRCDIR(src/main.vala)
-AC_CONFIG_MACRO_DIR([m4])
-
-AM_INIT_AUTOMAKE([1.11 tar-ustar dist-xz no-dist-gzip -Wno-portability foreign])
-AM_MAINTAINER_MODE([enable])
-AM_SILENT_RULES([yes])
-
-AC_PROG_CC
-AC_PROG_INSTALL
-AC_PROG_MAKE_SET
-AM_PROG_VALAC([0.25.1])
-PKG_PROG_PKG_CONFIG([0.22])
-
-## don't rerun to this point if we abort
-AC_CACHE_SAVE
-
-GLIB_GSETTINGS
-
-# Resources
-AC_PATH_PROG(GLIB_COMPILE_RESOURCES, glib-compile-resources)
-
-# Mallard help
-YELP_HELP_INIT
-
-APPSTREAM_XML
-
-AM_GNU_GETTEXT([external])
-AM_GNU_GETTEXT_VERSION([0.19.8])
-AC_SUBST([GETTEXT_PACKAGE], [baobab])
-
-PKG_CHECK_MODULES(BAOBAB, [
- gtk+-3.0 >= 3.19.1
- glib-2.0 >= 2.39.90
- gio-2.0 >= 2.30.0
-])
-
-AC_CONFIG_FILES([
-Makefile
-data/Makefile
-data/org.gnome.baobab.gschema.xml
-help/Makefile
-pixmaps/Makefile
-src/Makefile
-po/Makefile.in
-])
-
-AC_OUTPUT
-
-echo "
- Baobab $VERSION
-
- prefix: ${prefix}
- Vala compiler: ${VALAC}
- C compiler: ${CC}
-
- Now type 'make' to build $PACKAGE
-"
diff --git a/data/Makefile.am b/data/Makefile.am
deleted file mode 100644
index 1d5fe3b..0000000
--- a/data/Makefile.am
+++ /dev/null
@@ -1,52 +0,0 @@
-NULL =
-
-baobabappdir = $(datadir)/applications
-baobabapp_in_files = org.gnome.baobab.desktop.in
-baobabapp_DATA = $(baobabapp_in_files:.desktop.in=.desktop)
-
-$(baobabapp_in_files): $(baobabapp_in_files:.desktop.in=.desktop.in.in)
- sed -e "s|\@VERSION\@|@VERSION@|" $< > $@
-
-$(baobabapp_DATA): $(baobabapp_in_files)
- $(AM_V_GEN) $(MSGFMT) --desktop --template $< -d $(top_srcdir)/po -o $@
-
-
-appstream_in_files = org.gnome.baobab.appdata.xml.in
-appstream_XML = $(appstream_in_files:.appdata.xml.in=.appdata.xml)
-@APPSTREAM_XML_RULES@
-
-$(appstream_XML): $(appstream_in_files)
- $(AM_V_GEN) $(MSGFMT) --xml --template $< -d $(top_srcdir)/po -o $@
-
-dbusservicedir = $(datadir)/dbus-1/services
-dbusservice_DATA = org.gnome.baobab.service
-
-org.gnome.baobab.service: Makefile
- $(AM_V_GEN) (echo '[D-BUS Service]'; \
- echo 'Name=org.gnome.baobab'; \
- echo 'Exec=${bindir}/baobab --gapplication-service') > $@.tmp && \
- mv $@.tmp $@
-
-gsettingsschema_in_files = org.gnome.baobab.gschema.xml.in
-gsettings_SCHEMAS = $(gsettingsschema_in_files:.xml.in=.xml)
-@GSETTINGS_RULES@
-
-man_MANS = baobab.1
-
-EXTRA_DIST = \
- org.gnome.baobab.desktop.in.in \
- $(gsettingsschema_in_files) \
- $(man_MANS) \
- $(baobabicon_DATA) \
- $(appstream_in_files) \
- $(NULL)
-
-CLEANFILES = \
- $(baobabapp_in_files) \
- $(baobabapp_DATA) \
- $(gsettings_SCHEMAS) \
- $(appstream_XML) \
- org.gnome.baobab.service \
- $(NULL)
-
--include $(top_srcdir)/git.mk
diff --git a/pixmaps/Makefile.am b/data/icons/Makefile.am
index a8d72d7..a8d72d7 100644
--- a/pixmaps/Makefile.am
+++ b/data/icons/Makefile.am
diff --git a/pixmaps/baobab.svg b/data/icons/baobab.svg
index c5380ed..c5380ed 100644
--- a/pixmaps/baobab.svg
+++ b/data/icons/baobab.svg
diff --git a/pixmaps/hicolor_apps_16x16_baobab.png b/data/icons/hicolor/16x16/apps/baobab.png
index 4f405a1..4f405a1 100644
--- a/pixmaps/hicolor_apps_16x16_baobab.png
+++ b/data/icons/hicolor/16x16/apps/baobab.png
Binary files differ
diff --git a/pixmaps/hicolor_apps_22x22_baobab.png b/data/icons/hicolor/22x22/apps/baobab.png
index 2d9b595..2d9b595 100644
--- a/pixmaps/hicolor_apps_22x22_baobab.png
+++ b/data/icons/hicolor/22x22/apps/baobab.png
Binary files differ
diff --git a/pixmaps/hicolor_apps_24x24_baobab.png b/data/icons/hicolor/24x24/apps/baobab.png
index 3984db2..3984db2 100644
--- a/pixmaps/hicolor_apps_24x24_baobab.png
+++ b/data/icons/hicolor/24x24/apps/baobab.png
Binary files differ
diff --git a/pixmaps/hicolor_apps_256x256_baobab.png b/data/icons/hicolor/256x256/apps/baobab.png
index 688f825..688f825 100644
--- a/pixmaps/hicolor_apps_256x256_baobab.png
+++ b/data/icons/hicolor/256x256/apps/baobab.png
Binary files differ
diff --git a/pixmaps/hicolor_apps_32x32_baobab.png b/data/icons/hicolor/32x32/apps/baobab.png
index 2e147ef..2e147ef 100644
--- a/pixmaps/hicolor_apps_32x32_baobab.png
+++ b/data/icons/hicolor/32x32/apps/baobab.png
Binary files differ
diff --git a/pixmaps/hicolor_apps_48x48_baobab.png b/data/icons/hicolor/48x48/apps/baobab.png
index b15bf3f..b15bf3f 100644
--- a/pixmaps/hicolor_apps_48x48_baobab.png
+++ b/data/icons/hicolor/48x48/apps/baobab.png
Binary files differ
diff --git a/pixmaps/hicolor_apps_scalable_baobab-symbolic.svg b/data/icons/hicolor/symbolic/apps/baobab-symbolic.svg
index be931a6..be931a6 100644
--- a/pixmaps/hicolor_apps_scalable_baobab-symbolic.svg
+++ b/data/icons/hicolor/symbolic/apps/baobab-symbolic.svg
diff --git a/data/meson.build b/data/meson.build
new file mode 100644
index 0000000..c8c53a0
--- /dev/null
+++ b/data/meson.build
@@ -0,0 +1,31 @@
+icondir = join_paths(get_option('datadir'), 'icons/hicolor')
+foreach size: ['16x16', '22x22', '32x32', '48x48', '256x256', 'symbolic']
+ install_subdir('icons/hicolor/' + size, install_dir: icondir)
+endforeach
+
+install_man ('baobab.1')
+
+desktop_file = i18n.merge_file(
+ input: 'org.gnome.baobab.desktop.in',
+ output: 'org.gnome.baobab.desktop',
+ type: 'desktop',
+ po_dir: '../po',
+ install: true,
+ install_dir: join_paths(get_option('datadir'), 'applications'),
+)
+
+appdata_file = i18n.merge_file(
+ input: 'org.gnome.baobab.appdata.xml.in',
+ output: 'org.gnome.baobab.appdata.xml',
+ po_dir: '../po',
+ install: true,
+ install_dir: join_paths(get_option('datadir'), 'appdata'),
+)
+
+gschema_file = i18n.merge_file(
+ input: 'org.gnome.baobab.gschema.xml.in',
+ output: 'org.gnome.baobab.gschema.xml',
+ po_dir: '../po',
+ install: true,
+ install_dir: join_paths(get_option('datadir'), 'glib-2.0', 'schemas')
+)
diff --git a/data/org.gnome.baobab.desktop.in.in b/data/org.gnome.baobab.desktop.in
index 5623bf9..d5290c3 100644
--- a/data/org.gnome.baobab.desktop.in.in
+++ b/data/org.gnome.baobab.desktop.in
@@ -13,8 +13,4 @@ StartupNotify=true
MimeType=inode/directory;
Categories=GTK;GNOME;System;Filesystem;X-GNOME-Utilities;
NotShowIn=KDE;
-X-GNOME-Bugzilla-Bugzilla=GNOME
-X-GNOME-Bugzilla-Product=gnome-utils
-X-GNOME-Bugzilla-Component=baobab
-X-GNOME-Bugzilla-Version=@VERSION@
DBusActivatable=true
diff --git a/data/org.gnome.baobab.gschema.xml.in b/data/org.gnome.baobab.gschema.xml.in
index b966340..41c100f 100644
--- a/data/org.gnome.baobab.gschema.xml.in
+++ b/data/org.gnome.baobab.gschema.xml.in
@@ -1,4 +1,4 @@
-<schemalist gettext-domain="@GETTEXT_PACKAGE@">
+<schemalist gettext-domain="baobab">
<schema id="org.gnome.baobab" path="/org/gnome/baobab/">
<child name="preferences" schema="org.gnome.baobab.preferences"/>
<child name="ui" schema="org.gnome.baobab.ui"/>
diff --git a/git.mk b/git.mk
deleted file mode 100644
index d3c0e35..0000000
--- a/git.mk
+++ /dev/null
@@ -1,350 +0,0 @@
-# git.mk, a small Makefile to autogenerate .gitignore files
-# for autotools-based projects.
-#
-# Copyright 2009, Red Hat, Inc.
-# Copyright 2010,2011,2012,2013 Behdad Esfahbod
-# Written by Behdad Esfahbod
-#
-# Copying and distribution of this file, with or without modification,
-# is permitted in any medium without royalty provided the copyright
-# notice and this notice are preserved.
-#
-# The latest version of this file can be downloaded from:
-GIT_MK_URL = https://raw.githubusercontent.com/behdad/git.mk/master/git.mk
-#
-# Bugs, etc, should be reported upstream at:
-# https://github.com/behdad/git.mk
-#
-# To use in your project, import this file in your git repo's toplevel,
-# then do "make -f git.mk". This modifies all Makefile.am files in
-# your project to -include git.mk. Remember to add that line to new
-# Makefile.am files you create in your project, or just rerun the
-# "make -f git.mk".
-#
-# This enables automatic .gitignore generation. If you need to ignore
-# more files, add them to the GITIGNOREFILES variable in your Makefile.am.
-# But think twice before doing that. If a file has to be in .gitignore,
-# chances are very high that it's a generated file and should be in one
-# of MOSTLYCLEANFILES, CLEANFILES, DISTCLEANFILES, or MAINTAINERCLEANFILES.
-#
-# The only case that you need to manually add a file to GITIGNOREFILES is
-# when remove files in one of mostlyclean-local, clean-local, distclean-local,
-# or maintainer-clean-local make targets.
-#
-# Note that for files like editor backup, etc, there are better places to
-# ignore them. See "man gitignore".
-#
-# If "make maintainer-clean" removes the files but they are not recognized
-# by this script (that is, if "git status" shows untracked files still), send
-# me the output of "git status" as well as your Makefile.am and Makefile for
-# the directories involved and I'll diagnose.
-#
-# For a list of toplevel files that should be in MAINTAINERCLEANFILES, see
-# Makefile.am.sample in the git.mk git repo.
-#
-# Don't EXTRA_DIST this file. It is supposed to only live in git clones,
-# not tarballs. It serves no useful purpose in tarballs and clutters the
-# build dir.
-#
-# This file knows how to handle autoconf, automake, libtool, gtk-doc,
-# gnome-doc-utils, yelp.m4, mallard, intltool, gsettings, dejagnu, appdata,
-# appstream.
-#
-# This makefile provides the following targets:
-#
-# - all: "make all" will build all gitignore files.
-# - gitignore: makes all gitignore files in the current dir and subdirs.
-# - .gitignore: make gitignore file for the current dir.
-# - gitignore-recurse: makes all gitignore files in the subdirs.
-#
-# KNOWN ISSUES:
-#
-# - Recursive configure doesn't work as $(top_srcdir)/git.mk inside the
-# submodule doesn't find us. If you have configure.{in,ac} files in
-# subdirs, add a proxy git.mk file in those dirs that simply does:
-# "include $(top_srcdir)/../git.mk". Add more ..'s to your taste.
-# And add those files to git. See vte/gnome-pty-helper/git.mk for
-# example.
-#
-
-
-
-###############################################################################
-# Variables user modules may want to add to toplevel MAINTAINERCLEANFILES:
-###############################################################################
-
-#
-# Most autotools-using modules should be fine including this variable in their
-# toplevel MAINTAINERCLEANFILES:
-GITIGNORE_MAINTAINERCLEANFILES_TOPLEVEL = \
- $(srcdir)/aclocal.m4 \
- $(srcdir)/autoscan.log \
- $(srcdir)/configure.scan \
- `AUX_DIR=$(srcdir)/$$(cd $(top_srcdir); $(AUTOCONF) --trace 'AC_CONFIG_AUX_DIR:$$1' ./configure.ac); \
- test "x$$AUX_DIR" = "x$(srcdir)/" && AUX_DIR=$(srcdir); \
- for x in \
- ar-lib \
- compile \
- config.guess \
- config.rpath \
- config.sub \
- depcomp \
- install-sh \
- ltmain.sh \
- missing \
- mkinstalldirs \
- test-driver \
- ylwrap \
- ; do echo "$$AUX_DIR/$$x"; done` \
- `cd $(top_srcdir); $(AUTOCONF) --trace 'AC_CONFIG_HEADERS:$$1' ./configure.ac | \
- head -n 1 | while read f; do echo "$(srcdir)/$$f.in"; done`
-#
-# All modules should also be fine including the following variable, which
-# removes automake-generated Makefile.in files:
-GITIGNORE_MAINTAINERCLEANFILES_MAKEFILE_IN = \
- `cd $(top_srcdir); $(AUTOCONF) --trace 'AC_CONFIG_FILES:$$1' ./configure.ac | \
- while read f; do \
- case $$f in Makefile|*/Makefile) \
- test -f "$(srcdir)/$$f.am" && echo "$(srcdir)/$$f.in";; esac; \
- done`
-#
-# Modules that use libtool and use AC_CONFIG_MACRO_DIR() may also include this,
-# though it's harmless to include regardless.
-GITIGNORE_MAINTAINERCLEANFILES_M4_LIBTOOL = \
- `MACRO_DIR=$(srcdir)/$$(cd $(top_srcdir); $(AUTOCONF) --trace 'AC_CONFIG_MACRO_DIR:$$1' ./configure.ac); \
- if test "x$$MACRO_DIR" != "x$(srcdir)/"; then \
- for x in \
- libtool.m4 \
- ltoptions.m4 \
- ltsugar.m4 \
- ltversion.m4 \
- lt~obsolete.m4 \
- ; do echo "$$MACRO_DIR/$$x"; done; \
- fi`
-
-
-
-###############################################################################
-# Default rule is to install ourselves in all Makefile.am files:
-###############################################################################
-
-git-all: git-mk-install
-
-git-mk-install:
- @echo "Installing git makefile"
- @any_failed=; \
- find "`test -z "$(top_srcdir)" && echo . || echo "$(top_srcdir)"`" -name Makefile.am | while read x; do \
- if grep 'include .*/git.mk' $$x >/dev/null; then \
- echo "$$x already includes git.mk"; \
- else \
- failed=; \
- echo "Updating $$x"; \
- { cat $$x; \
- echo ''; \
- echo '-include $$(top_srcdir)/git.mk'; \
- } > $$x.tmp || failed=1; \
- if test x$$failed = x; then \
- mv $$x.tmp $$x || failed=1; \
- fi; \
- if test x$$failed = x; then : else \
- echo "Failed updating $$x"; >&2 \
- any_failed=1; \
- fi; \
- fi; done; test -z "$$any_failed"
-
-git-mk-update:
- wget $(GIT_MK_URL) -O $(top_srcdir)/git.mk
-
-.PHONY: git-all git-mk-install git-mk-update
-
-
-
-###############################################################################
-# Actual .gitignore generation:
-###############################################################################
-
-$(srcdir)/.gitignore: Makefile.am $(top_srcdir)/git.mk
- @echo "git.mk: Generating $@"
- @{ \
- if test "x$(DOC_MODULE)" = x -o "x$(DOC_MAIN_SGML_FILE)" = x; then :; else \
- for x in \
- $(DOC_MODULE)-decl-list.txt \
- $(DOC_MODULE)-decl.txt \
- tmpl/$(DOC_MODULE)-unused.sgml \
- "tmpl/*.bak" \
- $(REPORT_FILES) \
- $(DOC_MODULE).pdf \
- xml html \
- ; do echo "/$$x"; done; \
- FLAVOR=$$(cd $(top_srcdir); $(AUTOCONF) --trace 'GTK_DOC_CHECK:$$2' ./configure.ac); \
- case $$FLAVOR in *no-tmpl*) echo /tmpl;; esac; \
- if echo "$(SCAN_OPTIONS)" | grep -q "\-\-rebuild-types"; then \
- echo "/$(DOC_MODULE).types"; \
- fi; \
- if echo "$(SCAN_OPTIONS)" | grep -q "\-\-rebuild-sections"; then \
- echo "/$(DOC_MODULE)-sections.txt"; \
- fi; \
- if test "$(abs_srcdir)" != "$(abs_builddir)" ; then \
- for x in \
- $(SETUP_FILES) \
- $(DOC_MODULE).types \
- ; do echo "/$$x"; done; \
- fi; \
- fi; \
- if test "x$(DOC_MODULE)$(DOC_ID)" = x -o "x$(DOC_LINGUAS)" = x; then :; else \
- for lc in $(DOC_LINGUAS); do \
- for x in \
- $(if $(DOC_MODULE),$(DOC_MODULE).xml) \
- $(DOC_PAGES) \
- $(DOC_INCLUDES) \
- ; do echo "/$$lc/$$x"; done; \
- done; \
- for x in \
- $(_DOC_OMF_ALL) \
- $(_DOC_DSK_ALL) \
- $(_DOC_HTML_ALL) \
- $(_DOC_MOFILES) \
- $(DOC_H_FILE) \
- "*/.xml2po.mo" \
- "*/*.omf.out" \
- ; do echo /$$x; done; \
- fi; \
- if test "x$(HELP_ID)" = x -o "x$(HELP_LINGUAS)" = x; then :; else \
- for lc in $(HELP_LINGUAS); do \
- for x in \
- $(HELP_FILES) \
- "$$lc.stamp" \
- "$$lc.mo" \
- ; do echo "/$$lc/$$x"; done; \
- done; \
- fi; \
- if test "x$(gsettings_SCHEMAS)" = x; then :; else \
- for x in \
- $(gsettings_SCHEMAS:.xml=.valid) \
- $(gsettings__enum_file) \
- ; do echo "/$$x"; done; \
- fi; \
- if test "x$(appdata_XML)" = x; then :; else \
- for x in \
- $(appdata_XML:.xml=.valid) \
- ; do echo "/$$x"; done; \
- fi; \
- if test "x$(appstream_XML)" = x; then :; else \
- for x in \
- $(appstream_XML:.xml=.valid) \
- ; do echo "/$$x"; done; \
- fi; \
- if test -f $(srcdir)/po/Makefile.in.in; then \
- for x in \
- ABOUT-NLS \
- po/Makefile.in.in \
- po/Makefile.in.in~ \
- po/Makefile.in \
- po/Makefile \
- po/Makevars.template \
- po/POTFILES \
- po/Rules-quot \
- po/stamp-it \
- po/stamp-po \
- po/.intltool-merge-cache \
- "po/*.gmo" \
- "po/*.header" \
- "po/*.mo" \
- "po/*.sed" \
- "po/*.sin" \
- po/$(GETTEXT_PACKAGE).pot \
- intltool-extract.in \
- intltool-merge.in \
- intltool-update.in \
- ; do echo "/$$x"; done; \
- fi; \
- if test -f $(srcdir)/configure; then \
- for x in \
- autom4te.cache \
- configure \
- config.h \
- stamp-h1 \
- libtool \
- config.lt \
- ; do echo "/$$x"; done; \
- fi; \
- if test "x$(DEJATOOL)" = x; then :; else \
- for x in \
- $(DEJATOOL) \
- ; do echo "/$$x.sum"; echo "/$$x.log"; done; \
- echo /site.exp; \
- fi; \
- if test "x$(am__dirstamp)" = x; then :; else \
- echo "$(am__dirstamp)"; \
- fi; \
- if test "x$(findstring libtool,$(LTCOMPILE))" = x -a "x$(findstring libtool,$(LTCXXCOMPILE))" = x -a "x$(GTKDOC_RUN)" = x; then :; else \
- for x in \
- "*.lo" \
- ".libs" "_libs" \
- ; do echo "$$x"; done; \
- fi; \
- for x in \
- .gitignore \
- $(GITIGNOREFILES) \
- $(CLEANFILES) \
- $(PROGRAMS) $(check_PROGRAMS) $(EXTRA_PROGRAMS) \
- $(LIBRARIES) $(check_LIBRARIES) $(EXTRA_LIBRARIES) \
- $(LTLIBRARIES) $(check_LTLIBRARIES) $(EXTRA_LTLIBRARIES) \
- so_locations \
- $(MOSTLYCLEANFILES) \
- $(TEST_LOGS) \
- $(TEST_LOGS:.log=.trs) \
- $(TEST_SUITE_LOG) \
- $(TESTS:=.test) \
- "*.gcda" \
- "*.gcno" \
- $(DISTCLEANFILES) \
- $(am__CONFIG_DISTCLEAN_FILES) \
- $(CONFIG_CLEAN_FILES) \
- TAGS ID GTAGS GRTAGS GSYMS GPATH tags \
- "*.tab.c" \
- $(MAINTAINERCLEANFILES) \
- $(BUILT_SOURCES) \
- $(patsubst %.vala,%.c,$(filter %.vala,$(SOURCES))) \
- $(filter %_vala.stamp,$(DIST_COMMON)) \
- $(filter %.vapi,$(DIST_COMMON)) \
- $(filter $(addprefix %,$(notdir $(patsubst %.vapi,%.h,$(filter %.vapi,$(DIST_COMMON))))),$(DIST_COMMON)) \
- Makefile \
- Makefile.in \
- "*.orig" \
- "*.rej" \
- "*.bak" \
- "*~" \
- ".*.sw[nop]" \
- ".dirstamp" \
- ; do echo "/$$x"; done; \
- for x in \
- "*.$(OBJEXT)" \
- $(DEPDIR) \
- ; do echo "$$x"; done; \
- } | \
- sed "s@^/`echo "$(srcdir)" | sed 's/\(.\)/[\1]/g'`/@/@" | \
- sed 's@/[.]/@/@g' | \
- LC_ALL=C sort | uniq > $@.tmp && \
- mv $@.tmp $@;
-
-all: $(srcdir)/.gitignore gitignore-recurse-maybe
-gitignore: $(srcdir)/.gitignore gitignore-recurse
-
-gitignore-recurse-maybe:
- @for subdir in $(DIST_SUBDIRS); do \
- case " $(SUBDIRS) " in \
- *" $$subdir "*) :;; \
- *) test "$$subdir" = . -o -e "$$subdir/.git" || (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) gitignore || echo "Skipping $$subdir");; \
- esac; \
- done
-gitignore-recurse:
- @for subdir in $(DIST_SUBDIRS); do \
- test "$$subdir" = . -o -e "$$subdir/.git" || (cd $$subdir && $(MAKE) $(AM_MAKEFLAGS) gitignore || echo "Skipping $$subdir"); \
- done
-
-maintainer-clean: gitignore-clean
-gitignore-clean:
- -rm -f $(srcdir)/.gitignore
-
-.PHONY: gitignore-clean gitignore gitignore-recurse gitignore-recurse-maybe
diff --git a/help/Makefile.am b/help/Makefile.am
deleted file mode 100644
index 019254d..0000000
--- a/help/Makefile.am
+++ /dev/null
@@ -1,27 +0,0 @@
-@YELP_HELP_RULES@
-
-HELP_ID = baobab
-
-# List of pages
-HELP_FILES = \
- index.page \
- introduction.page \
- legal.xml \
- pref-view-chart.page \
- problem-permissions.page \
- problem-slow-scan.page \
- question-open-folder.page \
- question-trash.page \
- scan-file-system.page \
- scan-folder.page \
- scan-home.page \
- scan-remote.page
-
-# List of figures to be included
-HELP_MEDIA = \
- media/hicolor_apps_48x48_baobab.png
-
-# List of translations
-HELP_LINGUAS = ca cs da de el es fi fr gl hu id it ko pl pt pt_BR ru sl sv zh_CN
-
--include $(top_srcdir)/git.mk
diff --git a/help/meson.build b/help/meson.build
new file mode 100644
index 0000000..cfbdef8
--- /dev/null
+++ b/help/meson.build
@@ -0,0 +1,48 @@
+help_files = [
+ 'index.page',
+ 'introduction.page',
+ 'pref-view-chart.page',
+ 'problem-permissions.page',
+ 'problem-slow-scan.page',
+ 'question-open-folder.page',
+ 'question-trash.page',
+ 'scan-file-system.page',
+ 'scan-folder.page',
+ 'scan-home.page',
+ 'scan-remote.page',
+ 'legal.xml'
+]
+
+help_media = [
+ 'media/hicolor_apps_48x48_baobab.png'
+]
+
+help_linguas = [
+ 'ca',
+ 'cs',
+ 'da',
+ 'de',
+ 'el',
+ 'es',
+ 'fi',
+ 'fr',
+ 'gl',
+ 'hu',
+ 'id',
+ 'it',
+ 'ko',
+ 'pl',
+ 'pt',
+ 'pt_BR',
+ 'ru',
+ 'sl',
+ 'sv',
+ 'zh_CN'
+]
+
+gnome.yelp(
+ meson.project_name(),
+ sources: help_files,
+ media: help_media,
+ languages: help_linguas,
+)
diff --git a/meson.build b/meson.build
new file mode 100644
index 0000000..549c831
--- /dev/null
+++ b/meson.build
@@ -0,0 +1,34 @@
+project(
+ 'baobab', ['vala', 'c'],
+ version: '3.25.90',
+ license: 'GPL2+',
+ meson_version: '>= 0.41.0',
+)
+
+gnome = import('gnome')
+i18n = import('i18n')
+
+glib = dependency('glib-2.0', version: '>=2.44')
+gio = dependency('gio-2.0', version: '>=2.44')
+gio_unix = dependency('gio-unix-2.0', version: '>=2.44')
+gobject = dependency('gobject-2.0', version: '>=2.44')
+gtk = dependency('gtk+-3.0', version: '>=3.20')
+
+cc = meson.get_compiler('c')
+math = cc.find_library('m', required: false)
+
+conf = configuration_data()
+conf.set_quoted('PACKAGE_NAME', meson.project_name())
+conf.set_quoted('PACKAGE_VERSION', meson.project_version())
+conf.set_quoted('VERSION', meson.project_version())
+conf.set_quoted('GETTEXT_PACKAGE', meson.project_name())
+conf.set_quoted('GNOMELOCALEDIR', join_paths(get_option('prefix'), get_option('datadir'), '/locale'))
+configure_file(output: 'config.h', configuration: conf)
+config_h_dir = include_directories('.')
+
+meson.add_install_script(join_paths('build-aux', 'post-install.py'))
+
+subdir('data')
+subdir('help')
+subdir('po')
+subdir('src')
diff --git a/po/meson.build b/po/meson.build
new file mode 100644
index 0000000..fe664e1
--- /dev/null
+++ b/po/meson.build
@@ -0,0 +1,2 @@
+i18n.gettext(meson.project_name(), preset: 'glib')
+
diff --git a/src/Makefile.am b/src/Makefile.am
deleted file mode 100644
index d0da00a..0000000
--- a/src/Makefile.am
+++ /dev/null
@@ -1,67 +0,0 @@
-NULL =
-
-AM_CPPFLAGS = \
- -DGETTEXT_PACKAGE=\""$(GETTEXT_PACKAGE)"\" \
- -DGNOMELOCALEDIR=\""$(localedir)"\" \
- $(NULL)
-
-bin_PROGRAMS = baobab
-
-BUILT_SOURCES = baobab-resources.c
-
-baobab_VALAFLAGS = \
- --target-glib=2.38 \
- --pkg gtk+-3.0 \
- --pkg gio-2.0 \
- --pkg gio-unix-2.0 \
- --gresources=baobab.gresource.xml \
- $(NULL)
-
-VALA_SOURCES = \
- baobab-application.vala \
- baobab-cellrenderers.vala \
- baobab-chart.vala \
- baobab-treemap.vala \
- baobab-ringschart.vala \
- baobab-location.vala \
- baobab-location-list.vala \
- baobab-scanner.vala \
- baobab-window.vala \
- main.vala \
- $(NULL)
-
-baobab_SOURCES = \
- $(VALA_SOURCES) \
- config.vapi \
- $(BUILT_SOURCES) \
- $(NULL)
-
-resource_files = $(shell $(GLIB_COMPILE_RESOURCES) --generate-dependencies --sourcedir=$(srcdir) $(srcdir)/baobab.gresource.xml)
-baobab-resources.c: baobab.gresource.xml $(resource_files)
- $(AM_V_GEN) $(GLIB_COMPILE_RESOURCES) --target=$@ --sourcedir=$(srcdir) --generate-source $<
-
-AM_CFLAGS = \
- $(BAOBAB_CFLAGS) \
- -Wall \
- -Wno-unused-but-set-variable \
- -Wno-unused-variable \
- $(NULL)
-
-baobab_LDFLAGS = -rdynamic
-baobab_LDADD = \
- -lm \
- $(BAOBAB_LIBS) \
- $(NULL)
-
-MAINTAINERCLEANFILES = \
- *.stamp \
- $(VALA_SOURCES:.vala=.c) \
- $(BUILT_SOURCES) \
- $(NULL)
-
-EXTRA_DIST = \
- baobab.gresource.xml \
- $(resource_files) \
- $(NULL)
-
--include $(top_srcdir)/git.mk
diff --git a/src/meson.build b/src/meson.build
new file mode 100644
index 0000000..bd7977d
--- /dev/null
+++ b/src/meson.build
@@ -0,0 +1,57 @@
+resource_files = files('baobab.gresource.xml')
+resources = gnome.compile_resources('org.gnome.baobab', resource_files, c_name: 'resources')
+
+vapi_sources = [
+ 'config.vapi',
+]
+
+baobab_vala_sources = [
+ 'baobab-application.vala',
+ 'baobab-cellrenderers.vala',
+ 'baobab-chart.vala',
+ 'baobab-location-list.vala',
+ 'baobab-location.vala',
+ 'baobab-ringschart.vala',
+ 'baobab-scanner.vala',
+ 'baobab-treemap.vala',
+ 'baobab-window.vala',
+ 'main.vala'
+]
+
+baobab_sources = [
+ vapi_sources,
+ baobab_vala_sources,
+ resources
+]
+
+baobab_vala_args = [
+ '--target-glib', '2.44',
+ '--vapidir', meson.current_source_dir(),
+ '--gresources', resource_files,
+]
+
+baobab_c_args = [
+ '-include', 'config.h'
+]
+
+baobab_link_args = [
+ '-rdynamic'
+]
+
+baobab_dependencies = [
+ glib,
+ gio,
+ gio_unix,
+ gobject,
+ gtk,
+ math
+]
+
+executable('baobab', baobab_sources,
+ include_directories: config_h_dir,
+ vala_args: baobab_vala_args,
+ c_args: baobab_c_args,
+ dependencies: baobab_dependencies,
+ link_args: baobab_link_args,
+ install: true
+)