[eog: 5/21] build: Use / instead of join_paths



commit 2ce1a66bc67288b6ac99551b3ad5bd47afd73d03
Author: Iñigo Martínez <inigomartinez gmail com>
Date:   Thu Jun 27 13:46:54 2019 +0200

    build: Use / instead of join_paths
    
    Since meson 0.49, the `/` character can be used to join paths[0], so
    all the instances of `join_paths` have been replaced.
    
    [0] http://mesonbuild.com/Release-notes-for-0-49-0.html#joining-paths-with-

 data/icons/meson.build | 10 +++++-----
 data/meson.build       |  6 +++---
 meson.build            | 20 ++++++++++----------
 src/meson.build        |  8 ++++----
 tests/meson.build      |  4 ++--
 5 files changed, 24 insertions(+), 24 deletions(-)
---
diff --git a/data/icons/meson.build b/data/icons/meson.build
index 34a4f397..bd400c3d 100644
--- a/data/icons/meson.build
+++ b/data/icons/meson.build
@@ -1,22 +1,22 @@
 install_subdir(
   'scalable/apps',
-  install_dir: join_paths(eog_datadir, 'icons/hicolor/scalable')
+  install_dir: eog_datadir / 'icons/hicolor/scalable'
 )
 
 install_subdir(
   'symbolic',
-  install_dir: join_paths(eog_datadir, 'icons/hicolor')
+  install_dir: eog_datadir / 'icons/hicolor'
 )
 
 foreach icon_size: ['16x16', '22x22', '24x24', '32x32', '48x48']
   install_subdir(
-    join_paths(icon_size, 'actions'),
-    install_dir: join_paths(eog_pkgdatadir, 'icons/hicolor', icon_size),
+    icon_size / 'actions',
+    install_dir: eog_pkgdatadir / 'icons/hicolor' / icon_size,
     exclude_files: ['eog-plugin.svg', 'slideshow-play.svg', 'eog-image-gallery.svg']
   )
 endforeach
 
 install_subdir(
   'scalable/actions',
-  install_dir: join_paths(eog_pkgdatadir, 'icons/hicolor/scalable')
+  install_dir: eog_pkgdatadir / 'icons/hicolor/scalable'
 )
diff --git a/data/meson.build b/data/meson.build
index 378863a3..0a6c21c4 100644
--- a/data/meson.build
+++ b/data/meson.build
@@ -32,7 +32,7 @@ i18n.merge_file(
   output: desktop,
   po_dir: po_dir,
   install: true,
-  install_dir: join_paths(eog_datadir, 'applications')
+  install_dir: eog_datadir / 'applications'
 )
 
 appdata = 'eog.appdata.xml'
@@ -43,7 +43,7 @@ i18n.merge_file(
   output: appdata,
   po_dir: po_dir,
   install: true,
-  install_dir: join_paths(eog_datadir, 'metainfo')
+  install_dir: eog_datadir / 'metainfo'
 )
 
 schema_conf = configuration_data()
@@ -61,5 +61,5 @@ configure_file(
 
 install_data(
   'eog.convert',
-  install_dir: join_paths(eog_datadir, 'GConf', 'gsettings')
+  install_dir: eog_datadir / 'GConf/gsettings'
 )
diff --git a/meson.build b/meson.build
index 1d43985d..46104936 100644
--- a/meson.build
+++ b/meson.build
@@ -17,16 +17,16 @@ eog_gir_ns = 'Eog'
 eog_gir_version = '1.0'
 
 eog_prefix = get_option('prefix')
-eog_datadir = join_paths(eog_prefix, get_option('datadir'))
-eog_libdir = join_paths(eog_prefix, get_option('libdir'))
-eog_localedir = join_paths(eog_prefix, get_option('localedir'))
+eog_datadir = eog_prefix / get_option('datadir')
+eog_libdir = eog_prefix / get_option('libdir')
+eog_localedir = eog_prefix / get_option('localedir')
 
-eog_pkgdatadir = join_paths(eog_datadir, meson.project_name())
-eog_pkglibdir = join_paths(eog_libdir, meson.project_name())
-eog_pkglibexecdir = join_paths(eog_prefix, get_option('libexecdir'), meson.project_name())
+eog_pkgdatadir = eog_datadir / meson.project_name()
+eog_pkglibdir = eog_libdir / meson.project_name()
+eog_pkglibexecdir = eog_prefix / get_option('libexecdir') / meson.project_name()
 
-eog_pluginsdir = join_paths(eog_pkglibdir, 'plugins')
-eog_schemadir = join_paths(eog_datadir, 'glib-2.0', 'schemas')
+eog_pluginsdir = eog_pkglibdir / 'plugins'
+eog_schemadir = eog_datadir / 'glib-2.0/schemas'
 
 cc = meson.get_compiler('c')
 
@@ -185,8 +185,8 @@ gnome = import('gnome')
 i18n = import('i18n')
 pkg = import('pkgconfig')
 
-data_dir = join_paths(meson.source_root(), 'data')
-po_dir = join_paths(meson.source_root(), 'po')
+data_dir = meson.source_root() / 'data'
+po_dir = meson.source_root() / 'po'
 
 top_inc = include_directories('.')
 
diff --git a/src/meson.build b/src/meson.build
index 747b76b4..956de4b6 100644
--- a/src/meson.build
+++ b/src/meson.build
@@ -94,7 +94,7 @@ endif
 
 install_headers(
   headers,
-  subdir: join_paths(eog_api_name, meson.project_name())
+  subdir: eog_api_name / meson.project_name()
 )
 
 sources += gnome.compile_resources(
@@ -139,7 +139,7 @@ cflags = [
   '-DLIBDIR="@0@"'.format(eog_libdir)
 ]
 
-symbol_map = join_paths(meson.current_source_dir(), 'symbol.map')
+symbol_map = meson.current_source_dir() / 'symbol.map'
 
 ldflags = []
 if have_version_script
@@ -214,8 +214,8 @@ eog = executable(
 if enable_introspection
   gir_sources = sources + headers
 
-  gir_dir = join_paths(eog_pkgdatadir, 'gir-' + eog_gir_version)
-  typelib_dir = join_paths(eog_pkglibdir, 'girepository-' + eog_gir_version)
+  gir_dir = eog_pkgdatadir / 'gir-' + eog_gir_version
+  typelib_dir = eog_pkglibdir / 'girepository-' + eog_gir_version
 
   gnome.generate_gir(
     eog,
diff --git a/tests/meson.build b/tests/meson.build
index e5ebd32e..5d0e4f59 100644
--- a/tests/meson.build
+++ b/tests/meson.build
@@ -1,5 +1,5 @@
-tests_execdir = join_paths(eog_pkglibexecdir, 'installed-tests')
-tests_metadir = join_paths(eog_datadir, 'installed-tests', meson.project_name())
+tests_execdir = eog_pkglibexecdir / 'installed-tests'
+tests_metadir = eog_datadir / 'installed-tests' / meson.project_name()
 
 tests_data = files(
   'actions.feature',


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]