android 編譯錯誤匯總

來源:互聯網
上載者:User

1.錯誤:目的編譯stk.apk進system.img..

解決: 在PRODUCT_PACKAGES := stk後,編譯後發現 system.img 沒有stk.apk。後細心比較後發現編譯系統是區分大小寫,改stk--->Stk後編譯進去了。 ----2011.12.14

 

2.錯誤:目的編譯gralloc.msm7k.so。

解決:但加裝位置不對,以致沒有編譯進system.img..PRODUCT_PACKAGES := gralloc.msm7k原本放在BoardConfig.mk,沒有成功。改放在mmk.mk中後成功了(產品名為mmk).--------2011.12.14


3.錯誤:目的能夠編譯msm7625..

錯誤提示:

build/core/base_rules.mk:74: *** Module name: msm7k...build/core/base_rules.mk:75: *** Makefile location:              .              .              .build/core/base_rules.mk:98: *** user tag detected on new module - user tagsare only supported on legacy modules.  Stop.

解決:原碼中缺少對armv6j支援。主要是build/core/combo/arch/arm --少了armv6j.mk;dalvik/vm下也有幾個與armv6j相關的檔案缺失。從其它原碼copy過來,重新編譯就可以解決

4. 遇到錯誤:

build/core/base_rules.mk:78: *** Module name: jsilver
build/core/base_rules.mk:79: *** Makefile location: external/jsilver
build/core/base_rules.mk:80: *
build/core/base_rules.mk:81: * Each module must use a LOCAL_MODULE_TAGS in its
build/core/base_rules.mk:82: * Android.mk. Possible tags declared by a module:
build/core/base_rules.mk:83: *
build/core/base_rules.mk:84: *     optional, debug, eng, tests, samples
build/core/base_rules.mk:85: *
build/core/base_rules.mk:86: * If the module is expected to be in all builds
build/core/base_rules.mk:87: * of a product, then it should use the
build/core/base_rules.mk:88: * "optional" tag:
build/core/base_rules.mk:89: *
build/core/base_rules.mk:90: *    Add "LOCAL_MODULE_TAGS := optional" in the
build/core/base_rules.mk:91: *    Android.mk for the affected module, and add
build/core/base_rules.mk:92: *    the LOCAL_MODULE value for that component
build/core/base_rules.mk:93: *    into the PRODUCT_PACKAGES section of product
build/core/base_rules.mk:94: *    makefile(s) where it's necessary, if
build/core/base_rules.mk:95: *    appropriate.
build/core/base_rules.mk:96: *
build/core/base_rules.mk:97: * If the component should be in EVERY build of ALL
build/core/base_rules.mk:98: * products, then add its LOCAL_MODULE value to the
build/core/base_rules.mk:99: * PRODUCT_PACKAGES section of
build/core/base_rules.mk:100: * build/target/product/core.mk
build/core/base_rules.mk:101: *
build/core/base_rules.mk:102: *** user tag detected on new module - user tags are only supported on legacy modules.  Stop.

This is due to the declaration of LOCAL_MODULE_TAGS. To fix it just follow the instructions that suggest including the optional tag. Thanks to [10] for the command line that replace user tag by optional tag on every affected file.

用這個命令列將所有user改成optional即可:

find ./ -exec grep -l "LOCAL_MODULE_TAGS := user" {} \; -exec sed -i.bak s/"LOCAL_MODULE_TAGS := user"/"LOCAL_MODULE_TAGS := optional"/g {} \;

             

相關文章

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.