我需要为 Android 修改 Chromium。因为我很少或根本没有使用 Linux 的经验,所以我在编译它时遇到了困难,现在我被难住了。
我一直在按照这里的步骤操作:https ://code.google.com/p/chromium/wiki/AndroidBuildInstructions
这大致是我在全新 Ubuntu 13.04 (raring) 安装上执行的命令列表:
sudo apt-get install git-svn subversion g++ gtk+-2.0 gyp ant
# here I download depot_tools into the home dir
git clone https://chromium.googlesource.com/chromium/tools/depot_tools.git
export PATH="$PATH"\:`pwd`/depot_tools
# here I download the Chromium source code into ~/src
fetch android --nosvn=True
sudo ./src/build/install-build-deps.sh
gclient sync --nohooks
# download "jdk-6u38-linux-x64.bin" from the Oracle website, then
chmod 755 ~/Downloads/
sudo mkdir /usr/lib/jvm
cd /usr/lib/jvm && sudo /bin/sh ~/Downloads/jdk-6u38-linux-x64.bin -noregister
sudo update-alternatives --install /usr/bin/javac javac /usr/lib/jvm/jdk1.6.0_38/bin/javac 50000
sudo update-alternatives --install /usr/bin/java java /usr/lib/jvm/jdk1.6.0_38/bin/java 50000
sudo update-alternatives --install /usr/bin/javaws javaws /usr/lib/jvm/jdk1.6.0_38/bin/javaws 50000
sudo update-alternatives --install /usr/bin/javap javap /usr/lib/jvm/jdk1.6.0_38/bin/javap 50000
sudo update-alternatives --config javac
sudo update-alternatives --config java
sudo update-alternatives --config javaws
sudo update-alternatives --config javap
export JAVA_HOME=/usr/lib/jvm/jdk1.6.0_38
export PATH=$JAVA_HOME/bin\:"$PATH"
unset CC
unset CXX
cd ~/src
./build/android/envsetup.sh
# edit install-build-deps-android.sh
# replacing "ant1.8" with "ant" (a hack of mine)
sudo ./build/install-build-deps-android.sh
export GYP_DEFINES="target_arch=x64"
现在我缺少android_gyp并且在 ~/src 文件夹中的任何地方都找不到它。
这是它说我应该执行它的地方: http ://code.google.com/p/chromium/wiki/AndroidBuildInstructions#Compile
如果我尝试跳过该命令,它会说我没有“build.ninja”,所以是的......
有人可以帮我吗?我是新来的。谢谢