summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--configure.ac14
-rw-r--r--version.h2
2 files changed, 14 insertions, 2 deletions
diff --git a/configure.ac b/configure.ac
index 2c4d2888d2..d8103cbe8a 100644
--- a/configure.ac
+++ b/configure.ac
@@ -552,7 +552,19 @@ AS_IF([test "$GCC" = yes], [
# argument check. The performance drop is very little and Ubuntu enables
# _FORTIFY_SOURCE=2 by default. So, let's support it for protecting us from
# a mistake of silly C extensions.
- RUBY_TRY_CFLAGS(-D_FORTIFY_SOURCE=2, [RUBY_APPEND_OPTION(XCFLAGS, -D_FORTIFY_SOURCE=2)])
+
+ # TODO: check if link succeeds with _FORTIFY_SOURCE=2.
+ AS_CASE(["$target_os"],
+ [mingw*], [
+ fortify_source=no
+ ])
+ AC_ARG_ENABLE(fortify_source,
+ AS_HELP_STRING([--disable-fortify-source],
+ [disable -D_FORTIFY_SOURCE=2 option, which causes link error on mingw]),
+ [fortify_source=$enableval])
+ AS_IF([test "x$fortify_source" != xno], [
+ RUBY_TRY_CFLAGS(-D_FORTIFY_SOURCE=2, [RUBY_APPEND_OPTION(XCFLAGS, -D_FORTIFY_SOURCE=2)])
+ ])
: ${MJIT_HEADER_FLAGS='-P -dD'}
diff --git a/version.h b/version.h
index c3a2539227..bc10bb4f12 100644
--- a/version.h
+++ b/version.h
@@ -1,6 +1,6 @@
#define RUBY_VERSION "2.6.7"
#define RUBY_RELEASE_DATE "2021-02-28"
-#define RUBY_PATCHLEVEL 156
+#define RUBY_PATCHLEVEL 157
#define RUBY_RELEASE_YEAR 2021
#define RUBY_RELEASE_MONTH 2