1 /* 2 * Copyright (C) 2023 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 #include <iostream> 17 18 #define PRINT_SET(x) std::cout << #x << " set" << std::endl; 19 #define PRINT_UNSET(x) std::cout << #x << " unset" << std::endl; 20 main()21int main() { 22 #ifdef VALUE1 23 PRINT_SET(VALUE1) 24 #else 25 PRINT_UNSET(VALUE1) 26 #endif 27 28 #ifdef VALUE1_PLUS_ANDROID 29 PRINT_SET(VALUE1_PLUS_ANDROID) 30 #else 31 PRINT_UNSET(VALUE1_PLUS_ANDROID) 32 #endif 33 34 #ifdef VALUE1_PLUS_HOST 35 PRINT_SET(VALUE1_PLUS_HOST) 36 #else 37 PRINT_UNSET(VALUE1_PLUS_HOST) 38 #endif 39 40 #ifdef VALUE2 41 PRINT_SET(VALUE2) 42 #else 43 PRINT_UNSET(VALUE2) 44 #endif 45 46 #ifdef VALUE2_PLUS_ANDROID 47 PRINT_SET(VALUE2_PLUS_ANDROID) 48 #else 49 PRINT_UNSET(VALUE2_PLUS_ANDROID) 50 #endif 51 52 #ifdef VALUE2_PLUS_HOST 53 PRINT_SET(VALUE2_PLUS_HOST) 54 #else 55 PRINT_UNSET(VALUE2_PLUS_HOST) 56 #endif 57 58 #ifdef DEFAULT 59 PRINT_SET(DEFAULT) 60 #else 61 PRINT_UNSET(DEFAULT) 62 #endif 63 64 #ifdef DEFAULT_PLUS_ANDROID 65 PRINT_SET(DEFAULT_PLUS_ANDROID) 66 #else 67 PRINT_UNSET(DEFAULT_PLUS_ANDROID) 68 #endif 69 70 #ifdef DEFAULT_PLUS_HOST 71 PRINT_SET(DEFAULT_PLUS_HOST) 72 #else 73 PRINT_UNSET(DEFAULT_PLUS_HOST) 74 #endif 75 76 #ifdef BOOL_VAR 77 PRINT_SET(BOOL_VAR) 78 #else 79 PRINT_UNSET(BOOL_VAR) 80 #endif 81 82 #ifdef BOOL_VAR_PLUS_ANDROID 83 PRINT_SET(BOOL_VAR_PLUS_ANDROID) 84 #else 85 PRINT_UNSET(BOOL_VAR_PLUS_ANDROID) 86 #endif 87 88 #ifdef BOOL_VAR_PLUS_HOST 89 PRINT_SET(BOOL_VAR_PLUS_HOST) 90 #else 91 PRINT_UNSET(BOOL_VAR_PLUS_HOST) 92 #endif 93 94 #ifdef BOOL_VAR_DEFAULT 95 PRINT_SET(BOOL_VAR_DEFAULT) 96 #else 97 PRINT_UNSET(BOOL_VAR_DEFAULT) 98 #endif 99 100 #ifdef BOOL_VAR_DEFAULT_PLUS_ANDROID 101 PRINT_SET(BOOL_VAR_DEFAULT_PLUS_ANDROID) 102 #else 103 PRINT_UNSET(BOOL_VAR_DEFAULT_PLUS_ANDROID) 104 #endif 105 106 #ifdef BOOL_VAR_DEFAULT_PLUS_HOST 107 PRINT_SET(BOOL_VAR_DEFAULT_PLUS_HOST) 108 #else 109 PRINT_UNSET(BOOL_VAR_DEFAULT_PLUS_HOST) 110 #endif 111 112 return 0; 113 } 114