Skip to content

Commit ed2366d

Browse files
committed
Fix target_link_libraries
1 parent b932f95 commit ed2366d

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

cmake/libprotobuf-lite.cmake

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -65,9 +65,9 @@ endif()
6565

6666
add_library(libprotobuf-lite ${protobuf_SHARED_OR_STATIC}
6767
${libprotobuf_lite_files} ${libprotobuf_lite_includes} ${libprotobuf_lite_rc_files})
68-
target_link_libraries(libprotobuf-lite ${CMAKE_THREAD_LIBS_INIT})
68+
target_link_libraries(libprotobuf-lite PUBLIC ${CMAKE_THREAD_LIBS_INIT})
6969
if(protobuf_LINK_LIBATOMIC)
70-
target_link_libraries(libprotobuf-lite atomic)
70+
target_link_libraries(libprotobuf-lite PUBLIC atomic)
7171
endif()
7272
if(${CMAKE_SYSTEM_NAME} STREQUAL "Android")
7373
target_link_libraries(libprotobuf-lite log)

cmake/libprotobuf.cmake

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,7 @@ if(protobuf_WITH_ZLIB)
119119
target_link_libraries(libprotobuf PUBLIC ${ZLIB_LIBRARIES})
120120
endif()
121121
if(protobuf_LINK_LIBATOMIC)
122-
target_link_libraries(libprotobuf atomic)
122+
target_link_libraries(libprotobuf PUBLIC atomic)
123123
endif()
124124
if(${CMAKE_SYSTEM_NAME} STREQUAL "Android")
125125
target_link_libraries(libprotobuf log)

0 commit comments

Comments
 (0)