diff -Nru pangomm-2.46.2/ChangeLog pangomm-2.46.3/ChangeLog --- pangomm-2.46.2/ChangeLog 2021-12-05 15:44:15.419206600 +0000 +++ pangomm-2.46.3/ChangeLog 2022-09-21 14:52:15.274570700 +0000 @@ -1,3 +1,60 @@ +2022-09-21 Kjell Ahlstedt + + 2.46.3 + +2022-09-12 Kjell Ahlstedt + + Convert README to README.md + +2022-05-24 Chun-wei Fan + + meson/MSVC: Re-organize warning-related compiler flags + + Add a short description for each of the warning-related compiler flags that we + apply globally. + + Also, apply '/wd4267' only when we are building a 64-bit build, as that warning + should only be related to 64-bit builds. + +2022-05-23 Chun-wei Fan + + Meson: Apply /wd4828 for building gendef.exe only + + ...as that warning is only generated when building gendef.exe. Also, only + build gendef.exe when glibmm's gmmproc is unable to produce pangomm headers + that can export pangomm symbols via compiler directives. + + Move the '/utf-8' check to be with the other compiler flags. + +2022-05-20 Kjell Ahlstedt + + meson.build: Avoid configuration warnings + +2022-02-27 Kjell Ahlstedt + + meson.build: Check if Perl is required for building documentation + + New versions of mm-common use the Python scripts doc_postprocess.py + and doc_install.py instead of the Perl scripts doc-postprocess.pl and + doc-install.pl when documentation is built. + +2022-02-22 Kjell Ahlstedt + + Context::get_font_map(): Fix reference count + + pango_context_get_font_map() returns "(transfer none)". + See https://mail.gnome.org/archives/gtkmm-list/2022-February/msg00031.html + +2022-02-15 Kjell Ahlstedt + + meson.build: Specify 'check' option in run_command() + + The default value will be changed in future Meson releases. + + Don't use deprecated python3.path(). + Let import('python').find_installation() always find the python + installation used to run Meson. + 2021-12-05 Kjell Ahlstedt 2.46.2 @@ -1452,53 +1509,3 @@ 2.26.1 -2010-04-16 Murray Cumming - - Regenerated C documentation XML. - - * pango/src/pango_docs.xml: Regenerated with the improved docextract_to_xml.py. - -2010-03-17 Murray Cumming - - Regenerated pango function .defs. - - * pango/src/pango_methods.defs: Regnerated with h2defs.py thought there is - no significant change. - -2009-09-21 Murray Cumming - - 2.26.0 - -2009-09-19 Daniel Elstner - - Support Automake silent rules - - * configure.ac: Call the AM_SILENT_RULES macro if it is defined. - (AM_INIT_AUTOMAKE): Add check-news option. - (MM_INIT_MODULE): Move block below Automake initialization. - -2009-09-07 Daniel Elstner - - Update Doxygen configuration for Doxygen 1.6.1 - - * docs/reference/Doxyfile.in: Update file using Doxygen 1.6.1. - (SORT_MEMBERS_CTORS_1ST): Set option to YES. - -2009-09-07 Daniel Elstner - - Delete obsolete MAINTAINERS file - -2009-08-28 Daniel Elstner - - Increment version to 2.25.1.3 and update news - - * configure.ac (AC_INIT): Bump version to pangomm 2.25.1.3. - * NEWS: Write news entry for pangomm 2.25.1.3. - -2009-08-28 Daniel Elstner - - Fix documentation location in pkg-config files - - * pango/pangomm{,-uninstalled}.pc.in (htmlrefpub): Point to - library.gnome.org. - diff -Nru pangomm-2.46.2/configure.ac pangomm-2.46.3/configure.ac --- pangomm-2.46.2/configure.ac 2021-12-05 15:44:14.739203700 +0000 +++ pangomm-2.46.3/configure.ac 2022-09-21 14:48:50.000000000 +0000 @@ -15,7 +15,7 @@ ## You should have received a copy of the GNU Lesser General Public License ## along with this library. If not, see . -AC_INIT([pangomm], [2.46.2], +AC_INIT([pangomm], [2.46.3], [https://gitlab.gnome.org/GNOME/pangomm/issues/], [pangomm], [http://www.gtkmm.org/]) AC_PREREQ([2.59]) diff -Nru pangomm-2.46.2/debian/changelog pangomm-2.46.3/debian/changelog --- pangomm-2.46.2/debian/changelog 2022-09-01 20:48:29.000000000 +0000 +++ pangomm-2.46.3/debian/changelog 2022-09-21 16:35:07.000000000 +0000 @@ -1,3 +1,11 @@ +pangomm (2.46.3-1) unstable; urgency=medium + + * New upstream release + * debian/control.in: Bump minimum meson to 0.55.0 + * Stop installing README.md: it only contains build instructions + + -- Jeremy Bicha Wed, 21 Sep 2022 12:35:07 -0400 + pangomm (2.46.2-2) unstable; urgency=medium * debian/watch: Watch for 2.46.x releases. diff -Nru pangomm-2.46.2/debian/control pangomm-2.46.3/debian/control --- pangomm-2.46.2/debian/control 2022-09-01 20:48:29.000000000 +0000 +++ pangomm-2.46.3/debian/control 2022-09-21 16:35:07.000000000 +0000 @@ -6,7 +6,7 @@ Section: libs Priority: optional Maintainer: Debian GNOME Maintainers -Uploaders: Martin Pitt , Michael Biebl , Sebastian Dröge +Uploaders: Jeremy Bicha , Michael Biebl Build-Depends: debhelper-compat (= 13), dh-sequence-gnome, doxygen, @@ -15,7 +15,7 @@ libglibmm-2.4-dev (>= 2.48.0), libpango1.0-dev (>= 1.41.0), libxml-parser-perl, - meson (>= 0.54.0), + meson (>= 0.55.0), mm-common (>= 0.9.8), xsltproc Standards-Version: 4.6.1 diff -Nru pangomm-2.46.2/debian/control.in pangomm-2.46.3/debian/control.in --- pangomm-2.46.2/debian/control.in 2022-09-01 20:48:29.000000000 +0000 +++ pangomm-2.46.3/debian/control.in 2022-09-21 16:35:07.000000000 +0000 @@ -11,7 +11,7 @@ libglibmm-2.4-dev (>= 2.48.0), libpango1.0-dev (>= 1.41.0), libxml-parser-perl, - meson (>= 0.54.0), + meson (>= 0.55.0), mm-common (>= 0.9.8), xsltproc Standards-Version: 4.6.1 diff -Nru pangomm-2.46.2/debian/libpangomm-1.4-1v5.docs pangomm-2.46.3/debian/libpangomm-1.4-1v5.docs --- pangomm-2.46.2/debian/libpangomm-1.4-1v5.docs 2022-09-01 20:48:29.000000000 +0000 +++ pangomm-2.46.3/debian/libpangomm-1.4-1v5.docs 2022-09-21 16:35:07.000000000 +0000 @@ -1,3 +1,2 @@ AUTHORS NEWS -README diff -Nru pangomm-2.46.2/docs/reference/meson.build pangomm-2.46.3/docs/reference/meson.build --- pangomm-2.46.2/docs/reference/meson.build 2021-12-05 15:44:14.775203700 +0000 +++ pangomm-2.46.3/docs/reference/meson.build 2022-09-21 14:48:50.000000000 +0000 @@ -142,7 +142,7 @@ # Install Devhelp file and html files. meson.add_install_script( - python3.path(), doc_reference_py, 'install_doc', + python3, doc_reference_py, 'install_doc', doctool_dir, devhelp_file.full_path(), install_devhelpdir, @@ -165,7 +165,7 @@ if can_add_dist_script # Distribute built files and files copied by mm-common-get. meson.add_dist_script( - python3.path(), doc_reference_py, 'dist_doc', + python3, doc_reference_py, 'dist_doc', doctool_dir, doctool_dist_dir, meson.current_build_dir(), diff -Nru pangomm-2.46.2/meson.build pangomm-2.46.3/meson.build --- pangomm-2.46.2/meson.build 2021-12-05 15:44:14.775203700 +0000 +++ pangomm-2.46.3/meson.build 2022-09-21 14:48:50.000000000 +0000 @@ -1,13 +1,14 @@ # This file is part of pangomm. project('pangomm', 'cpp', - version: '2.46.2', + version: '2.46.3', license: 'LGPLv2.1+', default_options: [ - 'cpp_std=c++11' + 'cpp_std=c++11', + 'warning_level=1', ], - meson_version: '>= 0.54.0', # required for meson.override_dependency() - # and dep.get_variable(internal:) + meson_version: '>= 0.55.0', # required for meson.add_dist_script(python3, ...) + # and meson.add_install_script(python3, ...) ) pangomm_api_version = '1.4' @@ -44,7 +45,7 @@ cpp_compiler = meson.get_compiler('cpp') is_msvc = cpp_compiler.get_id() == 'msvc' -python3 = import('python').find_installation('python3') +python3 = import('python').find_installation() python_version = python3.language_version() python_version_req = '>= 3.5' @@ -59,7 +60,7 @@ import sys sys.exit(os.path.isdir("@0@") or os.path.isfile("@0@")) '''.format(project_source_root / '.git') -is_git_build = run_command(python3, '-c', cmd_py).returncode() != 0 +is_git_build = run_command(python3, '-c', cmd_py, check: false).returncode() != 0 # Are we testing a dist tarball while it's being built? # There ought to be a better way. https://github.com/mesonbuild/meson/issues/6866 @@ -73,10 +74,12 @@ if is_dist_check message('Looks like a tarball is being tested. ' + \ 'Option "dist-warnings" is used instead of "warnings".') - warning_level = get_option('dist-warnings') + cpp_warnings = get_option('dist-warnings') else - warning_level = get_option('warnings') + cpp_warnings = get_option('warnings') endif +warning_level = get_option('warning_level').to_int() +werror = get_option('werror') build_deprecated_api = get_option('build-deprecated-api') build_documentation_opt = get_option('build-documentation') build_documentation = build_documentation_opt == 'true' or \ @@ -139,7 +142,6 @@ mm_common_get = find_program('mm-common-get', required: true) endif m4 = find_program('m4', required: maintainer_mode) # Used by gmmproc (in glibmm) -perl = find_program('perl', required: maintainer_mode or build_documentation) doxygen = find_program('doxygen', required: build_documentation) dot = find_program('dot', required: build_documentation) # Used by Doxygen xsltproc = find_program('xsltproc', required: build_documentation) @@ -155,19 +157,36 @@ if maintainer_mode # Copy files to untracked/build_scripts and untracked/docs. run_command(mm_common_get, '--force', script_dir, - project_source_root / 'untracked' / 'docs') + project_source_root / 'untracked' / 'docs', + check: true, + ) else cmd_py = ''' import os import sys sys.exit(os.path.isfile("@0@")) '''.format(generate_binding_py) - file_exists = run_command(python3, '-c', cmd_py).returncode() != 0 + file_exists = run_command(python3, '-c', cmd_py, check: false).returncode() != 0 if not file_exists error('Missing files in untracked/. You must enable maintainer-mode.') endif endif +# Check if perl is required and available. +doc_perl_prop = run_command( + python3, doc_reference_py, 'get_script_property', + '', # MMDOCTOOLDIR is not used + 'requires_perl', + check: false, +) +doc_requires_perl = true +if doc_perl_prop.returncode() == 0 and doc_perl_prop.stdout() == 'false' + doc_requires_perl = false +endif + +perl = find_program('perl', required: maintainer_mode or \ + (build_documentation and doc_requires_perl)) + # pangomm's own script files. pangomm_script_dir = project_source_root / 'tools' dummy_header_py = pangomm_script_dir / 'dummy-header.py' @@ -180,8 +199,6 @@ msvc14x_toolset_ver = '' if is_msvc - add_project_arguments(cpp_compiler.get_supported_arguments([ '/utf-8', '/wd4828']), language: 'cpp') - # Check for the first line in a file generated with gmmproc, # to see which gmmproc version was used if maintainer_mode @@ -198,7 +215,7 @@ # Enable __declspec(dllexport) if the pangomm headers generated from the .hg files # were generated using a recent enough gmmproc - build_shared_libs_directly = run_command(check_gmmproc_ver_cmd).returncode() == 0 + build_shared_libs_directly = run_command(check_gmmproc_ver_cmd, check: false).returncode() == 0 message('Using __declspec(dllexport) to build pangomm: @0@'.format(build_shared_libs_directly ? 'YES' : 'NO')) # Put in the toolset version if the build is done with Visual Studio @@ -219,24 +236,25 @@ endif # Set compiler warnings. +# Meson warns if any of the /W1, /W2, /W3, /W4, /Wall, -Wall, -Wextra, -Werror +# compiler options are added with add_project_arguments(). +# Avoid such warnings, when possible. +# See _warn_about_builtin_args() in meson/mesonbuild/interpreter/interpreter.py. warning_flags = [] -if warning_level == 'min' - if is_msvc - warning_flags = ['/W3'] - else - warning_flags = ['-Wall'] +if cpp_warnings == 'min' + if warning_level == 0 + warning_flags = is_msvc ? ['/W2'] : ['-Wall'] endif -elif warning_level == 'max' or warning_level == 'fatal' - if is_msvc - warning_flags = ['/W4'] - else - warning_flags = '-pedantic -Wall -Wextra -Wformat-security -Wsuggest-override -Wshadow -Wno-long-long'.split() +elif cpp_warnings == 'max' or cpp_warnings == 'fatal' + if warning_level < 3 + warning_flags = is_msvc ? ['/W4'] : ['-pedantic', '-Wall', '-Wextra'] endif - if warning_level == 'fatal' - if is_msvc - warning_flags += ['/WX'] - else - warning_flags += ['-Werror'] + if not is_msvc + warning_flags += '-Wformat-security -Wsuggest-override -Wshadow -Wno-long-long'.split() + endif + if cpp_warnings == 'fatal' + if not werror + warning_flags += is_msvc ? ['/WX'] : ['-Werror'] endif deprecations = 'G PANGO GLIBMM SIGCXX'.split() foreach d : deprecations @@ -251,10 +269,20 @@ # MSVC: Ignore warnings that aren't really harmful, but make those # that should not be overlooked stand out. if is_msvc - foreach wd : ['/FImsvc_recommended_pragmas.h', '/wd4267', '/EHsc'] - disabled_warning = cpp_compiler.get_supported_arguments(wd) - add_project_arguments(disabled_warning, language: 'cpp') - endforeach + disable_warnings_list = [ + '/FImsvc_recommended_pragmas.h', # Turn off harmless warnings but make potentially + # dangerous ones glaring, distributed with GLib + '/EHsc', # avoid warnings caused by exception handling model used + '/utf-8', # Avoid C4819 unicode conversion warnings when building on CJK locales + ] + if host_machine.cpu_family() == 'x86_64' or host_machine.cpu_family() == 'aarch64' + # 'var' : conversion from 'size_t' to 'type', possible loss of data (applies on 64-bit builds) + disable_warnings_list += '/wd4267' + endif + add_project_arguments( + cpp_compiler.get_supported_arguments(disable_warnings_list), + language: 'cpp' + ) endif # add_dist_script() is not allowed in a subproject if meson.version() < 0.58.0. @@ -270,13 +298,13 @@ if can_add_dist_script # Add a ChangeLog file to the distribution directory. meson.add_dist_script( - python3.path(), dist_changelog_py, + python3, dist_changelog_py, project_source_root, ) # Add build scripts to the distribution directory, and delete .gitignore # files and an empty $MESON_PROJECT_DIST_ROOT/build/ directory. meson.add_dist_script( - python3.path(), dist_build_scripts_py, + python3, dist_build_scripts_py, project_source_root, 'untracked' / 'build_scripts', ) @@ -319,7 +347,8 @@ meson.project_name() + ' ' + meson.project_version(), '', ' Maintainer mode: @0@@1@'.format(maintainer_mode_opt, real_maintainer_mode), - ' Compiler warnings: @0@'.format(warning_level), + ' Compiler warnings: @0@ (warning_level: @1@, werror: @2@)'. \ + format(cpp_warnings, warning_level, werror), ' Build deprecated API: @0@'.format(build_deprecated_api), 'Build HTML documentation: @0@@1@'.format(build_documentation_opt, real_build_documentation), 'Directories:', diff -Nru pangomm-2.46.2/MSVC_NMake/gendef/meson.build pangomm-2.46.3/MSVC_NMake/gendef/meson.build --- pangomm-2.46.2/MSVC_NMake/gendef/meson.build 2021-12-05 15:44:14.735203500 +0000 +++ pangomm-2.46.3/MSVC_NMake/gendef/meson.build 2022-09-21 14:48:50.000000000 +0000 @@ -1,9 +1,10 @@ # MSVC_NMake/gendef -# Input: - -# Output: - +# Input: is_msvc, build_shared_libs_directly +# Output: gendef # Used to generate the .def file required to obtain the import .lib file -if is_msvc - gendef = executable('gendef', 'gendef.cc', install: false,) +if is_msvc and not build_shared_libs_directly + gendef_cxx_flags = cpp_compiler.get_supported_arguments(['/wd4828']) + gendef = executable('gendef', 'gendef.cc', cpp_args: gendef_cxx_flags, install: false,) endif diff -Nru pangomm-2.46.2/NEWS pangomm-2.46.3/NEWS --- pangomm-2.46.2/NEWS 2021-12-05 15:44:14.739203700 +0000 +++ pangomm-2.46.3/NEWS 2022-09-21 14:48:50.000000000 +0000 @@ -1,3 +1,19 @@ +2.46.3 (stable): + +* Context::get_font_map(): Fix reference count + (Kjell Ahlstedt) + +Build: +* Meson build: Specify 'check' option in run_command() + Will be necessary with future versions of Meson. + Require Meson >= 0.55.0 +* Meson build: Check if Perl is required for building documentation +* Meson build: Avoid unnecessary configuration warnings + (Kjell Ahlstedt) +* Meson build: Re-organize warning-related compiler flags for MSVC + (Chun-wei Fan) + + 2.46.2 (stable): Build: diff -Nru pangomm-2.46.2/pango/pangomm/meson.build pangomm-2.46.3/pango/pangomm/meson.build --- pangomm-2.46.2/pango/pangomm/meson.build 2021-12-05 15:44:14.803203800 +0000 +++ pangomm-2.46.3/pango/pangomm/meson.build 2022-09-21 14:48:50.000000000 +0000 @@ -175,6 +175,7 @@ meson.current_build_dir(), src_untracked_pangomm, hg_ccg_basenames, + check: true, ) built_cc_files = [ rel_untracked_pangomm / 'wrap_init.cc' ] @@ -254,7 +255,7 @@ # Install built .h and _p.h files. meson.add_install_script( - python3.path(), generate_binding_py, 'install_built_h_files', + python3, generate_binding_py, 'install_built_h_files', built_h_cc_dir, install_includedir / pangomm_pcname / 'pangomm', # subdir below {prefix} hg_ccg_basenames @@ -263,7 +264,7 @@ if can_add_dist_script # Distribute built files. meson.add_dist_script( - python3.path(), generate_binding_py, 'dist_built_files', + python3, generate_binding_py, 'dist_built_files', built_h_cc_dir, untracked_pangomm, hg_ccg_basenames, diff -Nru pangomm-2.46.2/pango/src/context.ccg pangomm-2.46.3/pango/src/context.ccg --- pangomm-2.46.2/pango/src/context.ccg 2021-12-05 15:44:14.895204300 +0000 +++ pangomm-2.46.3/pango/src/context.ccg 2022-09-21 14:48:50.000000000 +0000 @@ -25,7 +25,7 @@ Glib::ArrayHandle< Glib::RefPtr > Context::list_families() const { //Get array: - PangoFontFamily** pFamilies = 0; + PangoFontFamily** pFamilies = nullptr; int n_families = 0; pango_context_list_families(const_cast(gobj()), &pFamilies, &n_families); @@ -35,7 +35,7 @@ Pango::FontMetrics Context::get_metrics(const FontDescription& desc) const { - return FontMetrics(pango_context_get_metrics(const_cast(gobj()), desc.gobj(), 0)); + return FontMetrics(pango_context_get_metrics(const_cast(gobj()), desc.gobj(), nullptr)); } ListHandle_Item Context::itemize(const Glib::ustring& text, const AttrList& attrs) const @@ -43,7 +43,7 @@ return ListHandle_Item( pango_itemize(const_cast(gobj()), text.c_str(), 0, text.bytes(), - const_cast(attrs.gobj()), 0), + const_cast(attrs.gobj()), nullptr), Glib::OWNERSHIP_DEEP); } @@ -75,4 +75,3 @@ } } /* namespace Pango */ - diff -Nru pangomm-2.46.2/pango/src/context.hg pangomm-2.46.3/pango/src/context.hg --- pangomm-2.46.2/pango/src/context.hg 2021-12-05 15:44:14.903204200 +0000 +++ pangomm-2.46.3/pango/src/context.hg 2022-09-21 14:48:50.000000000 +0000 @@ -88,8 +88,8 @@ _WRAP_METHOD(void set_font_map(const Glib::RefPtr& font_map), pango_context_set_font_map) - _WRAP_METHOD(Glib::RefPtr get_font_map(), pango_context_get_font_map) - _WRAP_METHOD(Glib::RefPtr get_font_map() const, pango_context_get_font_map) + _WRAP_METHOD(Glib::RefPtr get_font_map(), pango_context_get_font_map, refreturn) + _WRAP_METHOD(Glib::RefPtr get_font_map() const, pango_context_get_font_map, refreturn, constversion) _WRAP_METHOD(guint get_serial() const, pango_context_get_serial) @@ -174,4 +174,3 @@ }; } /* namespace Pango */ - diff -Nru pangomm-2.46.2/README pangomm-2.46.3/README --- pangomm-2.46.2/README 2021-12-05 15:44:14.739203700 +0000 +++ pangomm-2.46.3/README 1970-01-01 00:00:00.000000000 +0000 @@ -1,84 +0,0 @@ -This is pangomm, a C++ API for Pango. -See http://www.gtkmm.org/ - -# Building - -Whenever possible, you should use the official binary packages approved by the -supplier of your operating system, such as your Linux distribution. - -## Building on Windows - -See README.win32 - -## Building from a release tarball - -Extract the tarball and go to the extracted directory: - $ tar xf pangomm-@PANGOMM_VERSION@.tar.xz - $ cd pangomm-@PANGOMM_VERSION@ - -It's easiest to build with Meson, if the tarball was made with Meson, -and to build with Autotools, if the tarball was made with Autotools. -Then you don't have to use maintainer-mode. - -How do you know how the tarball was made? If it was made with Meson, -it contains files in untracked/pango/pangomm/ and other subdirectories -of untracked/. - -### Building from a tarball with Meson - -Don't call the builddir 'build'. There is a directory called 'build' with -files used by Autotools. - - $ meson --prefix /some_directory --libdir lib your_builddir . - $ cd your_builddir - -If the tarball was made with Autotools, you must enable maintainer-mode: - $ meson configure -Dmaintainer-mode=true - -Then, regardless of how the tarball was made: - $ ninja - $ ninja install - -### Building from a tarball with Autotools - -If the tarball was made with Autotools: - $ ./configure --prefix=/some_directory -If the tarball was made with Meson, you must enable maintainer-mode: - $ ./autogen.sh --prefix=/some_directory - -Then, regardless of how the tarball was made: - $ make - $ make install - -## Building from git - -Building from git can be difficult so you should prefer building from -a release tarball unless you need to work on the pangomm code itself. - -jhbuild can be a good help - https://gitlab.gnome.org/GNOME/jhbuild - https://wiki.gnome.org/Projects/Jhbuild - -### Building from git with Meson - -Maintainer-mode is enabled by default when you build from a git clone. - -Don't call the builddir 'build'. There is a directory called 'build' with -files used by Autotools. - - $ meson --prefix /some_directory --libdir lib your_builddir . - $ cd your_builddir - $ ninja - $ ninja install -You can create a tarball like so: - $ ninja dist - -### Building from git with Autotools - - $ ./autogen.sh --prefix=/some_directory - $ make - $ make install -You can create a tarball like so: - $ make distcheck -or - $ make dist diff -Nru pangomm-2.46.2/README.md pangomm-2.46.3/README.md --- pangomm-2.46.2/README.md 1970-01-01 00:00:00.000000000 +0000 +++ pangomm-2.46.3/README.md 2022-09-21 14:48:50.000000000 +0000 @@ -0,0 +1,103 @@ +# pangomm +This is pangomm, a C++ API for Pango. +See http://www.gtkmm.org/ + +# Building + +Whenever possible, you should use the official binary packages approved by the +supplier of your operating system, such as your Linux distribution. + +## Building on Windows + +See README.win32 + +## Building from a release tarball + +Extract the tarball and go to the extracted directory: +``` + $ tar xf pangomm-@PANGOMM_VERSION@.tar.xz + $ cd pangomm-@PANGOMM_VERSION@ +``` + +It's easiest to build with Meson, if the tarball was made with Meson, +and to build with Autotools, if the tarball was made with Autotools. +Then you don't have to use maintainer-mode. + +How do you know how the tarball was made? If it was made with Meson, +it contains files in untracked/pango/pangomm/ and other subdirectories +of untracked/. + +### Building from a tarball with Meson + +Don't call the builddir 'build'. There is a directory called 'build' with +files used by Autotools. +``` + $ meson --prefix /some_directory --libdir lib your_builddir . + $ cd your_builddir +``` +If the tarball was made with Autotools, you must enable maintainer-mode: +``` + $ meson configure -Dmaintainer-mode=true +``` + +Then, regardless of how the tarball was made: +``` + $ ninja + $ ninja install +``` +### Building from a tarball with Autotools + +If the tarball was made with Autotools: +``` + $ ./configure --prefix=/some_directory +``` +If the tarball was made with Meson, you must enable maintainer-mode: +``` + $ ./autogen.sh --prefix=/some_directory +``` + +Then, regardless of how the tarball was made: +``` + $ make + $ make install +``` +## Building from git + +Building from git can be difficult so you should prefer building from +a release tarball unless you need to work on the pangomm code itself. + +jhbuild can be a good help +- https://gitlab.gnome.org/GNOME/jhbuild +- https://wiki.gnome.org/Projects/Jhbuild +- https://gnome.pages.gitlab.gnome.org/jhbuild + +### Building from git with Meson + +Maintainer-mode is enabled by default when you build from a git clone. + +Don't call the builddir 'build'. There is a directory called 'build' with +files used by Autotools. +``` + $ meson --prefix /some_directory --libdir lib your_builddir . + $ cd your_builddir + $ ninja + $ ninja install +``` +You can create a tarball like so: +``` + $ ninja dist +``` +### Building from git with Autotools +``` + $ ./autogen.sh --prefix=/some_directory + $ make + $ make install +``` +You can create a tarball like so: +``` + $ make distcheck +``` +or +``` + $ make dist +```