summaryrefslogtreecommitdiffstats
path: root/meson.build
diff options
context:
space:
mode:
authorDave Davenport <qball@gmpclient.org>2017-10-16 19:18:19 +0200
committerDave Davenport <qball@gmpclient.org>2017-10-16 19:18:19 +0200
commit65dfa23e2a9706e28427b04fdd8da105a94fec1d (patch)
treed4218a10155b9ce2f178eae2356c290f3cdf911b /meson.build
parent12e7b67ddd5a8bcb23e1e122b7f257cf55883ce2 (diff)
[Meson] Fix pkg-config file generation with meson.
Diffstat (limited to 'meson.build')
-rw-r--r--meson.build25
1 files changed, 14 insertions, 11 deletions
diff --git a/meson.build b/meson.build
index f82c7517..62fd1c3a 100644
--- a/meson.build
+++ b/meson.build
@@ -239,20 +239,23 @@ install_data(
install_dir: themedir
)
-pkgconfig = import('pkgconfig')
-pkgconfig.generate(
- name: 'rofi',
- filebase: 'rofi',
- description: 'Header files for rofi plugins',
- version: meson.project_version(),
- requires_private: [
- 'glib-2.0 >= 2.40',
- 'gmodule-2.0',
- 'cairo',
- ],
+pkg = import('pkgconfig')
+pkgconfig_conf = configuration_data()
+pkgconfig_conf.set('prefix', get_option('prefix'))
+pkgconfig_conf.set('exec_prefix', '${prefix}')
+pkgconfig_conf.set('VERSION', meson.project_version())
+pkgconfig_conf.set('libdir', join_paths('${prefix}',get_option('libdir')))
+pkgconfig_conf.set('includedir', join_paths('${prefix}',get_option('includedir')))
+
+configure_file(
+ input: 'pkgconfig/rofi.pc.in',
+ output: 'rofi.pc',
+ configuration: pkgconfig_conf,
+ install_dir: join_paths(get_option('libdir'), 'pkgconfig'),
)
+
test('history test', executable('history.test', [
'test/history-test.c',
],