編輯:關於Android編程
LOCAL_PATH :=$(call my-dir) include $(CLEAR_VARS) LOCAL_MODULE_TAGS := optional #LOCAL_JAVA_LIBRARIES := ScannerAPI telephony-common telephony-msim LOCAL_STATIC_JAVA_LIBRARIES :=zxing android-support-v4 android-support-v13 LOCAL_SRC_FILES :=$(call all-java-files-under, src) LOCAL_PACKAGE_NAME := SetInput2 LOCAL_CERTIFICATE := platform #簽名為platform include $(BUILD_PACKAGE) include $(CLEAR_VARS) LOCAL_PREBUILT_STATIC_JAVA_LIBRARIES :=zxing:libs/zxing-1.6-core.jar include $(BUILD_MULTI_PREBUILT)
LOCAL_PATH:= $(call my-dir) include $(CLEAR_VARS) LOCAL_MODULE := busybox LOCAL_MODULE_TAGS := optional LOCAL_MODULE_CLASS := EXECUTABLES LOCAL_SRC_FILES := busybox LOCAL_MODULE_PATH := $(PRODUCT_OUT)/system/xbin include $(BUILD_PREBUILT)
LOCAL_PATH := $(call my-dir) include $(CLEAR_VARS) LOCAL_MODULE_TAGS := optional LOCAL_MODULE := rsota LOCAL_SRC_FILES := $(LOCAL_MODULE).apk LOCAL_MODULE_CLASS := APPS LOCAL_MODULE_PATH := $(PRODUCT_OUT)/system/app LOCAL_CERTIFICATE := platform LOCAL_MODULE_SUFFIX := .apk include $(BUILD_PREBUILT)
(apk,so和Android.mk在一個目錄下):
LOCAL_PATH := $(call my-dir) include $(CLEAR_VARS) LOCAL_MODULE_TAGS := optional eng LOCAL_MODULE := LiangdusIME LOCAL_SRC_FILES := $(LOCAL_MODULE).apk LOCAL_MODULE_CLASS := APPS LOCAL_MODULE_PATH := $(PRODUCT_OUT)/system/priv-app LOCAL_CERTIFICATE := platform LOCAL_MODULE_SUFFIX := .apk include $(BUILD_PREBUILT) include $(CLEAR_VARS) LOCAL_MODULE := libLDWWIme LOCAL_MODULE_CLASS := SHARED_LIBRARIES LOCAL_MODULE_SUFFIX := .so LOCAL_MULTILIB := 32 LOCAL_MODULE_TAGS := optional LOCAL_SRC_FILES := libLDWWIme.so LOCAL_MODULE_PATH := $(PRODUCT_OUT)/system/priv-app/LiangdusIME/lib/arm include $(BUILD_PREBUILT)
LOCAL_PATH := $(call my-dir) #====== so lab ===== include $(CLEAR_VARS) LOCAL_PREBUILT_LIBS := armeabi-v7a/libctp_jni.so LOCAL_MULTILIB := 32 LOCAL_MODULE_TAGS := optional include $(BUILD_MULTI_PREBUILT) include $(CLEAR_VARS) LOCAL_PREBUILT_LIBS := armeabi-v7a/libkeypad_jni.so LOCAL_MULTILIB := 32 LOCAL_MODULE_TAGS := optional include $(BUILD_MULTI_PREBUILT) include $(CLEAR_VARS) LOCAL_PREBUILT_LIBS := arm64-v8a/libctp_jni.so LOCAL_MULTILIB := 64 LOCAL_MODULE_TAGS := optional include $(BUILD_MULTI_PREBUILT) include $(CLEAR_VARS) LOCAL_PREBUILT_LIBS := arm64-v8a/libkeypad_jni.so LOCAL_MULTILIB := 64 LOCAL_MODULE_TAGS := optional include $(BUILD_MULTI_PREBUILT) # ==== app ======================== include $(CLEAR_VARS) LOCAL_MODULE_TAGS := optional LOCAL_MODULE := SeuicService LOCAL_MODULE_CLASS := APPS LOCAL_CERTIFICATE := PRESIGNED #預簽名過了,不需在簽名了 LOCAL_MODULE_PATH := $(TARGET_OUT)/app LOCAL_REQUIRED_MODULES := \ #本模塊加入系統,我需要的依賴模塊也必須加入 libkeypad_jni \ libctp_jni LOCAL_SRC_FILES := SeuicService.apk include $(BUILD_PREBUILT)其中LOCAL_REQUIRED_MODULES表示預置SeuicService這個模塊時,會先去執行依賴的模塊,就是內置so庫。這樣執行的結果是SeuicService.apk放到了android系統的system/app下,armeabi-v7a的2個so庫內置到了android系統的system/lib/下,arm64-v8a的2個so放到了system/lib64/下,apk不管運行在32還是64位虛擬機都能正常。 例子二的區別是so庫誰都能用,例子一的so庫只有自己能用。
LOCAL_PATH := $(call my-dir) # ==== app ======================== include $(CLEAR_VARS) LOCAL_MODULE_TAGS := optional LOCAL_MODULE := Chrome LOCAL_MODULE_CLASS := APPS LOCAL_CERTIFICATE := PRESIGNED LOCAL_MODULE_PATH := $(TARGET_OUT)/app LOCAL_POST_PROCESS_COMMAND := $(shell mkdir -p $(LOCAL_MODULE_PATH)/Chrome/lib/arm) LOCAL_POST_PROCESS_COMMAND := $(shell cp -r $(LOCAL_PATH)/lib/armeabi-v7a/* $(LOCAL_MODULE_PATH)/Chrome/lib/arm) LOCAL_SRC_FILES := Chrome.apk include $(BUILD_PREBUILT)
LOCAL_PATH:= $(call my-dir) include $(CLEAR_VARS) LOCAL_MODULE_TAGS := optional LOCAL_STATIC_JAVA_LIBRARIES := libbaidumapapi LOCAL_SRC_FILES := $(call all-subdir-java-files) LOCAL_PACKAGE_NAME := MyMaps include $(BUILD_PACKAGE) ################################################## include $(CLEAR_VARS) LOCAL_PREBUILT_STATIC_JAVA_LIBRARIES :=libbaidumapapi:libs/baidumapapi.jar LOCAL_PREBUILT_LIBS :=libBMapApiEngine_v1_3_1:libs/armeabi/libBMapApiEngine_v1_3_1.so LOCAL_MODULE_TAGS := optional include $(BUILD_MULTI_PREBUILT)
4)Android如何調用第三方SO庫
The APK file does not exist on disk.Error while Installing APK解決方案:Android Studio獲取SH
小米5尊享版和標准版有什麼區別?備受期待的小米手機5於2月24日發布,推出了三個版本,分別是標准版、高配版和尊享版,標准版和高配版僅在內存上有不同,而尊享版
一、問題描述 在開發中,當我們需要的有一張大圖片同時還需要一些小圖片時,我們只需要通過代碼對此圖片進行不同比例的縮放即可,這樣大大節約資源,減小了安裝包的尺寸 。除縮
在使用App的時候,首次登錄都需要用戶輸入密碼的,有些朋友為了安全起見密碼設置的比較長,導致很多次密碼都輸入錯誤,嚴重影響了用戶體驗效果。這一點移動開發者做好了准備工作,