win/package: provide common tools

References #1507
Closes #1811

curl.exe curl_7_52_1_openssl_nghttp2_x86.7z from https://winampplugins.co.uk/curl/
    curl 7.52.1 (x86_64-pc-win32) libcurl/7.52.1 OpenSSL/1.0.2k zlib/1.2.8 nghttp2/1.19.0
    Protocols: dict file ftp ftps gopher http https imap imaps ldap pop3 pop3s rtsp smb smbs smtp smtps telnet tftp
    Features: AsynchDNS IPv6 Largefile NTLM SSL libz HTTP2 HTTPS-proxy

tidy.exe http://tidybatchfiles.info
    HTML Tidy for Windows
    tidy version 5.3.14 date 2017.01.09 compiled for Windows win32 x86.

7za.exe http://www.7-zip.org
    7-Zip 16.04 (2016-10-04)

cat.exe http://unxutils.sourceforge.net

from gVim:
    diff.exe GNU diffutils version 2.7
    xxd.exe V1.10 27oct98 by Juergen Weigert (Win32)
    ye olde hacked-up tee.exe
This commit is contained in:
Justin M. Keyes 2017-02-10 00:53:36 +01:00
parent 7caaa106e3
commit 2fbc42aa8a
3 changed files with 10 additions and 4 deletions

View File

@ -299,7 +299,7 @@ if(WIN32)
install(DIRECTORY ${PROJECT_BINARY_DIR}/windows_runtime_deps/
DESTINATION ${CMAKE_INSTALL_BINDIR})
foreach(BIN win32yank.exe)
foreach(BIN cat.exe curl.exe diff.exe tee.exe tidy.exe win32yank.exe)
unset(BIN_PATH CACHE)
find_program(BIN_PATH ${BIN})
if(NOT BIN_PATH)

View File

@ -120,6 +120,10 @@ set(LUV_SHA256 86a199403856018cd8e5529c8527450c83664a3d36f52d5253cbe909ea6c5a06)
set(GPERF_URL http://ftp.gnu.org/pub/gnu/gperf/gperf-3.0.4.tar.gz)
set(GPERF_SHA256 767112a204407e62dbc3106647cf839ed544f3cf5d0f0523aaa2508623aad63e)
# 7za.exe cat.exe curl.exe ca-bundle.crt diff.exe tee.exe tidy.exe xxd.exe
set(WINTOOLS_URL https://github.com/neovim/deps/raw/5d23093c66d63a8777244ed84de727c26d3f7b79/opt/win32tools.zip)
set(WINTOOLS_SHA256 40c7d1fbed47d8b1cf3b3cada6bfe0e0df06d99beb48775b4db27972d3ceafc1)
set(WIN32YANK_URL https://github.com/equalsraf/win32yank/releases/download/v0.0.2/win32yank.zip)
set(WIN32YANK_SHA256 78869bf68565607cda1b6a3d549e2487d59d6f0f16f9b003e123c0086f90309d)
@ -173,6 +177,9 @@ endif()
include(GetBinaryDeps)
if(WIN32)
GetBinaryDep(TARGET wintools
INSTALL_COMMAND ${CMAKE_COMMAND} -E copy_directory . ${DEPS_INSTALL_DIR}/bin)
GetBinaryDep(TARGET win32yank
INSTALL_COMMAND ${CMAKE_COMMAND} -E copy win32yank.exe ${DEPS_INSTALL_DIR}/bin)
@ -182,7 +189,6 @@ if(WIN32)
elseif(TARGET_ARCH STREQUAL "X86")
set(TARGET_ARCH ia32)
endif()
GetBinaryDep(TARGET winpty
INSTALL_COMMAND ${CMAKE_COMMAND} -E make_directory ${DEPS_INSTALL_DIR}/bin
COMMAND ${CMAKE_COMMAND} -DFROM_GLOB=${DEPS_BUILD_DIR}/src/winpty/${TARGET_ARCH}/bin/*

View File

@ -21,7 +21,7 @@ function(GetBinaryDep)
set(URL ${${URL_VARNAME}})
set(HASH ${${HASH_VARNAME}})
if(NOT URL OR NOT HASH )
message(FATAL_ERROR "${URL_VARNAME} and ${HASH_VARNAME} must be set")
message(FATAL_ERROR "${URL_VARNAME} and ${HASH_VARNAME} must be set")
endif()
ExternalProject_Add(${_gettool_TARGET}
@ -41,6 +41,6 @@ function(GetBinaryDep)
CONFIGURE_COMMAND ""
BUILD_COMMAND ""
INSTALL_COMMAND ${CMAKE_COMMAND} -E make_directory ${DEPS_INSTALL_DIR}/bin
COMMAND "${_gettool_INSTALL_COMMAND}")
COMMAND "${_gettool_INSTALL_COMMAND}")
list(APPEND THIRD_PARTY_DEPS ${__gettool_TARGET})
endfunction()