зеркало из https://github.com/github/ruby.git
configure.ac: add --disable-fiber-coroutine option
* configure.ac: add --disable-fiber-coroutine option, and disable it on x86-mingw32 for now. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@65899 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
Родитель
9cda5bba1b
Коммит
f1ed4b713b
|
@ -144,6 +144,7 @@ XRUBY_RUBYHDRDIR = @XRUBY_RUBYHDRDIR@
|
|||
BOOTSTRAPRUBY = @BOOTSTRAPRUBY@
|
||||
|
||||
COROUTINE_H = @X_FIBER_COROUTINE_H@
|
||||
COROUTINE_OBJ = $(COROUTINE_H:.h=.@OBJEXT@)
|
||||
|
||||
#### End of system configuration section. ####
|
||||
|
||||
|
|
|
@ -138,6 +138,7 @@ COMMONOBJS = array.$(OBJEXT) \
|
|||
vm_backtrace.$(OBJEXT) \
|
||||
vm_dump.$(OBJEXT) \
|
||||
vm_trace.$(OBJEXT) \
|
||||
$(COROUTINE_OBJ) \
|
||||
$(DTRACE_OBJ) \
|
||||
$(BUILTIN_ENCOBJS) \
|
||||
$(BUILTIN_TRANSOBJS) \
|
||||
|
@ -895,8 +896,9 @@ strstr.$(OBJEXT): {$(VPATH)}strstr.c
|
|||
nt.$(OBJEXT): {$(VPATH)}nt.c
|
||||
ia64.$(OBJEXT): {$(VPATH)}ia64.s
|
||||
$(CC) $(CFLAGS) -c $<
|
||||
$(COROUTINE_H:.h=).$(OBJEXT): {$(VPATH)}$(COROUTINE_H:.h=).$(ASMEXT)
|
||||
$(COROUTINE_H:.h=).$(OBJEXT): $(COROUTINE_H:Context.h=.time)
|
||||
.coroutine_obj $(COROUTINE_OBJ): \
|
||||
{$(VPATH)}$(COROUTINE_H:.h=).$(ASMEXT) \
|
||||
$(COROUTINE_H:Context.h=.time)
|
||||
$(COROUTINE_H:Context.h=.time):
|
||||
$(Q) $(MAKEDIRS) $(@D)
|
||||
@exit > $@
|
||||
|
|
46
configure.ac
46
configure.ac
|
@ -963,6 +963,7 @@ main()
|
|||
AS_IF([test "$target_cpu" = x64], [
|
||||
ac_cv_func___builtin_setjmp=no
|
||||
ac_cv_func_round=no
|
||||
rb_cv_fiber_coroutine=no # TODO: Enable this after AppVeyor msys2 build succeeds
|
||||
])
|
||||
ac_cv_func_tgamma=no
|
||||
rb_cv_negative_time_t=yes
|
||||
|
@ -2326,38 +2327,35 @@ AS_IF([test "${universal_binary-no}" = yes ], [
|
|||
AC_DEFINE_UNQUOTED(STACK_GROW_DIRECTION, $dir)
|
||||
])
|
||||
|
||||
AC_MSG_CHECKING(native coroutine implementation for ${target_cpu}-${target_os})
|
||||
AS_CASE(["$target_cpu-$target_os"],
|
||||
AC_ARG_ENABLE(fiber-coroutine,
|
||||
AS_HELP_STRING([--disable-fiber-coroutine], [disable native coroutine implementation for fiber]),
|
||||
[rb_cv_fiber_coroutine=$enableval])
|
||||
AS_CASE(["$rb_cv_fiber_coroutine"], [yes|''], [
|
||||
AC_MSG_CHECKING(native coroutine implementation for ${target_cpu}-${target_os})
|
||||
AS_CASE(["$target_cpu-$target_os"],
|
||||
[x*64-darwin*], [
|
||||
AC_MSG_RESULT(amd64)
|
||||
COROUTINE_H=coroutine/amd64/Context.h
|
||||
AC_DEFINE_UNQUOTED(FIBER_USE_COROUTINE, ["$COROUTINE_H"])
|
||||
AC_LIBOBJ([coroutine/amd64/Context])
|
||||
rb_cv_fiber_coroutine=amd64
|
||||
],
|
||||
[x*64-linux], [
|
||||
AC_MSG_RESULT(amd64)
|
||||
COROUTINE_H=coroutine/amd64/Context.h
|
||||
AC_DEFINE_UNQUOTED(FIBER_USE_COROUTINE, ["$COROUTINE_H"])
|
||||
AC_LIBOBJ([coroutine/amd64/Context])
|
||||
rb_cv_fiber_coroutine=amd64
|
||||
],
|
||||
[*86-linux], [
|
||||
AC_MSG_RESULT(x86)
|
||||
COROUTINE_H=coroutine/x86/Context.h
|
||||
AC_DEFINE_UNQUOTED(FIBER_USE_COROUTINE, ["$COROUTINE_H"])
|
||||
AC_LIBOBJ([coroutine/x86/Context])
|
||||
rb_cv_fiber_coroutine=x86
|
||||
],
|
||||
[x64-mingw32], [
|
||||
rb_cv_fiber_coroutine=win64
|
||||
],
|
||||
# TODO: Enable this after AppVeyor msys2 build succeeds
|
||||
# [x64-mingw32], [
|
||||
# AC_MSG_RESULT(win64)
|
||||
# COROUTINE_H=coroutine/win64/Context.h
|
||||
# AC_DEFINE_UNQUOTED(FIBER_USE_COROUTINE, ["$COROUTINE_H"])
|
||||
# AC_LIBOBJ([coroutine/win64/Context])
|
||||
# ],
|
||||
[*], [
|
||||
AC_MSG_RESULT(no)
|
||||
rb_cv_fiber_coroutine=
|
||||
]
|
||||
)
|
||||
AC_SUBST(X_FIBER_COROUTINE_H, [$COROUTINE_H])
|
||||
)
|
||||
AC_MSG_RESULT(${rb_cv_fiber_coroutine:-no})
|
||||
])
|
||||
AS_IF([test "${rb_cv_fiber_coroutine:-no}" != no], [
|
||||
COROUTINE_H=coroutine/$rb_cv_fiber_coroutine/Context.h
|
||||
AC_DEFINE_UNQUOTED(FIBER_USE_COROUTINE, ["$COROUTINE_H"])
|
||||
AC_SUBST(X_FIBER_COROUTINE_H, [$COROUTINE_H])
|
||||
])
|
||||
|
||||
AS_IF([test x"$enable_pthread" = xyes], [
|
||||
for pthread_lib in thr pthread pthreads c c_r root; do
|
||||
|
|
|
@ -293,10 +293,10 @@ DLNOBJ = dln.obj
|
|||
COROUTINE_H = coroutine/Win64/Context.h
|
||||
!elseif "$(ARCH)" == "i386"
|
||||
COROUTINE_H = coroutine/Win32/Context.h
|
||||
!else
|
||||
COROUTINE_H =
|
||||
!endif
|
||||
!if defined(COROUTINE_H)
|
||||
MISSING = $(MISSING) $(COROUTINE_H:.h=.obj)
|
||||
!endif
|
||||
COROUTINE_OBJ = $(COROUTINE_H:.h=.obj)
|
||||
|
||||
ARFLAGS = -machine:$(MACHINE) -out:
|
||||
LD = $(CC)
|
||||
|
|
Загрузка…
Ссылка в новой задаче