Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

MSYS2 acquisition failed #10322

Closed
bogdanlytvynovskyi opened this issue Mar 6, 2020 · 8 comments · Fixed by #10346
Closed

MSYS2 acquisition failed #10322

bogdanlytvynovskyi opened this issue Mar 6, 2020 · 8 comments · Fixed by #10346
Assignees
Labels
category:vcpkg-bug The issue is with the vcpkg system (including helper scripts in `scripts/cmake/`) depends:upstream-changes Waiting on a change to the upstream project

Comments

@bogdanlytvynovskyi
Copy link

Describe the bug
When doing fresh build from vcpkg anything that requires msys2, build will fail due to repo.msys2.org being down

Environment

  • OS: Windows
  • Compiler: NA

To Reproduce
Steps to reproduce the behavior:

  1. ./vcpkg install ffmpeg
  2. See error

Expected behavior
I would expect for msys retrieval code target mirrors in case repo.msys2.org is down

msys2 issue reported here: msys2/MSYS2-packages#1884

@JackBoosY JackBoosY added category:vcpkg-bug The issue is with the vcpkg system (including helper scripts in `scripts/cmake/`) depends:upstream-changes Waiting on a change to the upstream project labels Mar 6, 2020
@JackBoosY
Copy link
Contributor

Related: #1098

@MVoz
Copy link
Contributor

MVoz commented Mar 6, 2020

copy
https://github.com/msys2/MSYS2-packages/tree/master/pacman-mirrors

to
...\vcpkg\downloads\tools\msys2\msys64\etc\pacman.d

@bogdanlytvynovskyi
Copy link
Author

@JackBoosY - it seems that vcpkg_acquire_msys.cmake has support for mirrors. Following patch did a trick for me. Would you kindly take care of creating proper PR for this?
msys2_mirror.txt

@MaverickTse
Copy link
Contributor

@JackBoosY - it seems that vcpkg_acquire_msys.cmake has support for mirrors. Following patch did a trick for me. Would you kindly take care of creating proper PR for this?
msys2_mirror.txt

The one reason that I'm reluctant to make a PR is that any "mirror" hardcoded in the cmake script is going to receive increased traffic, and I cannot tell if any mirror is more reliable than others (Personal server is out, China server... may not be comfortable for everyone).

Also the pacman -Syu command will also access the default repo.msys2.org.

In addition, running pacman -Syu from a 2018 archive can take quite a while and MAY break msys2 itself.

@bogdanlytvynovskyi
Copy link
Author

The one reason that I'm reluctant to make a PR is that any "mirror" hardcoded in the cmake script is going to receive increased traffic, and I cannot tell if any mirror is more reliable than others

This is the reason mirrors exist, unless I am missing something. Working is better than non working IMO.

Also the pacman -Syu command will also access the default repo.msys2.org.

Yes it does, and then resorts to other mirrors.

In addition, running pacman -Syu from a 2018 archive can take quite a while and MAY break msys2 itself

Not sure specifically about this concern. I took exactly same version as currently used and it worked pretty well for me

MaverickTse added a commit to MaverickTse/vcpkg that referenced this issue Mar 8, 2020
Proposal to resolve microsoft#10322
* Use Sourceforge as MSYS2 download source (up to SF to choose mirror, fair to everyone and more reliable)
* Updated msys2 version to 2019-05-24 (Otherwise need to spend extra time on ```pacman -Syu```)
* Updated SHA512 accordingly
* Tested with building icu:x64-windows
@ylluminate
Copy link

After a fresh install from downloading and installing from a nightly installer build, where do you put the mirror list so that pacman -Syu works again?

Out of the box this simply fails and doesn't try to pull from mirrors for me...

@MaverickTse
Copy link
Contributor

At lease the 20190524 xz version works for me. Tested with building icu:x64-windows. The older 2018 version has problem with mirror however.
I'd refrain from using nightly... can be too buggy for an important infrastructure

@MaverickTse
Copy link
Contributor

There is a PKGBUILD package in the github msys2 repo that handles mirror:

https://github.com/msys2/MSYS2-packages/tree/master/pacman-mirrors

strega-nil pushed a commit that referenced this issue Mar 10, 2020
 Resolves #10322

* Update MSYS2 download source. Resolve #10322

Proposal to resolve #10322
* Use Sourceforge as MSYS2 download source (up to SF to choose mirror, fair to everyone and more reliable)
* Updated msys2 version to 2019-05-24 (Otherwise need to spend extra time on ```pacman -Syu```)
* Updated SHA512 accordingly
* Tested with building icu:x64-windows

* add official repo as backup
Toxe pushed a commit to Toxe/vcpkg that referenced this issue Mar 11, 2020
…ft#10346)

 Resolves microsoft#10322

* Update MSYS2 download source. Resolve microsoft#10322

Proposal to resolve microsoft#10322
* Use Sourceforge as MSYS2 download source (up to SF to choose mirror, fair to everyone and more reliable)
* Updated msys2 version to 2019-05-24 (Otherwise need to spend extra time on ```pacman -Syu```)
* Updated SHA512 accordingly
* Tested with building icu:x64-windows

* add official repo as backup
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
category:vcpkg-bug The issue is with the vcpkg system (including helper scripts in `scripts/cmake/`) depends:upstream-changes Waiting on a change to the upstream project
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants