[soil] Update repository (#17012)

* [soil] Update repository

* Remove skip from ci.baseline.txt

* Update CMakeLists.txt and add support field

* update version files

* Update to another repository

* Rename SOILConfig.cmake.in to soilConfig.cmake.in

* Update ports/soil/portfile.cmake

* Update configureVersion file

* Update and rename SOILConfigVersion.cmake.in to soilConfigVersion.cmake.in

* Update version files

* Update versions/s-/soil.json
This commit is contained in:
NancyLi1013 2021-04-30 04:56:26 +08:00 committed by GitHub
parent 70610f4494
commit 11d559a0c9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
11 changed files with 74 additions and 86 deletions

View File

@ -1,50 +0,0 @@
cmake_minimum_required(VERSION 3.8)
project(SOIL C)
option(INSTALL_HEADERS "Install header files" ON)
set(INSTALL_CMAKE_DIR share/soil)
add_library(SOIL STATIC
src/image_helper.c
src/stb_image_aug.c
src/image_DXT.c
src/SOIL.c)
target_include_directories(SOIL INTERFACE $<INSTALL_INTERFACE:include>)
if(INSTALL_HEADERS)
install(TARGETS SOIL
EXPORT SOILTargets
ARCHIVE DESTINATION lib
LIBRARY DESTINATION lib)
install(FILES src/SOIL.h
DESTINATION include/SOIL/)
# Prepare and install package files
set(SOIL_VERSION "2018.7.7")
export(TARGETS SOIL FILE "${PROJECT_BINARY_DIR}/SOILTargets.cmake")
export(PACKAGE SOIL)
# Create the SOILConfig.cmake and SOILConfigVersion files
configure_file(SOILConfig.cmake.in "${PROJECT_BINARY_DIR}/SOILConfig.cmake" @ONLY)
configure_file(SOILConfigVersion.cmake.in "${PROJECT_BINARY_DIR}/SOILConfigVersion.cmake" @ONLY)
# Install the SOILConfig.cmake and SOILConfigVersion.cmake
install(FILES
"${PROJECT_BINARY_DIR}/SOILConfig.cmake"
"${PROJECT_BINARY_DIR}/SOILConfigVersion.cmake"
DESTINATION "${INSTALL_CMAKE_DIR}")
# Install the export set for use with the install-tree
install(EXPORT SOILTargets DESTINATION
"${INSTALL_CMAKE_DIR}")
else()
install(TARGETS SOIL
ARCHIVE DESTINATION lib
LIBRARY DESTINATION lib)
endif()

View File

@ -1,3 +0,0 @@
Source: soil
Version: 2008.07.07-2
Description: Simple OpenGL Image Library

View File

@ -1,6 +0,0 @@
https://www.lonesock.net/soil.html
Simple OpenGL Image Library
License:
Public Domain

View File

@ -0,0 +1,45 @@
diff --git a/CMakeLists.txt b/CMakeLists.txt
index c29d9bf..fc66b85 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -1,5 +1,7 @@
cmake_minimum_required(VERSION 2.6)
+project(soil C)
+
include_directories(inc)
ADD_LIBRARY( soil STATIC
@@ -8,3 +10,31 @@ ADD_LIBRARY( soil STATIC
src/image_DXT.c
src/SOIL.c
)
+
+target_include_directories(soil INTERFACE $<INSTALL_INTERFACE:include>)
+
+install(TARGETS soil
+ EXPORT soilTargets
+ ARCHIVE DESTINATION lib
+ LIBRARY DESTINATION lib)
+
+install(FILES inc/SOIL/SOIL.h
+ DESTINATION include/SOIL)
+
+# Prepare and install package files
+set(soil_VERSION "2021.4.22")
+
+export(TARGETS soil FILE "${PROJECT_BINARY_DIR}/soilTargets.cmake")
+
+export(PACKAGE soil)
+# Create the soilConfig.cmake and soilConfigVersion files
+configure_file(soilConfig.cmake.in "${PROJECT_BINARY_DIR}/soilConfig.cmake" @ONLY)
+configure_file(soilConfigVersion.cmake.in "${PROJECT_BINARY_DIR}/soilConfigVersion.cmake" @ONLY)
+# Install the soilConfig.cmake and soilConfigVersion.cmake
+install(FILES
+ "${PROJECT_BINARY_DIR}/soilConfig.cmake"
+ "${PROJECT_BINARY_DIR}/soilConfigVersion.cmake"
+ DESTINATION "share/soil")
+# Install the export set for use with the install-tree
+install(EXPORT soilTargets DESTINATION
+ "share/soil")
\ No newline at end of file

View File

@ -1,28 +1,28 @@
vcpkg_download_distfile(ARCHIVE
URLS "http://www.lonesock.net/files/soil.zip"
FILENAME "soil-2008.07.07.zip"
SHA512 a575a84aa65b7556320779d635561341f5cf156418d0462473e5d1eb082829be3bcb30600b4887af75aeddd3715de16bdb3ca1668ebaa93eea62bacf22b79548
)
vcpkg_fail_port_install(ON_TARGET "uwp")
vcpkg_extract_source_archive_ex(
vcpkg_from_github(
OUT_SOURCE_PATH SOURCE_PATH
ARCHIVE ${ARCHIVE}
REPO paralin/soil
REF 8bb18a909f94e58afbc0bda941ffc6eee58b4066 # committed on 2014-03-06
SHA512 6cbaa10d8b2a274c389fda723db53a3f1ba7d25a7367df40efec4d0553c09f0d67fb16f927bba2ff0aed4234e3a83922edcc574ffac72dd7e05d6cec768b561b
HEAD_REF master
PATCHES fix-cmakelists.patch
)
file(COPY
${CMAKE_CURRENT_LIST_DIR}/CMakeLists.txt
${CMAKE_CURRENT_LIST_DIR}/SOILConfig.cmake.in
${CMAKE_CURRENT_LIST_DIR}/SOILConfigVersion.cmake.in
${CMAKE_CURRENT_LIST_DIR}/LICENSE
${CMAKE_CURRENT_LIST_DIR}/soilConfig.cmake.in
${CMAKE_CURRENT_LIST_DIR}/soilConfigVersion.cmake.in
DESTINATION ${SOURCE_PATH}
)
vcpkg_configure_cmake(
SOURCE_PATH ${SOURCE_PATH}
PREFER_NINJA
OPTIONS_DEBUG -DINSTALL_HEADERS=OFF
)
vcpkg_install_cmake()
file(INSTALL ${SOURCE_PATH}/LICENSE DESTINATION ${CURRENT_PACKAGES_DIR}/share/${PORT} RENAME copyright)
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/include")
file(REMOVE_RECURSE "${CURRENT_PACKAGES_DIR}/debug/share")
file(INSTALL ${SOURCE_PATH}/LICENSE.txt DESTINATION ${CURRENT_PACKAGES_DIR}/share/${PORT} RENAME copyright)

View File

@ -5,9 +5,9 @@
# Load targets
get_filename_component(SOIL_CMAKE_DIR "${CMAKE_CURRENT_LIST_FILE}" PATH)
include("${SOIL_CMAKE_DIR}/SOILTargets.cmake")
include("${SOIL_CMAKE_DIR}/soilTargets.cmake")
# Set properties
get_target_property(SOIL_INCLUDE_DIRS SOIL INTERFACE_INCLUDE_DIRECTORIES)
set(SOIL_LIBRARIES SOIL)
get_target_property(SOIL_INCLUDE_DIRS soil INTERFACE_INCLUDE_DIRECTORIES)
set(SOIL_LIBRARIES soil)
mark_as_advanced(SOIL_INCLUDE_DIRS SOIL_LIBRARIES)

7
ports/soil/vcpkg.json Normal file
View File

@ -0,0 +1,7 @@
{
"name": "soil",
"version-date": "2021-04-22",
"description": "SOIL is a tiny C library used primarily for uploading textures into OpenGL.",
"homepage": "https://github.com/paralin/soil",
"supports": "!uwp"
}

View File

@ -1507,16 +1507,6 @@ sockpp:arm-uwp=fail
sockpp:x64-uwp=fail
soem:x64-uwp=fail
soem:arm-uwp=fail
# soil upstream is gone; if we do not have another source before 2021-03-01 we will remove the port
soil:arm-uwp=skip
soil:x64-uwp=skip
soil:arm64-windows=skip
soil:x64-windows=skip
soil:x86-windows=skip
soil:x64-windows-static=skip
soil:x64-windows-static-md=skip
soil:x64-linux=skip
soil:x64-osx=skip
soil2:arm-uwp=fail
soil2:x64-uwp=fail
soqt:arm64-windows=fail

View File

@ -5661,7 +5661,7 @@
"port-version": 0
},
"soil": {
"baseline": "2008.07.07-2",
"baseline": "2021-04-22",
"port-version": 0
},
"soil2": {

View File

@ -1,5 +1,10 @@
{
"versions": [
{
"git-tree": "9798401f421c850fbce93d990b143283ae5af293",
"version-date": "2021-04-22",
"port-version": 0
},
{
"git-tree": "4d137f0a640e2e1628d22a6a57018582f4e472a4",
"version-string": "2008.07.07-2",