[gnome-tweaks/wip/christopherdavis/python3-deprecation-fix] build: Use python module instead of deprecated python3 module



commit 6e694f8db8ae27bab686c3b46d6cae77cdc763d5
Author: Christopher Davis <brainblasted disroot org>
Date:   Tue Feb 26 13:43:27 2019 -0500

    build: Use python module instead of deprecated python3 module
    
    meson has a different python module that can handle both
    python2 and python3. Use of the python3 module is deprecated.
    
    This commit has us use the new module's rules.

 meson.build | 7 ++++---
 1 file changed, 4 insertions(+), 3 deletions(-)
---
diff --git a/meson.build b/meson.build
index e19b4c8..04ec8be 100644
--- a/meson.build
+++ b/meson.build
@@ -1,11 +1,12 @@
 project('gnome-tweaks',
   version: '3.31.90',
-  meson_version: '>= 0.40.0'
+  meson_version: '>= 0.46.0'
 )
 
 gnome = import('gnome')
 i18n = import('i18n')
-python3 = import('python3')
+python = import('python')
+py_installation = python.find_installation('python3')
 
 prefix = get_option('prefix')
 
@@ -13,7 +14,7 @@ bindir = join_paths(prefix, get_option('bindir'))
 datadir = join_paths(prefix, get_option('datadir'))
 libexecdir = join_paths(prefix, get_option('libexecdir'))
 localedir = join_paths(prefix, get_option('localedir'))
-pythondir = join_paths(prefix, python3.sysconfig_path('purelib'))
+pythondir = join_paths(prefix, py_installation.get_path('purelib'))
 
 pkgdatadir = join_paths(datadir, meson.project_name())
 


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