8

I know this question has been asked before many times but none of the solution is working for me.

Whenever I am trying to run my project I am getting this error:

Error:Execution failed for task ':gpuimage:compileReleaseNdk'. com.android.ide.common.process.ProcessException: Error while executing process F:\Android\sdk\ndk-bundle\ndk-build.cmd with arguments {NDK_PROJECT_PATH=null APP_BUILD_SCRIPT=F:\Studio_Workspace\klubchat-android\gpuimage\build\intermediates\ndk\release\Android.mk APP_PLATFORM=android-25 NDK_OUT=F:\Studio_Workspace\klubchat-android\gpuimage\build\intermediates\ndk\release\obj NDK_LIBS_OUT=F:\Studio_Workspace\klubchat-android\gpuimage\build\intermediates\ndk\release\lib APP_STL=gnustl_shared APP_ABI=all}

Please let me know how can I resolve this issue. I am stuck because of this.

Thanks in Advance!

marc_s
  • 732,580
  • 175
  • 1,330
  • 1,459
Arpit
  • 604
  • 5
  • 17
  • You still use the old deprecated NDK approach in Android Studio. I believe it's time to switch to the new version, see https://developer.android.com/studio/projects/add-native-code.html#ndkCompile – Alex Cohn Sep 25 '17 at 08:06
  • Thanks for the answer. I tried with the new version but was not able to generate the files that would be required...like CMakeList.txt. Please let me know how to use it. – Arpit Sep 26 '17 at 10:55
  • The link above shows how you copy the auto-generated **Android.mk** to your project. This may be easier than switching to **cmake**. – Alex Cohn Sep 26 '17 at 10:57
  • I am not able to find the auto-generated Android.mk file. I have an external library(gpuimage) that i want to use. But not able to use it. – Arpit Sep 28 '17 at 04:56
  • If you don't have cpp files of your own, you don't need NDK. It's enough to put the prebuilt library in **jniLibs** directory of your project, see instructions [here](https://stackoverflow.com/a/29234765/192373). – Alex Cohn Sep 28 '17 at 08:26
  • @AlexCohn : Thanks for the help. Yes I do not have any .cpp file. I have added the "gpuimage" external library as a module. I will check how can I add .so files and will revert you back.. – Arpit Sep 28 '17 at 10:05
  • @Arpit any progress on this? – feanor07 Dec 06 '17 at 08:18
  • 1
    @alptugd I have used an older version of NDK and by that my issue is resolved. – Arpit Dec 06 '17 at 08:52
  • @Arpit can you tell us which version? – Moustafa EL-Saghier Aug 30 '18 at 11:11
  • @MoustafEL-Saghier downgrade from NDK 18 to NDK 17 fixed it for me – mbonness Dec 20 '18 at 01:34
  • @ thanks I'll look in it – Moustafa EL-Saghier Feb 22 '19 at 15:33

0 Answers0