Skip to content

Commit

Permalink
Merge branch 'dev'
Browse files Browse the repository at this point in the history
  • Loading branch information
herumi committed Mar 7, 2024
2 parents 9c0f5d3 + 9f53572 commit 487a6d1
Showing 1 changed file with 10 additions and 4 deletions.
14 changes: 10 additions & 4 deletions meson.build
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,8 @@ project(
default_options: 'b_ndebug=if-release'
)

install_subdir('xbyak', install_dir: get_option('includedir'))
include_dir = get_option('prefix') / get_option('includedir')
install_subdir('xbyak', install_dir: include_dir)

xbyak_dep = declare_dependency(include_directories: include_directories('.'))

Expand All @@ -22,15 +23,19 @@ import('pkgconfig').generate(
name: meson.project_name(),
description: 'JIT assembler for x86(IA32), x64(AMD64, x86-64)',
version: meson.project_version(),
url: 'https://github.com/herumi/xbyak'
url: 'https://github.com/herumi/xbyak',
variables: ['includedir=@0@'.format(include_dir)],
dataonly: true,
)

shared_cmake_dir = get_option('prefix') / 'share/cmake/xbyak'
if meson.version().version_compare('>=0.50.0')
cmake = import('cmake')

cmake.write_basic_package_version_file(
name: meson.project_name(),
version: meson.project_version()
version: meson.project_version(),
install_dir: shared_cmake_dir,
)

cmake_conf = configuration_data()
Expand All @@ -40,6 +45,7 @@ if meson.version().version_compare('>=0.50.0')
cmake.configure_package_config_file(
name: meson.project_name(),
input: 'cmake'/'meson-config.cmake.in',
configuration: cmake_conf
configuration: cmake_conf,
install_dir: shared_cmake_dir,
)
endif

0 comments on commit 487a6d1

Please sign in to comment.