Skip to content

Commit

Permalink
ios下编译静态库
Browse files Browse the repository at this point in the history
  • Loading branch information
chexiongsheng committed Dec 12, 2024
1 parent 21f8676 commit a5083e8
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -135,7 +135,11 @@ if(NOT MSVC)
list(APPEND qjs_libs m)
endif()

add_library(PapiQjs SHARED ${qjs_sources} ${eastl_headers} ${eastl_sources})
if ( APPLE AND IOS )
add_library(PapiQjs STATIC ${qjs_sources} ${eastl_headers} ${eastl_sources})
else ()
add_library(PapiQjs SHARED ${qjs_sources} ${eastl_headers} ${eastl_sources})
endif()
target_compile_definitions(PapiQjs PRIVATE ${qjs_defines})
target_include_directories(PapiQjs PUBLIC
$<BUILD_INTERFACE:${CMAKE_CURRENT_SOURCE_DIR}>
Expand Down

0 comments on commit a5083e8

Please sign in to comment.