From: "thomthom (Thomas Thomassen)" Date: 2022-11-04T17:19:36+00:00 Subject: [ruby-core:110609] [Ruby master Bug#18876] OpenSSL fails to autoload in --with-static-linked-ext builds Issue #18876 has been updated by thomthom (Thomas Thomassen). alanwu (Alan Wu) wrote in #note-13: > thomthom (Thomas Thomassen) wrote in #note-12: > > So is `--with-static-linked-ext` causing a bug with `autoload`? Or is it a configuration issue? > > Yeah, it's a bug and not a configuration issue. > `defined?` is a keyword and the argument isn't evaluated like in a method call which is > why it could behave differently from referencing the constant in a normal context. Is there an open ticket to track this bug? This one appear to have been closed. ---------------------------------------- Bug #18876: OpenSSL fails to autoload in --with-static-linked-ext builds https://bugs.ruby-lang.org/issues/18876#change-99941 * Author: Gloomy_meng (Gloomy Meng) * Status: Closed * Priority: Normal * ruby -v: 3.1.1 * Backport: 2.7: UNKNOWN, 3.0: UNKNOWN, 3.1: UNKNOWN ---------------------------------------- i try use ruby + gem in my macos app with .a framework, i need install ruby in a custom location. so i make & make install openssl with this configure: ``` shell /usr/bin/perl Configure --prefix="......./local/dependencies" no-shared zlib darwin64-x86_64-cc ``` then make & make install ruby with this configure: ``` shell /bin/sh configure --prefix /Users/xxxxx/xxxx/local/bundle --with-openssl-dir="/Users/xxxxx/xxxx/local/dependencies" --enable-load-relative --with-static-linked-ext --disable-install-doc --with-out-ext="xxxxxx" ``` ------ because i need to isolated environment, so i make `bundle-env` file for run shell. and i uploaded bundle-env file ------ and update gem by local ``` shell destroot/bundle/bin/bundle-env gem install downloads/rubygems-update-3.3.15.gem --no-document --env-shebang ``` at last, run install alway got exception: ``` shell destroot/bundle/bin/bundle-env gem install xxxxxxx --version="xxxxxx" --no-document --env-shebang ERROR: While executing gem ... (Gem::Exception) OpenSSL is not available. Install OpenSSL and rebuild Ruby (preferred) or use non-HTTPS sources ``` at the same env, i tried some command, and i got the right version what i make install ``` shell destroot/bundle/bin/bundle-env ruby --version // ruby 3.1.1p18 (2022-02-18 revision 53f5fc4236) [x86_64-darwin21] destroot/bundle/bin/bundle-env gem --version // 3.3.15 destroot/bundle/bin/bundle-env ruby -ropenssl -e 'puts OpenSSL::OPENSSL_VERSION' // OpenSSL 1.1.1i 8 Dec 2020 ``` ------ i found and uploaded `ext/openssl/mkmf.log` and ---Files-------------------------------- bundle-env (852 Bytes) mkmf.log (215 KB) -- https://bugs.ruby-lang.org/ Unsubscribe: