This is my CMakeLists.txt which is successfully building a shared library, I
just wanted to confirm if it's the right way and it:
cmake_minimum_required(VERSION 3.6)
project(main)
include_directories(
${CMAKE_CURRENT_SOURCE_DIR}/include
I built this C++ executable using CMake 3.10.2 in Ubuntu 18.04 and it was
built
successfully using the first approach. I'm now trying to build it using the
same CMakeLists.txt and
folder structure in Android Studio which is also using CMake 3.10.2, this
time a library not an executable, that being
I built this C++ library using CMake 3.10.2 in Ubuntu 18.04 and it was built
successfully. I'm trying to build it using the same CMakeLists.txt and
folder structure in Android Studio which is also using Cmake 3.10.2.
On running inspection results inside Android Studio, inside C++, declaration
*Approach 1:*
CMakeLists.txt:
cmake_minimum_required(VERSION 3.6)
project(main CXX C)
add_executable(main main.cpp)
target_include_directories(main PRIVATE
include build/deps/yara/src/yara/libyara/include)
target_link_libraries (main
-Lbuild/src/
This is the program I want to run, main.cpp:
#include
#include "yaracpp/yaracpp.h"
int main() {
yaracpp::YaraDetector yara;
yara.addRules(R"(
rule example {
strings:
$s = "Hello"
condition:
$s
})");
if