Skip to content

Commit

Permalink
enable rtti for cross compiling
Browse files Browse the repository at this point in the history
  • Loading branch information
nihui committed Nov 22, 2023
1 parent 3cf8410 commit 2537d0a
Showing 1 changed file with 8 additions and 8 deletions.
16 changes: 8 additions & 8 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -80,20 +80,20 @@ option(NCNN_INT8 "int8 inference" ON)
option(NCNN_BF16 "bf16 inference" ON)
option(NCNN_FORCE_INLINE "force inline some function" ON)

if(ANDROID OR IOS OR NCNN_SIMPLESTL OR CMAKE_CROSSCOMPILING)
if(ANDROID OR IOS OR NCNN_SIMPLESTL)
option(NCNN_DISABLE_RTTI "disable rtti" ON)
option(NCNN_BUILD_TOOLS "build tools" OFF)
option(NCNN_BUILD_EXAMPLES "build examples" OFF)
option(NCNN_DISABLE_EXCEPTION "disable exception" ON)
else()
option(NCNN_DISABLE_RTTI "disable rtti" OFF)
option(NCNN_BUILD_TOOLS "build tools" ON)
option(NCNN_BUILD_EXAMPLES "build examples" ON)
option(NCNN_DISABLE_EXCEPTION "disable exception" OFF)
endif()

if(ANDROID OR IOS OR NCNN_SIMPLESTL)
option(NCNN_DISABLE_EXCEPTION "disable exception" ON)
if(ANDROID OR IOS OR NCNN_SIMPLESTL OR CMAKE_CROSSCOMPILING)
option(NCNN_BUILD_TOOLS "build tools" OFF)
option(NCNN_BUILD_EXAMPLES "build examples" OFF)
else()
option(NCNN_DISABLE_EXCEPTION "disable exception" OFF)
option(NCNN_BUILD_TOOLS "build tools" ON)
option(NCNN_BUILD_EXAMPLES "build examples" ON)
endif()

if(NCNN_SHARED_LIB)
Expand Down

0 comments on commit 2537d0a

Please sign in to comment.