Home | History | Annotate | Download | only in ns
      1 # Copyright (c) 2011 The WebRTC project authors. All Rights Reserved.
      2 #
      3 # Use of this source code is governed by a BSD-style license
      4 # that can be found in the LICENSE file in the root of the source
      5 # tree. An additional intellectual property rights grant can be found
      6 # in the file PATENTS.  All contributing project authors may
      7 # be found in the AUTHORS file in the root of the source tree.
      8 
      9 #############################
     10 # Build the non-neon library.
     11 LOCAL_PATH := $(call my-dir)
     12 
     13 include $(CLEAR_VARS)
     14 
     15 include $(LOCAL_PATH)/../../../../android-webrtc.mk
     16 
     17 LOCAL_MODULE_CLASS := STATIC_LIBRARIES
     18 LOCAL_MODULE := libwebrtc_ns
     19 LOCAL_MODULE_TAGS := optional
     20 LOCAL_GENERATED_SOURCES :=
     21 LOCAL_SRC_FILES := \
     22     noise_suppression_x.c \
     23     nsx_core.c
     24 
     25 # Files for floating point.
     26 # noise_suppression.c ns_core.c
     27 
     28 # Flags passed to both C and C++ files.
     29 LOCAL_CFLAGS := $(MY_WEBRTC_COMMON_DEFS)
     30 
     31 LOCAL_C_INCLUDES := \
     32     $(LOCAL_PATH)/interface \
     33     $(LOCAL_PATH)/../utility \
     34     $(LOCAL_PATH)/../../.. \
     35     $(LOCAL_PATH)/../../../common_audio/signal_processing/include \
     36     $(LOCAL_PATH)/../../../system_wrappers/interface
     37 
     38 LOCAL_STATIC_LIBRARIES += libwebrtc_system_wrappers
     39 
     40 LOCAL_SHARED_LIBRARIES := \
     41     libcutils \
     42     libdl
     43 
     44 ifndef NDK_ROOT
     45 ifndef WEBRTC_STL
     46 LOCAL_SHARED_LIBRARIES += libstlport
     47 include external/stlport/libstlport.mk
     48 else
     49 LOCAL_NDK_STL_VARIANT := $(WEBRTC_STL)
     50 LOCAL_SDK_VERSION := 14
     51 LOCAL_MODULE := $(LOCAL_MODULE)_$(WEBRTC_STL)
     52 endif
     53 else
     54 LOCAL_SHARED_LIBRARIES += libstlport
     55 endif
     56 
     57 include $(BUILD_STATIC_LIBRARY)
     58 
     59 #############################
     60 # Build the neon library.
     61 ifeq ($(WEBRTC_BUILD_NEON_LIBS),true)
     62 
     63 include $(CLEAR_VARS)
     64 
     65 LOCAL_ARM_MODE := arm
     66 LOCAL_MODULE_CLASS := STATIC_LIBRARIES
     67 LOCAL_MODULE := libwebrtc_ns_neon
     68 LOCAL_MODULE_TAGS := optional
     69 
     70 LOCAL_SRC_FILES := nsx_core_neon.c
     71 
     72 # Flags passed to both C and C++ files.
     73 LOCAL_CFLAGS := \
     74     $(MY_WEBRTC_COMMON_DEFS) \
     75     -mfpu=neon \
     76     -mfloat-abi=softfp \
     77     -flax-vector-conversions
     78 
     79 LOCAL_C_INCLUDES := \
     80     $(LOCAL_PATH)/interface \
     81     $(LOCAL_PATH)/../../.. \
     82     $(LOCAL_PATH)/../../../common_audio/signal_processing/include
     83 
     84 ifndef NDK_ROOT
     85 ifndef WEBRTC_STL
     86 LOCAL_SHARED_LIBRARIES += libstlport
     87 include external/stlport/libstlport.mk
     88 else
     89 LOCAL_NDK_STL_VARIANT := $(WEBRTC_STL)
     90 LOCAL_SDK_VERSION := 14
     91 LOCAL_MODULE := $(LOCAL_MODULE)_$(WEBRTC_STL)
     92 endif
     93 else
     94 LOCAL_SHARED_LIBRARIES += libstlport
     95 endif
     96 
     97 include $(BUILD_STATIC_LIBRARY)
     98 endif # ifeq ($(WEBRTC_BUILD_NEON_LIBS),true)
     99