mirror of
https://github.com/NixOS/nix
synced 2025-07-07 01:51:47 +02:00
Merge pull request #11809 from nix-windows/windows-build/meson-fixes
Meson fixes for msys2 builds
This commit is contained in:
commit
dfd0033afb
5 changed files with 47 additions and 14 deletions
|
@ -34,6 +34,8 @@ subdir('build-utils-meson/subprojects')
|
|||
run_command('ln', '-s',
|
||||
meson.project_build_root() / '__nothing_link_target',
|
||||
meson.project_build_root() / '__nothing_symlink',
|
||||
# native doesn't allow dangling symlinks, which the tests require
|
||||
env : { 'MSYS' : 'winsymlinks:lnk' },
|
||||
check : true,
|
||||
)
|
||||
can_link_symlink = run_command('ln',
|
||||
|
@ -74,6 +76,11 @@ if host_machine.system() == 'darwin'
|
|||
deps_other += [sandbox]
|
||||
endif
|
||||
|
||||
if host_machine.system() == 'windows'
|
||||
wsock32 = cxx.find_library('wsock32')
|
||||
deps_other += [wsock32]
|
||||
endif
|
||||
|
||||
subdir('build-utils-meson/threads')
|
||||
|
||||
boost = dependency(
|
||||
|
|
|
@ -230,6 +230,8 @@ foreach linkname : nix_symlinks
|
|||
t = custom_target(
|
||||
command: ['ln', '-sf', fs.name(this_exe), '@OUTPUT@'],
|
||||
output: linkname + executable_suffix,
|
||||
# native doesn't allow dangling symlinks, but the target executable often doesn't exist at this time
|
||||
env : { 'MSYS' : 'winsymlinks:lnk' },
|
||||
# TODO(Ericson2314): Don't do this once we have the `meson.override_find_program` working)
|
||||
build_by_default: true
|
||||
)
|
||||
|
@ -248,6 +250,8 @@ install_symlink(
|
|||
custom_target(
|
||||
command: ['ln', '-sf', fs.name(this_exe), '@OUTPUT@'],
|
||||
output: 'build-remote' + executable_suffix,
|
||||
# native doesn't allow dangling symlinks, but the target executable often doesn't exist at this time
|
||||
env : { 'MSYS' : 'winsymlinks:lnk' },
|
||||
# TODO(Ericson2314): Don't do this once we have the `meson.override_find_program` working)
|
||||
build_by_default: true
|
||||
)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue