0

I get an error when building Android from source which I have not tinkered with and it should really by all means work (I'm quite certain I've got all the libs installed, Java and Python in the correct version). Error messages go as follows:

> Traceback (most recent call last):
  File "../../base/android/jni_generator/jni_generator.py", line 1065, in <module>
    sys.exit(main(sys.argv))
  File "../../base/android/jni_generator/jni_generator.py", line 1061, in main
    options.optimize_generation)
  File "../../base/android/jni_generator/jni_generator.py", line 996, in GenerateJNIHeader
    jni_from_javap = JNIFromJavaP.CreateFromClass(input_file, namespace)
  File "../../base/android/jni_generator/jni_generator.py", line 507, in CreateFromClass
    stderr=subprocess.PIPE)
  File "/usr/lib/python2.7/subprocess.py", line 710, in __init__
    errread, errwrite)
  File "/usr/lib/python2.7/subprocess.py", line 1327, in _execute_child
    raise child_exception
OSError: [Errno 2] No such file or directory
make: *** [out/target/product/rk3066/obj/GYP/shared_intermediates/ui/gl/jni/Surface_jni.h] Error 1
make: *** Waiting for unfinished jobs....

I'm not really a specialist, so maybe the information I have provided is not complete. In this case - let me know.

4
  • On what OS are you trying to do this, are you using an IDE, and what commands did you type? Commented Sep 6, 2015 at 13:57
  • ============================================ PLATFORM_VERSION_CODENAME=REL PLATFORM_VERSION=4.4.2 TARGET_PRODUCT=rk3066 TARGET_BUILD_VARIANT=eng TARGET_BUILD_TYPE=release TARGET_BUILD_APPS= TARGET_ARCH=arm TARGET_ARCH_VARIANT=armv7-a-neon TARGET_CPU_VARIANT=cortex-a9 HOST_ARCH=x86 HOST_OS=linux HOST_OS_EXTRA=Linux-3.13.0-37-generic-x86_64-with-LinuxMint-17.1-rebecca HOST_BUILD_TYPE=release BUILD_ID=KOT49H OUT_DIR=out ============================================ Command used: $ make -j4 I'm not using an IDE, building in a terminal emulator. Commented Sep 6, 2015 at 14:00
  • @KrzysiekSetlak Did you solved your problem? Commented Sep 29, 2015 at 5:04
  • Nope, laid it off until later as I can't think of any solution, I don't know what is wrong at all :( Commented Sep 29, 2015 at 9:25

1 Answer 1

2

At line 507 in file external/chromium_org/base/android/jni_generator/jni_generator.py

   p = subprocess.Popen(args=['javap', class_name], 
                     cwd=os.path.dirname(class_file), 
                     stdout=subprocess.PIPE, 
                     stderr=subprocess.PIPE) 

It seems you don't have javap available in your PATH

If you have installed the jdk1.6.0_45 in usr/lib/jvm, then you can run this command

  sudo update-alternatives --install /usr/bin/javap javap /usr/lib/jvm/jdk1.6.0_45/bin/javap 1
Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.