1// 2// Copyright (C) 2016 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// Include the generated rules 18build = ["gen.bp"] 19 20genrule { 21 name: "ltp_syscalls_h", 22 tool_files: ["include/lapi/syscalls/regen.sh"], 23 cmd: "$(location) $(genDir)/lapi/syscalls.h", 24 srcs: ["include/lapi/syscalls/*.in"], 25 out: ["lapi/syscalls.h"], 26} 27 28cc_defaults { 29 name: "ltp_defaults", 30 31 cflags: [ 32 // Hacks for bionic compatibility 33 "-include bionic-compat.h", 34 35 "-Wall", 36 "-Werror", 37 // Keep some warnings to check later 38 "-Wno-error=absolute-value", 39 "-Wno-error=undefined-internal", 40 "-Wno-error=uninitialized", 41 "-Wno-error=user-defined-warnings", 42 // Silence noisy warnings 43 "-Wno-constant-conversion", 44 "-Wno-deprecated", 45 "-Wno-duplicate-decl-specifier", 46 "-Wno-empty-body", 47 "-Wno-format", 48 "-Wno-gnu-designator", 49 "-Wno-implicit-function-declaration", 50 "-Wno-incompatible-pointer-types-discards-qualifiers", 51 "-Wno-knr-promoted-parameter", 52 "-Wno-macro-redefined", 53 "-Wno-missing-braces", 54 "-Wno-missing-field-initializers", 55 "-Wno-parentheses-equality", 56 "-Wno-pointer-arith", 57 "-Wno-pointer-sign", 58 "-Wno-sign-compare", 59 "-Wno-tautological-compare", 60 "-Wno-unneeded-internal-declaration", 61 "-Wno-unused-function", 62 "-Wno-unused-parameter", 63 "-Wno-unused-variable", 64 ], 65 66 local_include_dirs: [ 67 "android/include", 68 "include", 69 ], 70 71 target: { 72 // bionic has broken signal handling for signum > 32 on 32-bit ARM and x86 73 // (for ABI reasons this can't be fixed) 74 android_arm: { 75 cflags: ["-DNUMSIGS=32"], 76 }, 77 android_x86: { 78 cflags: ["-DNUMSIGS=32"], 79 }, 80 }, 81 82 generated_headers: ["ltp_syscalls_h"], 83 84 static_libs: ["libcap"], 85 86 // TODO: recover libaio when the external project created 87 shared_libs: ["libselinux", "libasyncio"], 88} 89 90cc_defaults { 91 name: "ltp_test_defaults", 92 defaults: ["ltp_defaults"], 93 gtest: false, 94 no_named_install_directory: true, 95 relative_install_path: "ltp/testcases/bin", 96} 97