开发者社区> 问答> 正文

基于源码开发如何引入support-v4??报错

大家好:

      下了一个图片浏览的源码,用到了android-support-v4,但在编译时报错:

make: *** No rule to make target `/home/wenm/android4.2.2/out/target/common/obj/JAVA_LIBRARIES/android-supprot-v4_intermediates/javalib.jar', needed by `/home/wenm/android4.2.2/out/target/common/obj/APPS/PhotoViewSample_intermediates/classes-full-debug.jar'.  Stop.
make: Leaving directory `/home/wenm/android4.2.2'
wenm@ubuntu :~/android4.2.2/experiment/PhotoView/sample$

android.mk如下:

LOCAL_PATH:= $(call my-dir)
include $(CLEAR_VARS)

# optional: for all version
#     user: only for user version
#      eng: only for eng version
LOCAL_MODULE_TAGS := optional

LOCAL_SRC_FILES := $(call all-java-files-under, src)

#LOCAL_PROGUARD_ENABLED := disabled
#LOCAL_JAVA_LIBRARIES := telephony-common
#LOCAL_STATIC_JAVA_LIBRARIES := \
#    com.android.phone.common \
#    com.android.vcard \
#    android-common \
#    guava \
#    android-support-v13 \
#    android-support-v4 \
#    android-ex-variablespeed \

#LOCAL_REQUIRED_MODULES := libvariablespeed

LOCAL_STATIC_JAVA_LIBRARIES := \
    android-common \
    android-supprot-v4 \
    libPhotoView \

LOCAL_PACKAGE_NAME := PhotoViewSample
LOCAL_CERTIFICATE := shared

#LOCAL_PROGUARD_FLAG_FILES := proguard.flags

include $(BUILD_PACKAGE)

# Use the folloing include to make our test apk.
include $(call all-makefiles-under,$(LOCAL_PATH))

##########################################
include $(CLEAR_VARS)
LOCAL_PREBUILT_STATIC_JAVA_LIBRARIES := libPhotoView:./libs/PhotoView.jar
include $(BUILD_MULTI_PREBUILT)
##########################################

/home/wenm/android4.2.2/out/target/common/obj/JAVA_LIBRARIES/android-supprot-v4_intermediates/javalib.jar'  文件和目录都存在,不知为何?请教高手解答,谢谢!


展开
收起
爱吃鱼的程序员 2020-06-14 20:19:32 460 0
1 条回答
写回答
取消 提交回答
  • https://developer.aliyun.com/profile/5yerqm5bn5yqg?spm=a2c6h.12873639.0.0.6eae304abcjaIB

    问题应该出现在你这个定法,前面后面空格的原因,我直接负责你的过去编译也是报相同的问题,但我重新写了一次就好了,

    LOCAL_STATIC_JAVA_LIBRARIES:=\
       android-common\
       android-supprot-v4\
       libPhotoView

    1. LOCAL_STATIC_JAVA_LIBRARIES  : = \  
    2.  android-support-v4 

    2020-06-14 20:19:49
    赞同 展开评论 打赏
问答分类:
问答地址:
问答排行榜
最热
最新

相关电子书

更多
React Native 全量化实践—web 技术打造移动研发新模式 立即下载
APP加固新方向 --混淆和瘦身 立即下载
APP加固新方向-混淆和瘦身 立即下载