Skip to content

Commit 73aab33

Browse files
committed
Add utfcpp submdule
1 parent eaa66ea commit 73aab33

File tree

3 files changed

+8
-5
lines changed

3 files changed

+8
-5
lines changed

.gitmodules

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,3 +4,6 @@
44
[submodule "thirdparty/googletest"]
55
path = thirdparty/googletest
66
url = https://github.com/google/googletest
7+
[submodule "thirdparty/utfcpp"]
8+
path = thirdparty/utfcpp
9+
url = https://github.com/nemtrif/utfcpp

CMakeLists.txt

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@ project(libscratchcpp LANGUAGES C CXX)
55
set(CMAKE_INCLUDE_CURRENT_DIR ON)
66
set(CMAKE_CXX_STANDARD 17)
77
set(CMAKE_CXX_STANDARD_REQUIRED ON)
8-
set(ZIP_SRC thirdparty/zip/src)
98

109
option(LIBSCRATCHCPP_BUILD_UNIT_TESTS "Build unit tests" ON)
1110
option(LIBSCRATCHCPP_NETWORK_SUPPORT "Support for downloading projects" ON)
@@ -16,8 +15,6 @@ if (NOT (CMAKE_CXX_COMPILER_ID STREQUAL "GNU"))
1615
set(LIBSCRATCHCPP_COMPUTED_GOTO OFF CACHE BOOL "" FORCE)
1716
endif()
1817

19-
find_package(utf8cpp REQUIRED)
20-
2118
add_library(scratchcpp SHARED)
2219
add_subdirectory(src)
2320
include_directories(src) # TODO: Remove this line
@@ -66,21 +63,23 @@ target_sources(scratchcpp
6663
)
6764

6865
include(FetchContent)
66+
set(ZIP_SRC thirdparty/zip/src)
67+
set(UTFCPP_SRC thirdparty/utfcpp/source)
6968

7069
add_library(zip SHARED
7170
${ZIP_SRC}/zip.c
7271
${ZIP_SRC}/zip.h
7372
${ZIP_SRC}/miniz.h
7473
)
75-
include_directories(thirdparty/zip/src)
74+
target_include_directories(scratchcpp PUBLIC ${ZIP_SRC})
7675

76+
target_include_directories(scratchcpp PUBLIC ${UTFCPP_SRC})
7777
include_directories(thirdparty/spimpl)
7878

7979
FetchContent_Declare(json URL https://github.com/nlohmann/json/releases/download/v3.11.3/json.tar.xz)
8080
FetchContent_MakeAvailable(json)
8181

8282
target_link_libraries(scratchcpp PRIVATE nlohmann_json::nlohmann_json)
83-
target_link_libraries(scratchcpp PRIVATE utf8cpp)
8483
target_link_libraries(scratchcpp PRIVATE zip)
8584
target_link_libraries(scratchcpp PRIVATE scratchcpp-audio)
8685

thirdparty/utfcpp

Submodule utfcpp added at 6be08bb

0 commit comments

Comments
 (0)