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

[vcpkg/scripts/make] trying to iron out some issues #11836

Merged
merged 34 commits into from
Aug 13, 2020
Merged
Show file tree
Hide file tree
Changes from 26 commits
Commits
Show all changes
34 commits
Select commit Hold shift + click to select a range
3ccd4dd
take changes from fontconfig pr
Neumann-A Jul 26, 2020
a0907a1
[farmhash] add autoconf
Neumann-A Jul 26, 2020
0cf1aaa
[freexl] add autoconf
Neumann-A Jul 26, 2020
4fcff6c
[healpix] add autoconf
Neumann-A Jul 26, 2020
e9328fe
[libb2] add autoconf
Neumann-A Jul 26, 2020
b9725d7
[libwandio] add autoconf and patch
Neumann-A Jul 26, 2020
edf3b24
more autoconf
Neumann-A Jul 26, 2020
fc541db
[x264] fix windows build issues
Neumann-A Jul 26, 2020
ca25c71
minimal cleanup
Neumann-A Jul 26, 2020
3124ef9
Merge remote-tracking branch 'upstream/master' into fix_make_details
Neumann-A Aug 1, 2020
a307a02
[libwandio] some fixes
Neumann-A Aug 2, 2020
8093cf0
[vcpkg/scripts/make] add include to C/CXX flags correctly set machine…
Neumann-A Aug 2, 2020
eb73911
Merge remote-tracking branch 'upstream/master' into fix_make_details
Neumann-A Aug 2, 2020
1bab85b
remove unnecessary comments part 1
Neumann-A Aug 2, 2020
22bb852
cleanup part 2
Neumann-A Aug 2, 2020
c3413e8
cleanup
Neumann-A Aug 2, 2020
21487d6
remove unnecessary code
Neumann-A Aug 2, 2020
35b0d29
[pbc] fix osx regressions
Neumann-A Aug 3, 2020
c489dc1
Merge branch 'master' into fix_make_details
JackBoosY Aug 5, 2020
d90ae98
Merge remote-tracking branch 'upstream/master' into fix_make_details
Neumann-A Aug 5, 2020
9419320
Merge branch 'fix_make_details' of https://github.com/Neumann-A/vcpkg…
Neumann-A Aug 5, 2020
95f4ceb
[lzokay] format manifest
strega-nil Aug 5, 2020
8be872d
Merge remote-tracking branch 'upstream/master' into fix_make_details
Neumann-A Aug 6, 2020
4269503
Merge remote-tracking branch 'nil/fix-lzokay-formatting' into fix_mak…
Neumann-A Aug 6, 2020
d20fab1
try to copy sources to fix build issues
Neumann-A Aug 6, 2020
a194ae9
add autoconfig to force updated configure scripts
Neumann-A Aug 7, 2020
315d92d
bump port versions of openmpi and ocilib
Neumann-A Aug 7, 2020
c4caa38
added lib paths back into vcpkg_build_make because they are probably …
Neumann-A Aug 8, 2020
9718a36
Use CPP flags
Neumann-A Aug 8, 2020
c399f28
Apply suggestions from code review
Neumann-A Aug 10, 2020
0a546dd
Apply more changes forom CR
Neumann-A Aug 10, 2020
a7ce732
fix wrong variables.
Neumann-A Aug 10, 2020
21e9617
use the list macro instead of the single var macro
Neumann-A Aug 11, 2020
06896bb
also use it at the top
Neumann-A Aug 11, 2020
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion ports/farmhash/CONTROL
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
Source: farmhash
Version: 1.1-1
Version: 1.1
Port-Version: 2
Homepage: https://github.com/google/farmhash
Description: FarmHash, a family of hash functions.
Supports: !arm
1 change: 1 addition & 0 deletions ports/farmhash/portfile.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ if((VCPKG_TARGET_IS_LINUX OR VCPKG_TARGET_IS_OSX) AND NOT ENV{CXX_FLAGS}) # This
endif()
file(REMOVE_RECURSE "${SOURCE_PATH}/configure")
vcpkg_configure_make(
AUTOCONFIG
SOURCE_PATH ${SOURCE_PATH}
)

Expand Down
3 changes: 2 additions & 1 deletion ports/freexl/CONTROL
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
Source: freexl
Version: 1.0.4-9
Version: 1.0.4
Port-Version: 10
Homepage: https://www.gaia-gis.it/gaia-sins/freexl-sources
Description: FreeXL is an open source library to extract valid data from within an Excel (.xls) spreadsheet
Build-Depends: libiconv
1 change: 1 addition & 0 deletions ports/freexl/portfile.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,7 @@ elseif (CMAKE_HOST_UNIX OR CMAKE_HOST_APPLE) # Build in UNIX
)
file(REMOVE_RECURSE "${SOURCE_PATH}/configure")
vcpkg_configure_make(
AUTOCONFIG
SOURCE_PATH ${SOURCE_PATH}
OPTIONS_DEBUG
INSTALLED_ROOT="${CURRENT_INSTALLED_DIR}"
Expand Down
3 changes: 2 additions & 1 deletion ports/healpix/CONTROL
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
Source: healpix
Version: 1.12.10-5
Version: 1.12.10
Port-Version: 6
Homepage: http://healpix.sourceforge.net/
Description: HEALPix is an acronym for Hierarchical Equal Area isoLatitude Pixelation of a sphere.
Build-Depends: cfitsio
Expand Down
1 change: 1 addition & 0 deletions ports/healpix/portfile.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ vcpkg_from_sourceforge(
)

vcpkg_configure_make(
AUTOCONFIG
SOURCE_PATH ${SOURCE_PATH}
PROJECT_SUBPATH src/cxx
COPY_SOURCE
Expand Down
1 change: 1 addition & 0 deletions ports/libb2/portfile.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ if(CMAKE_HOST_WIN32)
endif()

vcpkg_configure_make(
AUTOCONFIG
SOURCE_PATH ${SOURCE_PATH}
OPTIONS ${OPTIONS}
)
Expand Down
2 changes: 1 addition & 1 deletion ports/libb2/vcpkg.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "libb2",
"version-string": "0.98.1",
"port-version": 3,
"port-version": 4,
"description": "C library providing BLAKE2b, BLAKE2s, BLAKE2bp, BLAKE2sp",
"homepage": "https://github.com/BLAKE2/libb2",
"supports": "!windows"
Expand Down
5 changes: 3 additions & 2 deletions ports/libcrafter/CONTROL
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
Source: libcrafter
Version: 0.3-1
Version: 0.3
Port-Version: 2
Homepage: https://github.com/pellegre/libcrafter
Description: Libcrafter is a high level library for C++ designed to create and decode network packets.
Build-Depends: libpcap
Build-Depends: libpcap
1 change: 1 addition & 0 deletions ports/libcrafter/portfile.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ vcpkg_from_github(
)

vcpkg_configure_make(
AUTOCONFIG
SOURCE_PATH ${SOURCE_PATH}
PROJECT_SUBPATH libcrafter
OPTIONS
Expand Down
5 changes: 3 additions & 2 deletions ports/libmagic/CONTROL
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
Source: libmagic
Version: 5.37-1
Version: 5.37
Port-Version: 2
Homepage: https://github.com/file/file
Description: This library can be used to classify files according to magic number tests.
Description: This library can be used to classify files according to magic number tests.
1 change: 1 addition & 0 deletions ports/libmagic/portfile.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ vcpkg_from_github(
)

vcpkg_configure_make(
AUTOCONFIG
SOURCE_PATH ${SOURCE_PATH}
)
vcpkg_install_make()
Expand Down
5 changes: 3 additions & 2 deletions ports/libwandio/CONTROL
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
Source: libwandio
Version: 4.2.1-2
Version: 4.2.1
Port-Version: 3
Homepage: https://github.com/wanduow/wandio
Description: C library for simple and efficient file IO.
Build-Depends: zlib, zstd, liblzma, lz4, curl, pthread, bzip2
Build-Depends: zlib, zstd, liblzma, lzo, lz4, curl, pthread, bzip2
Neumann-A marked this conversation as resolved.
Show resolved Hide resolved
18 changes: 0 additions & 18 deletions ports/libwandio/configure.lib.patch
Original file line number Diff line number Diff line change
Expand Up @@ -120,21 +120,3 @@ index 4579fbb3d..f6be008c8 100644
fi
AC_DEFINE(HAVE_LIBLZ4S, 1, "Compiled with lz4 stream support")
with_lz4=streamapi
@@ -296,12 +304,14 @@ AC_ARG_WITH([http],
AS_IF([test "x$with_http" != "xno"],
[
# we need curl_easy_pause which was added in 7.18.0
- AC_CHECK_LIB(curl, curl_easy_pause, have_curl=yes, have_curl=no)
+ AC_SEARCH_LIBS(curl_easy_pause, [curl curl-d], have_curl=yes, have_curl=no, [-lssl -lcrypto $ac_cv_search_pthread_create -ldl])
+ # AC_CHECK_LIB(curl, curl_easy_pause, have_curl=yes, have_curl=no)
], [have_curl=no])

AS_IF([test "x$have_curl" = "xyes"], [
- if test "$ac_cv_lib_curl_curl_easy_pause" != "none required"; then
- LIBWANDIO_LIBS="$LIBWANDIO_LIBS -lcurl"
+ if test "$ac_cv_search_curl_easy_pause" != "none required"; then
+ LIBWANDIO_LIBS="$LIBWANDIO_LIBS $ac_cv_search_curl_easy_pause -lssl -lcrypto $ac_cv_search_pthread_create -ldl"
+ LIBS="$LIBS -lssl -lcrypto $ac_cv_search_pthread_create -ldl"
fi
AC_DEFINE(HAVE_HTTP, 1, "Compiled with http support")
with_http=yes],
14 changes: 14 additions & 0 deletions ports/libwandio/configure.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
diff --git a/configure.ac b/configure.ac
index e250c0c31..0465120ba 100644
--- a/configure.ac
+++ b/configure.ac
@@ -83,7 +83,7 @@ ADD_INCLS=""
ADD_LDFLAGS="$ADD_LDFLAGS -L\$(abs_top_srcdir)/lib"
LIBWANDIO_LIBS=""

-CFLAGS="$CFLAGS -Wall -Wmissing-prototypes -Wextra -DLT_BUILDING_DLL=1"
+CFLAGS="$CFLAGS -Wall -DLT_BUILDING_DLL=1 -DNOMINMAX"
-CXXFLAGS="$CXXFLAGS -Wall -DLT_BUILDING_DLL=1"
+CXXFLAGS="$CXXFLAGS -Wall -DLT_BUILDING_DLL=1 -DNOMINMAX"

# Check for -fvisibility
22 changes: 22 additions & 0 deletions ports/libwandio/curl.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
diff --git a/configure.ac b/configure.ac
index 4579fbb3d..f6be008c8 100644
--- a/configure.ac
+++ b/configure.ac
@@ -296,12 +304,14 @@ AC_ARG_WITH([http],
AS_IF([test "x$with_http" != "xno"],
[
# we need curl_easy_pause which was added in 7.18.0
- AC_CHECK_LIB(curl, curl_easy_pause, have_curl=yes, have_curl=no)
+ AC_SEARCH_LIBS(curl_easy_pause, [curl curl-d libcurl libcurl-d], have_curl=yes, have_curl=no, [-lCrypt32 -lWldap32 -lWs2_32 -ladvapi32])
+ # AC_CHECK_LIB(curl, curl_easy_pause, have_curl=yes, have_curl=no)
], [have_curl=no])

AS_IF([test "x$have_curl" = "xyes"], [
- if test "$ac_cv_lib_curl_curl_easy_pause" != "none required"; then
- LIBWANDIO_LIBS="$LIBWANDIO_LIBS -lcurl"
+ if test "$ac_cv_search_curl_easy_pause" != "none required"; then
+ LIBWANDIO_LIBS="$LIBWANDIO_LIBS -lCrypt32 -lWldap32 -lWs2_32 -ladvapi32 $ac_cv_search_curl_easy_pause"
+ LIBS="$LIBS"
fi
AC_DEFINE(HAVE_HTTP, 1, "Compiled with http support")
with_http=yes],
22 changes: 22 additions & 0 deletions ports/libwandio/openssl.patch
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
diff --git a/configure.ac b/configure.ac
index 4579fbb3d..f6be008c8 100644
--- a/configure.ac
+++ b/configure.ac
@@ -296,12 +304,14 @@ AC_ARG_WITH([http],
AS_IF([test "x$with_http" != "xno"],
[
# we need curl_easy_pause which was added in 7.18.0
- AC_CHECK_LIB(curl, curl_easy_pause, have_curl=yes, have_curl=no)
+ AC_SEARCH_LIBS(curl_easy_pause, [curl curl-d], have_curl=yes, have_curl=no, [-lssl -lcrypto $ac_cv_search_pthread_create -ldl])
+ # AC_CHECK_LIB(curl, curl_easy_pause, have_curl=yes, have_curl=no)
], [have_curl=no])

AS_IF([test "x$have_curl" = "xyes"], [
- if test "$ac_cv_lib_curl_curl_easy_pause" != "none required"; then
- LIBWANDIO_LIBS="$LIBWANDIO_LIBS -lcurl"
+ if test "$ac_cv_search_curl_easy_pause" != "none required"; then
+ LIBWANDIO_LIBS="$LIBWANDIO_LIBS $ac_cv_search_curl_easy_pause -lssl -lcrypto $ac_cv_search_pthread_create -ldl"
+ LIBS="$LIBS -lssl -lcrypto $ac_cv_search_pthread_create -ldl"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should this be fixed instead by producing .pc files for curl and using

PKG_CHECK_MODULES([CURL], [curl])
LIBS="$LIBS $CURL_LIBS"

Based on my reading of https://autotools.io/pkgconfig/pkg_check_modules.html, the default action-if-not-found is to error out.

Otherwise, we should Build-Depends: openssl in libwandio because it's directly expressing a dependency on openssl (e.g. imagine a case of building curl without openssl and thus this would fail).

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would be a proper fix but I did not want to touch this port any more than necessary. Because every dependency in libwandio would need that fix. If you want I can back out the patches to libwandio.

fi
AC_DEFINE(HAVE_HTTP, 1, "Compiled with http support")
with_http=yes],
11 changes: 11 additions & 0 deletions ports/libwandio/portfile.cmake
Original file line number Diff line number Diff line change
@@ -1,13 +1,24 @@
if(VCPKG_TARGET_IS_WINDOWS)
vcpkg_check_linkage(ONLY_STATIC_LIBRARY)
set(PATCHES curl.patch)
#TODO: Still does not work. Requires proper "signal" support and "unistd"
Neumann-A marked this conversation as resolved.
Show resolved Hide resolved
else()
set(PATCHES openssl.patch) # needed if curl is using openssl
endif()

vcpkg_from_github(
OUT_SOURCE_PATH SOURCE_PATH
REPO wanduow/wandio
REF 012b646e7ba7ab191a5a2206488adfac493fcdc6
SHA512 e94a82038902c34933c4256f8bd4d7ef3f2cf32fea46f8e31a25df34cc90d3a275ff56d3bc9892aca0c85e6d875e696f96a836cc1444fe165db8364331e6e77d
HEAD_REF master
PATCHES configure.lib.patch # This is how configure.ac files with dependencies get fixed.
configure.patch
${PATCHES}
)

vcpkg_configure_make(
AUTOCONFIG
SOURCE_PATH ${SOURCE_PATH}
COPY_SOURCE
)
Expand Down
4 changes: 2 additions & 2 deletions ports/lzokay/vcpkg.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "lzokay",
"version-string": "2020-07-30",
"homepage": "https://github.com/jackoalan/lzokay",
"description": "lzokay – MIT licensed C++ implementation of LZO compression/decompression algorithm"
"description": "lzokay – MIT licensed C++ implementation of LZO compression/decompression algorithm",
"homepage": "https://github.com/jackoalan/lzokay"
}
74 changes: 38 additions & 36 deletions ports/ocilib/portfile.cmake
Original file line number Diff line number Diff line change
@@ -1,62 +1,64 @@
vcpkg_fail_port_install(ON_ARCH "arm" ON_TARGET "uwp")

vcpkg_from_github(
OUT_SOURCE_PATH SOURCE_PATH
REPO vrogier/ocilib
REF v4.6.4
SHA512 83f5614a23c8fb4ab02517dec95d8b490c5ef472302735d5cc4cf483cc51513cc81ae2e1b4618c7c73fb5b071efe422e463b46fa79492ccb4775b511a943295a
HEAD_REF master
PATCHES
out_of_source_build_version_file_configure.patch
OUT_SOURCE_PATH SOURCE_PATH
REPO vrogier/ocilib
REF v4.6.4
SHA512 83f5614a23c8fb4ab02517dec95d8b490c5ef472302735d5cc4cf483cc51513cc81ae2e1b4618c7c73fb5b071efe422e463b46fa79492ccb4775b511a943295a
HEAD_REF master
PATCHES
out_of_source_build_version_file_configure.patch
)

if(VCPKG_TARGET_IS_WINDOWS)
if(VCPKG_PLATFORM_TOOLSET MATCHES "v142")
if(VCPKG_PLATFORM_TOOLSET MATCHES "v142")
set(SOLUTION_TYPE vs2019)
set(OCILIB_ARCH_X86 x86)
set(OCILIB_ARCH_X64 x64)
elseif(VCPKG_PLATFORM_TOOLSET MATCHES "v141")
elseif(VCPKG_PLATFORM_TOOLSET MATCHES "v141")
set(SOLUTION_TYPE vs2017)
set(OCILIB_ARCH_X86 Win32)
set(OCILIB_ARCH_X64 Win64)
else()
else()
set(SOLUTION_TYPE vs2015)
set(OCILIB_ARCH_X86 Win32)
set(OCILIB_ARCH_X64 Win64)
endif()
endif()

if(VCPKG_TARGET_ARCHITECTURE STREQUAL "x86")
set(PLATFORM ${OCILIB_ARCH_X86})
else()
set(PLATFORM ${OCILIB_ARCH_X64})
endif()
# There is no debug configuration
# As it is a C library, build the release configuration and copy its output to the debug folder
set(VCPKG_BUILD_TYPE release)
vcpkg_install_msbuild(
SOURCE_PATH ${SOURCE_PATH}
PROJECT_SUBPATH proj/dll/ocilib_dll_${SOLUTION_TYPE}.sln
INCLUDES_SUBPATH include
LICENSE_SUBPATH LICENSE
RELEASE_CONFIGURATION "Release - ANSI"
PLATFORM ${PLATFORM}
USE_VCPKG_INTEGRATION
ALLOW_ROOT_INCLUDES)
# There is no debug configuration
# As it is a C library, build the release configuration and copy its output to the debug folder
set(VCPKG_BUILD_TYPE release)
vcpkg_install_msbuild(
SOURCE_PATH ${SOURCE_PATH}
PROJECT_SUBPATH proj/dll/ocilib_dll_${SOLUTION_TYPE}.sln
INCLUDES_SUBPATH include
LICENSE_SUBPATH LICENSE
RELEASE_CONFIGURATION "Release - ANSI"
PLATFORM ${PLATFORM}
USE_VCPKG_INTEGRATION
ALLOW_ROOT_INCLUDES)

file(MAKE_DIRECTORY ${CURRENT_PACKAGES_DIR}/debug)
file(COPY ${CURRENT_PACKAGES_DIR}/bin ${CURRENT_PACKAGES_DIR}/lib DESTINATION ${CURRENT_PACKAGES_DIR}/debug)
file(MAKE_DIRECTORY ${CURRENT_PACKAGES_DIR}/debug)
file(COPY ${CURRENT_PACKAGES_DIR}/bin ${CURRENT_PACKAGES_DIR}/lib DESTINATION ${CURRENT_PACKAGES_DIR}/debug)
else()
vcpkg_configure_make(
SOURCE_PATH ${SOURCE_PATH}
OPTIONS
--with-oracle-import=runtime
)
vcpkg_configure_make(
COPY_SOURCE
AUTOCONFIG
Neumann-A marked this conversation as resolved.
Show resolved Hide resolved
SOURCE_PATH ${SOURCE_PATH}
OPTIONS
--with-oracle-import=runtime
)

vcpkg_install_make()
vcpkg_install_make()

file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/share)
file(RENAME ${CURRENT_PACKAGES_DIR}/share/doc/${PORT} ${CURRENT_PACKAGES_DIR}/share/${PORT})
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/share/doc)
file(INSTALL ${SOURCE_PATH}/LICENSE DESTINATION ${CURRENT_PACKAGES_DIR}/share/${PORT} RENAME copyright)
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/share)
file(RENAME ${CURRENT_PACKAGES_DIR}/share/doc/${PORT} ${CURRENT_PACKAGES_DIR}/share/${PORT})
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/share/doc)
file(INSTALL ${SOURCE_PATH}/LICENSE DESTINATION ${CURRENT_PACKAGES_DIR}/share/${PORT} RENAME copyright)
endif()
1 change: 1 addition & 0 deletions ports/openmpi/portfile.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ get_filename_component(PERL_PATH ${PERL} DIRECTORY)
vcpkg_add_to_path(${PERL_PATH})

vcpkg_configure_make(
COPY_SOURCE
SOURCE_PATH ${SOURCE_PATH}
OPTIONS
--with-hwloc=internal
Expand Down
4 changes: 2 additions & 2 deletions ports/pbc/CONTROL
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
Source: pbc
Version: 0.5.14
Port-Version: 3
Build-Depends: mpir (windows), gmp(!windows)
Port-Version: 4
Build-Depends: mpir (windows), gmp (!windows)
Homepage: https://crypto.stanford.edu/pbc
Description: Pairing-Based Crypto library provides low-level routines for pairing-based cryptosystems.
Supports: !uwp
5 changes: 3 additions & 2 deletions ports/x264/CONTROL
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
Source: x264
Version: 157-303c484ec828ed0-8
Version: 157-303c484ec828ed0
Port-Version: 9
Homepage: https://github.com/mirror/x264
Description: x264 is a free software library and application for encoding video streams into the H.264/MPEG-4 AVC compression format
Build-Depends: pthread (linux&osx)
Build-Depends: pthread (linux&osx)
Loading