Changeset 06b0211b in mainline for uspace/lib/posix
- Timestamp:
- 2013-04-29T11:29:45Z (13 years ago)
- Branches:
- lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
- Children:
- aa2b32c
- Parents:
- ba4799a (diff), df956b9b (diff)
Note: this is a merge changeset, the changes displayed below correspond to the merge itself.
Use the(diff)links above to see all the changes relative to each parent. - Location:
- uspace/lib/posix
- Files:
-
- 6 edited
-
include/posix/fcntl.h (modified) (1 diff)
-
include/posix/float.h (modified) (3 diffs)
-
include/posix/limits.h (modified) (1 diff)
-
include/posix/math.h (modified) (1 diff)
-
include/posix/stdio.h (modified) (1 diff)
-
source/math.c (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
uspace/lib/posix/include/posix/fcntl.h
rba4799a r06b0211b 48 48 #define O_ACCMODE (O_RDONLY | O_WRONLY | O_RDWR) 49 49 50 /* Dummy compatibility flag */ 51 #undef O_NOCTTY 52 #define O_NOCTTY 0 53 50 54 /* fcntl commands */ 51 55 #undef F_DUPFD -
uspace/lib/posix/include/posix/float.h
rba4799a r06b0211b 36 36 #define POSIX_FLOAT_H_ 37 37 38 /* 39 * The macros defined below are needed for compilation of MPFR 40 * (http://www.mpfr.org/). Probably, they should be provided by GCC 41 * itself but that does not work for cross-compilation. 42 * 38 /* Rouding direction -1 - unknown */ 39 #define FLT_ROUNDS (-1) 40 41 /* define some standard C constants in terms of GCC built-ins */ 42 #ifdef __GNUC__ 43 #undef DBL_MANT_DIG 44 #define DBL_MANT_DIG __DBL_MANT_DIG__ 45 #undef DBL_MIN_EXP 46 #define DBL_MIN_EXP __DBL_MIN_EXP__ 47 #undef DBL_MAX_EXP 48 #define DBL_MAX_EXP __DBL_MAX_EXP__ 49 #undef DBL_MAX 50 #define DBL_MAX __DBL_MAX__ 51 #undef DBL_MAX_10_EXP 52 #define DBL_MAX_10_EXP __DBL_MAX_10_EXP__ 53 #undef DBL_MIN_10_EXP 54 #define DBL_MIN_10_EXP __DBL_MIN_10_EXP__ 55 #undef DBL_MIN 56 #define DBL_MIN __DBL_MIN__ 57 #undef DBL_DIG 58 #define DBL_DIG __DBL_DIG__ 59 #undef DBL_EPSILON 60 #define DBL_EPSILON __DBL_EPSILON__ 61 #undef FLT_RADIX 62 #define FLT_RADIX __FLT_RADIX__ 63 #else 64 /* For something else than GCC, following definitions are provided. 43 65 * They are intentionally guarded by the given macro to ensure that anyone 44 66 * who wants them states this explicitly. … … 50 72 */ 51 73 #ifdef FLOAT_H_YES_I_REALLY_WANT_LIMITS 52 53 74 /* float limits */ 54 75 #define FLT_MIN 1.1754943508222875079687365372222456778186655567720875215087517062784172594547271728515625e-38 … … 82 103 #endif 83 104 105 #endif /* __GNUC__ */ 106 84 107 #endif /* POSIX_FLOAT_H_ */ 85 108 -
uspace/lib/posix/include/posix/limits.h
rba4799a r06b0211b 49 49 #define PATH_MAX 256 50 50 51 /* it's probably a safe assumption */ 52 #undef CHAR_BIT 53 #define CHAR_BIT 8 54 51 55 #endif /* POSIX_LIMITS_H_ */ 52 56 -
uspace/lib/posix/include/posix/math.h
rba4799a r06b0211b 40 40 #endif 41 41 42 #ifdef __GNUC__ 43 #define HUGE_VAL (__builtin_huge_val()) 44 #endif 45 42 46 /* Normalization Functions */ 43 47 extern double __POSIX_DEF__(ldexp)(double x, int exp); 44 48 extern double __POSIX_DEF__(frexp)(double num, int *exp); 45 49 50 double __POSIX_DEF__(fabs)(double x); 51 double __POSIX_DEF__(floor)(double x); 52 double __POSIX_DEF__(modf)(double x, double *iptr); 53 double __POSIX_DEF__(fmod)(double x, double y); 54 double __POSIX_DEF__(pow)(double x, double y); 55 double __POSIX_DEF__(exp)(double x); 56 double __POSIX_DEF__(sqrt)(double x); 57 double __POSIX_DEF__(log)(double x); 58 double __POSIX_DEF__(sin)(double x); 59 double __POSIX_DEF__(cos)(double x); 60 double __POSIX_DEF__(atan2)(double y, double x); 46 61 47 62 #endif /* POSIX_MATH_H_ */ -
uspace/lib/posix/include/posix/stdio.h
rba4799a r06b0211b 70 70 71 71 typedef struct _IO_FILE FILE; 72 73 #ifndef LIBPOSIX_INTERNAL 74 enum _buffer_type { 75 /** No buffering */ 76 _IONBF, 77 /** Line buffering */ 78 _IOLBF, 79 /** Full buffering */ 80 _IOFBF 81 }; 82 #endif 72 83 73 84 extern FILE *stdin; -
uspace/lib/posix/source/math.c
rba4799a r06b0211b 63 63 } 64 64 65 /** 66 * 67 * @param x 68 * @return 69 */ 70 double posix_cos(double x) 71 { 72 // TODO: Python dependency 73 not_implemented(); 74 } 75 76 /** 77 * 78 * @param x 79 * @param y 80 * @return 81 */ 82 double posix_pow(double x, double y) 83 { 84 // TODO: Python dependency 85 not_implemented(); 86 } 87 88 /** 89 * 90 * @param x 91 * @return 92 */ 93 double posix_floor(double x) 94 { 95 // TODO: Python dependency 96 not_implemented(); 97 } 98 99 /** 100 * 101 * @param x 102 * @return 103 */ 104 double posix_fabs(double x) 105 { 106 // TODO: Python dependency 107 not_implemented(); 108 } 109 110 /** 111 * 112 * @param x 113 * @param iptr 114 * @return 115 */ 116 double posix_modf(double x, double *iptr) 117 { 118 // TODO: Python dependency 119 not_implemented(); 120 } 121 122 /** 123 * 124 * @param x 125 * @param y 126 * @return 127 */ 128 double posix_fmod(double x, double y) 129 { 130 // TODO: Python dependency 131 not_implemented(); 132 } 133 134 /** 135 * 136 * @param x 137 * @return 138 */ 139 double posix_log(double x) 140 { 141 // TODO: Python dependency 142 not_implemented(); 143 } 144 145 /** 146 * 147 * @param x 148 * @param y 149 * @return 150 */ 151 double posix_atan2(double y, double x) 152 { 153 // TODO: Python dependency 154 not_implemented(); 155 } 156 157 /** 158 * 159 * @param x 160 * @return 161 */ 162 double posix_sin(double x) 163 { 164 // TODO: Python dependency 165 not_implemented(); 166 } 167 168 /** 169 * 170 * @param x 171 * @return 172 */ 173 double posix_exp(double x) 174 { 175 // TODO: Python dependency 176 not_implemented(); 177 } 178 179 /** 180 * 181 * @param x 182 * @return 183 */ 184 double posix_sqrt(double x) 185 { 186 // TODO: Python dependency 187 not_implemented(); 188 } 189 65 190 /** @} 66 191 */
Note:
See TracChangeset
for help on using the changeset viewer.
