early-access version 2853
This commit is contained in:
28
externals/vcpkg/ports/mongoose/CMakeLists.txt
vendored
Executable file
28
externals/vcpkg/ports/mongoose/CMakeLists.txt
vendored
Executable file
@@ -0,0 +1,28 @@
|
||||
cmake_minimum_required(VERSION 3.14)
|
||||
|
||||
project(mongoose C)
|
||||
|
||||
include(GNUInstallDirs)
|
||||
|
||||
option(ENABLE_SSL "Build with openssl support" OFF)
|
||||
|
||||
set(CMAKE_INCLUDE_CURRENT_DIR ON)
|
||||
|
||||
add_library(mongoose mongoose.c)
|
||||
target_include_directories(mongoose PUBLIC $<INSTALL_INTERFACE:${CMAKE_INSTALL_INCLUDEDIR}>)
|
||||
set_target_properties(mongoose PROPERTIES PUBLIC_HEADER mongoose.h)
|
||||
|
||||
if (ENABLE_SSL)
|
||||
find_package(OpenSSL REQUIRED)
|
||||
target_compile_options(mongoose PRIVATE -DMG_ENABLE_SSL)
|
||||
target_link_libraries(mongoose PRIVATE OpenSSL::SSL OpenSSL::Crypto)
|
||||
endif()
|
||||
|
||||
install(TARGETS mongoose EXPORT unofficial-mongoose-config)
|
||||
|
||||
install(
|
||||
EXPORT unofficial-mongoose-config
|
||||
NAMESPACE unofficial::mongoose::
|
||||
DESTINATION share/unofficial-mongoose
|
||||
PERMISSIONS OWNER_READ OWNER_WRITE GROUP_READ WORLD_READ
|
||||
)
|
||||
30
externals/vcpkg/ports/mongoose/portfile.cmake
vendored
Executable file
30
externals/vcpkg/ports/mongoose/portfile.cmake
vendored
Executable file
@@ -0,0 +1,30 @@
|
||||
vcpkg_check_linkage(ONLY_STATIC_LIBRARY)
|
||||
|
||||
vcpkg_from_github(
|
||||
OUT_SOURCE_PATH SOURCE_PATH
|
||||
REPO cesanta/mongoose
|
||||
REF 1b82aa02aa3d6fecfc23ed0a94c6917f139de1ad #v7.6
|
||||
SHA512 50f13a2cc5dca6ccbc30e9686166b8615faad0ea010966d215d583c04338396a5d2613fe065cc17d8f918673b20004596ca8f73f1b636679db82dbb063698a80
|
||||
HEAD_REF master
|
||||
)
|
||||
|
||||
file(COPY "${CMAKE_CURRENT_LIST_DIR}/CMakeLists.txt" DESTINATION "${SOURCE_PATH}")
|
||||
|
||||
vcpkg_check_features(OUT_FEATURE_OPTIONS FEATURE_OPTIONS
|
||||
FEATURES
|
||||
ssl ENABLE_SSL
|
||||
)
|
||||
|
||||
vcpkg_cmake_configure(
|
||||
SOURCE_PATH "${SOURCE_PATH}"
|
||||
OPTIONS ${FEATURE_OPTIONS}
|
||||
)
|
||||
|
||||
vcpkg_cmake_install()
|
||||
|
||||
vcpkg_cmake_config_fixup(PACKAGE_NAME unofficial-${PORT} CONFIG_PATH share/unofficial-${PORT})
|
||||
|
||||
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include")
|
||||
|
||||
# Handle copyright
|
||||
file(INSTALL "${SOURCE_PATH}/LICENSE" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}" RENAME copyright)
|
||||
26
externals/vcpkg/ports/mongoose/vcpkg.json
vendored
Executable file
26
externals/vcpkg/ports/mongoose/vcpkg.json
vendored
Executable file
@@ -0,0 +1,26 @@
|
||||
{
|
||||
"name": "mongoose",
|
||||
"version": "7.6",
|
||||
"description": "Embedded web server / embedded networking library",
|
||||
"homepage": "https://cesanta.com/",
|
||||
"license": null,
|
||||
"supports": "!uwp",
|
||||
"dependencies": [
|
||||
{
|
||||
"name": "vcpkg-cmake",
|
||||
"host": true
|
||||
},
|
||||
{
|
||||
"name": "vcpkg-cmake-config",
|
||||
"host": true
|
||||
}
|
||||
],
|
||||
"features": {
|
||||
"ssl": {
|
||||
"description": "Build with openssl",
|
||||
"dependencies": [
|
||||
"openssl"
|
||||
]
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user