[libpeas] build: fix min/max version warnings
- From: Christian Hergert <chergert src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [libpeas] build: fix min/max version warnings
- Date: Wed, 9 Feb 2022 01:37:49 +0000 (UTC)
commit 7e007a651120ef4a9043afc9ef0b1c140731eae9
Author: Christian Hergert <chergert redhat com>
Date: Tue Feb 8 17:37:09 2022 -0800
build: fix min/max version warnings
We don't want these applied to the gir compilation, so manually add the
project_c_args to the targets we care about having min/max glib version
applied.
libpeas-gtk/meson.build | 2 +-
libpeas/meson.build | 4 ++--
loaders/lua5.1/meson.build | 2 +-
loaders/python/meson.build | 2 +-
loaders/python3/meson.build | 2 +-
meson.build | 4 ++--
peas-demo/meson.build | 2 +-
peas-demo/plugins/helloworld/meson.build | 2 +-
peas-demo/plugins/secondtime/meson.build | 2 +-
9 files changed, 11 insertions(+), 11 deletions(-)
---
diff --git a/libpeas-gtk/meson.build b/libpeas-gtk/meson.build
index daf98ec6..01e10eb9 100644
--- a/libpeas-gtk/meson.build
+++ b/libpeas-gtk/meson.build
@@ -49,7 +49,7 @@ libpeas_gtk_sha = library(
darwin_versions: lib_version_osx,
include_directories: rootdir,
dependencies: libpeas_gtk_deps,
- c_args: libpeas_gtk_c_args,
+ c_args: project_c_args + libpeas_gtk_c_args,
link_args: libpeas_gtk_link_args,
install: true,
)
diff --git a/libpeas/meson.build b/libpeas/meson.build
index d32c6b91..f3199e9b 100644
--- a/libpeas/meson.build
+++ b/libpeas/meson.build
@@ -107,8 +107,8 @@ libpeas_sha = library(
darwin_versions: lib_version_osx,
include_directories: [rootdir, libpeas_srcdir],
dependencies: libpeas_deps,
- c_args: libpeas_c_args + hidden_visibility_args,
- objc_args: libpeas_c_args,
+ c_args: project_c_args + libpeas_c_args + hidden_visibility_args,
+ objc_args: project_c_args + libpeas_c_args,
link_args: libpeas_link_args,
install: true,
)
diff --git a/loaders/lua5.1/meson.build b/loaders/lua5.1/meson.build
index fc1f5662..f87707d9 100644
--- a/loaders/lua5.1/meson.build
+++ b/loaders/lua5.1/meson.build
@@ -33,7 +33,7 @@ lua51_loader_sha = shared_module(
lua51_loader_c + lua51_loader_res,
include_directories: rootdir,
dependencies: lua51_loader_deps,
- c_args: lua51_loader_c_args,
+ c_args: project_c_args + lua51_loader_c_args,
install: true,
install_dir: join_paths(
pkglibdir,
diff --git a/loaders/python/meson.build b/loaders/python/meson.build
index 215f3eff..9ca733ab 100644
--- a/loaders/python/meson.build
+++ b/loaders/python/meson.build
@@ -36,7 +36,7 @@ python2_loader_sha = shared_module(
python2_loader_c + python2_loader_res,
include_directories: rootdir,
dependencies: python2_loader_deps,
- c_args: python2_loader_c_args,
+ c_args: project_c_args + python2_loader_c_args,
install: true,
install_dir: join_paths(
pkglibdir,
diff --git a/loaders/python3/meson.build b/loaders/python3/meson.build
index a97c81ee..d6f9ebad 100644
--- a/loaders/python3/meson.build
+++ b/loaders/python3/meson.build
@@ -36,7 +36,7 @@ python3_loader_sha = shared_module(
python3_loader_c + python3_loader_res,
include_directories: rootdir,
dependencies: python3_loader_deps,
- c_args: python3_loader_c_args,
+ c_args: project_c_args + python3_loader_c_args,
install: true,
install_dir: join_paths(
pkglibdir,
diff --git a/meson.build b/meson.build
index ccb3c6c9..ba250ea4 100644
--- a/meson.build
+++ b/meson.build
@@ -214,10 +214,10 @@ glib_version_arr = glib_req_version.split('.')
glib_major_version = glib_version_arr[0]
glib_minor_version = glib_version_arr[1]
-add_project_arguments([
+project_c_args = [
'-DGLIB_VERSION_MIN_REQUIRED=GLIB_VERSION_@0@_@1@'.format(glib_major_version, glib_minor_version),
'-DGLIB_VERSION_MAX_ALLOWED=GLIB_VERSION_@0@_@1@'.format(glib_major_version, glib_minor_version),
-], language: 'c')
+]
module_suffix = []
if build_machine.system() == 'darwin'
diff --git a/peas-demo/meson.build b/peas-demo/meson.build
index e9872104..a3ec53b2 100644
--- a/peas-demo/meson.build
+++ b/peas-demo/meson.build
@@ -17,7 +17,7 @@ peas_demo_c_args = [
executable(
peas_demo_name,
peas_demo_c,
- c_args: peas_demo_c_args,
+ c_args: project_c_args + peas_demo_c_args,
dependencies: [libpeas_gtk_dep],
install: true,
)
diff --git a/peas-demo/plugins/helloworld/meson.build b/peas-demo/plugins/helloworld/meson.build
index 73743615..c4ad81cb 100644
--- a/peas-demo/plugins/helloworld/meson.build
+++ b/peas-demo/plugins/helloworld/meson.build
@@ -18,7 +18,7 @@ libhelloworld_lib = shared_library(
libhelloworld_c,
include_directories: rootdir,
dependencies: [gtk_dep, libpeas_gtk_dep],
- c_args: libhelloworld_c_args,
+ c_args: project_c_args + libhelloworld_c_args,
install_dir: join_paths(peas_demo_plugins_dir, 'helloworld'),
install: true,
)
diff --git a/peas-demo/plugins/secondtime/meson.build b/peas-demo/plugins/secondtime/meson.build
index e79097a5..c1631a79 100644
--- a/peas-demo/plugins/secondtime/meson.build
+++ b/peas-demo/plugins/secondtime/meson.build
@@ -17,7 +17,7 @@ libsecondtime_lib = shared_library(
libsecondtime_c,
include_directories: rootdir,
dependencies: [gtk_dep, libpeas_dep],
- c_args: libsecondtime_c_args,
+ c_args: project_c_args + libsecondtime_c_args,
install_dir: join_paths(peas_demo_plugins_dir, 'secondtime'),
install: true,
)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]