Fix building gem with gcc 15.1.1#229
Closed
skipkayhil wants to merge 1 commit intotrilogy-libraries:mainfrom
Closed
Fix building gem with gcc 15.1.1#229skipkayhil wants to merge 1 commit intotrilogy-libraries:mainfrom
skipkayhil wants to merge 1 commit intotrilogy-libraries:mainfrom
Conversation
```
Installing trilogy 2.9.0 with native extensions
Gem::Ext::BuildError: ERROR: Failed to build gem native extension.
current directory: /home/hartley/.local/share/mise/installs/ruby/3.4.3/lib/ruby/gems/3.4.0/gems/trilogy-2.9.0/ext/trilogy-ruby
/home/hartley/.local/share/mise/installs/ruby/3.4.3/bin/ruby extconf.rb
checking for CRYPTO_malloc() in -lcrypto... *** extconf.rb failed ***
Could not create Makefile due to some reason, probably lack of necessary
libraries and/or headers. Check the mkmf.log file for more details. You may
need configuration options.
```
Previously, trying to build Trilogy with gcc 15.1.1 would result in an
error like above. Other gems with c extensions have encountered the same
error with gcc 15.1.1, and their fix was to use `append_cflags` instead
of modifying `$CFLAGS`.
Testing locally, `bundle exec rake build && gem install pkg/*.gem` fails
with the above error before this patch but is able to install the gem
after.
Contributor
Author
|
Fixed by rebuilding my Ruby with ruby/ruby@2297afd (I used |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #228
Previously, trying to build Trilogy with gcc 15.1.1 would result in an error like above. Other gems with c extensions have encountered the same error with gcc 15.1.1, and their fix was to use
append_cflagsinstead of modifying$CFLAGS. (RubyCrypto/ed25519#45, tonytonyjan/jaro_winkler#62)Testing locally,
bundle exec rake build && gem install pkg/*.gemfails with the above error before this patch but is able to install the gem after.