Home | History | Annotate | Download | only in gui
      1 # Copyright 2010 The Android Open Source Project
      2 #
      3 # Licensed under the Apache License, Version 2.0 (the "License");
      4 # you may not use this file except in compliance with the License.
      5 # You may obtain a copy of the License at
      6 #
      7 #      http://www.apache.org/licenses/LICENSE-2.0
      8 #
      9 # Unless required by applicable law or agreed to in writing, software
     10 # distributed under the License is distributed on an "AS IS" BASIS,
     11 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     12 # See the License for the specific language governing permissions and
     13 # limitations under the License.
     14 
     15 LOCAL_PATH := $(call my-dir)
     16 include $(CLEAR_VARS)
     17 
     18 LOCAL_CLANG := true
     19 LOCAL_CPPFLAGS := -std=c++1y -Weverything -Werror
     20 
     21 # The static constructors and destructors in this library have not been noted to
     22 # introduce significant overheads
     23 LOCAL_CPPFLAGS += -Wno-exit-time-destructors
     24 LOCAL_CPPFLAGS += -Wno-global-constructors
     25 
     26 # We only care about compiling as C++14
     27 LOCAL_CPPFLAGS += -Wno-c++98-compat-pedantic
     28 
     29 # We don't need to enumerate every case in a switch as long as a default case
     30 # is present
     31 LOCAL_CPPFLAGS += -Wno-switch-enum
     32 
     33 # Allow calling variadic macros without a __VA_ARGS__ list
     34 LOCAL_CPPFLAGS += -Wno-gnu-zero-variadic-macro-arguments
     35 
     36 # Don't warn about struct padding
     37 LOCAL_CPPFLAGS += -Wno-padded
     38 
     39 LOCAL_CPPFLAGS += -DDEBUG_ONLY_CODE=$(if $(filter userdebug eng,$(TARGET_BUILD_VARIANT)),1,0)
     40 
     41 LOCAL_SRC_FILES := \
     42 	IGraphicBufferConsumer.cpp \
     43 	IConsumerListener.cpp \
     44 	BitTube.cpp \
     45 	BufferItem.cpp \
     46 	BufferItemConsumer.cpp \
     47 	BufferQueue.cpp \
     48 	BufferQueueConsumer.cpp \
     49 	BufferQueueCore.cpp \
     50 	BufferQueueProducer.cpp \
     51 	BufferSlot.cpp \
     52 	ConsumerBase.cpp \
     53 	CpuConsumer.cpp \
     54 	DisplayEventReceiver.cpp \
     55 	GLConsumer.cpp \
     56 	GraphicBufferAlloc.cpp \
     57 	GuiConfig.cpp \
     58 	IDisplayEventConnection.cpp \
     59 	IGraphicBufferAlloc.cpp \
     60 	IGraphicBufferProducer.cpp \
     61 	IProducerListener.cpp \
     62 	ISensorEventConnection.cpp \
     63 	ISensorServer.cpp \
     64 	ISurfaceComposer.cpp \
     65 	ISurfaceComposerClient.cpp \
     66 	LayerState.cpp \
     67 	OccupancyTracker.cpp \
     68 	Sensor.cpp \
     69 	SensorEventQueue.cpp \
     70 	SensorManager.cpp \
     71 	StreamSplitter.cpp \
     72 	Surface.cpp \
     73 	SurfaceControl.cpp \
     74 	SurfaceComposerClient.cpp \
     75 	SyncFeatures.cpp \
     76 
     77 LOCAL_SHARED_LIBRARIES := \
     78 	libbinder \
     79 	libcutils \
     80 	libEGL \
     81 	libGLESv2 \
     82 	libsync \
     83 	libui \
     84 	libutils \
     85 	liblog
     86 
     87 
     88 LOCAL_MODULE := libgui
     89 
     90 ifeq ($(TARGET_BOARD_PLATFORM), tegra)
     91 	LOCAL_CFLAGS += -DDONT_USE_FENCE_SYNC
     92 endif
     93 ifeq ($(TARGET_BOARD_PLATFORM), tegra3)
     94 	LOCAL_CFLAGS += -DDONT_USE_FENCE_SYNC
     95 endif
     96 
     97 include $(BUILD_SHARED_LIBRARY)
     98 
     99 ifeq (,$(ONE_SHOT_MAKEFILE))
    100 include $(call first-makefiles-under,$(LOCAL_PATH))
    101 endif
    102