aboutsummaryrefslogtreecommitdiff
path: root/mesonbuild
diff options
context:
space:
mode:
authorDylan Baker <dylan@pnwbakers.com>2020-03-04 11:36:49 -0800
committerDylan Baker <dylan@pnwbakers.com>2020-03-05 09:31:29 -0800
commitb231ff36df8e5cb21fa41a6380516c6cf5bf9c4e (patch)
treedc76fd26378448325498f87c4d778844d6b48273 /mesonbuild
parente3beaf87a58d8143ad05048b029314779e5e19b2 (diff)
downloadmeson-b231ff36df8e5cb21fa41a6380516c6cf5bf9c4e.zip
meson-b231ff36df8e5cb21fa41a6380516c6cf5bf9c4e.tar.gz
meson-b231ff36df8e5cb21fa41a6380516c6cf5bf9c4e.tar.bz2
Remove some uses of mesonlib.run_once
These are basically doing what mlog.log(..., once=True) does, so lets just use that. The once argument to mlog is newer, so these probably should have been changed already.
Diffstat (limited to 'mesonbuild')
-rw-r--r--mesonbuild/modules/gnome.py4
-rw-r--r--mesonbuild/modules/i18n.py5
2 files changed, 4 insertions, 5 deletions
diff --git a/mesonbuild/modules/gnome.py b/mesonbuild/modules/gnome.py
index 4ff40ad..ec8935e 100644
--- a/mesonbuild/modules/gnome.py
+++ b/mesonbuild/modules/gnome.py
@@ -83,11 +83,11 @@ class GnomeModule(ExtensionModule):
mlog.bold('https://bugzilla.gnome.org/show_bug.cgi?id=774368'))
@staticmethod
- @mesonlib.run_once
def _print_gdbus_warning():
mlog.warning('Code generated with gdbus_codegen() requires the root directory be added to\n'
' include_directories of targets with GLib < 2.51.3:',
- mlog.bold('https://github.com/mesonbuild/meson/issues/1387'))
+ mlog.bold('https://github.com/mesonbuild/meson/issues/1387'),
+ once=True)
@FeatureNewKwargs('gnome.compile_resources', '0.37.0', ['gresource_bundle', 'export', 'install_header'])
@permittedKwargs({'source_dir', 'c_name', 'dependencies', 'export', 'gresource_bundle', 'install_header',
diff --git a/mesonbuild/modules/i18n.py b/mesonbuild/modules/i18n.py
index 80ec8bd..2652e7d 100644
--- a/mesonbuild/modules/i18n.py
+++ b/mesonbuild/modules/i18n.py
@@ -16,7 +16,7 @@ import shutil
from os import path
from .. import coredata, mesonlib, build, mlog
-from ..mesonlib import MesonException, run_once
+from ..mesonlib import MesonException
from . import ModuleReturnValue
from . import ExtensionModule
from ..interpreterbase import permittedKwargs, FeatureNew, FeatureNewKwargs
@@ -59,9 +59,8 @@ PRESET_ARGS = {
class I18nModule(ExtensionModule):
@staticmethod
- @run_once
def nogettext_warning():
- mlog.warning('Gettext not found, all translation targets will be ignored.')
+ mlog.warning('Gettext not found, all translation targets will be ignored.', once=True)
return ModuleReturnValue(None, [])
@staticmethod