1. 程式人生 > >mac os x 10.11.5編譯msm8916 android4.4.4

mac os x 10.11.5編譯msm8916 android4.4.4

1.大小寫敏感問題

 分割槽為大小寫敏感分割槽

hdiutil create -type SPARSE -fs 'Case-sensitive Journaled HFS+' -size 70g ~/android.dmg

hdiutil attach ~/android.dmg.sparseimage -mountpoint /Volumes/android

cd /Volumes/android

2.jdk1.6 從蘋果官網下載,oracle從jdk1.7才有os版。

http://download.csdn.net/detail/baimingyong007/9579631   

3.mac os x10.6 .因為xcdoe是最新版7.3.1 只有10.11sdk。

Can not find SDK 10.6 at /Developer/SDKs/MacOSX10.6.sdk

 最後下了xcode6.4,解決這個問題。


4.

system/core/include/log/log.h:38:20: error: stdarg.h: No such file or directory

這其實也是Xcode版本惹的禍!臥槽,Xcode咋這麼多屁事呢,早知道裝個低版本好了。解決方案怎麼也沒找到,最後不經意見讓我發現了。原來還是在build/core/combo/HOST_darwin-x86.mk裡面

ifeq ($(mac_sdk_version),10.8)
# Mac SDK 10.8 no longer has stdarg.h, etc
host_toolchain_header := $(HOST_TOOLCHAIN_ROOT)/lib/gcc/i686-apple-darwin$(gcc_darwin_version)/4.2.1/include
HOST_GLOBAL_CFLAGS += -isystem $(host_toolchain_header)
endif
else

看到了吧,他這裡只判斷了10.8。在10.8裡面就已經沒有stdarg.h了,那麼在我們的10.9和10.10裡面肯定也沒有了。但是卻沒有走進這個判斷。所以更改很簡單,就是把10.8改成10.9

5.

SyntaxError: Unable to find any JNI methods for org/chromium/ui/base/LocalizationUtils.

make: *** [out/target/product/M9PLUS/obj/GYP/shared_intermediates/ui/jni/LocalizationUtils_jni.h] Error 1

make: *** Waiting for unfinished jobs....

這個是由於xcode 版本問題。我下個、xcode5.1.1。

6.

vendor/qcom/opensource/kernel-tests/memory_prof/memory_prof.c:46:27: fatal error: linux/msm_ion.h: No such file or directory

adding the path to the kernel headers to common.mk (hardware/qcom/display/msm8226/common.mk in your case): common_includes += path_goes_here

7.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
scripts/kconfig/conf --silentoldconfig Kconfig
  CHK     include/linux/version.h
  CHK     include/generated/utsrelease.h
  UPD     include/generated/utsrelease.h
make[1]: `include/generated/mach-types.h' is up to date.
  CALL    scripts/checksyscalls.sh
  HOSTCC  scripts/mod/mk_elfconfig
scripts/mod/mk_elfconfig.c:4:10: fatal error: 'elf.h' file not found
#include <elf.h>
         ^
1 error generated.
make[2]: *** [scripts/mod/mk_elfconfig] Error 1
make[1]: *** [scripts/mod] Error 2
make: *** [scripts] Error 2

這個問題是由於os x的系統include路徑裡面少了一個elf.h這個檔案,到 http://www.rockbox.org/tracker/9006?getfile=16683 這個地方,把裡面的內容儲存成elf.h,放到核心原始碼的scripts/mod/下面即可。

順便看到了作者遇到的第二個與elf.h有關的問題,

elf.h之前是因為在系統include庫裡面,現在放到了scripts/mod下面,編譯.c檔案的時候定義elf.h的時候有問題,想必會c的人都知道#include 和#include “elf.h” 的區別吧。把scripts/mod下面的mk_elfconfig.c,modpost.h這兩個檔案,開頭前幾行的#include 改成#include “elf.h”。

8.

make[5]: *** [/Volumes/untitled/android/out/target/product/M9PLUS/obj/KERNEL_OBJ/usr/include/../../drivers/staging/android/linux/.install] Error 1

make[4]: *** [linux] Error 2

make[3]: *** [../../drivers/staging/android/uapi] Error 2

make[2]: *** [headers_install] Error 2

make[1]: *** [sub-make] Error 2

make: *** [out/target/product/M9PLUS/obj/KERNEL_OBJ/usr] Error 2

make: *** Waiting for unfinished jobs....