🐛 Fixed MyGUI build on windows

This commit is contained in:
Edgar 2021-08-06 17:35:50 +02:00
parent 642ef3dcd6
commit fb90c5e78e
No known key found for this signature in database
GPG Key ID: 17D930BB616061A5
3 changed files with 29 additions and 1 deletions

2
.gitignore vendored
View File

@ -1,3 +1,3 @@
build/
tmp/
upload.sh
upload.*

View File

@ -5,6 +5,7 @@ sources:
patches:
"3.4.0":
- patch_file: "patches/3.4.0/CMakeLists.txt.patch"
- patch_file: "patches/3.4.0/AddLibPNG.patch"
requirements:
- "ogre3d/[1.x]@anotherfoxguy/stable"
- "freetype/[2.x]"

View File

@ -0,0 +1,27 @@
--- MyGUIEngine/CMakeLists.txt
+++ MyGUIEngine/CMakeLists.txt
@@ -41,8 +41,24 @@
endif()
if (MYGUI_USE_FREETYPE)
+ # FreeType from conan has seperate libraries
+ find_package(PNG)
+ find_package(BZip2)
+
+ find_library(BROTLICOMMON_LIBRARY NAMES brotlicommon brotlicommon-static)
+ find_library(BROTLIDEC_LIBRARY NAMES brotlidec brotlidec-static)
+
+ if(NOT ${BROTLIDEC_LIBRARY} STREQUAL "BROTLICOMMON_LIBRARY-NOTFOUND" AND NOT ${BROTLIDEC_LIBRARY} STREQUAL "BROTLIDEC_LIBRARY-NOTFOUND")
+ set(BROTLI_LIBRARIES ${BROTLICOMMON_LIBRARY} ${BROTLIDEC_LIBRARY})
+ message(STATUS "Brotli libraries found: ${BROTLI_LIBRARIES}")
+ else()
+ message(WARNING "Brotli library not found: ${BROTLICOMMON_LIBRARY} ${BROTLIDEC_LIBRARY}")
+ endif()
target_link_libraries(${PROJECTNAME}
${FREETYPE_LIBRARIES}
+ ${PNG_LIBRARIES}
+ ${BZIP2_LIBRARIES}
+ ${BROTLI_LIBRARIES}
${ZLIB_LIBRARIES}
)
endif()