mirror of
https://github.com/microsoft/vcpkg.git
synced 2024-11-27 19:09:00 +08:00
[many ports] Include functional to fix error C2039 and C2504 (#30946)
This commit is contained in:
parent
3ef62a2a76
commit
2b1d52a7a5
12
ports/kenlm/include_functional.patch
Normal file
12
ports/kenlm/include_functional.patch
Normal file
@ -0,0 +1,12 @@
|
||||
diff --git a/util/string_piece_hash.hh b/util/string_piece_hash.hh
|
||||
index 6ff6f88..16808cd 100644
|
||||
--- a/util/string_piece_hash.hh
|
||||
+++ b/util/string_piece_hash.hh
|
||||
@@ -1,6 +1,7 @@
|
||||
#ifndef UTIL_STRING_PIECE_HASH_H
|
||||
#define UTIL_STRING_PIECE_HASH_H
|
||||
|
||||
+#include <functional>
|
||||
#include "util/have.hh"
|
||||
#include "util/string_piece.hh"
|
||||
|
@ -9,18 +9,16 @@ vcpkg_from_github(
|
||||
PATCHES
|
||||
fix-boost.patch
|
||||
fix-const-overloaded.patch
|
||||
include_functional.patch # Upstream PR https://github.com/kpu/kenlm/pull/428, please remove this patch when updating this port.
|
||||
)
|
||||
|
||||
file(REMOVE "${SOURCE_PATH}/cmake/modules/FindEigen3.cmake")
|
||||
|
||||
vcpkg_check_features(OUT_FEATURE_OPTIONS FEATURE_OPTIONS FEATURES
|
||||
interpolate ENABLE_INTERPOLATE
|
||||
vcpkg_check_features(OUT_FEATURE_OPTIONS FEATURE_OPTIONS
|
||||
FEATURES
|
||||
interpolate ENABLE_INTERPOLATE
|
||||
)
|
||||
|
||||
if ("interpolate" IN_LIST FEATURES AND VCPKG_TARGET_IS_WINDOWS)
|
||||
message(FATAL_ERROR "The interpolate feature does not support Windows.")
|
||||
endif()
|
||||
|
||||
vcpkg_cmake_configure(
|
||||
SOURCE_PATH "${SOURCE_PATH}"
|
||||
OPTIONS
|
||||
@ -45,5 +43,4 @@ vcpkg_copy_pdbs()
|
||||
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include")
|
||||
|
||||
# Copyright and License
|
||||
file(INSTALL "${SOURCE_PATH}/COPYING" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}" RENAME copyright)
|
||||
file(INSTALL "${SOURCE_PATH}/LICENSE" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}" RENAME license)
|
||||
vcpkg_install_copyright(FILE_LIST "${SOURCE_PATH}/COPYING" "${SOURCE_PATH}/LICENSE")
|
||||
|
@ -1,7 +1,7 @@
|
||||
{
|
||||
"name": "kenlm",
|
||||
"version": "20200924",
|
||||
"port-version": 3,
|
||||
"port-version": 4,
|
||||
"description": "KenLM: Faster and Smaller Language Model Queries",
|
||||
"supports": "!(arm64 & windows)",
|
||||
"dependencies": [
|
||||
@ -26,6 +26,7 @@
|
||||
"features": {
|
||||
"interpolate": {
|
||||
"description": "Build interpolation program",
|
||||
"supports": "!windows",
|
||||
"dependencies": [
|
||||
{
|
||||
"name": "eigen3",
|
||||
|
12
ports/mathgl/include_functional.patch
Normal file
12
ports/mathgl/include_functional.patch
Normal file
@ -0,0 +1,12 @@
|
||||
diff --git a/src/prc/writePRC.h b/src/prc/writePRC.h
|
||||
index d0b4e0e..3bc68ea 100644
|
||||
--- a/src/prc/writePRC.h
|
||||
+++ b/src/prc/writePRC.h
|
||||
@@ -31,6 +31,7 @@
|
||||
#include "PRC.h"
|
||||
#include <float.h>
|
||||
#include <math.h>
|
||||
+#include <functional>
|
||||
|
||||
static const uint32_t m1=(uint32_t)-1;
|
||||
static const double pi=acos(-1.0);
|
@ -1,4 +1,3 @@
|
||||
vcpkg_minimum_required(VERSION 2022-10-12)
|
||||
vcpkg_from_sourceforge(
|
||||
OUT_SOURCE_PATH SOURCE_PATH
|
||||
REPO mathgl/mathgl
|
||||
@ -15,6 +14,7 @@ vcpkg_from_sourceforge(
|
||||
fix-format-specifiers.patch
|
||||
fix-glut.patch
|
||||
fix-mgllab.patch
|
||||
include_functional.patch
|
||||
fix-include-property.patch
|
||||
)
|
||||
file(REMOVE_RECURSE "${SOURCE_PATH}/addons/getopt")
|
||||
@ -105,4 +105,4 @@ vcpkg_replace_string("${CURRENT_PACKAGES_DIR}/include/mgl2/config.h" "#define MG
|
||||
vcpkg_replace_string("${CURRENT_PACKAGES_DIR}/include/mgl2/config.h" "#define MGL_FONT_PATH\t\"${CURRENT_PACKAGES_DIR}/share/mathgl/fonts\"" "")
|
||||
|
||||
file(INSTALL "${CMAKE_CURRENT_LIST_DIR}/usage" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}")
|
||||
file(INSTALL "${SOURCE_PATH}/COPYING" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}" RENAME copyright)
|
||||
vcpkg_install_copyright(FILE_LIST "${SOURCE_PATH}/COPYING")
|
||||
|
@ -1,7 +1,7 @@
|
||||
{
|
||||
"name": "mathgl",
|
||||
"version": "8.0.1",
|
||||
"port-version": 1,
|
||||
"port-version": 2,
|
||||
"description": "MathGL is a free library of fast C++ routines for the plotting of the data varied in one or more dimensions",
|
||||
"license": "GPL-3.0-only",
|
||||
"supports": "!uwp",
|
||||
|
12
ports/moos-core/include_functional.patch
Normal file
12
ports/moos-core/include_functional.patch
Normal file
@ -0,0 +1,12 @@
|
||||
diff --git a/Core/libMOOS/Utils/MOOSUtilityFunctions.cpp b/Core/libMOOS/Utils/MOOSUtilityFunctions.cpp
|
||||
index 9d4473f..3f91018 100644
|
||||
--- a/Core/libMOOS/Utils/MOOSUtilityFunctions.cpp
|
||||
+++ b/Core/libMOOS/Utils/MOOSUtilityFunctions.cpp
|
||||
@@ -47,6 +47,7 @@
|
||||
#include <time.h>
|
||||
#include <stdarg.h>
|
||||
#include <math.h>
|
||||
+#include <functional>
|
||||
|
||||
#ifndef _WIN32
|
||||
#include <unistd.h>
|
@ -3,18 +3,17 @@ vcpkg_check_linkage(ONLY_STATIC_LIBRARY ONLY_DYNAMIC_CRT)
|
||||
vcpkg_from_github(
|
||||
OUT_SOURCE_PATH SOURCE_PATH
|
||||
REPO themoos/core-moos
|
||||
REF v10.4.0
|
||||
REF "v${VERSION}"
|
||||
SHA512 8a82074bd219bbedbe56c2187afe74a55a252b0654a675c64d1f75e62353b0874e7b405d9f677fadb297e955d11aea50a07e8f5f3546be3c4ddab76fe356a51e
|
||||
HEAD_REF master
|
||||
PATCHES
|
||||
cmake_fix.patch
|
||||
include_functional.patch
|
||||
)
|
||||
|
||||
vcpkg_cmake_configure(
|
||||
SOURCE_PATH "${SOURCE_PATH}"
|
||||
DISABLE_PARALLEL_CONFIGURE
|
||||
OPTIONS
|
||||
-DCMAKE_ENABLE_EXPORT=OFF
|
||||
)
|
||||
|
||||
vcpkg_cmake_install()
|
||||
@ -26,4 +25,4 @@ file(MAKE_DIRECTORY "${CURRENT_PACKAGES_DIR}/tools")
|
||||
file(RENAME "${CURRENT_PACKAGES_DIR}/bin" "${CURRENT_PACKAGES_DIR}/tools/${PORT}")
|
||||
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/bin" "${CURRENT_PACKAGES_DIR}/debug/include")
|
||||
|
||||
file(INSTALL "${SOURCE_PATH}/Core/GPLCore.txt" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}" RENAME copyright)
|
||||
vcpkg_install_copyright(FILE_LIST "${SOURCE_PATH}/Core/GPLCore.txt")
|
||||
|
@ -1,10 +1,10 @@
|
||||
{
|
||||
"name": "moos-core",
|
||||
"version": "10.4.0",
|
||||
"port-version": 7,
|
||||
"port-version": 8,
|
||||
"description": "A very light weight, easy to use middleware.",
|
||||
"homepage": "https://sites.google.com/site/moossoftware/",
|
||||
"license": null,
|
||||
"license": "GPL-2.0-or-later",
|
||||
"dependencies": [
|
||||
{
|
||||
"name": "vcpkg-cmake",
|
||||
|
12
ports/rappture/include_functional.patch
Normal file
12
ports/rappture/include_functional.patch
Normal file
@ -0,0 +1,12 @@
|
||||
diff --git a/src/core/RpUnits.h b/src/core/RpUnits.h
|
||||
index a640205..e697424 100644
|
||||
--- a/src/core/RpUnits.h
|
||||
+++ b/src/core/RpUnits.h
|
||||
@@ -59,6 +59,7 @@ enum RP_UNITS_CONSTS {
|
||||
#include <stdlib.h>
|
||||
#include <errno.h>
|
||||
#include <math.h>
|
||||
+#include <functional>
|
||||
|
||||
#include "RpDict.h"
|
||||
#include "RpUnitsStd.h"
|
@ -10,13 +10,14 @@ vcpkg_extract_source_archive(
|
||||
SOURCE_PATH
|
||||
ARCHIVE ${ARCHIVE}
|
||||
PATCHES
|
||||
"${CMAKE_CURRENT_LIST_DIR}/rappture.patch"
|
||||
rappture.patch
|
||||
include_functional.patch
|
||||
)
|
||||
|
||||
file(COPY ${CMAKE_CURRENT_LIST_DIR}/CMakeLists.txt DESTINATION ${SOURCE_PATH})
|
||||
file(COPY "${CMAKE_CURRENT_LIST_DIR}/CMakeLists.txt" DESTINATION "${SOURCE_PATH}")
|
||||
|
||||
vcpkg_cmake_configure(
|
||||
SOURCE_PATH ${SOURCE_PATH}
|
||||
SOURCE_PATH "${SOURCE_PATH}"
|
||||
)
|
||||
|
||||
vcpkg_cmake_install()
|
||||
@ -26,10 +27,6 @@ vcpkg_cmake_config_fixup()
|
||||
vcpkg_copy_pdbs()
|
||||
|
||||
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include")
|
||||
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/share)
|
||||
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/share")
|
||||
|
||||
file(
|
||||
INSTALL ${SOURCE_PATH}/license.terms
|
||||
DESTINATION ${CURRENT_PACKAGES_DIR}/share/${PORT}
|
||||
RENAME copyright
|
||||
)
|
||||
vcpkg_install_copyright(FILE_LIST "${SOURCE_PATH}/license.terms")
|
||||
|
@ -1,7 +1,7 @@
|
||||
{
|
||||
"name": "rappture",
|
||||
"version": "1.9",
|
||||
"port-version": 3,
|
||||
"port-version": 4,
|
||||
"description": "Rappture is a toolkit supporting Rapid application infrastructure, making it quick and easy to develop powerful scientific applications.",
|
||||
"license": null,
|
||||
"dependencies": [
|
||||
|
24
ports/spaceland/include_functional.patch
Normal file
24
ports/spaceland/include_functional.patch
Normal file
@ -0,0 +1,24 @@
|
||||
diff --git a/src/sl/connectivity.hpp b/src/sl/connectivity.hpp
|
||||
index 1942c6c..1b66b9d 100644
|
||||
--- a/src/sl/connectivity.hpp
|
||||
+++ b/src/sl/connectivity.hpp
|
||||
@@ -26,6 +26,7 @@
|
||||
#include <sl/operators.hpp>
|
||||
#include <sl/hash.hpp>
|
||||
#include <cassert>
|
||||
+#include <functional>
|
||||
|
||||
namespace sl {
|
||||
|
||||
diff --git a/src/sl/hash.hpp b/src/sl/hash.hpp
|
||||
index 3093a13..5f5b144 100644
|
||||
--- a/src/sl/hash.hpp
|
||||
+++ b/src/sl/hash.hpp
|
||||
@@ -24,6 +24,7 @@
|
||||
#define SL_HASH_HPP
|
||||
|
||||
#include <sl/utility.hpp>
|
||||
+#include <functional>
|
||||
|
||||
namespace sl {
|
||||
|
@ -9,6 +9,7 @@ vcpkg_download_distfile(ARCHIVE
|
||||
vcpkg_extract_source_archive(
|
||||
SOURCE_PATH
|
||||
ARCHIVE "${ARCHIVE}"
|
||||
PATCHES include_functional.patch
|
||||
)
|
||||
|
||||
vcpkg_cmake_configure(
|
||||
@ -25,4 +26,4 @@ vcpkg_cmake_configure(
|
||||
vcpkg_cmake_install()
|
||||
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include")
|
||||
|
||||
file(INSTALL "${SOURCE_PATH}/COPYING" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}" RENAME copyright)
|
||||
vcpkg_install_copyright(FILE_LIST "${SOURCE_PATH}/COPYING")
|
||||
|
@ -1,7 +1,7 @@
|
||||
{
|
||||
"name": "spaceland",
|
||||
"version": "7.8.2",
|
||||
"port-version": 7,
|
||||
"port-version": 8,
|
||||
"description": "Spaceland Lib (sl) is a suite for geometric computation, specifically adapted to OpenGL.",
|
||||
"dependencies": [
|
||||
{
|
||||
|
@ -3486,7 +3486,7 @@
|
||||
},
|
||||
"kenlm": {
|
||||
"baseline": "20200924",
|
||||
"port-version": 3
|
||||
"port-version": 4
|
||||
},
|
||||
"keystone": {
|
||||
"baseline": "0.9.2",
|
||||
@ -5046,7 +5046,7 @@
|
||||
},
|
||||
"mathgl": {
|
||||
"baseline": "8.0.1",
|
||||
"port-version": 1
|
||||
"port-version": 2
|
||||
},
|
||||
"matio": {
|
||||
"baseline": "1.5.23",
|
||||
@ -5250,7 +5250,7 @@
|
||||
},
|
||||
"moos-core": {
|
||||
"baseline": "10.4.0",
|
||||
"port-version": 7
|
||||
"port-version": 8
|
||||
},
|
||||
"moos-essential": {
|
||||
"baseline": "10.0.1",
|
||||
@ -6882,7 +6882,7 @@
|
||||
},
|
||||
"rappture": {
|
||||
"baseline": "1.9",
|
||||
"port-version": 3
|
||||
"port-version": 4
|
||||
},
|
||||
"raygui": {
|
||||
"baseline": "3.2",
|
||||
@ -7498,7 +7498,7 @@
|
||||
},
|
||||
"spaceland": {
|
||||
"baseline": "7.8.2",
|
||||
"port-version": 7
|
||||
"port-version": 8
|
||||
},
|
||||
"span-lite": {
|
||||
"baseline": "0.10.3",
|
||||
|
@ -1,5 +1,10 @@
|
||||
{
|
||||
"versions": [
|
||||
{
|
||||
"git-tree": "6f1bed68940353855027de67f5f6d33c5dbe8617",
|
||||
"version": "20200924",
|
||||
"port-version": 4
|
||||
},
|
||||
{
|
||||
"git-tree": "4947aeed6f0e7817a4be646bbb7685e4e5ebf62a",
|
||||
"version": "20200924",
|
||||
|
@ -1,5 +1,10 @@
|
||||
{
|
||||
"versions": [
|
||||
{
|
||||
"git-tree": "34ffe72f88b0fa47c8bf8ad235ed3cf109560f65",
|
||||
"version": "8.0.1",
|
||||
"port-version": 2
|
||||
},
|
||||
{
|
||||
"git-tree": "edd98363d2569c9ef358506313ce110045708f6a",
|
||||
"version": "8.0.1",
|
||||
|
@ -1,5 +1,10 @@
|
||||
{
|
||||
"versions": [
|
||||
{
|
||||
"git-tree": "9f2f00b654a7a9a9a810ae8d84099c9567f847cf",
|
||||
"version": "10.4.0",
|
||||
"port-version": 8
|
||||
},
|
||||
{
|
||||
"git-tree": "2081cab97d387c22addea1cec2a244f45a1a6b09",
|
||||
"version": "10.4.0",
|
||||
|
@ -1,5 +1,10 @@
|
||||
{
|
||||
"versions": [
|
||||
{
|
||||
"git-tree": "31376dbc3c6b3f397f76819c46c05a653c47e1ce",
|
||||
"version": "1.9",
|
||||
"port-version": 4
|
||||
},
|
||||
{
|
||||
"git-tree": "fabc9ec282c2f7ec7f5d5e2ae48fbaacb9227876",
|
||||
"version": "1.9",
|
||||
|
@ -1,5 +1,10 @@
|
||||
{
|
||||
"versions": [
|
||||
{
|
||||
"git-tree": "261556139a5816276568790ac8b8c7eba3b58f72",
|
||||
"version": "7.8.2",
|
||||
"port-version": 8
|
||||
},
|
||||
{
|
||||
"git-tree": "e8139a817a073bd514472aae3fb0366dcc52d620",
|
||||
"version": "7.8.2",
|
||||
|
Loading…
Reference in New Issue
Block a user