From 50847d0c8e7c9073d94d27c83d507e7f2fc4d992 Mon Sep 17 00:00:00 2001 From: Cialloo <70629889+luckyweNda@users.noreply.github.com> Date: Fri, 5 May 2023 01:31:46 +0800 Subject: [PATCH] [rcon] add new port (#31131) * add valve source rcon protocal library, depend on asio * add license * fix format error * add version 1.0.0 * add blank line at the end of portfile.cmake and usage file * execute vcpkg x-add-version --all --overwrite-version to fix error in CI * change package name to cialloo-rcon * change version * Update versions/baseline.json Co-authored-by: jim wang <122244446+jimwang118@users.noreply.github.com> --------- Co-authored-by: jim wang <122244446+jimwang118@users.noreply.github.com> --- ports/cialloo-rcon/portfile.cmake | 16 ++++++++++++++++ ports/cialloo-rcon/usage | 4 ++++ ports/cialloo-rcon/vcpkg.json | 10 ++++++++++ versions/baseline.json | 4 ++++ versions/c-/cialloo-rcon.json | 9 +++++++++ 5 files changed, 43 insertions(+) create mode 100644 ports/cialloo-rcon/portfile.cmake create mode 100644 ports/cialloo-rcon/usage create mode 100644 ports/cialloo-rcon/vcpkg.json create mode 100644 versions/c-/cialloo-rcon.json diff --git a/ports/cialloo-rcon/portfile.cmake b/ports/cialloo-rcon/portfile.cmake new file mode 100644 index 0000000000..466fba8087 --- /dev/null +++ b/ports/cialloo-rcon/portfile.cmake @@ -0,0 +1,16 @@ +vcpkg_from_github( + OUT_SOURCE_PATH SOURCE_PATH + REPO luckyweNda/rcon + REF 6ea49bbd54bbf7604e4e3f6fc2dbd4e507d7bd90 + SHA512 84fefc80e6c47decd9fedb2df1ce1c2671cf8159eb8d60d9b90e3208dd2bd5786eb1bbd526d1d252cd1fc4c6bbb0377712b224c8a4b7ea66b52c6184c241f85e + HEAD_REF main +) + +# Install include directory +file(INSTALL "${SOURCE_PATH}/include" DESTINATION "${CURRENT_PACKAGES_DIR}") + +# Handle copyright +file(INSTALL "${SOURCE_PATH}/LICENSE" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}" RENAME copyright) + +# Copy usage file +file(INSTALL "${CMAKE_CURRENT_LIST_DIR}/usage" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}") diff --git a/ports/cialloo-rcon/usage b/ports/cialloo-rcon/usage new file mode 100644 index 0000000000..9c33607bbd --- /dev/null +++ b/ports/cialloo-rcon/usage @@ -0,0 +1,4 @@ +The package rcon is header only and can be used from CMake via: + + find_path(RCON_INCLUDE_DIRS "rcon.hpp") + target_include_directories(main PRIVATE ${RCON_INCLUDE_DIRS}) diff --git a/ports/cialloo-rcon/vcpkg.json b/ports/cialloo-rcon/vcpkg.json new file mode 100644 index 0000000000..ea7d342984 --- /dev/null +++ b/ports/cialloo-rcon/vcpkg.json @@ -0,0 +1,10 @@ +{ + "name": "cialloo-rcon", + "version": "1.0.0", + "description": "implementation in valve source rcon protocal", + "homepage": "https://github.com/luckyweNda/rcon", + "license": "MIT", + "dependencies": [ + "asio" + ] +} diff --git a/versions/baseline.json b/versions/baseline.json index f946a9d006..0365f71863 100644 --- a/versions/baseline.json +++ b/versions/baseline.json @@ -1504,6 +1504,10 @@ "baseline": "8.0.0", "port-version": 0 }, + "cialloo-rcon": { + "baseline": "1.0.0", + "port-version": 0 + }, "cimg": { "baseline": "2.9.9", "port-version": 0 diff --git a/versions/c-/cialloo-rcon.json b/versions/c-/cialloo-rcon.json new file mode 100644 index 0000000000..d02323dbc0 --- /dev/null +++ b/versions/c-/cialloo-rcon.json @@ -0,0 +1,9 @@ +{ + "versions": [ + { + "git-tree": "15e453031d883d06102b67a48336af5c3930a1ae", + "version": "1.0.0", + "port-version": 0 + } + ] +}