Skip to content

Commit

Permalink
Pass --symlink-type native to internal Cygwin
Browse files Browse the repository at this point in the history
Enhances what's available in the bin directory
  • Loading branch information
dra27 committed May 13, 2024
1 parent df4a390 commit 49e3210
Showing 1 changed file with 19 additions and 6 deletions.
25 changes: 19 additions & 6 deletions src/state/opamSysInteract.ml
Original file line number Diff line number Diff line change
Expand Up @@ -325,6 +325,12 @@ module Cygwin = struct
[ "--packages";
OpamStd.List.concat_map "," OpamSysPkg.to_string spkgs ]
in
let args =
if Unix.has_symlink () then
"--symlink-type" :: "native" :: args
else
args
in
OpamSystem.make_command
(OpamFilename.to_string local_cygwin_setupexe)
args @@> fun r ->
Expand Down Expand Up @@ -974,12 +980,19 @@ let install_packages_commands_t ?(env=OpamVariable.Map.empty) config sys_package
"--packages";
String.concat "," packages;
] @ (if Cygwin.is_internal config then
[ "--upgrade-also";
"--only-site";
"--site"; Cygwin.mirror;
"--local-package-dir";
OpamFilename.Dir.to_string (Cygwin.internal_cygcache ());
] else [])
let common =
[ "--upgrade-also";
"--only-site";
"--site"; Cygwin.mirror;
"--local-package-dir";
OpamFilename.Dir.to_string (Cygwin.internal_cygcache ());
]
in
if Unix.has_symlink () then
"--symlink-type" :: "native" :: common
else
common
else [])
],
None
| Debian ->
Expand Down

0 comments on commit 49e3210

Please sign in to comment.