Stephen Kiazyk | e77dce2 | 2017-03-14 15:38:12 -0700 | [diff] [blame] | 1 | // Copyright (C) 2015 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 | sourceFiles = [ |
| 16 | "native_buffer_queue.cpp", |
| 17 | "display_client.cpp", |
Stephen Kiazyk | e77dce2 | 2017-03-14 15:38:12 -0700 | [diff] [blame] | 18 | "display_manager_client_impl.cpp", |
| 19 | "display_rpc.cpp", |
| 20 | "dummy_native_window.cpp", |
| 21 | "gl_fenced_flush.cpp", |
| 22 | "graphics.cpp", |
| 23 | "late_latch.cpp", |
| 24 | "video_mesh_surface_client.cpp", |
| 25 | "vsync_client.cpp", |
Stephen Kiazyk | e77dce2 | 2017-03-14 15:38:12 -0700 | [diff] [blame] | 26 | "screenshot_client.cpp", |
| 27 | "frame_history.cpp", |
| 28 | ] |
| 29 | |
| 30 | localIncludeFiles = [ |
| 31 | "include", |
| 32 | ] |
| 33 | |
| 34 | sharedLibraries = [ |
| 35 | "libbase", |
| 36 | "libcutils", |
| 37 | "liblog", |
| 38 | "libutils", |
| 39 | "libEGL", |
| 40 | "libGLESv2", |
| 41 | "libvulkan", |
| 42 | "libui", |
| 43 | "libgui", |
| 44 | "libhardware", |
| 45 | "libsync", |
| 46 | "libnativewindow", |
| 47 | ] |
| 48 | |
| 49 | staticLibraries = [ |
| 50 | "libbufferhub", |
| 51 | "libbufferhubqueue", |
| 52 | "libdvrcommon", |
| 53 | "libdvrgraphics", |
| 54 | "libvrsensor", |
| 55 | "libpdx_default_transport", |
| 56 | ] |
| 57 | |
| 58 | headerLibraries = [ |
| 59 | "vulkan_headers", |
| 60 | ] |
| 61 | |
| 62 | cc_library { |
| 63 | tags: ["tests"], |
| 64 | srcs: sourceFiles, |
| 65 | cflags: ["-DLOG_TAG=\"libdisplay\"", |
| 66 | "-DTRACE=0", |
| 67 | "-DATRACE_TAG=ATRACE_TAG_GRAPHICS", |
| 68 | "-DGL_GLEXT_PROTOTYPES", |
| 69 | "-DEGL_EGLEXT_PROTOTYPES", |
| 70 | ], // + [ "-UNDEBUG", "-DDEBUG", "-O0", "-g" ], |
| 71 | export_include_dirs: localIncludeFiles, |
| 72 | shared_libs: sharedLibraries, |
| 73 | static_libs: staticLibraries, |
| 74 | header_libs: headerLibraries, |
| 75 | export_header_lib_headers: headerLibraries, |
| 76 | |
| 77 | name: "libdisplay", |
| 78 | } |
| 79 | |
| 80 | graphicsAppTestFiles = ["tests/graphics_app_tests.cpp"] |
| 81 | |
| 82 | cc_test { |
| 83 | name: "graphics_app_tests", |
| 84 | tags: ["optional"], |
| 85 | |
| 86 | srcs: graphicsAppTestFiles, |
| 87 | |
| 88 | shared_libs: sharedLibraries, |
| 89 | |
| 90 | static_libs: ["libdisplay"] + staticLibraries, |
| 91 | } |
| 92 | |
| 93 | dummyNativeWindowTestFiles = ["tests/dummy_native_window_tests.cpp"] |
| 94 | |
| 95 | cc_test { |
| 96 | name: "dummy_native_window_tests", |
| 97 | tags: [ "optional" ], |
| 98 | srcs: dummyNativeWindowTestFiles, |
| 99 | shared_libs: sharedLibraries, |
| 100 | static_libs: [ "libdisplay" ] + staticLibraries, |
| 101 | } |
| 102 | |