vcpkg/ports/osgearth/make-all-find-packages-required.patch
Kai Pastor 99346bb692
[libwebp] Update, cleanup (#23864)
* Update to v1.2.2

* Fix libwebpmux Windows name breakage

The pc file relies on the original output name:
No 'lib' prefix for MSVC. No 'liblib' prefix for mingw.

* Minor portfile updates

* Don't self-depend on default features

* Fix the libwebpmux feature

* Fix internal tool dependencies

* Drop Xrandr patch (fixed in freeglut)

* Drop X11 patch (fixed in freeglut)

* Cleanup CMake config patch, no extra case hacks

* Adjust webp lib names in skia, qt5-imageformats

* Adjust downstream WEBP cmake usage

* Debug qtimageformats [skip actions]

* [tiff] Drive-by fix for CMake warning

* Drop non-standard debug postfix

* Update indentation

* Update port versions

* Update versions

* Revert qtimageformat debug change

* Fixup qt5-imageformats change

* Update versions
2022-04-13 11:26:56 -07:00

115 lines
3.5 KiB
Diff

diff --git a/CMakeLists.txt b/CMakeLists.txt
index 7541c8d07..cc14d2160 100755
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -122,40 +122,53 @@ option(OSGEARTH_ENABLE_GEOCODER "Enable the geocoder (GDAL/OGR must be built wit
# Mobile/GLES:
IF (OSGEARTH_USE_GLES)
- find_package(OpenGLES)
+ find_package(OpenGLES REQUIRED)
ELSE ()
- find_package(OpenGL)
+ find_package(OpenGL REQUIRED)
ENDIF (OSGEARTH_USE_GLES)
# required
find_package(OSG REQUIRED)
-find_package(CURL REQUIRED)
+find_package(CURL CONFIG REQUIRED)
+set(CURL_LIBRARY CURL::libcurl)
find_package(GDAL REQUIRED)
-
+set(GDAL_LIBRARY ${GDAL_LIBRARIES})
+set(GDAL_FOUND 1)
# optional
-find_package(GEOS)
-find_package(Sqlite3)
-find_package(Draco)
-find_package(BASISU)
-find_package(GLEW)
-find_package(Protobuf)
-find_package(WEBP)
-find_package(Blend2D)
+find_package(geos CONFIG REQUIRED)
+set(GEOS_LIBRARY GEOS::geos GEOS::geos_c)
+set(GEOS_FOUND 1)
+find_package(unofficial-sqlite3 CONFIG REQUIRED)
+set(SQLITE3_FOUND 1)
+set(SQLITE3_LIBRARY unofficial::sqlite3::sqlite3)
+find_package(Draco REQUIRED)
+find_package(BASISU REQUIRED)
+find_package(GLEW REQUIRED)
+set(GLEW_LIBRARIES GLEW::GLEW)
+set(GLEW_FOUND 1)
+find_package(protobuf CONFIG REQUIRED)
+set(Protobuf_LIBRARIES protobuf::libprotoc protobuf::libprotobuf)
+set(Protobuf_FOUND 1)
+find_package(WEBP NAMES WebP CONFIG REQUIRED)
+set(WEBP_LIBRARY WebP::webp)
+find_package(Blend2D CONFIG REQUIRED)
if(OSGEARTH_ENABLE_PROFILING)
- find_package(Tracy)
+ find_package(Tracy REQUIRED)
endif()
if(OSGEARTH_BUILD_ZIP_PLUGIN)
- find_package(LIBZIP)
+ find_package(libzip CONFIG REQUIRED)
+ set(LIBZIP_LIBRARY libzip::zip)
+ set(LIBZIP_FOUND 1)
endif()
if(OSGEARTH_BUILD_TRITON_NODEKIT)
- find_package(Triton QUIET)
+ find_package(Triton QUIET REQUIRED)
endif()
if(OSGEARTH_BUILD_SILVERLINING_NODEKIT)
- find_package(SilverLining QUIET)
+ find_package(SilverLining QUIET REQUIRED)
endif()
# Sqlite enables the MBTiles format:
@@ -193,7 +207,7 @@ SET (PROTOBUF_USE_DLLS FALSE CACHE BOOL "Set this to true if Protobuf is compile
# Duktape is the JavaScript interpreter
SET (WITH_EXTERNAL_DUKTAPE FALSE CACHE BOOL "Use bundled or system wide version of Duktape")
IF (WITH_EXTERNAL_DUKTAPE)
- find_package(Duktape)
+ find_package(Duktape REQUIRED)
ENDIF (WITH_EXTERNAL_DUKTAPE)
# Whether to install shaders (glsl files).
@@ -204,7 +218,9 @@ OPTION(OSGEARTH_INSTALL_SHADERS "Whether to deploy GLSL shaders when doing a Mak
# TinyXML is an XML parsing library
SET (WITH_EXTERNAL_TINYXML FALSE CACHE BOOL "Use bundled or system wide version of TinyXML")
IF (WITH_EXTERNAL_TINYXML)
- find_package(TinyXML)
+ find_package(tinyxml CONFIG REQUIRED)
+ set(TINYXML_FOUND 1)
+ set(TINYXML_LIBRARY unofficial-tinyxml::unofficial-tinyxml)
ENDIF (WITH_EXTERNAL_TINYXML)
# postfix settings for various configs
diff --git a/src/osgEarth/CMakeLists.txt b/src/osgEarth/CMakeLists.txt
index cd55c1164..4ecb61f0d 100644
--- a/src/osgEarth/CMakeLists.txt
+++ b/src/osgEarth/CMakeLists.txt
@@ -909,11 +909,11 @@ IF(FILEGDB_FOUND)
LINK_WITH_VARIABLES(${LIB_NAME} FILEGDB_LIBRARY)
ENDIF()
-IF(BLEND2D_FOUND)
+#IF(BLEND2D_FOUND)
add_definitions(-DOSGEARTH_HAVE_BLEND2D)
- include_directories(${BLEND2D_INCLUDES})
- link_with_variables(${LIB_NAME} BLEND2D_LIBRARY)
-ENDIF()
+# include_directories(${BLEND2D_INCLUDES})
+ target_link_libraries(${LIB_NAME} blend2d::blend2d)
+#ENDIF()
IF (WIN32)
LINK_EXTERNAL(${LIB_NAME} ${TARGET_EXTERNAL_LIBRARIES} ${CMAKE_THREAD_LIBS_INIT} ${MATH_LIBRARY} )