[gupnp] build: Move config.h to private folder
- From: Jens Georg <jensgeorg src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gupnp] build: Move config.h to private folder
- Date: Sat, 19 Jun 2021 16:37:42 +0000 (UTC)
commit 98b2f54fa6138c8975d5595e63b3d128e1d27072
Author: Jens Georg <mail jensge org>
Date: Sat Jun 19 18:20:14 2021 +0200
build: Move config.h to private folder
This is necessary to use it nicely in a subproject, see
https://mesonbuild.com/Wrap-best-practices-and-tips.html#do-not-put-configh-in-external-search-path
internal/meson.build | 3 +++
libgupnp/meson.build | 2 +-
meson.build | 6 ++----
3 files changed, 6 insertions(+), 5 deletions(-)
---
diff --git a/internal/meson.build b/internal/meson.build
new file mode 100644
index 0000000..4060f6a
--- /dev/null
+++ b/internal/meson.build
@@ -0,0 +1,3 @@
+config_h = configure_file(output : 'config.h', configuration : conf)
+config_h_inc = include_directories('.')
+
diff --git a/libgupnp/meson.build b/libgupnp/meson.build
index 1f79b8a..266a138 100644
--- a/libgupnp/meson.build
+++ b/libgupnp/meson.build
@@ -106,7 +106,7 @@ libgupnp = library(
darwin_versions : darwin_versions,
dependencies : dependencies + system_deps,
c_args : context_manager_args,
- include_directories: include_directories('..'),
+ include_directories: [include_directories('..'), config_h_inc],
install: true
)
diff --git a/meson.build b/meson.build
index f31e4be..0b8f298 100644
--- a/meson.build
+++ b/meson.build
@@ -18,9 +18,7 @@ add_project_arguments(cc.get_supported_arguments('-Werror=deprecated-declaration
conf.set('GLIB_VERSION_MIN_REQUIRED', 'GLIB_VERSION_' + glib_version.underscorify())
conf.set('GLIB_VERSION_MAX_ALLOWED', 'GLIB_VERSION_' + glib_version.underscorify())
-config_h = configure_file(output : 'config.h', configuration : conf)
-add_project_arguments('-DHAVE_CONFIG_H=1', language : 'c')
-
+subdir('internal')
guul = subproject('guul', default_options : ['default_library=static'])
gssdp_dep = dependency('gssdp-1.2', version : '>= 1.2.3', default_options: ['sniffer=false'])
@@ -34,7 +32,7 @@ dependencies = [
dependency('gobject-2.0', version : '>= ' + glib_version),
dependency('libsoup-2.4', version : '>= 2.48.0'),
gssdp_dep,
- dependency('libxml-2.0')
+ dependency('libxml-2.0'),
]
subdir('libgupnp')
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]