13d58139fSopenharmony_ci/* 23d58139fSopenharmony_ci * Copyright (c) Huawei Technologies Co., Ltd. 2014-2021. All rights reserved. 33d58139fSopenharmony_ci * Licensed under Mulan PSL v2. 43d58139fSopenharmony_ci * You can use this software according to the terms and conditions of the Mulan PSL v2. 53d58139fSopenharmony_ci * You may obtain a copy of Mulan PSL v2 at: 63d58139fSopenharmony_ci * http://license.coscl.org.cn/MulanPSL2 73d58139fSopenharmony_ci * THIS SOFTWARE IS PROVIDED ON AN "AS IS" BASIS, WITHOUT WARRANTIES OF ANY KIND, 83d58139fSopenharmony_ci * EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO NON-INFRINGEMENT, 93d58139fSopenharmony_ci * MERCHANTABILITY OR FIT FOR A PARTICULAR PURPOSE. 103d58139fSopenharmony_ci * See the Mulan PSL v2 for more details. 113d58139fSopenharmony_ci * Description: By defining corresponding macro for UNICODE string and including "output.inl", 123d58139fSopenharmony_ci * this file generates real underlying function used by printf family API. 133d58139fSopenharmony_ci * Create: 2014-02-25 143d58139fSopenharmony_ci */ 153d58139fSopenharmony_ci 163d58139fSopenharmony_ci/* If some platforms don't have wchar.h, don't include it */ 173d58139fSopenharmony_ci#if !(defined(SECUREC_VXWORKS_PLATFORM)) 183d58139fSopenharmony_ci/* If there is no macro above, it will cause compiling alarm */ 193d58139fSopenharmony_ci#if defined(_MSC_VER) && (_MSC_VER >= 1400) 203d58139fSopenharmony_ci#ifndef _CRTIMP_ALTERNATIVE 213d58139fSopenharmony_ci#define _CRTIMP_ALTERNATIVE /* Comment microsoft *_s function */ 223d58139fSopenharmony_ci#endif 233d58139fSopenharmony_ci#ifndef __STDC_WANT_SECURE_LIB__ 243d58139fSopenharmony_ci#define __STDC_WANT_SECURE_LIB__ 0 253d58139fSopenharmony_ci#endif 263d58139fSopenharmony_ci#endif 273d58139fSopenharmony_ci#include <wchar.h> 283d58139fSopenharmony_ci#endif 293d58139fSopenharmony_ci 303d58139fSopenharmony_ci/* fix redefined */ 313d58139fSopenharmony_ci#undef SECUREC_ENABLE_WCHAR_FUNC 323d58139fSopenharmony_ci/* Disable wchar func to clear vs warning */ 333d58139fSopenharmony_ci#define SECUREC_ENABLE_WCHAR_FUNC 0 343d58139fSopenharmony_ci#define SECUREC_FORMAT_OUTPUT_INPUT 1 353d58139fSopenharmony_ci 363d58139fSopenharmony_ci#ifndef SECUREC_FOR_WCHAR 373d58139fSopenharmony_ci#define SECUREC_FOR_WCHAR 383d58139fSopenharmony_ci#endif 393d58139fSopenharmony_ci 403d58139fSopenharmony_ci#include "secureprintoutput.h" 413d58139fSopenharmony_ci 423d58139fSopenharmony_ci#include "output.inl" 433d58139fSopenharmony_ci 44