aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJack·Boos·Yu <47264268+JackBoosY@users.noreply.github.com>2020-07-03 09:36:40 -0700
committerGitHub <noreply@github.com>2020-07-03 09:36:40 -0700
commit21b56d99293aa364964b99946847986c5276c3b8 (patch)
treefc010edec8fbaf0674bc0ceb454a36c753c8b4d8
parent3d2a7ca33e9997051ea221c30ccd4835989879ad (diff)
downloadvcpkg-21b56d99293aa364964b99946847986c5276c3b8.tar.gz
vcpkg-21b56d99293aa364964b99946847986c5276c3b8.zip
[vcpkg_from_sourceforge] Add retry mirror function (2/2) (#12018)
-rw-r--r--docs/maintainers/vcpkg_from_sourceforge.md4
-rw-r--r--ports/argtable2/CONTROL2
-rw-r--r--ports/cairo/CONTROL2
-rw-r--r--ports/cunit/CONTROL2
-rw-r--r--ports/epsilon/CONTROL2
-rw-r--r--ports/freeglut/CONTROL2
-rw-r--r--ports/freeimage/CONTROL2
-rw-r--r--ports/geographiclib/CONTROL2
-rw-r--r--ports/giflib/CONTROL2
-rw-r--r--ports/gsoap/CONTROL2
-rw-r--r--ports/healpix/CONTROL2
-rw-r--r--ports/irrlicht/CONTROL2
-rw-r--r--ports/itpp/CONTROL2
-rw-r--r--ports/libaiff/CONTROL2
-rw-r--r--ports/libdisasm/CONTROL2
-rw-r--r--ports/libmad/CONTROL2
-rw-r--r--ports/libmikmod/CONTROL2
-rw-r--r--ports/libnice/CONTROL2
-rw-r--r--ports/libnice/portfile.cmake3
-rw-r--r--ports/libsquish/CONTROL2
-rw-r--r--ports/libusb-win32/CONTROL2
-rw-r--r--ports/libuuid/CONTROL2
-rw-r--r--ports/libxmp-lite/CONTROL2
-rw-r--r--ports/mathgl/CONTROL2
-rw-r--r--ports/mp3lame/CONTROL2
-rw-r--r--ports/opencc/CONTROL2
-rw-r--r--ports/pcre/CONTROL2
-rw-r--r--ports/pcre/portfile.cmake12
-rw-r--r--ports/plplot/CONTROL2
-rw-r--r--ports/podofo/CONTROL2
-rw-r--r--ports/polyclipping/CONTROL2
-rw-r--r--ports/portmidi/CONTROL2
-rw-r--r--ports/rapidxml/CONTROL2
-rw-r--r--ports/sigslot/CONTROL2
-rw-r--r--ports/tinyxml/CONTROL2
-rw-r--r--ports/wtl/CONTROL2
-rw-r--r--scripts/cmake/vcpkg_download_distfile.cmake37
-rw-r--r--scripts/cmake/vcpkg_from_sourceforge.cmake71
38 files changed, 134 insertions, 59 deletions
diff --git a/docs/maintainers/vcpkg_from_sourceforge.md b/docs/maintainers/vcpkg_from_sourceforge.md
index 823ee82f9..faad06215 100644
--- a/docs/maintainers/vcpkg_from_sourceforge.md
+++ b/docs/maintainers/vcpkg_from_sourceforge.md
@@ -4,10 +4,10 @@ Download and extract a project from sourceforge.
## Usage:
```cmake
-vcpkg_from_sourceforge(
+vcpkg_from_sourceforge(
OUT_SOURCE_PATH SOURCE_PATH
REPO <cunit/CUnit>
- [REF <2.1-3>]
+ [REF <2.1-3>]
SHA512 <547b417109332...>
FILENAME <CUnit-2.1-3.tar.bz2>
[DISABLE_SSL]
diff --git a/ports/argtable2/CONTROL b/ports/argtable2/CONTROL
index 7a953dd14..6cdb294cf 100644
--- a/ports/argtable2/CONTROL
+++ b/ports/argtable2/CONTROL
@@ -1,4 +1,4 @@
Source: argtable2
-Version: 2.13-5
+Version: 2.13-7
Homepage: http://argtable.sourceforge.net
Description: Argtable is an ANSI C library for parsing GNU style command line options with a minimum of fuss.
diff --git a/ports/cairo/CONTROL b/ports/cairo/CONTROL
index cbbe5d3d8..0eda86fac 100644
--- a/ports/cairo/CONTROL
+++ b/ports/cairo/CONTROL
@@ -1,5 +1,5 @@
Source: cairo
-Version: 1.16.0-5
+Version: 1.16.0-6
Homepage: https://cairographics.org
Description: Cairo is a 2D graphics library with support for multiple output devices. Currently supported output targets include the X Window System (via both Xlib and XCB), Quartz, Win32, image buffers, PostScript, PDF, and SVG file output. Experimental backends include OpenGL, BeOS, OS/2, and DirectFB.
Build-Depends: zlib, libpng, pixman, freetype, fontconfig
diff --git a/ports/cunit/CONTROL b/ports/cunit/CONTROL
index 21e97d948..c5725875f 100644
--- a/ports/cunit/CONTROL
+++ b/ports/cunit/CONTROL
@@ -1,4 +1,4 @@
Source: cunit
-Version: 2.1.3-4
+Version: 2.1.3-6
Homepage: https://sourceforge.net/projects/cunit/
Description: CUnit is a lightweight system for writing, administering, and running unit tests in C. It provides C programmers a basic testing functionality with a flexible variety of user interfaces
diff --git a/ports/epsilon/CONTROL b/ports/epsilon/CONTROL
index 8c829bef3..1547a9967 100644
--- a/ports/epsilon/CONTROL
+++ b/ports/epsilon/CONTROL
@@ -1,5 +1,5 @@
Source: epsilon
-Version: 0.9.2-2
+Version: 0.9.2-4
Homepage: https://sourceforge.net/projects/epsilon-project/
Description: EPSILON is an Open Source wavelet image compressor, that is aimed on parallel and robust image processing.
Build-Depends: libpopt \ No newline at end of file
diff --git a/ports/freeglut/CONTROL b/ports/freeglut/CONTROL
index fad233f80..452615768 100644
--- a/ports/freeglut/CONTROL
+++ b/ports/freeglut/CONTROL
@@ -1,4 +1,4 @@
Source: freeglut
-Version: 3.2.1-2
+Version: 3.2.1-4
Homepage: https://sourceforge.net/projects/freeglut/
Description: Open source implementation of GLUT with source and binary backwards compatibility.
diff --git a/ports/freeimage/CONTROL b/ports/freeimage/CONTROL
index d7b6a4311..36829adc7 100644
--- a/ports/freeimage/CONTROL
+++ b/ports/freeimage/CONTROL
@@ -1,5 +1,5 @@
Source: freeimage
-Version: 3.18.0-10
+Version: 3.18.0-12
Build-Depends: zlib, libpng, libjpeg-turbo, tiff, openjpeg, libwebp (!uwp), libraw, jxrlib, openexr
Homepage: https://sourceforge.net/projects/freeimage/
Description: Support library for graphics image formats
diff --git a/ports/geographiclib/CONTROL b/ports/geographiclib/CONTROL
index 18c787c72..a1c1aeff6 100644
--- a/ports/geographiclib/CONTROL
+++ b/ports/geographiclib/CONTROL
@@ -1,4 +1,4 @@
Source: geographiclib
-Version: 1.47-patch1-14
+Version: 1.47-patch1-16
Homepage: https://sourceforge.net/projects/geographiclib/
Description: a small set of C++ classes for performing conversions between geographic, UTM, UPS, MGRS, geocentric, and local cartesian coordinates, for gravity (e.g., EGM2008), geoid height, and geomagnetic field (e.g., WMM2010) calculations, and for solving geodesic problems.
diff --git a/ports/giflib/CONTROL b/ports/giflib/CONTROL
index bb796c97a..5361fc185 100644
--- a/ports/giflib/CONTROL
+++ b/ports/giflib/CONTROL
@@ -1,4 +1,4 @@
Source: giflib
-Version: 5.1.4-4
+Version: 5.1.4-6
Homepage: https://sourceforge.net/projects/giflib/
Description: A library for reading and writing gif images.
diff --git a/ports/gsoap/CONTROL b/ports/gsoap/CONTROL
index 27c7a8c1b..e5901fca7 100644
--- a/ports/gsoap/CONTROL
+++ b/ports/gsoap/CONTROL
@@ -1,5 +1,5 @@
Source: gsoap
-Version: 2.8.102-1
+Version: 2.8.102-4
Build-Depends: curl
Homepage: https://sourceforge.net/projects/gsoap2/
Description: The gSOAP toolkit is a C and C++ software development toolkit for SOAP and REST XML Web services and generic C/C++ XML data bindings.
diff --git a/ports/healpix/CONTROL b/ports/healpix/CONTROL
index a58d6ab63..629b095ee 100644
--- a/ports/healpix/CONTROL
+++ b/ports/healpix/CONTROL
@@ -1,5 +1,5 @@
Source: healpix
-Version: 1.12.10-2
+Version: 1.12.10-5
Homepage: http://healpix.sourceforge.net/
Description: HEALPix is an acronym for Hierarchical Equal Area isoLatitude Pixelation of a sphere.
Build-Depends: cfitsio
diff --git a/ports/irrlicht/CONTROL b/ports/irrlicht/CONTROL
index 3207b7ae8..e8ff45bdd 100644
--- a/ports/irrlicht/CONTROL
+++ b/ports/irrlicht/CONTROL
@@ -1,5 +1,5 @@
Source: irrlicht
-Version: 1.8.4-8
+Version: 1.8.4-10
Homepage: http://irrlicht.sourceforge.net
Description: Irrlicht lightning fast 3d engine
Build-Depends: zlib, libpng, bzip2, libjpeg-turbo
diff --git a/ports/itpp/CONTROL b/ports/itpp/CONTROL
index 8b1ae7701..2d4fa8900 100644
--- a/ports/itpp/CONTROL
+++ b/ports/itpp/CONTROL
@@ -1,4 +1,4 @@
Source: itpp
-Version: 4.3.1-3
+Version: 4.3.1-5
Homepage: http://itpp.sourceforge.net
Description: IT++ is a C++ library of mathematical, signal processing and communication classes and functions. Its main use is in simulation of communication systems and for performing research in the area of communications. \ No newline at end of file
diff --git a/ports/libaiff/CONTROL b/ports/libaiff/CONTROL
index 155f5e7d0..889511a5c 100644
--- a/ports/libaiff/CONTROL
+++ b/ports/libaiff/CONTROL
@@ -1,4 +1,4 @@
Source: libaiff
-Version: 5.0-4
+Version: 5.0-6
Homepage: https://sourceforge.net/projects/aifftools
Description: LibAiff is an open-source library, providing C applications transparent read & write operations for Audio Interchange File Format (AIFF) files, with the goal of supporting all of its features
diff --git a/ports/libdisasm/CONTROL b/ports/libdisasm/CONTROL
index 7ab323192..1a09c870e 100644
--- a/ports/libdisasm/CONTROL
+++ b/ports/libdisasm/CONTROL
@@ -1,4 +1,4 @@
Source: libdisasm
-Version: 0.23-5
+Version: 0.23-7
Homepage: https://sourceforge.net/projects/bastard
Description: x86 Disassembler Library.
diff --git a/ports/libmad/CONTROL b/ports/libmad/CONTROL
index a044ba76b..356ecc65f 100644
--- a/ports/libmad/CONTROL
+++ b/ports/libmad/CONTROL
@@ -1,4 +1,4 @@
Source: libmad
-Version: 0.15.1-6
+Version: 0.15.1-8
Homepage: http://www.mars.org/home/rob/proj/mpeg/
Description: high-quality MPEG audio decoder
diff --git a/ports/libmikmod/CONTROL b/ports/libmikmod/CONTROL
index 7344b8037..637052cb2 100644
--- a/ports/libmikmod/CONTROL
+++ b/ports/libmikmod/CONTROL
@@ -1,5 +1,5 @@
Source: libmikmod
-Version: 3.3.11.1-6
+Version: 3.3.11.1-8
Homepage: https://sourceforge.net/projects/mikmod/
Description: Mikmod is a module player and library supporting many formats, including mod, s3m, it, and xm.
Build-Depends: openal-soft
diff --git a/ports/libnice/CONTROL b/ports/libnice/CONTROL
index fcbc522a9..a2f87af5c 100644
--- a/ports/libnice/CONTROL
+++ b/ports/libnice/CONTROL
@@ -1,5 +1,5 @@
Source: libnice
-Version: 0.1.15-3
+Version: 0.1.15-4
Homepage: https://nice.freedesktop.org
Description: Libnice is an implementation of the IETF's Interactive Connectivity Establishment (ICE) standard (RFC 5245) and the Session Traversal Utilities for NAT (STUN) standard (RFC 5389).
Build-Depends: glib, openssl
diff --git a/ports/libnice/portfile.cmake b/ports/libnice/portfile.cmake
index fc58cdc13..ff09f4837 100644
--- a/ports/libnice/portfile.cmake
+++ b/ports/libnice/portfile.cmake
@@ -22,7 +22,6 @@ vcpkg_install_cmake()
vcpkg_copy_pdbs()
-file(COPY ${SOURCE_PATH}/COPYING DESTINATION ${CURRENT_PACKAGES_DIR}/share/${PORT})
file(COPY ${SOURCE_PATH}/COPYING.LGPL DESTINATION ${CURRENT_PACKAGES_DIR}/share/${PORT})
file(COPY ${SOURCE_PATH}/COPYING.MPL DESTINATION ${CURRENT_PACKAGES_DIR}/share/${PORT})
-file(RENAME ${CURRENT_PACKAGES_DIR}/share/${PORT}/COPYING ${CURRENT_PACKAGES_DIR}/share/${PORT}/copyright)
+file(INSTALL ${SOURCE_PATH}/COPYING DESTINATION ${CURRENT_PACKAGES_DIR}/share/${PORT} RENAME copyright)
diff --git a/ports/libsquish/CONTROL b/ports/libsquish/CONTROL
index 619a93780..2e3500478 100644
--- a/ports/libsquish/CONTROL
+++ b/ports/libsquish/CONTROL
@@ -1,4 +1,4 @@
Source: libsquish
-Version: 1.15-5
+Version: 1.15-7
Homepage: https://sourceforge.net/projects/libsquish
Description: Open source DXT compression library.
diff --git a/ports/libusb-win32/CONTROL b/ports/libusb-win32/CONTROL
index b10d90519..24dd02c85 100644
--- a/ports/libusb-win32/CONTROL
+++ b/ports/libusb-win32/CONTROL
@@ -1,5 +1,5 @@
Source: libusb-win32
-Version: 1.2.6.0-4
+Version: 1.2.6.0-6
Homepage: https://sourceforge.net/projects/libusb-win32
Description: Allows user space applications to access many USB device on Windows.
Supports: windows \ No newline at end of file
diff --git a/ports/libuuid/CONTROL b/ports/libuuid/CONTROL
index 3ec19066c..5c11b9cac 100644
--- a/ports/libuuid/CONTROL
+++ b/ports/libuuid/CONTROL
@@ -1,5 +1,5 @@
Source: libuuid
-Version: 1.0.3-5
+Version: 1.0.3-7
Homepage: https://sourceforge.net/projects/libuuid
Description: Universally unique id library
Supports: linux|osx \ No newline at end of file
diff --git a/ports/libxmp-lite/CONTROL b/ports/libxmp-lite/CONTROL
index 45e1069da..fd791aa29 100644
--- a/ports/libxmp-lite/CONTROL
+++ b/ports/libxmp-lite/CONTROL
@@ -1,4 +1,4 @@
Source: libxmp-lite
-Version: 4.4.1-4
+Version: 4.4.1-6
Homepage: https://sourceforge.net/projects/xmp/
Description: Lightweight version of libxmp that supports MOD, S3M, XM and IT modules.
diff --git a/ports/mathgl/CONTROL b/ports/mathgl/CONTROL
index 4dd6fbb51..7dc82d3f9 100644
--- a/ports/mathgl/CONTROL
+++ b/ports/mathgl/CONTROL
@@ -1,5 +1,5 @@
Source: mathgl
-Version: 2.4.3-4
+Version: 2.4.3-6
Description: MathGL is a free library of fast C++ routines for the plotting of the data varied in one or more dimensions
Default-Features: opengl, jpeg, png, zlib
diff --git a/ports/mp3lame/CONTROL b/ports/mp3lame/CONTROL
index bd8a34222..5cf900065 100644
--- a/ports/mp3lame/CONTROL
+++ b/ports/mp3lame/CONTROL
@@ -1,4 +1,4 @@
Source: mp3lame
-Version: 3.100-1
+Version: 3.100-3
Homepage: http://lame.sourceforge.net/
Description: LAME is a high quality MPEG Audio Layer III (MP3) encoder licensed under the LGPL.
diff --git a/ports/opencc/CONTROL b/ports/opencc/CONTROL
index b59adc760..49765c5b9 100644
--- a/ports/opencc/CONTROL
+++ b/ports/opencc/CONTROL
@@ -1,5 +1,5 @@
Source: opencc
-Version: 2020-04-26-4
+Version: 2020-04-26-6
Description: A project for conversion between Traditional and Simplified Chinese
Homepage: https://github.com/BYVoid/OpenCC
Supports: !(arm|arm64|uwp)
diff --git a/ports/pcre/CONTROL b/ports/pcre/CONTROL
index 97a79426a..97dd54c34 100644
--- a/ports/pcre/CONTROL
+++ b/ports/pcre/CONTROL
@@ -1,4 +1,4 @@
Source: pcre
-Version: 8.44-2
+Version: 8.44-4
Homepage: https://www.pcre.org/
Description: Perl Compatible Regular Expressions
diff --git a/ports/pcre/portfile.cmake b/ports/pcre/portfile.cmake
index 92926a32f..903d82a76 100644
--- a/ports/pcre/portfile.cmake
+++ b/ports/pcre/portfile.cmake
@@ -1,11 +1,15 @@
set(PCRE_VERSION 8.44)
-vcpkg_from_sourceforge(
- OUT_SOURCE_PATH SOURCE_PATH
- REPO pcre/pcre
- REF ${PCRE_VERSION}
+vcpkg_download_distfile(ARCHIVE
+ URLS "https://ftp.pcre.org/pub/pcre/pcre-${PCRE_VERSION}.zip"
+ "https://downloads.sourceforge.net/project/pcre/pcre/${PCRE_VERSION}/pcre-${PCRE_VERSION}.zip"
FILENAME "pcre-${PCRE_VERSION}.zip"
SHA512 adddec1236b25ff1c90e73835c2ba25d60a5839cbde2d6be7838a8ec099f7443dede931dc39002943243e21afea572eda71ee8739058e72235a192e4324398f0
+)
+
+vcpkg_extract_source_archive_ex(
+ OUT_SOURCE_PATH SOURCE_PATH
+ ARCHIVE ${ARCHIVE}
PATCHES
# Fix CMake Deprecation Warning concerning OLD behavior for policy CMP0026
# Suppress MSVC compiler warnings C4703, C4146, C4308, which fixes errors
diff --git a/ports/plplot/CONTROL b/ports/plplot/CONTROL
index af69724f7..fe5ea0b19 100644
--- a/ports/plplot/CONTROL
+++ b/ports/plplot/CONTROL
@@ -1,5 +1,5 @@
Source: plplot
-Version: 5.13.0-6
+Version: 5.13.0-8
Build-Depends: freetype, zlib, libpng, bzip2
Description: PLplot is a cross-platform software package for creating scientific plots whose (UTF-8) plot symbols and text are limited in practice only by what Unicode-aware system fonts are installed on a user's computer.
diff --git a/ports/podofo/CONTROL b/ports/podofo/CONTROL
index e2357fbe8..a6965d832 100644
--- a/ports/podofo/CONTROL
+++ b/ports/podofo/CONTROL
@@ -1,5 +1,5 @@
Source: podofo
-Version: 0.9.6-9
+Version: 0.9.6-11
Homepage: https://sourceforge.net/projects/podofo/
Description: PoDoFo is a library to work with the PDF file format
Build-Depends: zlib, libpng, libjpeg-turbo, tiff, openssl, freetype
diff --git a/ports/polyclipping/CONTROL b/ports/polyclipping/CONTROL
index 4a46772b2..198090cc6 100644
--- a/ports/polyclipping/CONTROL
+++ b/ports/polyclipping/CONTROL
@@ -1,4 +1,4 @@
Source: polyclipping
-Version: 6.4.2-2
+Version: 6.4.2-4
Homepage: https://sourceforge.net/projects/polyclipping/
Description: The Clipper library performs clipping and offsetting for both lines and polygons. All four boolean clipping operations are supported - intersection, union, difference and exclusive-or. Polygons can be of any shape including self-intersecting polygons.
diff --git a/ports/portmidi/CONTROL b/ports/portmidi/CONTROL
index 1fafc6e9f..f5518c3e1 100644
--- a/ports/portmidi/CONTROL
+++ b/ports/portmidi/CONTROL
@@ -1,5 +1,5 @@
Source: portmidi
-Version: 0.217.1-2
+Version: 0.217.1-4
Homepage: https://sourceforge.net/projects/portmedia/
Description: Free, cross-platform, open-source I/O library for MIDI
Supports: !uwp \ No newline at end of file
diff --git a/ports/rapidxml/CONTROL b/ports/rapidxml/CONTROL
index 0bc175e71..7e119fb70 100644
--- a/ports/rapidxml/CONTROL
+++ b/ports/rapidxml/CONTROL
@@ -1,4 +1,4 @@
Source: rapidxml
-Version: 1.13-2
+Version: 1.13-4
Homepage: https://sourceforge.net/projects/rapidxml
Description: RapidXml is an attempt to create the fastest XML parser possible, while retaining useability, portability and reasonable W3C compatibility.
diff --git a/ports/sigslot/CONTROL b/ports/sigslot/CONTROL
index d1d9afded..e785404eb 100644
--- a/ports/sigslot/CONTROL
+++ b/ports/sigslot/CONTROL
@@ -1,3 +1,3 @@
Source: sigslot
-Version: 1.0.0-1
+Version: 1.0.0-3
Description: Portable C++ type-safe, thread-safe signal/slot library for ISO C++, Unix/BSD/Linux and Win32. Sigslot allows C++ code to use the signal/slot paradigm made popular by, for example, Qt.
diff --git a/ports/tinyxml/CONTROL b/ports/tinyxml/CONTROL
index d6c4d6b24..3a83e411e 100644
--- a/ports/tinyxml/CONTROL
+++ b/ports/tinyxml/CONTROL
@@ -1,4 +1,4 @@
Source: tinyxml
-Version: 2.6.2-5
+Version: 2.6.2-7
Homepage: https://sourceforge.net/projects/tinyxml
Description: A simple, small, minimal, C++ XML parser that can be easily integrating into other programs.
diff --git a/ports/wtl/CONTROL b/ports/wtl/CONTROL
index 39e78b1d3..63f618d9b 100644
--- a/ports/wtl/CONTROL
+++ b/ports/wtl/CONTROL
@@ -1,4 +1,4 @@
Source: wtl
-Version: 10.0-8
+Version: 10.0-10
Homepage: https://sourceforge.net/projects/wtl/
Description: Windows Template Library (WTL) is a C++ library for developing Windows applications and UI components.
diff --git a/scripts/cmake/vcpkg_download_distfile.cmake b/scripts/cmake/vcpkg_download_distfile.cmake
index 8a8efd205..6ad073803 100644
--- a/scripts/cmake/vcpkg_download_distfile.cmake
+++ b/scripts/cmake/vcpkg_download_distfile.cmake
@@ -47,7 +47,7 @@
## * [fontconfig](https://github.com/Microsoft/vcpkg/blob/master/ports/fontconfig/portfile.cmake)
## * [freetype](https://github.com/Microsoft/vcpkg/blob/master/ports/freetype/portfile.cmake)
function(vcpkg_download_distfile VAR)
- set(options SKIP_SHA512)
+ set(options SKIP_SHA512 SILENT_EXIT)
set(oneValueArgs FILENAME SHA512)
set(multipleValuesArgs URLS HEADERS)
cmake_parse_arguments(vcpkg_download_distfile "${options}" "${oneValueArgs}" "${multipleValuesArgs}" ${ARGN})
@@ -171,18 +171,31 @@ function(vcpkg_download_distfile VAR)
endforeach(url)
endif()
- if (NOT download_success)
- message(FATAL_ERROR
- " \n"
- " Failed to download file.\n"
- " If you use a proxy, please set the HTTPS_PROXY and HTTP_PROXY environment\n"
- " variables to \"https://user:password@your-proxy-ip-address:port/\".\n"
- " Otherwise, please submit an issue at https://github.com/Microsoft/vcpkg/issues\n")
+ if (NOT vcpkg_download_distfile_SILENT_EXIT)
+ if (NOT download_success)
+ message(FATAL_ERROR
+ " \n"
+ " Failed to download file.\n"
+ " If you use a proxy, please set the HTTPS_PROXY and HTTP_PROXY environment\n"
+ " variables to \"https://user:password@your-proxy-ip-address:port/\".\n"
+ " Otherwise, please submit an issue at https://github.com/Microsoft/vcpkg/issues\n")
+ else()
+ test_hash("${download_file_path_part}" "downloaded file" "The file may have been corrupted in transit. This can be caused by proxies. If you use a proxy, please set the HTTPS_PROXY and HTTP_PROXY environment variables to \"https://user:password@your-proxy-ip-address:port/\".\n")
+ get_filename_component(downloaded_file_dir "${downloaded_file_path}" DIRECTORY)
+ file(MAKE_DIRECTORY "${downloaded_file_dir}")
+ file(RENAME ${download_file_path_part} ${downloaded_file_path})
+ endif()
else()
- test_hash("${download_file_path_part}" "downloaded file" "The file may have been corrupted in transit. This can be caused by proxies. If you use a proxy, please set the HTTPS_PROXY and HTTP_PROXY environment variables to \"https://user:password@your-proxy-ip-address:port/\".\n")
- get_filename_component(downloaded_file_dir "${downloaded_file_path}" DIRECTORY)
- file(MAKE_DIRECTORY "${downloaded_file_dir}")
- file(RENAME ${download_file_path_part} ${downloaded_file_path})
+ if (NOT download_success)
+ message(WARNING
+ " \n"
+ " Failed to download file.\n")
+ else()
+ test_hash("${download_file_path_part}" "downloaded file" "The file may have been corrupted in transit. This can be caused by proxies. If you use a proxy, please set the HTTPS_PROXY and HTTP_PROXY environment variables to \"https://user:password@your-proxy-ip-address:port/\".\n")
+ get_filename_component(downloaded_file_dir "${downloaded_file_path}" DIRECTORY)
+ file(MAKE_DIRECTORY "${downloaded_file_dir}")
+ file(RENAME ${download_file_path_part} ${downloaded_file_path})
+ endif()
endif()
endif()
set(${VAR} ${downloaded_file_path} PARENT_SCOPE)
diff --git a/scripts/cmake/vcpkg_from_sourceforge.cmake b/scripts/cmake/vcpkg_from_sourceforge.cmake
index 4df36a81d..258499242 100644
--- a/scripts/cmake/vcpkg_from_sourceforge.cmake
+++ b/scripts/cmake/vcpkg_from_sourceforge.cmake
@@ -82,7 +82,8 @@ function(vcpkg_from_sourceforge)
else()
set(URL_PROTOCOL https:)
endif()
- set(SOURCEFORGE_HOST ${URL_PROTOCOL}//downloads.sourceforge.net/project)
+
+ set(SOURCEFORGE_HOST ${URL_PROTOCOL}//sourceforge.net/projects)
string(FIND ${_vdus_REPO} "/" FOUND_ORG)
if (NOT FOUND_ORG EQUAL -1)
@@ -94,14 +95,14 @@ function(vcpkg_from_sourceforge)
endif()
set(ORG_NAME ${ORG_NAME}/)
else()
- set(REPO_NAME ${_vdus_REPO})
- set(ORG_NAME )
+ set(ORG_NAME ${_vdus_REPO}/)
+ set(REPO_NAME )
endif()
if (DEFINED _vdus_REF)
- set(URL "${SOURCEFORGE_HOST}/${ORG_NAME}${REPO_NAME}/${_vdus_REF}/${_vdus_FILENAME}")
+ set(URL "${SOURCEFORGE_HOST}/${ORG_NAME}files/${REPO_NAME}/${_vdus_REF}/${_vdus_FILENAME}")
else()
- set(URL "${SOURCEFORGE_HOST}/${ORG_NAME}${REPO_NAME}/${_vdus_FILENAME}")
+ set(URL "${SOURCEFORGE_HOST}/${ORG_NAME}${REPO_NAME}/files/${_vdus_FILENAME}")
endif()
set(NO_REMOVE_ONE_LEVEL )
@@ -111,12 +112,70 @@ function(vcpkg_from_sourceforge)
string(SUBSTRING "${_vdus_SHA512}" 0 10 SANITIZED_REF)
+ list(APPEND SOURCEFORGE_MIRRORS
+ cfhcable # United States
+ pilotfiber # New York, NY
+ gigenet # Chicago, IL
+ versaweb # Las Vegas, NV
+ ayera # Modesto, CA
+ netactuate # Durham, NC
+ phoenixnap # Tempe, AZ
+ astuteinternet # Vancouver, BC
+ freefr # Paris, France
+ netcologne # Cologne, Germany
+ deac-riga # Latvia
+ excellmedia # Hyderabad, India
+ iweb # Montreal, QC
+ jaist # Nomi, Japan
+ jztkft # Mezotur, Hungary
+ managedway # Detroit, MI
+ nchc # Taipei, Taiwan
+ netix # Bulgaria
+ ufpr # Curitiba, Brazil
+ tenet # Wynberg, South Africa
+ )
+
+ # Try to use auto-select first
+ set(DOWNLOAD_URL ${URL}/download)
+ message(STATUS "Trying auto-select mirror...")
vcpkg_download_distfile(ARCHIVE
- URLS "${URL}"
+ URLS "${DOWNLOAD_URL}"
SHA512 "${_vdus_SHA512}"
FILENAME "${_vdus_FILENAME}"
+ SILENT_EXIT
)
+
+ if (EXISTS ${ARCHIVE})
+ set(download_success 1)
+ endif()
+
+ if (NOT download_success EQUAL 1)
+ foreach(SOURCEFORGE_MIRROR ${SOURCEFORGE_MIRRORS})
+ set(DOWNLOAD_URL ${URL}/download?use_mirror=${SOURCEFORGE_MIRROR})
+ message(STATUS "Trying mirror ${SOURCEFORGE_MIRROR}...")
+ vcpkg_download_distfile(ARCHIVE
+ URLS "${DOWNLOAD_URL}"
+ SHA512 "${_vdus_SHA512}"
+ FILENAME "${_vdus_FILENAME}"
+ SILENT_EXIT
+ )
+
+ if (EXISTS ${ARCHIVE})
+ set(download_success 1)
+ break()
+ endif()
+ endforeach()
+ endif()
+ if (NOT download_success)
+ message(FATAL_ERROR [[
+ Couldn't download source from any of the sourceforge mirrors, please check your network.
+ If you use a proxy, please set the HTTPS_PROXY and HTTP_PROXY environment
+ variables to "http[s]://user:password@your-proxy-ip-address:port/".
+ Otherwise, please submit an issue at https://github.com/Microsoft/vcpkg/issues
+ ]])
+ endif()
+
vcpkg_extract_source_archive_ex(
OUT_SOURCE_PATH SOURCE_PATH
ARCHIVE "${ARCHIVE}"