mirror of
https://github.com/storytold/harfbuzz.git
synced 2026-11-24 16:31:14 +01:00
[fontations] Ouch
This commit is contained in:
1 parent
395270e494
commit
6cac2a1ae0
1 file changed
+34
@@ -0,0 +1,34 @@
|
||||
rust = import('unstable-rust')
|
||||
|
||||
hb_rs = rust.bindgen(
|
||||
input : '../hb.h',
|
||||
output : 'hb.rs',
|
||||
include_directories: incsrc,
|
||||
args : ['--allowlist-function=hb_.*', '--allowlist-type=hb_.*'],
|
||||
#args : ['--no-rustfmt-bindings'],
|
||||
)
|
||||
|
||||
cargo = find_program('cargo')
|
||||
|
||||
libharfbuzz_fontations = custom_target(
|
||||
'harfbuzz_fontations',
|
||||
input: ['lib.rs'],
|
||||
output: ['libharfbuzz_fontations.so'],
|
||||
depends: [hb_rs],
|
||||
env: ['OUT_DIR=' + meson.current_build_dir()],
|
||||
command: [
|
||||
cargo, 'build',
|
||||
'--release',
|
||||
'--lib',
|
||||
'--target-dir', meson.current_build_dir(),
|
||||
'-Z', 'unstable-options',
|
||||
'--artifact-dir', meson.current_build_dir(),
|
||||
'--manifest-path', meson.current_source_dir() / 'Cargo.toml'
|
||||
],
|
||||
install: true,
|
||||
install_dir: join_paths(get_option('prefix'), 'lib'),
|
||||
)
|
||||
|
||||
harfbuzz_fontations_dep = declare_dependency(
|
||||
link_with: libharfbuzz_fontations,
|
||||
)
|
||||
Reference in new issue
Block a user