early-access version 2853
This commit is contained in:
46
externals/vcpkg/ports/vlpp/CMakeLists.txt
vendored
Executable file
46
externals/vcpkg/ports/vlpp/CMakeLists.txt
vendored
Executable file
@@ -0,0 +1,46 @@
|
||||
cmake_minimum_required(VERSION 3.3.0)
|
||||
|
||||
project(Vlpp VERSION 0.10.0.0 LANGUAGES CXX)
|
||||
|
||||
# Sources
|
||||
set(SRCS
|
||||
Import/Vlpp.cpp
|
||||
Import/VlppWorkflowLibrary.cpp
|
||||
Import/VlppWorkflowCompiler.cpp
|
||||
Import/VlppWorkflowRuntime.cpp)
|
||||
|
||||
if(CMAKE_CXX_COMPILER_ID STREQUAL "MSVC")
|
||||
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /bigobj")
|
||||
endif()
|
||||
|
||||
if(NOT CMAKE_CXX_STANDARD)
|
||||
set(CMAKE_CXX_STANDARD 14)
|
||||
endif()
|
||||
|
||||
# Create and configure the target
|
||||
add_library(Vlpp ${SRCS})
|
||||
|
||||
# target_compile_definitions
|
||||
target_compile_definitions(Vlpp PRIVATE UNICODE)
|
||||
target_compile_definitions(Vlpp PRIVATE _UNICODE)
|
||||
|
||||
target_include_directories(Vlpp PRIVATE ${PROJECT_SOURCE_DIR}/Import)
|
||||
|
||||
# Install
|
||||
install(
|
||||
TARGETS Vlpp
|
||||
RUNTIME DESTINATION "bin"
|
||||
LIBRARY DESTINATION "lib"
|
||||
ARCHIVE DESTINATION "lib"
|
||||
)
|
||||
|
||||
if (NOT DEFINED SKIP_HEADERS)
|
||||
install(
|
||||
FILES
|
||||
Import/Vlpp.h
|
||||
Import/VlppWorkflowLibrary.h
|
||||
Import/VlppWorkflowCompiler.h
|
||||
Import/VlppWorkflowRuntime.h
|
||||
DESTINATION "include"
|
||||
)
|
||||
endif()
|
||||
34
externals/vcpkg/ports/vlpp/fix-arm.patch
vendored
Executable file
34
externals/vcpkg/ports/vlpp/fix-arm.patch
vendored
Executable file
@@ -0,0 +1,34 @@
|
||||
--- a/Import/Vlpp.h
|
||||
+++ b/Import/Vlpp.h
|
||||
@@ -50,13 +50,12 @@
|
||||
#define abstract
|
||||
#endif
|
||||
-
|
||||
+#include <stdlib.h>
|
||||
#if defined VCZH_MSVC
|
||||
#include <intrin.h>
|
||||
#elif defined VCZH_GCC
|
||||
-#include <x86intrin.h>
|
||||
#include <stdint.h>
|
||||
#include <stddef.h>
|
||||
#include <wchar.h>
|
||||
#define abstract
|
||||
#define __thiscall
|
||||
#define __forceinline inline
|
||||
@@ -160,14 +159,14 @@
|
||||
#define UI64TOA_S _ui64toa_s
|
||||
#define UI64TOW_S _ui64tow_s
|
||||
#if defined VCZH_MSVC
|
||||
#define INCRC(x) (_InterlockedIncrement((volatile long*)(x)))
|
||||
#define DECRC(x) (_InterlockedDecrement((volatile long*)(x)))
|
||||
#elif defined VCZH_GCC
|
||||
-#define INCRC(x) (__sync_add_and_fetch(x, 1))
|
||||
-#define DECRC(x) (__sync_sub_and_fetch(x, 1))
|
||||
+#define INCRC(x) (__atomic_add_fetch(x, 1, __ATOMIC_SEQ_CST))
|
||||
+#define DECRC(x) (__atomic_sub_fetch(x, 1, __ATOMIC_SEQ_CST))
|
||||
#endif
|
||||
#endif
|
||||
|
||||
/***********************************************************************
|
||||
Basic Types
|
||||
***********************************************************************/
|
||||
27
externals/vcpkg/ports/vlpp/portfile.cmake
vendored
Executable file
27
externals/vcpkg/ports/vlpp/portfile.cmake
vendored
Executable file
@@ -0,0 +1,27 @@
|
||||
vcpkg_check_linkage(ONLY_STATIC_LIBRARY)
|
||||
|
||||
vcpkg_from_github(
|
||||
OUT_SOURCE_PATH SOURCE_PATH
|
||||
REPO vczh-libraries/Release
|
||||
REF 5dfe25c4f4997da2d7a23bdc80c2438e72d9813a # 0.11.0.0
|
||||
SHA512 5d585e561246385b074c625a3644b79defa22328dab0ab14112c846cb917f384abb617a5f400971ca29e4ee5ac391b88b17ee65d594caf9ebf279806db669a4a
|
||||
HEAD_REF master
|
||||
PATCHES fix-arm.patch
|
||||
)
|
||||
|
||||
file(COPY "${CMAKE_CURRENT_LIST_DIR}/CMakeLists.txt" DESTINATION "${SOURCE_PATH}")
|
||||
|
||||
vcpkg_cmake_configure(
|
||||
SOURCE_PATH "${SOURCE_PATH}"
|
||||
)
|
||||
|
||||
vcpkg_cmake_install()
|
||||
vcpkg_copy_pdbs()
|
||||
|
||||
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include")
|
||||
|
||||
# Tools
|
||||
file(INSTALL "${SOURCE_PATH}/Tools/CppMerge.exe" DESTINATION "${CURRENT_PACKAGES_DIR}/tools")
|
||||
|
||||
# Handle copyright
|
||||
file(INSTALL "${SOURCE_PATH}/LICENSE.md" DESTINATION "${CURRENT_PACKAGES_DIR}/share/vlpp" RENAME copyright)
|
||||
14
externals/vcpkg/ports/vlpp/vcpkg.json
vendored
Executable file
14
externals/vcpkg/ports/vlpp/vcpkg.json
vendored
Executable file
@@ -0,0 +1,14 @@
|
||||
{
|
||||
"name": "vlpp",
|
||||
"version": "0.11.0.0",
|
||||
"port-version": 3,
|
||||
"description": "Common C++ construction, including string operation / generic container / linq / General-LR parser generator / multithreading / reflection for C++ / etc",
|
||||
"homepage": "https://github.com/vczh-libraries/Release",
|
||||
"license": null,
|
||||
"dependencies": [
|
||||
{
|
||||
"name": "vcpkg-cmake",
|
||||
"host": true
|
||||
}
|
||||
]
|
||||
}
|
||||
Reference in New Issue
Block a user