• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * Copyright (c) 2020-2021 Huawei Device Co., Ltd.
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 
16 #ifndef OHOS_ACELITE_CONFIG_H
17 #define OHOS_ACELITE_CONFIG_H
18 
19 // some features depend on the low layer configuration
20 #include "graphic_config.h"
21 
22 #if (ENABLE_OHOS_ACELITE_PRODUCT_CONFIG == 1)
23 #include "product_acelite_config.h"
24 #endif
25 /**
26  * ================================================================================================
27  *                 config for wearable
28  * ================================================================================================
29  */
30 /**
31  * the flag indicating watch product
32  */
33 #ifndef OHOS_ACELITE_PRODUCT_WATCH
34 #define OHOS_ACELITE_PRODUCT_WATCH 1
35 #endif
36 
37 // delete this after jerry porting is ready
38 #ifndef JERRY_PORTING_DEPENDENCY
39 #define JERRY_PORTING_DEPENDENCY 1
40 #endif
41 
42 /**
43  * enable Canvas component Feature API on ipcamera real devices
44  */
45 #ifndef FEATURE_COMPONENT_CANVAS
46 #define FEATURE_COMPONENT_CANVAS 1
47 #endif
48 
49 /**
50  * enable QRcode component
51  */
52 #ifndef FEATURE_COMPONENT_QRCODE
53 #define FEATURE_COMPONENT_QRCODE 1
54 #endif
55 
56 /**
57  * support terminate() API from JS
58  */
59 #ifndef FEATURE_TERMINATE_ABILITY
60 #define FEATURE_TERMINATE_ABILITY 1
61 #endif
62 
63 /**
64  * support screenOnVisible() API from JS
65  */
66 #ifndef FEATURE_SCREEN_ON_VISIBLE
67 #define FEATURE_SCREEN_ON_VISIBLE 1
68 #endif
69 
70 /**
71  * enable FeatureAbility API
72  */
73 #ifndef FEATURE_FEATURE_ABILITY_MODULE
74 #define FEATURE_FEATURE_ABILITY_MODULE 1
75 #endif
76 
77 /**
78  * enable timer JS API
79  */
80 #ifndef FEATURE_TIMER_MODULE
81 #define FEATURE_TIMER_MODULE 1
82 #endif
83 
84 /**
85  * enable localization feature
86  */
87 #ifndef FEATURE_LOCALIZATION_MODULE
88 #define FEATURE_LOCALIZATION_MODULE 1
89 #endif
90 
91 #ifndef FEATURE_ACELITE_HI_LOG_PRINTF
92 #define FEATURE_ACELITE_HI_LOG_PRINTF 1
93 #endif
94 
95 /**
96  * support mc ace log module trace
97  */
98 #ifndef FEATURE_ACELITE_MC_LOG_PRINTF
99 #define FEATURE_ACELITE_MC_LOG_PRINTF 1
100 #endif
101 
102 /**
103  * support mc ace event and error code print
104  */
105 #ifndef FEATURE_ACELITE_MC_EVENT_ERROR_CODE_PRINT
106 #define FEATURE_ACELITE_MC_EVENT_ERROR_CODE_PRINT 1
107 #endif
108 
109 /**
110  * support mc console log
111  */
112 #ifndef FEATURE_USER_MC_LOG_PRINTF
113 #define FEATURE_USER_MC_LOG_PRINTF 1
114 #endif
115 
116 /**
117  * support config for product JS modules
118  */
119 #ifndef FEATURE_PRODUCT_MODULE
120 #define FEATURE_PRODUCT_MODULE 1
121 #endif
122 
123 /**
124  * support config for private JS modules
125  */
126 #ifndef FEATURE_PRIVATE_MODULE
127 #define FEATURE_PRIVATE_MODULE 1
128 #endif
129 
130 /**
131  * support using memory pool from product side
132  */
133 #ifndef FEATURE_ACELITE_PRODUCT_MEMORY_POOL
134 #define FEATURE_ACELITE_PRODUCT_MEMORY_POOL 1
135 #endif
136 
137 /**
138  * define the max length of user's console log
139  */
140 #ifndef CONSOLE_LOG_LINE_MAX_LENGTH
141 #define CONSOLE_LOG_LINE_MAX_LENGTH (96)
142 #endif
143 
144 #ifndef ACELITE_DEPENDENCY_IS_READY
145 #define ACELITE_DEPENDENCY_IS_READY 1
146 #endif
147 /**
148  * support mc ace dfx module
149  */
150 #ifndef FEATURE_ACELITE_DFX_MODULE
151 #define FEATURE_ACELITE_DFX_MODULE 1
152 #endif
153 
154 #ifndef FEATURE_ACELITE_LITE_DFX_MODULE
155 #define FEATURE_ACELITE_LITE_DFX_MODULE 1
156 #endif
157 
158 /**
159  * support mc lazy loading
160  */
161 #ifndef FEATURE_LAZY_LOADING_MODULE
162 #define FEATURE_LAZY_LOADING_MODULE 1
163 #endif
164 
165 /**
166  * support fatal error handling on device which not support process
167  */
168 #ifndef FEATURE_FATAL_ERROR_HANDLING
169 #define FEATURE_FATAL_ERROR_HANDLING 1
170 #endif
171 
172 /**
173  * support intl module
174  */
175 #ifndef FEATURE_INTL_MODULE
176 #define FEATURE_INTL_MODULE 1
177 #endif
178 
179 /**
180  * supoort number format module
181  */
182 #ifndef FEATURE_NUMBER_FORMAT
183 #define FEATURE_NUMBER_FORMAT 1
184 #endif
185 
186 /**
187  * date time module
188  */
189 #ifndef FEATURE_DATE_FORMAT
190 #define FEATURE_DATE_FORMAT 1
191 #endif
192 
193 #ifndef FEATURE_API_VERSION
194 #define FEATURE_API_VERSION 1
195 #endif
196 
197 #ifndef JS_ENGINE_STATIC_MULTI_CONTEXTS_ENABLED
198 #define JS_ENGINE_STATIC_MULTI_CONTEXTS_ENABLED 1
199 #endif
200 
201 #ifndef FEATURE_MODULE_STORAGE
202 #define FEATURE_MODULE_STORAGE 0
203 #endif
204 
205 #ifndef FEATURE_MODULE_AUDIO
206 #define FEATURE_MODULE_AUDIO 0
207 #endif
208 
209 #ifndef FEATURE_MODULE_DEVICE
210 #define FEATURE_MODULE_DEVICE 0
211 #endif
212 
213 #ifndef FEATURE_SUPPORT_HTTP
214 #define FEATURE_SUPPORT_HTTP 0
215 #endif
216 
217 #ifndef FEATURE_MODULE_GEO
218 #define FEATURE_MODULE_GEO 0
219 #endif
220 
221 #ifndef FEATURE_MODULE_SENSOR
222 #define FEATURE_MODULE_SENSOR 0
223 #endif
224 
225 #ifndef FEATURE_MODULE_BRIGHTNESS
226 #define FEATURE_MODULE_BRIGHTNESS 0
227 #endif
228 
229 #ifndef FEATURE_MODULE_BATTERY
230 #define FEATURE_MODULE_BATTERY 0
231 #endif
232 
233 #ifndef FEATURE_MODULE_CONFIGURATION
234 #define FEATURE_MODULE_CONFIGURATION 0
235 #endif
236 
237 /**
238  * support js profiler
239  */
240 #ifndef FEATURE_ACELITE_MC_JS_PROFILER
241 #define FEATURE_ACELITE_MC_JS_PROFILER 1
242 #endif
243 
244 #ifndef DEFAULT_PROFILER_MSG_PATH
245 #define DEFAULT_PROFILER_MSG_PATH "user/log/"
246 #endif
247 
248 #ifndef PROFILER_ENABLE_FLAG_FILE
249 #define PROFILER_ENABLE_FLAG_FILE "user/data/profiler_enable"
250 #endif
251 
252 #ifndef RUNTIME_MODE_FILE_PATH
253 #define RUNTIME_MODE_FILE_PATH "user/data/jsparser_enable"
254 #endif
255 
256 /**
257  * Rotation API feature
258  */
259 #if (ENABLE_ROTATE_INPUT == 1)
260 // low layer supports
261 #ifndef FEATURE_ROTATION_API
262 #define FEATURE_ROTATION_API 1
263 #endif
264 #endif // (ENABLE_ROTATE_INPUT == 1)
265 
266 #endif // OHOS_ACELITE_CONFIG_H
267