File linphone-fix-Archlinux-compilation.patch of Package linphone
--- liblinphone-5.3.1.orig/CMakeLists.txt
+++ liblinphone-5.3.1/CMakeLists.txt
@@ -78,6 +78,40 @@
cmake_dependent_option(ENABLE_GOCLEAR "Build with ZRTP GoClear message support (RFC 6189 - section 5.11)." YES "ENABLE_ZRTP" NO)
cmake_dependent_option(ENABLE_QRCODE "Enable QRCode support" YES "ENABLE_VIDEO" NO)
+##########################################################
+##
+## Archlinux fix for CMake
+## not being able to find all libraries
+##
+# Add functionality to print variables (useful for CMake debugging)
+include(CMakePrintHelpers)
+#
+# Determine where libraries usually end up...
+# /usr/lib64 on Fedora/openSUSE ... /usr/lib/x86_64-linux-gnu on Debian ... /usr/lib on Archlinux/Manjaro
+# It is needed when libraries are imported.
+# A typical linux library would be libc.so
+find_library(MY_LIBC_LIBRARY libc.so)
+cmake_print_variables(MY_LIBC_LIBRARY)
+# Get parent directory of libc.so
+cmake_path(GET MY_LIBC_LIBRARY PARENT_PATH MY_LINUX_USUAL_LIBRARY_DIR)
+cmake_print_variables(MY_LINUX_USUAL_LIBRARY_DIR)
+# Fix import libraries that CMake cannot find on its own
+add_library(jsoncpp_lib SHARED IMPORTED)
+set_property(TARGET jsoncpp_lib PROPERTY
+ IMPORTED_LOCATION "${MY_LINUX_USUAL_LIBRARY_DIR}/libjsoncpp.so")
+# IMPORTED_LOCATION "/usr/lib/libjsoncpp.so")
+add_library(bcg729 SHARED IMPORTED)
+set_property(TARGET bcg729 PROPERTY
+ IMPORTED_LOCATION "${MY_LINUX_USUAL_LIBRARY_DIR}/libbcg729.so")
+# IMPORTED_LOCATION "/usr/lib/libbcg729.so")
+add_library(bcmatroska2 SHARED IMPORTED)
+set_property(TARGET bcmatroska2 PROPERTY
+ IMPORTED_LOCATION "${MY_LINUX_USUAL_LIBRARY_DIR}/libbcmatroska2.so")
+# IMPORTED_LOCATION "/usr/lib/libbcmatroska2.so")
+##
+## End modification
+##
+###########################################################
set(CMAKE_CXX_STANDARD 17)
set(CMAKE_CXX_EXTENSIONS NO)