[games101-cgl] new port (#31831)

* [games101-cgl] new port

* [games101-cgl] update version file

* [games101-cgl] update version dataset

* Updated the logic for installing the source code repository

* Updated the logic for installing the source code repository

* Update ports/games101-cgl/portfile.cmake

Co-authored-by: Cheney Wang <38240633+Cheney-W@users.noreply.github.com>

* modify installation behavior

* add git-tree id

* Update version database

* add usage

* modify download hash

* update version data

---------

Co-authored-by: Cheney Wang <38240633+Cheney-W@users.noreply.github.com>
This commit is contained in:
endingly 2023-06-15 03:35:23 +08:00 committed by GitHub
parent 146797a23b
commit 3056fed522
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
5 changed files with 62 additions and 0 deletions

View File

@ -0,0 +1,21 @@
vcpkg_from_github(
OUT_SOURCE_PATH SOURCE_PATH
REPO endingly/games101-cgl
REF v${VERSION}
SHA512 609bc549a5bb20254fa8ae8a765b688352d017bf4f1fa278385b534da3c75eb81fc893dd1736db7efd0ab13c62de3597ccb678a3c2a6f31c0ee6549f6d5c9f3d
HEAD_REF main
)
vcpkg_cmake_configure(
SOURCE_PATH "${SOURCE_PATH}"
)
vcpkg_cmake_install()
vcpkg_copy_pdbs()
vcpkg_cmake_config_fixup()
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include")
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/share")
vcpkg_install_copyright(FILE_LIST "${SOURCE_PATH}/license")
file(INSTALL "${CMAKE_CURRENT_LIST_DIR}/usage" DESTINATION "${CURRENT_PACKAGES_DIR}/share/${PORT}")

7
ports/games101-cgl/usage Normal file
View File

@ -0,0 +1,7 @@
The package games101-cgl provides CMake targets:
find_package(games101-cgl CONFIG REQUIRED)
target_link_libraries(main PRIVATE games101-cgl)
And include header file like:
#include <CGL/CGL.h>

View File

@ -0,0 +1,21 @@
{
"$schema": "https://raw.githubusercontent.com/microsoft/vcpkg-tool/main/docs/vcpkg.schema.json",
"name": "games101-cgl",
"version": "0.1.0",
"description": "The package is for Games101's homework8 subproject.",
"homepage": "https://github.com/endingly/games101-cgl",
"license": "MIT",
"dependencies": [
"freetype",
"glew",
"glfw3",
{
"name": "vcpkg-cmake",
"host": true
},
{
"name": "vcpkg-cmake-config",
"host": true
}
]
}

View File

@ -2708,6 +2708,10 @@
"baseline": "1.4.1", "baseline": "1.4.1",
"port-version": 1 "port-version": 1
}, },
"games101-cgl": {
"baseline": "0.1.0",
"port-version": 0
},
"gamma": { "gamma": {
"baseline": "gamma-2018-01-27", "baseline": "gamma-2018-01-27",
"port-version": 6 "port-version": 6

View File

@ -0,0 +1,9 @@
{
"versions": [
{
"git-tree": "976ee066a06bc29768e1fd575da2e7d622cf6465",
"version": "0.1.0",
"port-version": 0
}
]
}