Home | History | Annotate | Download | only in test
      1 /*
      2  * Copyright (C) 2018 The Android Open Source Project
      3  *
      4  * Licensed under the Apache License, Version 2.0 (the "License");
      5  * you may not use this file except in compliance with the License.
      6  * You may obtain a copy of the License at
      7  *
      8  *      http://www.apache.org/licenses/LICENSE-2.0
      9  *
     10  * Unless required by applicable law or agreed to in writing, software
     11  * distributed under the License is distributed on an "AS IS" BASIS,
     12  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
     13  * See the License for the specific language governing permissions and
     14  * limitations under the License.
     15  */
     16 
     17 cc_defaults {
     18     name: "test_libbinder_ndk_defaults",
     19     shared_libs: [
     20         "libbase",
     21     ],
     22     strip: {
     23         none: true,
     24     },
     25     cflags: [
     26         "-O0",
     27         "-g",
     28     ],
     29 }
     30 
     31 cc_library_static {
     32     name: "test_libbinder_ndk_library",
     33     defaults: ["test_libbinder_ndk_defaults"],
     34     export_include_dirs: ["include"],
     35     shared_libs: ["libbinder_ndk"],
     36     export_shared_lib_headers: ["libbinder_ndk"],
     37     srcs: ["iface.cpp"],
     38 }
     39 
     40 cc_defaults {
     41     name: "test_libbinder_ndk_test_defaults",
     42     defaults: ["test_libbinder_ndk_defaults"],
     43     shared_libs: [
     44         "libandroid_runtime_lazy",
     45         "libbase",
     46         "libbinder",
     47         "libutils",
     48     ],
     49     static_libs: [
     50         "libbinder_ndk",
     51         "test_libbinder_ndk_library",
     52     ],
     53 }
     54 
     55 // This test is a unit test of the low-level API that is presented here,
     56 // specifically the parts which are outside of the NDK. Actual users should
     57 // also instead use AIDL to generate these stubs. See android.binder.cts.
     58 cc_test {
     59     name: "libbinder_ndk_test_client",
     60     defaults: ["test_libbinder_ndk_test_defaults"],
     61     srcs: ["main_client.cpp"],
     62 }
     63 
     64 cc_test {
     65     name: "libbinder_ndk_test_server",
     66     defaults: ["test_libbinder_ndk_test_defaults"],
     67     srcs: ["main_server.cpp"],
     68     gtest: false,
     69 }
     70