Commit cb9a58f2 authored by Vignesh Venkatasubramanian's avatar Vignesh Venkatasubramanian Committed by Commit Bot

Android.mk: Add a flag to disable libjpeg

Do not build jpeg related files if LIBYUV_DISABLE_JPEG  is set to
"yes".

BUG=libyuv:693

Change-Id: If1bc4602fb843ca7b2964844b53553aa0cca551c
Reviewed-on: https://chromium-review.googlesource.com/455475Reviewed-by: 's avatarFrank Barchard <fbarchard@google.com>
Commit-Queue: Vignesh Venkatasubramanian <vigneshv@google.com>
parent 2adb84e3
......@@ -15,12 +15,9 @@ LOCAL_SRC_FILES := \
source/convert_argb.cc \
source/convert_from.cc \
source/convert_from_argb.cc \
source/convert_jpeg.cc \
source/convert_to_argb.cc \
source/convert_to_i420.cc \
source/cpu_id.cc \
source/mjpeg_decoder.cc \
source/mjpeg_validate.cc \
source/planar_functions.cc \
source/rotate.cc \
source/rotate_any.cc \
......@@ -49,9 +46,17 @@ LOCAL_SRC_FILES := \
source/scale_neon64.cc \
source/video_common.cc
common_CFLAGS := -Wall -fexceptions -DHAVE_JPEG
LOCAL_CFLAGS += $(common_CFLAGS)
common_CFLAGS := -Wall -fexceptions
ifneq ($(LIBYUV_DISABLE_JPEG), "yes")
LOCAL_SRC_FILES += \
source/convert_jpeg.cc \
source/mjpeg_decoder.cc \
source/mjpeg_validate.cc
common_CFLAGS += -DHAVE_JPEG
LOCAL_SHARED_LIBRARIES := libjpeg
endif
LOCAL_CFLAGS += $(common_CFLAGS)
LOCAL_EXPORT_C_INCLUDES := $(LOCAL_PATH)/include
LOCAL_C_INCLUDES += $(LOCAL_PATH)/include
LOCAL_EXPORT_C_INCLUDE_DIRS := $(LOCAL_PATH)/include
......@@ -65,6 +70,8 @@ include $(CLEAR_VARS)
LOCAL_WHOLE_STATIC_LIBRARIES := libyuv_static
LOCAL_MODULE := libyuv
ifneq ($(LIBYUV_DISABLE_JPEG), "yes")
LOCAL_SHARED_LIBRARIES := libjpeg
endif
include $(BUILD_SHARED_LIBRARY)
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment