summaryrefslogtreecommitdiff
path: root/configure.ac
Commit message (Collapse)AuthorAgeFilesLines
* Introduce --enable-rjit=disasmTakashi Kokubun2023-04-271-1/+5
|
* Avoid linking capstone by defaultTakashi Kokubun2023-04-241-3/+3
| | | | Workaround for https://github.com/ruby/setup-ruby/pull/501#issuecomment-1520722486
* Use tools appropriate with CCNobuyoshi Nakada2023-04-091-0/+6
| | | | | | | | | | | | | | | | To get rid of mysterious errors such as: ``` /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/nm: error: libruby.3.3-static.a(/): The end of the file was unexpectedly encountered ``` and ``` ld: warning: ignoring file ../../libruby.3.3-static.a, building for macOS-x86_64 but attempting to link with file built for macOS-x86_64 Undefined symbols for architecture x86_64: "_rb_rational_num", referenced from: ```
* Include `--no-llvm-bc` option in `NM` macro only if usableNobuyoshi Nakada2023-04-081-0/+4
|
* [Bug#19161] Detect thread local storage specifierNobuyoshi Nakada2023-04-071-7/+16
| | | | | | Checking by `__STDC_VERSION__` is unreliable because old gcc 4.8 supports `-std=gnu11` option but does not implement `_Thread_local`. Check the implementation directly instead.
* Add Dir.fchdirJeremy Evans2023-03-241-0/+1
| | | | | | | | | | | | This is useful for passing directory file descriptors over UNIX sockets or to child processes to avoid TOCTOU vulnerabilities. The implementation follows the Dir.chdir code. This will raise NotImplementedError on platforms not supporting both fchdir and dirfd. Implements [Feature #19347]
* Fix ENABLE_MULTIARCHNobuyoshi Nakada2023-03-241-0/+3
| | | | | This macro is used in `ruby_init_loadpath()`, but was removed mistakenly at 31f4b2d86bfbc753cec9be376719acc4b120e944.
* YJIT: Make dev_nodebug closer to dev (#7570)Takashi Kokubun2023-03-201-0/+1
|
* RJIT: Use RJIT_STATS on --enable-rjit=devTakashi Kokubun2023-03-171-2/+2
| | | | RUBY_DEBUG is too slow.
* Bump the required BASERUBY version to 2.5 (#7504)Takashi Kokubun2023-03-101-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | [Misc #16671] I'd like to bump it to 2.7 to use pattern matching in tool/mk_builtin_loader.rb. However, I experienced a few blockers. 2.5 seems like the closest version that is easy enough to use on CIs, so let me bump the version to it as an intermediate step for it. I want to use &. and <<~ in 2.3 too. Known blockers: * AppVeyor Visual Studio 2015 doesn't have Ruby 2.7. You'd need to bump the version to Visual Studio 2019. * GitHub Actions windows-2019 doesn't have Ruby 2.7 either. You can use ruby/setup-ruby, but configure doesn't seem to work with it. * For ruby/ruby-ci-imaage, bionic doesn't have Ruby 2.7. I tried using ruby-build to build Ruby 2.7 from package, but the build on its CI seems to somehow loop forever when I do that. So I gave it up for now. We might want to wait until bionic becomes EOL. Note: * AppVeyor Visual Studio 2015 has Ruby <= 2.6.3 https://www.appveyor.com/docs/windows-images-software/#ruby * GitHub Actions windows-2019 uses Ruby 2.5.9 https://github.com/actions/runner-images/blob/main/images/win/Windows2019-Readme.md
* RJIT: Always enable --rjit-dump-disasmTakashi Kokubun2023-03-101-3/+3
|
* [Bug #19161] Check for TLS usabilityNobuyoshi Nakada2023-03-091-6/+7
| | | | On all platforms using GCC, even other than darwin.
* Link libcapstone no matter what cargo doesTakashi Kokubun2023-03-071-8/+4
| | | | | | | | | libcapstone used to break when it's linked from C and Rust at the same time, but it doesn't seem to happen anymore. Maybe it's related to recent symbol hygiene changes. Thank you if that's the case. This commit allows you to make both --enable-rjit=dev and --enable-yjit=dev work in the same binary.
* Allow enabling YJIT and RJIT independently (#7474)Takashi Kokubun2023-03-071-24/+55
| | | | | We used to require MJIT is supported when YJIT is supported. However, now that RJIT dropped some platforms that YJIT supports, it no longer makes sense. We should be able to enable only YJIT, and vice versa.
* s/mjit/rjit/Takashi Kokubun2023-03-061-3/+3
|
* s/MJIT/RJIT/Takashi Kokubun2023-03-061-22/+22
|
* Remove obsoleted tool/mjit_tabs.rbTakashi Kokubun2023-03-061-4/+0
|
* Drop obsoleted MJIT header (#7458)Takashi Kokubun2023-03-061-10/+0
| | | RJIT doesn't need this.
* Rely on YJIT's switch for nowTakashi Kokubun2023-03-051-5/+5
|
* Implement --mjit-dump-disasmTakashi Kokubun2023-03-051-0/+6
|
* Add support for LoongArch (#7343)小MAO钓鱼2023-02-221-0/+3
| | | | | | | | | * vm_dump.c: Dump machine registers on loongarch64 Linux. * coroutines: Support for native loongarch64 coroutines. --------- Co-authored-by: zangruochen <zangruochen@loongson.cn>
* Do not use `objcopy` on macOSNobuyoshi Nakada2023-02-151-10/+1
| | | | | | | | | | | | | | On macOS, it is not used to localize symbols in dynamic libraries (libruby.dylib and libyjit.o). Instead, using `objcopy` which does not support recent mach-O causes linker errors as bellow. ``` linking shared-library libruby.3.3.dylib error: cannot parse the debug map for 'libruby.3.3.dylib': Invalid data was encountered while parsing the file linking ruby ld: malformed mach-o: LC_*_DYLIB load command string extends beyond end of load command file './libruby.3.3.dylib' clang: error: linker command failed with exit code 1 (use -v to see invocation) ```
* Check if objcopy works to localize symbolNobuyoshi Nakada2023-02-141-0/+10
| | | | | LLVM objcopy does not support localizing symbols option, e.g, `--localize-symbol` and `--keep-global-symbol`, for MachO.
* Extract include/ruby/internal/attr/packed_struct.hNobuyoshi Nakada2023-02-081-3/+2
| | | | | | | | | Split `PACKED_STRUCT` and `PACKED_STRUCT_UNALIGNED` macros into the macros bellow: * `RBIMPL_ATTR_PACKED_STRUCT_BEGIN` * `RBIMPL_ATTR_PACKED_STRUCT_END` * `RBIMPL_ATTR_PACKED_STRUCT_UNALIGNED_BEGIN` * `RBIMPL_ATTR_PACKED_STRUCT_UNALIGNED_END`
* Silence dozens of useless warnings from `nm` on macOSNobuyoshi Nakada2023-01-311-6/+0
|
* configure: Keep OBJCOPY even when visibility options are availableAlan Wu2023-01-271-2/+1
| | | | | | | YJIT will need it to address symbol leakage issue. Fallback to `:` when OBJCOPY is not available on the system. Co-authored-by: Co-authored-by: Nobuyoshi Nakada <nobu@ruby-lang.org>
* configure: Don't use use LD=clang, ld takes different flagsAlan Wu2023-01-271-1/+1
| | | | | | This was a difference from using a GNU toolchain previously. It wasn't a problem because we don't invoke $(LD) in the Makefile currently. YJIT will want to invoke LD, so needs this consistency.
* Get rid of duplicate "--disable=gems" optionsNobuyoshi Nakada2023-01-261-1/+1
|
* Silence dozens of useless warnings from `ranlib` on macOS [ci skip]Nobuyoshi Nakada2023-01-231-0/+6
|
* Enable arm64 coroutine implementation on OpenBSD/arm64Jeremy Evans2022-12-251-0/+3
| | | | | Tested by another OpenBSD developer and confirmed to significantly improve things.
* Revert "darwin: resolve rb symbols from ext by `-flat_namespace` to see ↵NARUSE, Yui2022-12-241-4/+9
| | | | | | | | | libruby transitively" This reverts commit c5eefb7f37db2865891298dd1a1e60dff09560ad. Flat namespace breaks gems with C extention if its symbols conflict with ohter libraries.
* darwin: resolve rb symbols from ext by `-flat_namespace` to see libruby ↵Yuta Saito2022-12-231-9/+4
| | | | | | | | | | | | | | | transitively This repairs the assumption, which many fat-gem maintainer expect, "An extension built with --disable-shared Ruby is loadable from --enable-shared Ruby". By default all references resolved to a dynamic library use "two-level namespace", which record the library name and symbol name for each resolution entry. On the other hand, `-flat_namespace` discards the library name information and resolves symbols "flatly". This behavior is useful for us to ignore which image (`ruby` executable or `libruby.dylib`) provides rb symbols at runtime.
* configure.ac: limit miniruby dep to when bundle_loader needs itMike Dalessio2022-12-201-1/+1
| | | | | | | | See also e7bffe0 https://bugs.ruby-lang.org/issues/19239 Co-authored-by: Nobuyoshi Nakada <nobu@ruby-lang.org>
* YJIT: Improve the description about --enable-yjit (#6947)Takashi Kokubun2022-12-191-1/+1
|
* Suppress cross tool warning for pkg-config [ci skip]Nobuyoshi Nakada2022-12-181-0/+2
| | | | It is used from mkmf.rb on target environments.
* configure.ac: add miniruby to PREP when cross-compiling to darwinMike Dalessio2022-12-181-0/+4
| | | | | | | | miniruby is used to resolve symbols in ext bundles https://bugs.ruby-lang.org/issues/19239 Co-authored-by: Yuta Saito <kateinoigakukun@gmail.com>
* Make it so YJIT is no longer marked as experimental (#6909)Maxime Chevalier-Boisvert2022-12-121-1/+1
| | | | | Tested on production workloads at Shopify for > 1 year and proven to be quite stable. Enabling YJIT at run-time is still guarded behind the --yjit command-line option for now.
* YJIT: echo "\n" is not portableAlan Wu2022-12-021-1/+1
| | | | | | | It's unspecified by POSIX. zsh and dash give a newline and bash doesn't substitute it. Attributes don't have to be followed by a newline anyway, so just remove it. [Bug #19174]
* Fix up "Avoid bash specific variable substitution"Nobuyoshi Nakada2022-12-031-1/+1
| | | | | Keep `target_alias` empty if it is set to empty. If it is set to non empty, `os_version_style_transform` is not used.
* Avoid bash specific variable substitutionNobuyoshi Nakada2022-12-021-4/+7
| | | | | It may cause parse errors in some other sh even in never executed parts.
* YJIT: Make sure rustc's target matches before enabling (#6804)Alan Wu2022-11-241-2/+10
| | | | | | | | | | | | For people using Rosetta 2 on ARM Macs, it can happen that the rustc in the PATH compiles for x86_64 while clang is targeting ARM. We were enabling YJIT in these situations because the test program compiled fine, but caused linking failure later due to the architecture mismatch. Adjust the test program to fail when rustc's target arch is different from ruby's target arch. [Bug #19146]
* Add a comment about confusing code [ci skip]Takashi Kokubun2022-11-201-0/+1
|
* Add support for `sockaddr_un` on Windows. (#6513)Samuel Williams2022-11-171-0/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Windows: Fix warning about undefined if_indextoname() * Windows: Fix UNIXSocket on MINGW and make .pair more reliable * Windows: Use nonblock=true for read tests with scheduler * Windows: Move socket detection from File.socket? to File.stat Add S_IFSOCK to Windows and interpret reparse points accordingly. Enable tests that work now. * Windows: Use wide-char functions to UNIXSocket This fixes behaviour with non-ASCII characters. It also fixes deletion of temporary UNIXSocket.pair files. * Windows: Add UNIXSocket tests for specifics of Windows impl. * Windows: fix VC build due to missing _snwprintf Avoid usage of _snwprintf, since it fails linking ruby.dll like so: linking shared-library x64-vcruntime140-ruby320.dll x64-vcruntime140-ruby320.def : error LNK2001: unresolved external symbol snwprintf x64-vcruntime140-ruby320.def : error LNK2001: unresolved external symbol vsnwprintf_l whereas linking miniruby.exe succeeds. This patch uses snprintf on the UTF-8 string instead. Also remove branch GetWindowsDirectoryW, since it doesn't work. * Windows: Fix dangling symlink test failures Co-authored-by: Lars Kanis <kanis@comcard.de>
* YJIT: Show YJIT build option in RUBY_DESCRIPTION (#6738)Takashi Kokubun2022-11-161-0/+3
| | | YJIT: Show YJIT profile in RUBY_DESCRIPTION
* Define YJIT_STATS on --enable-yjit=stats (#6710)Takashi Kokubun2022-11-101-0/+1
|
* Set up EXTSTATIC before checking itAlan Wu2022-11-101-17/+17
| | | | | The bundle_loader check for darwin checks EXTSTATIC, but previously the setup for the variable comes after the check. I had trouble building using --with-static-linked-ext on darwin before this change.
* YJIT: Improve checking message for rustc version (#6693)Alan Wu2022-11-081-1/+3
| | | | | | | | | | | | | | | | | | | Preivously we didn't have a "checking ...." line for this check and when rustc was too old, we would dump the error message to the console like: checking for rustc... rustc error: there is no argument named `x` --> <anon>:1:33 | 1 | fn main() { let x = 1; format!("{x}"); } | ^^^ error: aborting due to previous error `configure` checks usually don't do this and this might be confusing. With this commit it now says something like: checking whether rustc is new enough for YJIT... no
* YJIT: improve/fix code to automatically build YJIT when available (#6684)Maxime Chevalier-Boisvert2022-11-081-33/+29
| | | | | | | * YJIT: improve/fix code to automatically build YJIT when available * Set YJIT_SUPPORT=no * Fix rustc => $RUSTC
* Check `rustc` with the targetNobuyoshi Nakada2022-11-061-12/+22
|
* `--disable-jit-support` should disable YJIT successfullyNobuyoshi Nakada2022-11-061-6/+10
| | | | | Even if `rustc` is available, it should not be an error unless `--enable-yjit` is explicitly given.