diff --git a/meson.build b/meson.build index 864b46a8a..a7f659d8e 100644 --- a/meson.build +++ b/meson.build @@ -18,6 +18,11 @@ if 'java' in wrapper add_languages('java') endif +# See https://github.com/kiwix/kiwix-lib/issues/371 +if target_machine.cpu_family() in ['arm', 'mips', 'm68k', 'ppc'] + extra_libs += '-latomic' +endif + thread_dep = dependency('threads') libicu_dep = dependency('icu-i18n', static:static_deps) libzim_dep = dependency('libzim', version : '>=6.1.1', static:static_deps) diff --git a/src/meson.build b/src/meson.build index ddb188119..e3b678acb 100644 --- a/src/meson.build +++ b/src/meson.build @@ -53,6 +53,7 @@ kiwixlib = library('kiwix', kiwix_sources, include_directories : inc, dependencies : all_deps, + link_args: extra_libs, version: meson.project_version(), install: true, install_dir: install_dir)