summaryrefslogtreecommitdiff
path: root/configure.ac
AgeCommit message (Collapse)Author
2018-08-24thread_pthread.c: use eventfd instead of pipe on Linuxnormal
Based on r64478, any regular user creating more than 1024 pipes on Linux will end up with tiny pipes with only a single page capacity. So avoid wasting user resources and use lighter eventfd on Linux. [ruby-core:88563] [Misc #15011] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64527 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-08-16configure.ac: LIBPATHENV on macOSnobu
* configure.ac (LIBPATHENV): use DYLD_FALLBACK_LIBRARY_PATH instead of DYLD_LIBRARY_PATH on macOS, to honor runtime paths embedded in the binaries. [ruby-core:88487] [Bug #14992] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64392 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-08-13thread_pthread: use POSIX timer or thread to get rid of racesnormal
This closes race condition where GVL is uncontended and a thread receives a signal immediately before calling the blocking function when releasing GVL: 1) check interrupts 2) release GVL 3) blocking function If signal fires after 1) but before 3), that thread may never wake up if GVL is uncontended We also need to wakeup the ubf_list unconditionally on gvl_yield; because two threads can be yielding to each other while waiting on IO#close while waiting on threads in IO#read or IO#gets. [ruby-core:88360] [Misc #14937] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64353 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-08-13Makefile.in: drop MJIT_DLDFLAGS_NOCOMPRESSk0kubun
which is obsoleted by r64331 git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64335 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-08-13Re-apply wrongly reverted r64330naruse
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64333 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-08-13support compressed debug_linenaruse
re-commit r64328 https://blogs.oracle.com/solaris/elf_section_compression-v2 https://gnu.wildebeest.org/blog/mjw/2016/01/13/elf-libelf-compressed-sections-and-elfutils/ git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64331 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-08-13configure.ac: use linker_flag to LIBRUBY_DLDFLAGSnobu
* configure.ac: use a feature flag `linker_flag`, than checking if the compiler is `GCC`. * configure.ac: append to LIBRUBY_DLDFLAGS once after initialized with DLDFLAGS. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64330 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-08-13Revert "support compressed debug_line"naruse
This reverts commit r64328 git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64329 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-08-13support compressed debug_linenaruse
https://blogs.oracle.com/solaris/elf_section_compression-v2 https://gnu.wildebeest.org/blog/mjw/2016/01/13/elf-libelf-compressed-sections-and-elfutils/ git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64328 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-08-12configure.ac: use the correct argumentk0kubun
for --compress-debug-sections. I thought "no" is the correct one because configure.ac has `AS_IF([test "x$compress_debug_sections" != xno]`, but it wasn't the case. This commit is needed to resolve errors like: /usr/bin/x86_64-linux-gnu-ld: invalid --compress-debug-sections option: `no' collect2: error: ld returned 1 exit status git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64326 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-08-12configure.ac: MJIT_DLDFLAGS_NOCOMPRESSk0kubun
is configured now, to force -Wl,--compress-debug-sections=no for MJIT only when the option is used in MJIT_DLDFLAGS. This needs to be done in configure.ac to resolve build failure like https://travis-ci.org/ruby/ruby/builds/415120662. Makefile.in: define it in mjit_config.h mjit_worker.c: replace hard-coded flag to MJIT_DLDFLAGS_NOCOMPRESS git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64325 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-08-11upgrade the default WINNT versionnobu
* configure.ac: set the default target Windows NT version to 0x0600, as well as mswin version since r50051. Windows XP has ended years ago. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@64294 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-07-05unrevert r63852 but keep SIGCHLD path disabled for win32normal
Reading win32/win32.c waitpid implementation, maybe waitpid(-1, ...) on that platform will never conflict with mjit use of waitpid. In any case, I've added WAITPID_USE_SIGCHLD macro to vm_core.h so it can be easy for Linux/BSD users to test (hopefully!) win32-compatible code. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63855 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-07-04Revert r63758 and related commitsnaruse
The change is unstable on Windows. Please re-commit it when it correctly supports Windows. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63852 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-07-03configure.ac: [DOC] refine help messagesnobu
cflags, cppflags, and cxxflags are additional flags to auto configured flags, and ignored when the their respective autoconf default variables are given. [ci skip] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63832 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-06-30use sigsetjmp on macOSnobu
SIGCHLD is used internally since r63758, the signal masks need to be restored. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63803 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-06-27hijack SIGCHLD handler for internal usenormal
Use a global SIGCHLD handler to guard all callers of rb_waitpid. To work safely with multi-threaded programs, we introduce a VM-wide waitpid_lock to be acquired BEFORE fork/vfork spawns the process. This is to be combined with the new ruby_waitpid_locked function used by mjit.c in a non-Ruby thread. Ruby-level SIGCHLD handlers registered with Signal.trap(:CHLD) continues to work as before and there should be no regressions in any existing use cases. Splitting the wait queues for PID > 0 and groups (PID <= 0) ensures we favor PID > 0 callers. The disabling of SIGCHLD in rb_f_system is longer necessary, as we use deferred signal handling and no longer make ANY blocking waitpid syscalls in other threads which could "beat" the waitpid call made by rb_f_system. We prevent SIGCHLD from firing in normal Ruby Threads and only enable it in the timer-thread, to prevent spurious wakeups from in test/-ext-/gvl/test_last_thread.rb with MJIT enabled. I've tried to guard as much of the code for RUBY_SIGCHLD==0 using C "if" statements rather than CPP "#if" so to reduce the likelyhood of portability problems as the compiler will see more code. We also work to suppress false-positives from Process.wait(-1, Process::WNOHANG) to quiets warnings from spec/ruby/core/process/wait2_spec.rb with MJIT enabled. Lastly, we must implement rb_grantpt for ext/pty. We need a MJIT-compatible way of supporting grantpt(3) which may spawn the `pt_chown' binary and call waitpid(2) on it. [ruby-core:87605] [Ruby trunk Bug#14867] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63758 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-06-22remove DISABLE_RUBYGEMS from config filesnobu
* configure.ac: removed DISABLE_RUBYGEMS macro from config.h, not to rebuild everything when the flag changed. * configure.ac, win32/configure.bat: make USE_RUBYGEMS lowercase. * tool/mkconfig.rb: remove RUBYGEMS stuff from rbconfig.rb, not to reconfigure and rebuild all extension libraries. * Makefile.in (CPPFLAGS): enable/disable Rubygems by USE_RUBYGEMS. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63718 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-06-14prefer clock_gettimenobu
* configure.ac: clock_gettime or gettimeofday must exist. * process.c (rb_clock_gettime): prefer clock_gettime over gettimeofday, as the latter is obsolete in SUSv4. * random.c (fill_random_seed): ditto. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63663 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-05-16configure.ac: move the checks of _XOPEN_SOURCE on Solarisngoto
* configure.ac (solaris*): Move the checks of _XOPEN_SOURCE to the location before r63443, to cover non-GCC compilers on Solaris. This partly reverts r63443. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63444 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-05-16configure.ac: move checks of -std=gnu99 and _XOPEN_SOURCE on Solarisngoto
* configure.ac (ansi_options): On Solaris, "-std=gnu99" should be appended to CPPFLAGS instead of warnflags and strict_warnflags, because the flag affects existance of functions and macros. * configure.ac (solaris*): Check _XOPEN_SOURCE just after checking "-std=gnu99" on Solaris. Because _XOPEN_SOURCE also affects existance of many functions and macros, it is good to define it earlier. The check is simplified to use AC_TRY_COMPILE with RUBY_WERROR_FLAG. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63443 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-05-16configure.ac: revert r63438ngoto
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63442 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-05-15Change logic to check _XOPEN_SOURCE on Solarisngoto
* configure.ac: Change logic to check _XOPEN_SOURCE on Solaris. With _XOPEN_SOURCE, "-std=gnu99" may also be added to CPPFLAGS. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63438 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-05-15configure.ac: maybe with jemallocnobu
* configure.ac (--with-jemalloc): accept `maybe` (other than `yes` and `no`), check for jemalloc and use it if possible. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63433 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-05-15-Wno-cast-function-typeshyouhei
GCC 8.1+ introduced this warning in -Weverything. It does shed some lights on something, but rather annoying than useful ATM. Might be a subject to revert this option in a future. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63429 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-05-11configure.ac: remove ineffective check on Solaris with GCCngoto
* configure.ac (solaris): Remove ineffective check for -std=iso9899:1999 on Solaris with GCC. The "-std=iso9899:1999" was replaced by "-std=gnu99" by the commit r54895. The check is no longer effective after that, and two years have passed without error reports. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63401 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-29Remove the teeny part from the shared library name on macOSknu
This will prevent macOS users from having to rebuild all extension libraries every time they upgrade ruby to a new teeny release. Before: - libruby.2.6.0.dylib - libruby.2.6.dylib -> libruby.2.6.0.dylib - libruby.dylib -> libruby.2.6.0.dylib After: - libruby.2.6.dylib - libruby.dylib -> libruby.2.6.dylib git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63300 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-09Prefer alignof() over _Alignof()shyouhei
to allow C++ programs include <ruby.h>. [Bug #14668] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63123 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-04-03Honor --silent optionnobu
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@63072 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-03-27configure.ac: string literal concatenationnobu
* configure.ac: bail out if string literal concatenation is not available, as it is used everywhere now. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62933 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-03-24configure.ac: named blocksnobu
* configure.ac: turned section block comments into named blocks. http://c16e.com/1603281120/ git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62910 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-03-16configure.ac: DLDFLAGS without arch flagsnobu
* configure.ac (DLDFLAGS): copy LDFLAGS before adding arch flags. multiple arch flags on universal binary make mjit_header.h failed. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62770 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-03-15configure.ac: fix rb_cv_gcc_compiler_casnobu
* configure.ac (rb_cv_gcc_compiler_cas): do not use one variable for multiple AC_CACHE_CHECK. in one check, select by different values. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62765 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-03-14configure.ac: basic libsnobu
* configure.ac: basic libraries like -lm are necessary for some extension libraries on some platforms. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62749 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-03-09configure.ac: --disable-mathn optionnobu
* Makefile.in, win32/Makefile.sub: move CANONICALIZATION_FOR_MATHN from config.h which affects all extension libraries to XCFLAGS for the core only. * configure.ac: added --disable-mathn option. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62705 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-03-03mjit_config.h: MJIT_LDSHAREDnobu
* configure.in (MJIT_LDSHARED): define based on LDSHARED with replacing CC with MJIT_CC. * Makefile.in, win32/Makefile.sub (mjit_config.h): instead of the default LDSHARED, use MJIT_LDSHARED to link mjit shared objects. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62644 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-03-02configure.ac: library options to MAINLIBSnobu
* configure.ac (MAINLIBS): moved library options for main program and static libruby, and append MAINLIBS to LIBRUBYARG_STATIC, as these libraries are not needed for linking to shared libruby. [ruby-core:85882] [Bug #14422] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62627 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-03-02configure.ac: fix up r59130nobu
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62625 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-03-01MJIT specific flagsnobu
Passing options to configure like as `configure MJIT_OPTFLAGS=-O MJIT_DEBUGFLAGS=-g` overrides options to be used to compile JIT code, separately from the default options to be used for ruby itself. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62623 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-02-18mjit.c: no va_copynobu
* mjit.c (form_args): do not use va_copy, which cannot detect appropriate way to simulate when cross compiling. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62463 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-02-17configure.ac: check clockid_t with necessary headersnobu
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62446 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-02-15thread_pthread.c: Use `getpagesize()` when `pthread_attr_getguardsize` is ↵mame
unavailable This is also for emscripten. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62409 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-02-15configure.ac: Use `pthread_create` to determine if pthread is availablemame
Instead of `pthread_kill`. This is because emscripten supports `pthread_create` but not `pthread_kill`. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62408 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-02-08MJIT header for multiarchnobu
* configure.ac: MJIT_HEADER_INSTALL_DIR to rubyarchhdrdir to support multiarch. * Makefile.in (MJIT_HEADER_INSTALL_DIR): configured by multiarch. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62320 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-02-06configure.ac: removed unnecessary pushdef/popdefnobu
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62247 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-02-06deal with aclocal(1)shyouhei
This commit updates files so that aclocal.m4 generated by aclocal(1) works well with our configure.ac * ac_checking.m4: merged back to configure.ac because aclocal(1) cannot handle this macro. * ruby_append_options.m4: no longer used. * ruby_check_va_copy.m4: define using AC_DEFUN so that aclocal(1) can find this macro. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62243 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-02-05va_copy is a C99ismshyouhei
Should provide appropriate fallback implementation. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62220 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-02-04common.mk: rb_mjit_header.hnobu
* common.mk (rb_mjit_header.h): moved from Makefile.in and win32/Makefile.sub. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62202 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-27Fix duplicated HAVE_NANkazu
And remove redundant `HAVE_*` macros, and use `USE_RB_*` macros instead. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@62067 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2018-01-20set AC_CONFIG_MACRO_DIRS [close GH-1793]shyouhei
We do not use aclocal(1) by default. But in case users do so, AC_CONFIG_MACRO_DIRS help them reconstruct the same contents as this commit includes. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@61982 b2dd03c8-39d4-4d8f-98ff-823fe69b080e