[vcpkg baseline][easyhook] Remove mismatch prebuild library after build (#19216)

* [easyhook] Remove mismatch prebuild library after build

* version

* update baseline

* Update ports/easyhook/portfile.cmake

Co-authored-by: Phoebe <20694052+PhoebeHui@users.noreply.github.com>

* Update ports/easyhook/vcpkg.json

* Update versions/e-/easyhook.json

* Update versions/e-/easyhook.json

Co-authored-by: Phoebe <20694052+PhoebeHui@users.noreply.github.com>
This commit is contained in:
Jack·Boos·Yu 2021-07-29 12:51:34 +08:00 committed by GitHub
parent 850662ca65
commit 8dddc6c899
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
6 changed files with 50 additions and 25 deletions

View File

@ -1,5 +0,0 @@
Source: easyhook
Version: 2.7.6789.0
Homepage: https://github.com/EasyHook/EasyHook
Description: This project supports extending (hooking) unmanaged code (APIs) with pure managed ones, from within a fully managed environment on 32- or 64-bit Windows Vista x64, Windows Server 2008 x64, Windows 7, Windows 8.1, and Windows 10.
Supports: windows

View File

@ -1,12 +1,6 @@
if (NOT VCPKG_TARGET_IS_WINDOWS)
message(FATAL_ERROR "easyhook only support windows.")
endif()
vcpkg_fail_port_install(ON_TARGET "Linux" "OSX" "UWP" ON_ARCH "arm" ON_LIBRARY_LINKAGE "static")
if (VCPKG_LIBRARY_LINKAGE STREQUAL static)
message(FATAL_ERROR "easyhook can only be built as dynamic library.")
endif()
message(".Net framework 4.0 is required, please install it before install easyhook.")
message(WARNING ".Net framework 4.0 is required, please install it before install easyhook.")
vcpkg_from_github(
OUT_SOURCE_PATH SOURCE_PATH
@ -17,20 +11,50 @@ vcpkg_from_github(
PATCHES fix-build.patch
)
if (VCPKG_TARGET_ARCHITECTURE STREQUAL "x86")
set(BUILD_ARCH "Win32")
elseif (VCPKG_TARGET_ARCHITECTURE STREQUAL "x64")
set(BUILD_ARCH "x64")
else()
message(FATAL_ERROR "Unsupported architecture: ${VCPKG_TARGET_ARCHITECTURE}")
endif()
vcpkg_install_msbuild(
SOURCE_PATH ${SOURCE_PATH}
PROJECT_SUBPATH EasyHook.sln
TARGET EasyHookDll
RELEASE_CONFIGURATION "netfx4-Release"
DEBUG_CONFIGURATION "netfx4-Debug"
PLATFORM ${BUILD_ARCH}
)
# Remove the mismatch rebuild library
if (VCPKG_TARGET_ARCHITECTURE STREQUAL "x86")
if (NOT VCPKG_BUILD_TYPE OR VCPKG_BUILD_TYPE STREQUAL "debug")
file(REMOVE "${CURRENT_PACKAGES_DIR}/debug/lib/AUX_ULIB_x64.LIB")
endif()
if (NOT VCPKG_BUILD_TYPE OR VCPKG_BUILD_TYPE STREQUAL "release")
file(REMOVE "${CURRENT_PACKAGES_DIR}/lib/AUX_ULIB_x64.LIB")
endif()
elseif (VCPKG_TARGET_ARCHITECTURE STREQUAL "x64")
if (NOT VCPKG_BUILD_TYPE OR VCPKG_BUILD_TYPE STREQUAL "debug")
file(REMOVE "${CURRENT_PACKAGES_DIR}/debug/lib/AUX_ULIB_x86.LIB")
endif()
if (NOT VCPKG_BUILD_TYPE OR VCPKG_BUILD_TYPE STREQUAL "release")
file(REMOVE "${CURRENT_PACKAGES_DIR}/lib/AUX_ULIB_x86.LIB")
endif()
endif()
# These libraries are useless, so remove.
file(REMOVE ${CURRENT_PACKAGES_DIR}/bin/EasyHook.dll ${CURRENT_PACKAGES_DIR}/bin/EasyHook.pdb)
file(REMOVE ${CURRENT_PACKAGES_DIR}/debug/bin/EasyHook.dll ${CURRENT_PACKAGES_DIR}/debug/bin/EasyHook.pdb)
if (NOT VCPKG_BUILD_TYPE OR VCPKG_BUILD_TYPE STREQUAL "debug")
file(REMOVE "${CURRENT_PACKAGES_DIR}/bin/EasyHook.dll" "${CURRENT_PACKAGES_DIR}/bin/EasyHook.pdb")
endif()
if (NOT VCPKG_BUILD_TYPE OR VCPKG_BUILD_TYPE STREQUAL "release")
file(REMOVE "${CURRENT_PACKAGES_DIR}/debug/bin/EasyHook.dll" "${CURRENT_PACKAGES_DIR}/debug/bin/EasyHook.pdb")
endif()
# Install includes
file(INSTALL ${SOURCE_PATH}/Public/easyhook.h DESTINATION ${CURRENT_PACKAGES_DIR}/include/easyhook)
file(INSTALL "${SOURCE_PATH}/Public/easyhook.h" DESTINATION "${CURRENT_PACKAGES_DIR}/include/easyhook")
# Handle copyright
file(INSTALL ${SOURCE_PATH}/LICENSE DESTINATION ${CURRENT_PACKAGES_DIR}/share/easyhook RENAME copyright)
file(INSTALL "${SOURCE_PATH}/LICENSE" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}" RENAME copyright)

View File

@ -0,0 +1,8 @@
{
"name": "easyhook",
"version": "2.7.6789.0",
"port-version": 1,
"description": "This project supports extending (hooking) unmanaged code (APIs) with pure managed ones, from within a fully managed environment on 32- or 64-bit Windows Vista x64, Windows Server 2008 x64, Windows 7, Windows 8.1, and Windows 10.",
"homepage": "https://github.com/EasyHook/EasyHook",
"supports": "windows & !(static | arm | uwp)"
}

View File

@ -247,13 +247,6 @@ duilib:x64-uwp=fail
duktape:x64-osx=skip
eastl:arm-uwp=fail
easyhook:arm64-windows=fail
easyhook:arm-uwp=fail
easyhook:x64-linux=fail
easyhook:x64-osx=fail
easyhook:x64-uwp=fail
easyhook:x64-windows-static=fail
easyhook:x64-windows-static-md=fail
easyloggingpp:arm-uwp=fail
easyloggingpp:x64-uwp=fail
eathread:arm64-windows=fail

View File

@ -1810,7 +1810,7 @@
},
"easyhook": {
"baseline": "2.7.6789.0",
"port-version": 0
"port-version": 1
},
"easyloggingpp": {
"baseline": "9.96.7-1",

View File

@ -1,5 +1,10 @@
{
"versions": [
{
"git-tree": "e427f42cec56130de81333fda405afabc88c9e82",
"version": "2.7.6789.0",
"port-version": 1
},
{
"git-tree": "cf87554bbdd4736b3b64210e7662d6bbe3d72b2a",
"version-string": "2.7.6789.0",