mirror of
https://github.com/privatevoid-net/nix-super.git
synced 2024-11-24 23:06:16 +02:00
Merge pull request #11156 from obsidiansystems/fix-bsd-pthread
Fix some BSD builds missing pthread functions
This commit is contained in:
commit
046cc8cbb3
18 changed files with 43 additions and 1 deletions
|
@ -61,6 +61,12 @@ let
|
||||||
workDir = null;
|
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
|
in
|
||||||
scope: {
|
scope: {
|
||||||
inherit stdenv versionSuffix;
|
inherit stdenv versionSuffix;
|
||||||
|
@ -130,5 +136,8 @@ scope: {
|
||||||
|
|
||||||
inherit resolvePath filesetToSource;
|
inherit resolvePath filesetToSource;
|
||||||
|
|
||||||
mkMesonDerivation = f: stdenv.mkDerivation (lib.extends localSourceLayer f);
|
mkMesonDerivation = f: stdenv.mkDerivation
|
||||||
|
(lib.extends
|
||||||
|
(lib.composeExtensions bsdNoLinkAsNeeded localSourceLayer)
|
||||||
|
f);
|
||||||
}
|
}
|
||||||
|
|
|
@ -30,6 +30,8 @@ deps_public_maybe_subproject = [
|
||||||
]
|
]
|
||||||
subdir('build-utils-meson/subprojects')
|
subdir('build-utils-meson/subprojects')
|
||||||
|
|
||||||
|
subdir('build-utils-meson/threads')
|
||||||
|
|
||||||
nlohmann_json = dependency('nlohmann_json', version : '>= 3.9')
|
nlohmann_json = dependency('nlohmann_json', version : '>= 3.9')
|
||||||
deps_public += nlohmann_json
|
deps_public += nlohmann_json
|
||||||
|
|
||||||
|
|
|
@ -29,6 +29,8 @@ deps_public_maybe_subproject = [
|
||||||
]
|
]
|
||||||
subdir('build-utils-meson/subprojects')
|
subdir('build-utils-meson/subprojects')
|
||||||
|
|
||||||
|
subdir('build-utils-meson/threads')
|
||||||
|
|
||||||
# TODO rename, because it will conflict with downstream projects
|
# TODO rename, because it will conflict with downstream projects
|
||||||
configdata.set_quoted('PACKAGE_VERSION', meson.project_version())
|
configdata.set_quoted('PACKAGE_VERSION', meson.project_version())
|
||||||
|
|
||||||
|
|
|
@ -26,6 +26,8 @@ deps_public_maybe_subproject = [
|
||||||
]
|
]
|
||||||
subdir('build-utils-meson/subprojects')
|
subdir('build-utils-meson/subprojects')
|
||||||
|
|
||||||
|
subdir('build-utils-meson/threads')
|
||||||
|
|
||||||
nlohmann_json = dependency('nlohmann_json', version : '>= 3.9')
|
nlohmann_json = dependency('nlohmann_json', version : '>= 3.9')
|
||||||
deps_public += nlohmann_json
|
deps_public += nlohmann_json
|
||||||
|
|
||||||
|
|
|
@ -26,6 +26,8 @@ deps_public_maybe_subproject = [
|
||||||
]
|
]
|
||||||
subdir('build-utils-meson/subprojects')
|
subdir('build-utils-meson/subprojects')
|
||||||
|
|
||||||
|
subdir('build-utils-meson/threads')
|
||||||
|
|
||||||
nlohmann_json = dependency('nlohmann_json', version : '>= 3.9')
|
nlohmann_json = dependency('nlohmann_json', version : '>= 3.9')
|
||||||
deps_public += nlohmann_json
|
deps_public += nlohmann_json
|
||||||
|
|
||||||
|
|
|
@ -29,6 +29,8 @@ deps_public_maybe_subproject = [
|
||||||
]
|
]
|
||||||
subdir('build-utils-meson/subprojects')
|
subdir('build-utils-meson/subprojects')
|
||||||
|
|
||||||
|
subdir('build-utils-meson/threads')
|
||||||
|
|
||||||
# TODO rename, because it will conflict with downstream projects
|
# TODO rename, because it will conflict with downstream projects
|
||||||
configdata.set_quoted('PACKAGE_VERSION', meson.project_version())
|
configdata.set_quoted('PACKAGE_VERSION', meson.project_version())
|
||||||
|
|
||||||
|
|
|
@ -26,6 +26,7 @@ deps_public_maybe_subproject = [
|
||||||
]
|
]
|
||||||
subdir('build-utils-meson/subprojects')
|
subdir('build-utils-meson/subprojects')
|
||||||
|
|
||||||
|
subdir('build-utils-meson/threads')
|
||||||
|
|
||||||
pubsetbuf_test = '''
|
pubsetbuf_test = '''
|
||||||
#include <iostream>
|
#include <iostream>
|
||||||
|
|
|
@ -27,6 +27,8 @@ deps_public_maybe_subproject = [
|
||||||
]
|
]
|
||||||
subdir('build-utils-meson/subprojects')
|
subdir('build-utils-meson/subprojects')
|
||||||
|
|
||||||
|
subdir('build-utils-meson/threads')
|
||||||
|
|
||||||
# TODO rename, because it will conflict with downstream projects
|
# TODO rename, because it will conflict with downstream projects
|
||||||
configdata.set_quoted('PACKAGE_VERSION', meson.project_version())
|
configdata.set_quoted('PACKAGE_VERSION', meson.project_version())
|
||||||
|
|
||||||
|
|
|
@ -25,6 +25,8 @@ deps_public_maybe_subproject = [
|
||||||
]
|
]
|
||||||
subdir('build-utils-meson/subprojects')
|
subdir('build-utils-meson/subprojects')
|
||||||
|
|
||||||
|
subdir('build-utils-meson/threads')
|
||||||
|
|
||||||
# TODO rename, because it will conflict with downstream projects
|
# TODO rename, because it will conflict with downstream projects
|
||||||
configdata.set_quoted('PACKAGE_VERSION', meson.project_version())
|
configdata.set_quoted('PACKAGE_VERSION', meson.project_version())
|
||||||
|
|
||||||
|
|
|
@ -28,6 +28,8 @@ deps_public_maybe_subproject = [
|
||||||
]
|
]
|
||||||
subdir('build-utils-meson/subprojects')
|
subdir('build-utils-meson/subprojects')
|
||||||
|
|
||||||
|
subdir('build-utils-meson/threads')
|
||||||
|
|
||||||
subdir('build-utils-meson/export-all-symbols')
|
subdir('build-utils-meson/export-all-symbols')
|
||||||
|
|
||||||
add_project_arguments(
|
add_project_arguments(
|
||||||
|
|
|
@ -27,6 +27,8 @@ deps_public_maybe_subproject = [
|
||||||
]
|
]
|
||||||
subdir('build-utils-meson/subprojects')
|
subdir('build-utils-meson/subprojects')
|
||||||
|
|
||||||
|
subdir('build-utils-meson/threads')
|
||||||
|
|
||||||
rapidcheck = dependency('rapidcheck')
|
rapidcheck = dependency('rapidcheck')
|
||||||
deps_public += rapidcheck
|
deps_public += rapidcheck
|
||||||
|
|
||||||
|
|
|
@ -25,6 +25,8 @@ deps_public_maybe_subproject = [
|
||||||
]
|
]
|
||||||
subdir('build-utils-meson/subprojects')
|
subdir('build-utils-meson/subprojects')
|
||||||
|
|
||||||
|
subdir('build-utils-meson/threads')
|
||||||
|
|
||||||
subdir('build-utils-meson/export-all-symbols')
|
subdir('build-utils-meson/export-all-symbols')
|
||||||
|
|
||||||
rapidcheck = dependency('rapidcheck')
|
rapidcheck = dependency('rapidcheck')
|
||||||
|
|
|
@ -24,6 +24,8 @@ deps_public_maybe_subproject = [
|
||||||
]
|
]
|
||||||
subdir('build-utils-meson/subprojects')
|
subdir('build-utils-meson/subprojects')
|
||||||
|
|
||||||
|
subdir('build-utils-meson/threads')
|
||||||
|
|
||||||
subdir('build-utils-meson/export-all-symbols')
|
subdir('build-utils-meson/export-all-symbols')
|
||||||
|
|
||||||
rapidcheck = dependency('rapidcheck')
|
rapidcheck = dependency('rapidcheck')
|
||||||
|
|
|
@ -24,6 +24,8 @@ deps_public_maybe_subproject = [
|
||||||
]
|
]
|
||||||
subdir('build-utils-meson/subprojects')
|
subdir('build-utils-meson/subprojects')
|
||||||
|
|
||||||
|
subdir('build-utils-meson/threads')
|
||||||
|
|
||||||
subdir('build-utils-meson/export-all-symbols')
|
subdir('build-utils-meson/export-all-symbols')
|
||||||
|
|
||||||
rapidcheck = dependency('rapidcheck')
|
rapidcheck = dependency('rapidcheck')
|
||||||
|
|
|
@ -25,6 +25,8 @@ deps_public_maybe_subproject = [
|
||||||
]
|
]
|
||||||
subdir('build-utils-meson/subprojects')
|
subdir('build-utils-meson/subprojects')
|
||||||
|
|
||||||
|
subdir('build-utils-meson/threads')
|
||||||
|
|
||||||
rapidcheck = dependency('rapidcheck')
|
rapidcheck = dependency('rapidcheck')
|
||||||
deps_public += rapidcheck
|
deps_public += rapidcheck
|
||||||
|
|
||||||
|
|
|
@ -25,6 +25,8 @@ deps_public_maybe_subproject = [
|
||||||
]
|
]
|
||||||
subdir('build-utils-meson/subprojects')
|
subdir('build-utils-meson/subprojects')
|
||||||
|
|
||||||
|
subdir('build-utils-meson/threads')
|
||||||
|
|
||||||
subdir('build-utils-meson/export-all-symbols')
|
subdir('build-utils-meson/export-all-symbols')
|
||||||
|
|
||||||
sqlite = dependency('sqlite3', 'sqlite', version : '>=3.6.19')
|
sqlite = dependency('sqlite3', 'sqlite', version : '>=3.6.19')
|
||||||
|
|
|
@ -23,6 +23,8 @@ deps_public_maybe_subproject = [
|
||||||
]
|
]
|
||||||
subdir('build-utils-meson/subprojects')
|
subdir('build-utils-meson/subprojects')
|
||||||
|
|
||||||
|
subdir('build-utils-meson/threads')
|
||||||
|
|
||||||
rapidcheck = dependency('rapidcheck')
|
rapidcheck = dependency('rapidcheck')
|
||||||
deps_public += rapidcheck
|
deps_public += rapidcheck
|
||||||
|
|
||||||
|
|
|
@ -25,6 +25,8 @@ deps_public_maybe_subproject = [
|
||||||
]
|
]
|
||||||
subdir('build-utils-meson/subprojects')
|
subdir('build-utils-meson/subprojects')
|
||||||
|
|
||||||
|
subdir('build-utils-meson/threads')
|
||||||
|
|
||||||
subdir('build-utils-meson/export-all-symbols')
|
subdir('build-utils-meson/export-all-symbols')
|
||||||
|
|
||||||
rapidcheck = dependency('rapidcheck')
|
rapidcheck = dependency('rapidcheck')
|
||||||
|
|
Loading…
Reference in a new issue