aboutsummaryrefslogtreecommitdiff
path: root/meson.build
diff options
context:
space:
mode:
Diffstat (limited to 'meson.build')
-rw-r--r--meson.build46
1 files changed, 5 insertions, 41 deletions
diff --git a/meson.build b/meson.build
index dac9ca6..a4b0c6e 100644
--- a/meson.build
+++ b/meson.build
@@ -1,49 +1,13 @@
-project('libembed', ['cpp'],
- version: '0.1',
- default_options: ['cpp_std=c++2a', 'warning_level=3'],
-)
-
-libzstd = dependency('libzstd')
-
-libembed_sourceset = import('sourceset').source_set()
-libembed_sourceset.add(when: libzstd, if_true: [ libzstd, files('lib/zstd.cpp') ] )
-libembed_conf = libembed_sourceset.apply(configuration_data())
-
-libembed = library('embed', libembed_conf.sources(),
- dependencies: libembed_conf.dependencies()
-)
-
-libembed_dep = declare_dependency(
- link_with: libembed,
- include_directories: include_directories('lib/')
+project('rcc', [],
+ version: '0.1.0',
+ license: 'BSD-2-Clause',
)
prog_python = import('python').find_installation('python3')
-
rcc = generator(prog_python,
output: '@BASENAME@.h',
arguments: [ meson.current_source_dir()/'rcc', '--output=@OUTPUT@', '@EXTRA_ARGS@', '@INPUT@' ]
)
-if not meson.is_subproject()
-resources_h = rcc.process(files('test/resources.xrc'), extra_args: [ '--namespace=staticdata', '-' ])
-
-zstd_dictionary = custom_target('zstd_dictionary',
- output: 'zstd_dict',
- input: 'rcc',
- command: [ prog_python, '@INPUT@', 'Zstd', '--train=@OUTPUT@', files('test/resources.xrc') ]
-)
-
-zstd_resources_h = custom_target('zstd_resources.h',
- output: 'zstd_resources.h',
- input: [ 'rcc', zstd_dictionary ],
- command: [prog_python, '@INPUT0@', '--namespace=zstd_data', '--output=@OUTPUT@', 'Zstd', '--dict=@INPUT1@', files('test/resources.xrc')],
-)
-
-test('libembed',
- executable('embed',
- sources: [ 'test/main.cpp', resources_h, zstd_resources_h ],
- dependencies: [ libembed_dep ]
- )
-)
-endif # meson.is_subproject()
+# example usage:
+#rcc.process(files('res/a.svg'), extra_args: [ '--namespace=svg', 'dump' ])