1 /*---------------------------------------------------------------------------* 2 Project: Horizon 3 File: nlib_horizon.h 4 5 Copyright (C)2009 Nintendo Co., Ltd. All rights reserved. 6 7 These coded instructions, statements, and computer programs contain 8 proprietary information of Nintendo of America Inc. and/or Nintendo 9 Company Ltd., and are protected by Federal copyright law. They may 10 not be disclosed to third parties or copied or duplicated in any form, 11 in whole or in part, without the prior written consent of Nintendo. 12 13 $Rev: 21978 $ 14 *---------------------------------------------------------------------------*/ 15 16 /** 17 * nlib.hからインクルードされる、HORIZON環境用定義 18 */ 19 20 21 #include <string.h> 22 #include <stdio.h> 23 #include <nn/nstd.h> 24 #include <nn/nstd/nstd_String.h> 25 26 #ifdef __cplusplus 27 extern "C" { 28 #endif 29 30 /* 31 以下の関数を用意してください。 32 ・NLIB_memcpy 33 ・NLIB_memcmp 34 ・NLIB_memmove 35 ・NLIB_memset 36 ・NLIB_strcmp 37 ・NLIB_strncmp 38 ・NLIB_strlcmp 39 ・NLIB_strlen 40 ・NLIB_strcat 41 ・NLIB_strlcat 42 ・NLIB_strcpy 43 ・NLIB_strlcpy 44 ・NLIB_strchr 45 ・NLIB_strrchr 46 ・NLIB_strstr 47 ・NLIB_strnlen 48 ・NLIB_snprintf 49 ・NLIB_strtok_r 50 */ 51 52 #define NLIB_memcpy nnnstdMemCpy 53 #define NLIB_memcmp memcmp 54 #define NLIB_memmove nnnstdMemMove 55 #define NLIB_memset memset 56 #define NLIB_strcmp strcmp 57 #define NLIB_strncmp strncmp 58 #define NLIB_strlcmp strlcmp 59 #define NLIB_strlen strlen 60 #define NLIB_strcat strcat 61 #define NLIB_strlcat strlca 62 #define NLIB_strcpy strcpy 63 #define NLIB_strlcpy strlcpy 64 #define NLIB_strchr strchr 65 #define NLIB_strrchr strrchr 66 #define NLIB_strstr strstr 67 68 int NLIB_strnlen(const char *str, int len); 69 70 #define NLIB_sprintf nnnstdTSPrintf 71 #define NLIB_snprintf nnnstdTSNPrintf 72 char *NLIB_strtok_r(char *str, const char *delim, char **last); /* strtok_r関数はTWLにないので、別途実装しています。 */ 73 74 75 #ifdef __cplusplus 76 } 77 #endif 78