Skip to content

Commit

Permalink
meson: Refactoring
Browse files Browse the repository at this point in the history
  • Loading branch information
ryonakano committed Jan 22, 2025
1 parent e785b9e commit eaec312
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 10 deletions.
29 changes: 20 additions & 9 deletions examples/meson.build
Original file line number Diff line number Diff line change
@@ -1,9 +1,20 @@
executable('example', 'live-chart.vala', dependencies: deps + [livechart_dep], build_by_default: false)
executable('example-fixed-max', 'fixed-max.vala', dependencies: deps + [livechart_dep], build_by_default: false)
executable('example-hide-parts', 'hide-parts.vala', dependencies: deps + [livechart_dep], build_by_default: false)
executable('example-configure-labels', 'configure-labels.vala', dependencies: deps + [livechart_dep], build_by_default: false)
executable('example-remove-serie', 'remove-serie.vala', dependencies: deps + [livechart_dep], build_by_default: false)
executable('example-replace-chart', 'replace-chart.vala', dependencies: deps + [livechart_dep], build_by_default: false)
executable('example-static-renderer', 'static-renderer.vala', dependencies: deps + [livechart_dep], build_by_default: false)
executable('example-static-chart', 'static-chart.vala', dependencies: deps + [livechart_dep], build_by_default: false)
executable('example-usec', 'live-chart-usec.vala', dependencies: deps + [livechart_dep], build_by_default: false)
examples = [
# [target name, [sources...]]
['example', ['live-chart.vala']],
['example-fixed-max', ['fixed-max.vala']],
['example-hide-parts', ['hide-parts.vala']],
['example-configure-labels', ['configure-labels.vala']],
['example-remove-serie', ['remove-serie.vala']],
['example-replace-chart', ['replace-chart.vala']],
['example-static-renderer', ['static-renderer.vala']],
['example-static-chart', ['static-chart.vala']],
['example-usec', ['live-chart-usec.vala']],
]

foreach example : examples
executable(example[0],
example[1],
dependencies: deps + [livechart_dep],
build_by_default: false
)
endforeach
10 changes: 9 additions & 1 deletion tests/meson.build
Original file line number Diff line number Diff line change
Expand Up @@ -30,5 +30,13 @@ test_sources = files(
)

vala_args += ['--enable-deprecated']
test('livechart-test', executable('livechart-test', test_sources, vala_args: vala_args, dependencies: deps + [livechart_dep], build_by_default: false))
test('livechart-test',
executable(
'livechart-test',
test_sources,
vala_args: vala_args,
dependencies: deps + [livechart_dep],
build_by_default: false
)
)

0 comments on commit eaec312

Please sign in to comment.