Lines 1-20
Link Here
|
1 |
--- src/CMakeLists.txt.orig 2023-03-27 18:48:43 UTC |
1 |
--- src/CMakeLists.txt.orig 2023-04-19 22:01:02 UTC |
2 |
+++ src/CMakeLists.txt |
2 |
+++ src/CMakeLists.txt |
3 |
@@ -516,6 +516,18 @@ See https://github.com/opencv/opencv/issues/19260]]) |
3 |
@@ -516,6 +516,24 @@ See https://github.com/opencv/opencv/issues/19260]]) |
4 |
endif() # ENABLE_OPENCV |
4 |
endif() # ENABLE_OPENCV |
5 |
add_feature_info("OpenCV algorithms" ENABLE_OPENCV "Use OpenCV algorithms") |
5 |
add_feature_info("OpenCV algorithms" ENABLE_OPENCV "Use OpenCV algorithms") |
6 |
|
6 |
|
7 |
+# EXECINFO |
7 |
+# EXECINFO |
8 |
+include(CheckFunctionExists) |
8 |
+include(CheckFunctionExists) |
9 |
+check_function_exists("backtrace" FUNCTION_BACKTRACE_FOUND) |
9 |
+include(CheckLibraryExists) |
|
|
10 |
+check_function_exists(backtrace FUNCTION_BACKTRACE_FOUND) |
10 |
+if(NOT FUNCTION_BACKTRACE_FOUND) |
11 |
+if(NOT FUNCTION_BACKTRACE_FOUND) |
11 |
+ find_library(EXECINFO_LIBRARY NAMES execinfo) |
12 |
+ find_library(EXECINFO_LIBRARY NAMES execinfo) |
12 |
+ if(NOT EXECINFO_LIBRARY) |
13 |
+ if(EXECINFO_LIBRARY) |
13 |
+ message(FATAL_ERROR "${EXECINFO_LIBRARY}") |
14 |
+ unset(FUNCTION_BACKTRACE_FOUND CACHE) |
14 |
+ endif(NOT EXECINFO_LIBRARY) |
15 |
+ check_library_exists(${EXECINFO_LIBRARY} backtrace "" FUNCTION_BACKTRACE_FOUND) |
15 |
+ target_link_libraries(openshot PRIVATE ${EXECINFO_LIBRARY}) |
16 |
+ endif(EXECINFO_LIBRARY) |
|
|
17 |
+endif(NOT FUNCTION_BACKTRACE_FOUND) |
18 |
+if(NOT FUNCTION_BACKTRACE_FOUND) |
19 |
+ message(FATAL_ERROR "backtrace - ${FUNCTION_BACKTRACE_FOUND}") |
16 |
+endif(NOT FUNCTION_BACKTRACE_FOUND) |
20 |
+endif(NOT FUNCTION_BACKTRACE_FOUND) |
17 |
+unset(FUNCTION_BACKTRACE_FOUND) |
21 |
+if(EXECINFO_LIBRARY) |
|
|
22 |
+ target_link_libraries(openshot PRIVATE ${EXECINFO_LIBRARY}) |
23 |
+endif(EXECINFO_LIBRARY) |
18 |
+ |
24 |
+ |
19 |
############### LINK LIBRARY ################# |
25 |
############### LINK LIBRARY ################# |
20 |
# Link remaining dependency libraries |
26 |
# Link remaining dependency libraries |