Skip to content

Commit

Permalink
Add fribidi as dependency
Browse files Browse the repository at this point in the history
  • Loading branch information
BLooperZ committed Aug 28, 2024
1 parent 2f19759 commit 3fcf4eb
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 0 deletions.
2 changes: 2 additions & 0 deletions CMake/Dependencies.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -284,3 +284,5 @@ if(GPERF)
find_package(Gperftools REQUIRED)
message("INFO: ${GPERFTOOLS_LIBRARIES}")
endif()

find_package(FRIBIDI REQUIRED)
13 changes: 13 additions & 0 deletions CMake/finders/FindFRIBIDI.cmake
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
find_package(PkgConfig)
pkg_check_modules(FRIBIDI QUIET fribidi)

find_path(FRIBIDI_INCLUDE_DIR
NAMES fribidi/fribidi.h)

find_library(FRIBIDI_LIBRARY NAMES fribidi)

if (NOT FRIBIDI_FOUND)
message(STATUS "GNU FriBidi not found")
else()
message(STATUS "Found GNU FriBidi: ${FRIBIDI_LIBRARY}")
endif (NOT FRIBIDI_FOUND)
4 changes: 4 additions & 0 deletions Source/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -384,12 +384,16 @@ target_link_libraries(libdevilutionx_parse_int PUBLIC
)

add_devilutionx_object_library(libdevilutionx_utf8
utils/unicode-bidi.cpp
utils/utf8.cpp
)
target_link_libraries(libdevilutionx_utf8 PRIVATE
hoehrmann_utf8
)

target_link_libraries(libdevilutionx_utf8 PRIVATE ${FRIBIDI_LIBRARY})


add_devilutionx_object_library(libdevilutionx_strings
utils/str_cat.cpp
utils/str_case.cpp
Expand Down

0 comments on commit 3fcf4eb

Please sign in to comment.