diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/init.c | 2 | ||||
| -rw-r--r-- | src/math.c | 3 |
2 files changed, 5 insertions, 0 deletions
diff --git a/src/init.c b/src/init.c index 17ce24313..1f7d4d364 100644 --- a/src/init.c +++ b/src/init.c @@ -57,7 +57,9 @@ mrb_init_core(mrb_state *mrb) mrb_init_exception(mrb); mrb_init_print(mrb); mrb_init_time(mrb); +#ifdef INCLUDE_MATH mrb_init_math(mrb); +#endif mrb_init_mrblib(mrb); diff --git a/src/math.c b/src/math.c index 1de9c0d8f..3898146b6 100644 --- a/src/math.c +++ b/src/math.c @@ -5,6 +5,8 @@ */ #include "mruby.h" + +#ifdef INCLUDE_MATH #include <math.h> #define domain_error(msg) \ @@ -679,3 +681,4 @@ mrb_init_math(mrb_state *mrb) mrb_define_module_function(mrb, mrb_math, "erf", math_erf, ARGS_REQ(1)); mrb_define_module_function(mrb, mrb_math, "erfc", math_erfc, ARGS_REQ(1)); } +#endif /* INCLUDE_MATH */ |
