early-access version 2853
This commit is contained in:
112
externals/vcpkg/ports/quickfix/00001-fix-build.patch
vendored
Executable file
112
externals/vcpkg/ports/quickfix/00001-fix-build.patch
vendored
Executable file
@@ -0,0 +1,112 @@
|
||||
diff --git a/CMakeLists.txt b/CMakeLists.txt
|
||||
index 48908ead..90c17759 100644
|
||||
--- a/CMakeLists.txt
|
||||
+++ b/CMakeLists.txt
|
||||
@@ -92,13 +92,13 @@ include_directories(${PYTHON_INCLUDE_DIRS})
|
||||
endif ()
|
||||
|
||||
if( WIN32 OR ${CMAKE_SYSTEM_NAME} STREQUAL "Linux" )
|
||||
-add_subdirectory(UnitTest++)
|
||||
+#add_subdirectory(UnitTest++)
|
||||
endif()
|
||||
|
||||
add_subdirectory(src)
|
||||
-add_subdirectory(examples)
|
||||
+#add_subdirectory(examples)
|
||||
if( WIN32)
|
||||
-add_subdirectory(test)
|
||||
+#add_subdirectory(test)
|
||||
endif()
|
||||
|
||||
install(DIRECTORY ${CMAKE_SOURCE_DIR}/spec/ DESTINATION share/quickfix
|
||||
diff --git a/src/CMakeLists.txt b/src/CMakeLists.txt
|
||||
index cb4a60c6..d21fa995 100644
|
||||
--- a/src/CMakeLists.txt
|
||||
+++ b/src/CMakeLists.txt
|
||||
@@ -1,6 +1,6 @@
|
||||
add_subdirectory(C++)
|
||||
|
||||
-if( WIN32 OR ${CMAKE_SYSTEM_NAME} STREQUAL "Linux" )
|
||||
+if(0)
|
||||
|
||||
add_executable(at at.cpp getopt.c)
|
||||
|
||||
diff --git a/src/C++/CMakeLists.txt b/src/C++/CMakeLists.txt
|
||||
index 07774c97..27692631 100644
|
||||
--- a/src/C++/CMakeLists.txt
|
||||
+++ b/src/C++/CMakeLists.txt
|
||||
@@ -1,3 +1,4 @@
|
||||
+project(quickfix)
|
||||
set(quickfix_VERSION_MAJOR 16)
|
||||
set(quickfix_VERSION_MINOR 0)
|
||||
set(quickfix_VERSION_PATCH 1)
|
||||
@@ -64,19 +65,22 @@ endif()
|
||||
|
||||
if (WIN32)
|
||||
add_library(${PROJECT_NAME} STATIC ${quickfix_SOURCES})
|
||||
- set_target_properties (${PROJECT_NAME} PROPERTIES DEBUG_POSTFIX d)
|
||||
target_link_libraries(${PROJECT_NAME} ${OPENSSL_LIBRARIES} ${MYSQL_CLIENT_LIBS} ${PostgreSQL_LIBRARIES} ws2_32)
|
||||
+ target_compile_definitions(${PROJECT_NAME} PRIVATE _CRT_SECURE_NO_WARNINGS _CRT_NONSTDC_NO_DEPRECATE)
|
||||
else()
|
||||
- add_library(${PROJECT_NAME} SHARED ${quickfix_SOURCES})
|
||||
+ add_library(${PROJECT_NAME} STATIC ${quickfix_SOURCES})
|
||||
target_link_libraries(${PROJECT_NAME} ${OPENSSL_LIBRARIES} ${MYSQL_CLIENT_LIBS} ${PostgreSQL_LIBRARIES} pthread)
|
||||
endif()
|
||||
|
||||
target_include_directories(${PROJECT_NAME} PRIVATE ${CMAKE_SOURCE_DIR} ${CMAKE_SOURCE_DIR}/src ${CMAKE_SOURCE_DIR}/src/C++)
|
||||
+target_include_directories(${PROJECT_NAME} PUBLIC $<INSTALL_INTERFACE:include>)
|
||||
|
||||
set_target_properties(${PROJECT_NAME} PROPERTIES VERSION ${quickfix_VERSION} SOVERSION ${quickfix_VERSION_MAJOR} )
|
||||
+target_compile_definitions(${PROJECT_NAME} PUBLIC HAVE_STD_UNIQUE_PTR HAVE_STD_SHARED_PTR HAVE_SSL=1)
|
||||
|
||||
-install(TARGETS ${PROJECT_NAME} DESTINATION lib)
|
||||
+install(TARGETS ${PROJECT_NAME} EXPORT quickfix-config DESTINATION lib)
|
||||
install(DIRECTORY ${CMAKE_SOURCE_DIR}/src/C++/ DESTINATION include/quickfix
|
||||
FILES_MATCHING PATTERN "*.h"
|
||||
PATTERN double-conversion EXCLUDE
|
||||
PATTERN test EXCLUDE)
|
||||
+install(EXPORT quickfix-config DESTINATION share/cmake/quickfix)
|
||||
diff --git a/src/C++/Utility.h b/src/C++/Utility.h
|
||||
index 0aa2cd3e..2829e110 100644
|
||||
--- a/src/C++/Utility.h
|
||||
+++ b/src/C++/Utility.h
|
||||
@@ -242,4 +242,10 @@ using std::strtol;
|
||||
using std::strerror;
|
||||
#endif
|
||||
|
||||
+#ifdef __cpp_noexcept_function_type
|
||||
+#define QUICKFIX_THROW(...) noexcept(false)
|
||||
+#else
|
||||
+#define QUICKFIX_THROW(...) throw(__VA_ARGS__)
|
||||
+#endif
|
||||
+
|
||||
#endif
|
||||
diff --git a/src/C++/UtilitySSL.cpp b/src/C++/UtilitySSL.cpp
|
||||
index a01606ac..aee41bbf 100644
|
||||
--- a/src/C++/UtilitySSL.cpp
|
||||
+++ b/src/C++/UtilitySSL.cpp
|
||||
@@ -498,7 +498,11 @@ static void ssl_rand_seed(void)
|
||||
/*
|
||||
* seed in the current process id (usually just 4 bytes)
|
||||
*/
|
||||
+#ifdef _MSC_VER
|
||||
+ pid = GetCurrentProcessId();
|
||||
+#else
|
||||
pid = getpid();
|
||||
+#endif
|
||||
l = sizeof(pid);
|
||||
RAND_seed((unsigned char *)&pid, l);
|
||||
/*
|
||||
diff --git a/src/C++/double-conversion/utils.h b/src/C++/double-conversion/utils.h
|
||||
index aef2f166..779b8ab7 100644
|
||||
--- a/src/C++/double-conversion/utils.h
|
||||
+++ b/src/C++/double-conversion/utils.h
|
||||
@@ -61,7 +61,7 @@
|
||||
// disabled.)
|
||||
// On Linux,x86 89255e-22 != Div_double(89255.0/1e22)
|
||||
#if defined(_M_X64) || defined(__x86_64__) || \
|
||||
- defined(__ARMEL__) || defined(__avr32__) || \
|
||||
+ defined(__ARMEL__) || defined(__avr32__) || defined(_M_ARM) || defined(_M_ARM64) || \
|
||||
defined(__hppa__) || defined(__ia64__) || \
|
||||
defined(__mips__) || \
|
||||
defined(__powerpc__) || defined(__ppc__) || defined(__ppc64__) || \
|
||||
15
externals/vcpkg/ports/quickfix/fix_wsl_symlink_error.patch
vendored
Executable file
15
externals/vcpkg/ports/quickfix/fix_wsl_symlink_error.patch
vendored
Executable file
@@ -0,0 +1,15 @@
|
||||
diff --git a/cmake/QuickfixPrebuildSetup.cmake b/cmake/QuickfixPrebuildSetup.cmake
|
||||
index 9e53126ec..1c3368fcb 100644
|
||||
--- a/cmake/QuickfixPrebuildSetup.cmake
|
||||
+++ b/cmake/QuickfixPrebuildSetup.cmake
|
||||
@@ -3,8 +3,9 @@
|
||||
if (NOT WIN32)
|
||||
add_custom_target(QUICKFIX_HEADERS_LINK ALL
|
||||
COMMAND ${CMAKE_COMMAND} -E make_directory ${CMAKE_SOURCE_DIR}/include/
|
||||
- COMMAND ${CMAKE_COMMAND} -E create_symlink ${CMAKE_SOURCE_DIR}/src/C++ ${CMAKE_SOURCE_DIR}/include/quickfix
|
||||
+ #COMMAND ${CMAKE_COMMAND} -E create_symlink ${CMAKE_SOURCE_DIR}/src/C++ ${CMAKE_SOURCE_DIR}/include/quickfix
|
||||
)
|
||||
+ include_directories(${CMAKE_SOURCE_DIR}/src/C++)
|
||||
else()
|
||||
add_custom_target(QUICKFIX_HEADERS_COPY ALL
|
||||
COMMAND ${CMAKE_COMMAND} -E make_directory ${CMAKE_SOURCE_DIR}/include/
|
||||
49
externals/vcpkg/ports/quickfix/portfile.cmake
vendored
Executable file
49
externals/vcpkg/ports/quickfix/portfile.cmake
vendored
Executable file
@@ -0,0 +1,49 @@
|
||||
vcpkg_check_linkage(ONLY_STATIC_LIBRARY)
|
||||
|
||||
vcpkg_from_github(
|
||||
OUT_SOURCE_PATH SOURCE_PATH
|
||||
REPO quickfix/quickfix
|
||||
REF v1.15.1
|
||||
SHA512 6c3dc53f25932c9b7516ab9228f634511ae0f399719f87f0ec2b38c380c0a7d1c808f0f9a14a70a063e1956118550d1121222283a9139f23cd4f8f038f595f70
|
||||
HEAD_REF master
|
||||
PATCHES
|
||||
00001-fix-build.patch
|
||||
fix_wsl_symlink_error.patch
|
||||
)
|
||||
|
||||
file(GLOB_RECURSE SRC_FILES RELATIVE "${SOURCE_PATH}"
|
||||
"${SOURCE_PATH}/src/*.cpp"
|
||||
"${SOURCE_PATH}/src/*.h"
|
||||
)
|
||||
|
||||
list(REMOVE_ITEM SRC_FILES "src/C++/Utility.h")
|
||||
list(REMOVE_ITEM SRC_FILES "src/C++/pugixml.cpp")
|
||||
|
||||
foreach(SRC_FILE IN LISTS SRC_FILES)
|
||||
file(READ "${SOURCE_PATH}/${SRC_FILE}" _contents)
|
||||
string(REPLACE "throw(" "QUICKFIX_THROW(" _contents "${_contents}")
|
||||
string(REPLACE "throw (" "QUICKFIX_THROW(" _contents "${_contents}")
|
||||
file(WRITE "${SOURCE_PATH}/${SRC_FILE}" "${_contents}")
|
||||
endforeach()
|
||||
|
||||
vcpkg_cmake_configure(
|
||||
SOURCE_PATH "${SOURCE_PATH}"
|
||||
OPTIONS
|
||||
-DHAVE_EMX=OFF
|
||||
-DHAVE_MYSQL=OFF
|
||||
-DHAVE_POSTGRESQL=OFF
|
||||
-DHAVE_PYTHON=OFF
|
||||
-DHAVE_PYTHON2=OFF
|
||||
-DHAVE_PYTHON3=OFF
|
||||
-DHAVE_SSL=ON
|
||||
)
|
||||
|
||||
vcpkg_cmake_install()
|
||||
vcpkg_copy_pdbs()
|
||||
vcpkg_cmake_config_fixup(CONFIG_PATH share/cmake/quickfix)
|
||||
|
||||
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include")
|
||||
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/share")
|
||||
|
||||
file(COPY "${CMAKE_CURRENT_LIST_DIR}/usage" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}")
|
||||
file(INSTALL "${SOURCE_PATH}/LICENSE" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}" RENAME copyright)
|
||||
4
externals/vcpkg/ports/quickfix/usage
vendored
Executable file
4
externals/vcpkg/ports/quickfix/usage
vendored
Executable file
@@ -0,0 +1,4 @@
|
||||
The package quickfix provides CMake targets:
|
||||
|
||||
find_package(quickfix CONFIG REQUIRED)
|
||||
target_link_libraries(main PRIVATE quickfix)
|
||||
19
externals/vcpkg/ports/quickfix/vcpkg.json
vendored
Executable file
19
externals/vcpkg/ports/quickfix/vcpkg.json
vendored
Executable file
@@ -0,0 +1,19 @@
|
||||
{
|
||||
"name": "quickfix",
|
||||
"version": "1.15.1",
|
||||
"port-version": 7,
|
||||
"description": "QuickFIX is a free and open source implementation of the FIX protocol.",
|
||||
"homepage": "https://github.com/quickfix/quickfix",
|
||||
"supports": "!uwp",
|
||||
"dependencies": [
|
||||
"openssl",
|
||||
{
|
||||
"name": "vcpkg-cmake",
|
||||
"host": true
|
||||
},
|
||||
{
|
||||
"name": "vcpkg-cmake-config",
|
||||
"host": true
|
||||
}
|
||||
]
|
||||
}
|
||||
Reference in New Issue
Block a user