Failures during Chromium build on Ubuntu - android

I am trying to build unmodified Chromium following official instructions, but i am getting the following error, I tried reinstalling Ubuntu 8, 12 but no difference:
[10/6591] ACTION Creating jsr_305_javalib jar
FAILED: cd ../../third_party/jsr-305; python ../../build/android/jar.py "--classes-dir=../../out/Release/gen/jsr_305_javalib/classes" "--jar-path=../../out/Release/lib.java/jsr_305_javalib.jar" "--excluded-classes=\"*/R.class\" \"*/R##*.class\"" "--ignore=035ff3d8153c7ebb3e17803d6ec654de -"
Traceback (most recent call last):
File "../../build/android/jar.py", line 53, in <module>
sys.exit(main(sys.argv))
File "../../build/android/jar.py", line 46, in main
DoJar(options)
File "../../build/android/jar.py", line 30, in DoJar
subprocess.check_call(jar_cmd, cwd=jar_cwd)
File "/usr/lib/python2.7/subprocess.py", line 506, in check_call
retcode = call(*popenargs, **kwargs)
File "/usr/lib/python2.7/subprocess.py", line 493, in call
return Popen(*popenargs, **kwargs).wait()
File "/usr/lib/python2.7/subprocess.py", line 679, in __init__
errread, errwrite)
File "/usr/lib/python2.7/subprocess.py", line 1249, in _execute_child
raise child_exception
OSError: [Errno 2] No such file or directory

I'd stopped at same error. Finally, I found my stupid mistake that I forgot to add PATH of jar command. The following command is needed in addition to the java set up guide in Chromium official build instructions.
sudo update-alternatives --install /usr/bin/jar jar /usr/lib/jvm/jdk1.6.0_xx/bin/jar 50000

You must install the depot_tools package. Try this commands;
git clone https://chromium.googlesource.com/chromium/tools/depot_tools.git
export PATH=$PATH:/path/to/depot_tools

Related

infer -- gradle build is not working

I'm trying to use the Infer tool to analyze my app code. I followed these steps and every time I'm trying to run infer -- gradle build I'm getting the below errors :
infer -- gradle build
Running and capturing gradle compilation...
Traceback (most recent call last):
File "/usr/local/bin/infer", line 183, in <module>
main()
File "/usr/local/bin/infer", line 147, in main
capture_exitcode = imported_module.gen_instance(args,cmd).capture()
File "/usr/local/Cellar/infer/0.8.1/libexec/infer/lib/python/inferlib/capture/gradle.py", line 87, in capture
cmds = self.get_infer_commands(util.get_build_output(self.build_cmd))
File "/usr/local/Cellar/infer/0.8.1/libexec/infer/lib/python/inferlib/capture/util.py", line 25, in get_build_output
proc = subprocess.Popen(build_cmd, stdout=subprocess.PIPE)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/subprocess.py", line 710, in __init__
errread, errwrite)
File "/System/Library/Frameworks/Python.framework/Versions/2.7/lib/python2.7/subprocess.py", line 1335, in _execute_child
raise child_exception
OSError: [Errno 2] No such file or directory
Any idea would be appreciated !!
I found that Infer is already included in the new android studio 2.2 where you can run it directly from Analyze->Infer Nullity then specify the scope.

Error on Chromium ARC Compilation when configure

Getting errors as below, when I follow step 4 of the instruction from Getting Started with ARC Open Source on Linux. OS is Ubuntu 14.04 LTS running in Hyper-V.
UBUNTU14:~/arc$ ./configure
ERROR:root:While running
['third_party/tools/depot_tools/third_party/gsutil/gsutil', 'cp',
'gs://arc-build/naclports/builds/pepper_40/python.zip',
'/tmp/tmpUZ0IoK/naclports-python'] ERROR:root:GSResponseError:
status=403, code=None, reason=Forbidden.
ERROR:root:Try prodaccess, and if it does not solve the problem try rm
~/.devstore_token ###STEP_WARNINGS### ERROR:root:Retrying after 9 s
sleeping Traceback (most recent call last): File
"/home/fkiller/arc/src/build/build_common.py", line 938, in wrapper
return func(*args, **kwargs) File "/home/fkiller/arc/src/build/util/download_package_util.py", line 243,
in _download_package_with_retries
self._download_method(url, download_package_path) File "/home/fkiller/arc/src/build/util/download_package_util.py", line 119,
in _download
build_common.get_gsutil_executable(), 'cp', url, destination_path]) File
"/home/fkiller/arc/src/build/util/download_package_util.py", line 97,
in execute_subprocess
output = subprocess.check_output(cmd, cwd=cwd, stderr=subprocess.STDOUT) File "/usr/lib/python2.7/subprocess.py",
line 573, in check_output
raise CalledProcessError(retcode, cmd, output=output) CalledProcessError: Command
'['third_party/tools/depot_tools/third_party/gsutil/gsutil', 'cp',
'gs://arc-build/naclports/builds/pepper_40/python.zip',
'/tmp/tmpUZ0IoK/naclports-python']' returned non-zero exit status 1
Any idea to resolve this without changing build script? I may manually pointing python.zip from other sources such as https://naclports.storage.googleapis.com/builds/pepper_40/trunk-147-g49eb4c9/publish/python/pnacl/python.zip, but I want to build it as is without changing scripts.
I've already tried to setup gsutil and its authenticator, but it didn't fix the issue.
EDIT: After #elijah-taylor fixed ACL, now I'm getting errors below
Traceback (most recent call last): File "src/build/configure.py",
line 365, in
sys.exit(main()) File "src/build/configure.py", line 347, in main
_gclient_sync_third_party() File "src/build/configure.py", line 132, in _gclient_sync_third_party
subprocess.check_output(cmd, cwd=os.path.dirname(gclient_filename)) File
"/usr/lib/python2.7/subprocess.py", line 566, in check_output
process = Popen(stdout=PIPE, *popenargs, **kwargs) 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
In the line 132,
File "src/build/configure.py", line 132, in _gclient_sync_third_party
subprocess.check_output(cmd, cwd=os.path.dirname(gclient_filename))
gclient_filename is "third_party/.gclient" and os.path.dirname(gclient_filename) is "thrid_party".
The problem was bad ACLs on the files. I reached out to #elijah-taylor for a fix, it should now work!
faced same issue..fixed after running the following.
apt-get install gsutil
apt-get install libwww-perl
chmod +x ./third_party/tools/depot_tools/third_party/gsutil/gsutil

Not able to build caffe in android

I'm trying to create an android app that can identify the object in the image and gives its name as result. I know caffe-library can be used for this but getting error when i run ./build.py .
command :
user_name#sysetm_name:~/caffe-android-lib$ ./build.py /bin/android-ndk-r10d/ndk-build
Error :
Traceback (most recent call last):
File "./build.py", line 102, in <module>
main(sys.argv[1:])
File "./build.py", line 94, in main
setup()
File "./build.py", line 24, in setup
call(['curl', '-O', PROTOBUF_URL])
File "/usr/lib/python2.7/subprocess.py", line 522, in call
return Popen(*popenargs, **kwargs).wait()
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 sure that the clone is recursive to include the dependencies:
*** caffe-android-lib Dependency:
Boost-for-Android
protobuf
Eigen
E.g.:
git clone --recursive https://github.com/sh1r0/caffe-android-lib.git
cd caffe-android-lib
./build.py $(NDK_PATH)
Or have you tried to install the dependencies (especially protobuf) from source?
Given the dependencies are correctly installed, then you will have a successful caffe-android build:
E.g.:
https://gist.github.com/melvincabatuan/6b5e37444b77326ae7b3
...updated 10980 targets...
Done!
...
[armeabi-v7a] Install : libcaffe_jni.so => libs/armeabi-v7a/libcaffe_jni.so

Downloading Android source code

I am new to Android. I wanted take a look at the Andriod source and started the download process. I am having a problem in initialising the repo. I am getting a below error:
$ repo init -u https://android.googlesource.com/platform/manifest
Traceback (most recent call last):
File "/bin/repo", line 685, in <module>
main(sys.argv[1:])
File "/bin/repo", line 652, in main
_Init(args)
File "/bin/repo", line 184, in _Init
_CheckGitVersion()
File "/bin/repo", line 209, in _CheckGitVersion
proc = subprocess.Popen(cmd, stdout=subprocess.PIPE)
File "/usr/lib/python2.6/subprocess.py", line 633, in __init__
errread, errwrite)
File "/usr/lib/python2.6/subprocess.py", line 1139, in _execute_child
raise child_exception
OSError: [Errno 2] No such file or directory
You need to install git. The typical command would be :
$ sudo apt-get install git-core

Problem while initializing the repo

While initializing the repo to download Android Source Code using the following command -
repo init -u git://android.git.kernel.org/platform/manifest.git
I'm getting the following error -
Traceback (most recent call last):
File "/home/pritamn/bin/repo", line 603, in <module>
main(sys.argv[1:])
File "/home/pritamn/bin/repo", line 570, in main
_Init(args)
File "/home/pritamn/bin/repo", line 184, in _Init
_CheckGitVersion()
File "/home/pritamn/bin/repo", line 213, in _CheckGitVersion
proc = subprocess.Popen(cmd, stdout=subprocess.PIPE)
File "/usr/lib/python2.7/subprocess.py", line 672, in __init__
errread, errwrite)
File "/usr/lib/python2.7/subprocess.py", line 1201, in _execute_child
raise child_exception
Can anybody please help me in pin-pointing the exact cause of this error?
You must have git installed for that command to work
Do you have git installed? Make sure it's installed by typing "git" on the command line.
Running on Win7 64bit I had to add "C:\Program Files (x86)\Git\bin" to my PATH in order for this to work.
I had this happen to me, you need to apt-get remove git-core and re-install it using apt-get install git-core.

Categories

Resources