Merge pull request #11156 from obsidiansystems/fix-bsd-pthread

Fix some BSD builds missing pthread functions
This commit is contained in:
John Ericson 2024-07-22 13:58:41 -04:00 committed by GitHub
commit 046cc8cbb3
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
18 changed files with 43 additions and 1 deletions

View File

@ -61,6 +61,12 @@ let
workDir = null;
};
# Work around weird `--as-needed` linker behavior with BSD, see
# https://github.com/mesonbuild/meson/issues/3593
bsdNoLinkAsNeeded = finalAttrs: prevAttrs: lib.optionalAttrs stdenv.hostPlatform.isBSD {
mesonFlags = [ (lib.mesonBool "b_asneeded" false) ] ++ prevAttrs.mesonFlags or [];
};
in
scope: {
inherit stdenv versionSuffix;
@ -130,5 +136,8 @@ scope: {
inherit resolvePath filesetToSource;
mkMesonDerivation = f: stdenv.mkDerivation (lib.extends localSourceLayer f);
mkMesonDerivation = f: stdenv.mkDerivation
(lib.extends
(lib.composeExtensions bsdNoLinkAsNeeded localSourceLayer)
f);
}

View File

@ -30,6 +30,8 @@ deps_public_maybe_subproject = [
]
subdir('build-utils-meson/subprojects')
subdir('build-utils-meson/threads')
nlohmann_json = dependency('nlohmann_json', version : '>= 3.9')
deps_public += nlohmann_json

View File

@ -29,6 +29,8 @@ deps_public_maybe_subproject = [
]
subdir('build-utils-meson/subprojects')
subdir('build-utils-meson/threads')
# TODO rename, because it will conflict with downstream projects
configdata.set_quoted('PACKAGE_VERSION', meson.project_version())

View File

@ -26,6 +26,8 @@ deps_public_maybe_subproject = [
]
subdir('build-utils-meson/subprojects')
subdir('build-utils-meson/threads')
nlohmann_json = dependency('nlohmann_json', version : '>= 3.9')
deps_public += nlohmann_json

View File

@ -26,6 +26,8 @@ deps_public_maybe_subproject = [
]
subdir('build-utils-meson/subprojects')
subdir('build-utils-meson/threads')
nlohmann_json = dependency('nlohmann_json', version : '>= 3.9')
deps_public += nlohmann_json

View File

@ -29,6 +29,8 @@ deps_public_maybe_subproject = [
]
subdir('build-utils-meson/subprojects')
subdir('build-utils-meson/threads')
# TODO rename, because it will conflict with downstream projects
configdata.set_quoted('PACKAGE_VERSION', meson.project_version())

View File

@ -26,6 +26,7 @@ deps_public_maybe_subproject = [
]
subdir('build-utils-meson/subprojects')
subdir('build-utils-meson/threads')
pubsetbuf_test = '''
#include <iostream>

View File

@ -27,6 +27,8 @@ deps_public_maybe_subproject = [
]
subdir('build-utils-meson/subprojects')
subdir('build-utils-meson/threads')
# TODO rename, because it will conflict with downstream projects
configdata.set_quoted('PACKAGE_VERSION', meson.project_version())

View File

@ -25,6 +25,8 @@ deps_public_maybe_subproject = [
]
subdir('build-utils-meson/subprojects')
subdir('build-utils-meson/threads')
# TODO rename, because it will conflict with downstream projects
configdata.set_quoted('PACKAGE_VERSION', meson.project_version())

View File

@ -28,6 +28,8 @@ deps_public_maybe_subproject = [
]
subdir('build-utils-meson/subprojects')
subdir('build-utils-meson/threads')
subdir('build-utils-meson/export-all-symbols')
add_project_arguments(

View File

@ -27,6 +27,8 @@ deps_public_maybe_subproject = [
]
subdir('build-utils-meson/subprojects')
subdir('build-utils-meson/threads')
rapidcheck = dependency('rapidcheck')
deps_public += rapidcheck

View File

@ -25,6 +25,8 @@ deps_public_maybe_subproject = [
]
subdir('build-utils-meson/subprojects')
subdir('build-utils-meson/threads')
subdir('build-utils-meson/export-all-symbols')
rapidcheck = dependency('rapidcheck')

View File

@ -24,6 +24,8 @@ deps_public_maybe_subproject = [
]
subdir('build-utils-meson/subprojects')
subdir('build-utils-meson/threads')
subdir('build-utils-meson/export-all-symbols')
rapidcheck = dependency('rapidcheck')

View File

@ -24,6 +24,8 @@ deps_public_maybe_subproject = [
]
subdir('build-utils-meson/subprojects')
subdir('build-utils-meson/threads')
subdir('build-utils-meson/export-all-symbols')
rapidcheck = dependency('rapidcheck')

View File

@ -25,6 +25,8 @@ deps_public_maybe_subproject = [
]
subdir('build-utils-meson/subprojects')
subdir('build-utils-meson/threads')
rapidcheck = dependency('rapidcheck')
deps_public += rapidcheck

View File

@ -25,6 +25,8 @@ deps_public_maybe_subproject = [
]
subdir('build-utils-meson/subprojects')
subdir('build-utils-meson/threads')
subdir('build-utils-meson/export-all-symbols')
sqlite = dependency('sqlite3', 'sqlite', version : '>=3.6.19')

View File

@ -23,6 +23,8 @@ deps_public_maybe_subproject = [
]
subdir('build-utils-meson/subprojects')
subdir('build-utils-meson/threads')
rapidcheck = dependency('rapidcheck')
deps_public += rapidcheck

View File

@ -25,6 +25,8 @@ deps_public_maybe_subproject = [
]
subdir('build-utils-meson/subprojects')
subdir('build-utils-meson/threads')
subdir('build-utils-meson/export-all-symbols')
rapidcheck = dependency('rapidcheck')