From 621b91fbd2ca27c67b17e3dbfcaae730b8ed5c94 Mon Sep 17 00:00:00 2001 From: Jaeyun Date: Fri, 1 Feb 2019 12:53:18 +0900 Subject: [PATCH] [Meson] configuration to install ini add config to set sub-plugins install prefix Signed-off-by: Jaeyun Jung --- meson.build | 15 ++++++++++++--- nnstreamer.ini | 6 ------ nnstreamer.ini.in | 6 ++++++ 3 files changed, 18 insertions(+), 9 deletions(-) delete mode 100644 nnstreamer.ini create mode 100644 nnstreamer.ini.in diff --git a/meson.build b/meson.build index 2373e2a..c37dfd2 100644 --- a/meson.build +++ b/meson.build @@ -35,11 +35,15 @@ plugins_install_dir = join_paths(nnstreamer_libdir, 'gstreamer-' + gst_api_veris subplugins_install_dir = nnstreamer_libdir examples_install_dir = nnstreamer_bindir +# nnstreamer sub-plugins path +subplugin_install_prefix = join_paths(nnstreamer_prefix, 'lib', 'nnstreamer') + nnstreamer_conf.set('PREFIX', nnstreamer_prefix) nnstreamer_conf.set('EXEC_PREFIX', nnstreamer_bindir) nnstreamer_conf.set('LIB_INSTALL_DIR', libs_install_dir) nnstreamer_conf.set('GST_INSTALL_DIR', plugins_install_dir) nnstreamer_conf.set('INCLUDE_INSTALL_DIR', nnstreamer_includedir) +nnstreamer_conf.set('SUBPLUGIN_INSTALL_PREFIX', subplugin_install_prefix) # Dependencies glib_dep = dependency('glib-2.0') @@ -106,14 +110,19 @@ if get_option('enable-test') or get_option('install-example') subdir('nnstreamer_example') endif -# Install .ini -install_data('nnstreamer.ini', install_dir : nnstreamer_inidir) - # Build unittests if get_option('enable-test') subdir('tests') endif +# Install .ini +configure_file(input: 'nnstreamer.ini.in', output: 'nnstreamer.ini', + install: true, + install_dir: nnstreamer_inidir, + configuration: nnstreamer_conf +) + +# Install .pc configure_file(input: 'nnstreamer.pc.in', output: 'nnstreamer.pc', install: true, install_dir: join_paths(libs_install_dir, 'pkgconfig'), diff --git a/nnstreamer.ini b/nnstreamer.ini deleted file mode 100644 index e34ef34..0000000 --- a/nnstreamer.ini +++ /dev/null @@ -1,6 +0,0 @@ -[filter] -filters=/usr/lib/nnstreamer/filters/ -customfilters=/usr/lib/nnstreamer/customfilters/ - -[decoder] -decoders=/usr/lib/nnstreamer/decoders/ diff --git a/nnstreamer.ini.in b/nnstreamer.ini.in new file mode 100644 index 0000000..e43c62c --- /dev/null +++ b/nnstreamer.ini.in @@ -0,0 +1,6 @@ +[filter] +filters=@SUBPLUGIN_INSTALL_PREFIX@/filters/ +customfilters=@SUBPLUGIN_INSTALL_PREFIX@/customfilters/ + +[decoder] +decoders=@SUBPLUGIN_INSTALL_PREFIX@/decoders/ -- 2.7.4