Add fast-obj library (#49975)

This commit is contained in:
Victor Gordan
2026-02-13 21:45:07 +00:00
committed by GitHub
parent ac7af7424c
commit af90a9c6a5
5 changed files with 76 additions and 0 deletions
+22
View File
@@ -0,0 +1,22 @@
cmake_minimum_required(VERSION 3.22)
project(fast-obj C)
add_library(fast-obj fast_obj.c)
target_include_directories(fast-obj PUBLIC
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}>
$<INSTALL_INTERFACE:include>
)
install(TARGETS fast-obj EXPORT fast-obj-config
ARCHIVE DESTINATION lib
LIBRARY DESTINATION lib
RUNTIME DESTINATION bin
)
install(FILES fast_obj.h DESTINATION include)
install(EXPORT fast-obj-config
NAMESPACE fast-obj::
DESTINATION share/fast-obj
)
+23
View File
@@ -0,0 +1,23 @@
vcpkg_check_linkage(ONLY_STATIC_LIBRARY)
vcpkg_from_github(
OUT_SOURCE_PATH SOURCE_PATH
REPO thisistherk/fast_obj
REF "v${VERSION}"
SHA512 8db413ce3526a91be7834d7fcec23b012738d017d2e28e4fc212fd58c0f5ef7fe4e7aea07aaf440fdc3ec7e6a6bfa32ea777a344a166246bcfd7bd35938b359f
HEAD_REF master
)
file(COPY "${CMAKE_CURRENT_LIST_DIR}/CMakeLists.txt" DESTINATION "${SOURCE_PATH}")
vcpkg_cmake_configure(
SOURCE_PATH "${SOURCE_PATH}"
)
vcpkg_cmake_install()
vcpkg_cmake_config_fixup(PACKAGE_NAME "fast-obj")
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include")
vcpkg_install_copyright(FILE_LIST "${SOURCE_PATH}/LICENSE")
+18
View File
@@ -0,0 +1,18 @@
{
"name": "fast-obj",
"version": "1.3",
"description": "Fast C OBJ parser - a single-header C/C++ library for loading Wavefront .obj files.",
"homepage": "https://github.com/thisistherk/fast_obj",
"license": "MIT",
"dependencies": [
"fmt",
{
"name": "vcpkg-cmake",
"host": true
},
{
"name": "vcpkg-cmake-config",
"host": true
}
]
}
+4
View File
@@ -2912,6 +2912,10 @@
"baseline": "8.2.3",
"port-version": 0
},
"fast-obj": {
"baseline": "1.3",
"port-version": 0
},
"fastcdr": {
"baseline": "2.3.5",
"port-version": 0
+9
View File
@@ -0,0 +1,9 @@
{
"versions": [
{
"git-tree": "c3eb88fc23edf4ec4553dec32730bbf5cd40ed73",
"version": "1.3",
"port-version": 0
}
]
}