Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
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
4 changes: 0 additions & 4 deletions ports/nghttp2/CONTROL

This file was deleted.

57 changes: 28 additions & 29 deletions ports/nghttp2/portfile.cmake
Original file line number Diff line number Diff line change
@@ -1,46 +1,45 @@
set(LIB_NAME nghttp2)
set(LIB_VERSION 1.42.0)

set(LIB_FILENAME ${LIB_NAME}-${LIB_VERSION}.tar.gz)

vcpkg_from_github(
OUT_SOURCE_PATH SOURCE_PATH
REPO nghttp2/nghttp2
REF v${LIB_VERSION}
SHA512 717494c9aa4eda64414535752df947d62311e7aed5cc6c4936400fcb2c9fc2818923668bcabc3e1bc61154d660f6765dad120e5a113d9eee3e934d66ee63a406
REF b799b063f882cc97f8484e95b41d0326260d9b93 # v1.44.0
SHA512 8e4a5d0b146606d1150b43c539244f615540bc25eab30bf67c673cccecdb3d4a02d99fb0136d81dc7ad4a579d9b38e62d91b1431884a8891c0d325c036cc4073
HEAD_REF master
)

if (VCPKG_LIBRARY_LINKAGE STREQUAL static)
set(ENABLE_STATIC_LIB ON)
set(ENABLE_SHARED_LIB OFF)
else()
set(ENABLE_STATIC_LIB OFF)
set(ENABLE_SHARED_LIB ON)
endif()
string(COMPARE EQUAL "${VCPKG_CRT_LINKAGE}" "static" ENABLE_STATIC_CRT)
string(COMPARE EQUAL "${VCPKG_LIBRARY_LINKAGE}" "static" ENABLE_STATIC_LIB)
string(COMPARE EQUAL "${VCPKG_LIBRARY_LINKAGE}" "dynamic" ENABLE_SHARED_LIB)

vcpkg_configure_cmake(
SOURCE_PATH ${SOURCE_PATH}
PREFER_NINJA
vcpkg_cmake_configure(
SOURCE_PATH "${SOURCE_PATH}"
OPTIONS
-DENABLE_LIB_ONLY=ON
-DENABLE_ASIO_LIB=OFF
-DENABLE_STATIC_LIB=${ENABLE_STATIC_LIB}
-DENABLE_SHARED_LIB=${ENABLE_SHARED_LIB}
"-DENABLE_STATIC_CRT=${ENABLE_STATIC_CRT}"
"-DENABLE_STATIC_LIB=${ENABLE_STATIC_LIB}"
"-DENABLE_SHARED_LIB=${ENABLE_SHARED_LIB}"
)

vcpkg_install_cmake()
vcpkg_cmake_install()
vcpkg_copy_pdbs()
vcpkg_fixup_pkgconfig()

file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/include)
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/debug/share)
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/share/man)
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/share/doc)
file(REMOVE_RECURSE
"${CURRENT_PACKAGES_DIR}/debug/include"
"${CURRENT_PACKAGES_DIR}/debug/share"
"${CURRENT_PACKAGES_DIR}/share/man"
"${CURRENT_PACKAGES_DIR}/share/doc"
)

if(VCPKG_LIBRARY_LINKAGE STREQUAL static)
file(REMOVE_RECURSE ${CURRENT_PACKAGES_DIR}/bin ${CURRENT_PACKAGES_DIR}/debug/bin)
file(REMOVE_RECURSE
"${CURRENT_PACKAGES_DIR}/bin"
"${CURRENT_PACKAGES_DIR}/debug/bin"
)
file(APPEND "${CURRENT_PACKAGES_DIR}/include/nghttp2/nghttp2ver.h" [[
#ifndef NGHTTP2_STATICLIB
# define NGHTTP2_STATICLIB
#endif
]])
endif()

file(INSTALL ${SOURCE_PATH}/COPYING DESTINATION ${CURRENT_PACKAGES_DIR}/share/${PORT} RENAME copyright)

vcpkg_copy_pdbs()
file(INSTALL "${SOURCE_PATH}/COPYING" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}" RENAME copyright)
12 changes: 12 additions & 0 deletions ports/nghttp2/vcpkg.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
{
"name": "nghttp2",
"version": "1.44.0",
"description": "Implementation of the Hypertext Transfer Protocol version 2 in C",
"homepage": "https://github.com/nghttp2/nghttp2",
"dependencies": [
{
"name": "vcpkg-cmake",
"host": true
}
]
}
2 changes: 1 addition & 1 deletion versions/baseline.json
Original file line number Diff line number Diff line change
Expand Up @@ -4357,7 +4357,7 @@
"port-version": 1
},
"nghttp2": {
"baseline": "1.42.0",
"baseline": "1.44.0",
"port-version": 0
},
"ngspice": {
Expand Down
5 changes: 5 additions & 0 deletions versions/n-/nghttp2.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
{
"versions": [
{
"git-tree": "7d98b71b7948db8173a563483081700e706268b0",
"version": "1.44.0",
"port-version": 0
},
{
"git-tree": "c962462a3cfe855132c4b1d565bc4e3c4a67797d",
"version-string": "1.42.0",
Expand Down