Skip to content

Commit

Permalink
Cxx: Try fix linux compilation
Browse files Browse the repository at this point in the history
  • Loading branch information
agdavydov81 committed Oct 20, 2023
1 parent 1c3ec34 commit 1a5644d
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions native/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -9,11 +9,10 @@ set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${CMAKE_C_FLAGS_IN}")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${CMAKE_CXX_FLAGS_IN}")

if (TARGET)
set(TARGET_FLAGS "--target=${TARGET} ${TARGET_EX}")
set(TARGET_FLAGS "--target=${TARGET} ${TARGET_EX} -I/usr/${TARGET}/include")
if (SYSROOT)
set(TARGET_FLAGS "${TARGET_FLAGS} --sysroot=${SYSROOT} -I${SYSROOT}/include/c++/v1")
endif()
set(TARGET_FLAGS "${TARGET_FLAGS} -I/usr/${TARGET}/include")
endif()
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${TARGET_FLAGS}")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} ${TARGET_FLAGS}")
endif()
Expand Down

0 comments on commit 1a5644d

Please sign in to comment.