# Setting up OpenCV in Android - NDK error

Łukasz 07/30/2017. 0 answers, 35 views

I am trying to setup OpenCV in my Android Project. I was following the tutorial on the youtube https://www.youtube.com/watch?v=JIHfqzTdOcQ. The only thing I have done differently was setting compileSdkVersion, buildToolsVersion and targetSdkVersion to 25 (and '25.0.0') in gradle.build because every time i have tried to set something else there Android Studio was replacing it for me with "correct" values. After finishing it I've encounter an error. It looks like this: Error

sourceSets.main {
jniLibs.srcDir 'src/main/libs'
jni.srcDirs = [] //disable automatic ndk-build call

}

but it didn't help. What am I doing wrong?