Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Help with installing oxidized-script [Failed to build gem native extension] #50

Open
Harrifresh opened this issue Jul 15, 2024 · 3 comments

Comments

@Harrifresh
Copy link

Hi all,

I saw someone else posted this exact problem on the top level Oxidized page but they were directed here instead. I couldn't find another issue from the same poster so I've created my own. ytti/oxidized#3200

I've setup an ubuntu 24.04 server to run oxidized, getting this error when attempting to install the oxidized-script gem:

Building native extensions. This could take a while...
ERROR:  Error installing oxidized-script:
        ERROR: Failed to build gem native extension.

    current directory: /var/lib/gems/3.2.0/gems/rugged-0.99.0/ext/rugged
/usr/bin/ruby3.2 -I/usr/lib/ruby/vendor_ruby extconf.rb
checking for gmake... yes
checking for cmake... yes
checking for pkg-config... yes
*** 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.

Provided configuration options:
        --with-opt-dir
        --without-opt-dir
        --with-opt-include
        --without-opt-include=${opt-dir}/include
        --with-opt-lib
        --without-opt-lib=${opt-dir}/lib
        --with-make-prog
        --without-make-prog
        --srcdir=.
        --curdir
        --ruby=/usr/bin/$(RUBY_BASE_NAME)3.2
        --with-sha1dc
        --without-sha1dc
        --use-system-libraries
extconf.rb:101:in `block in <main>': undefined method `exists?' for Dir:Class (NoMethodError)

    Dir.mkdir("build") if !Dir.exists?("build")
                              ^^^^^^^^
Did you mean?  exist?
        from extconf.rb:100:in `chdir'
        from extconf.rb:100:in `<main>'

To see why this extension failed to compile, please check the mkmf.log which can be found here:

  /var/lib/gems/3.2.0/extensions/x86_64-linux-gnu/3.2.0/rugged-0.99.0/mkmf.log

extconf failed, exit code 1

Gem files will remain installed in /var/lib/gems/3.2.0/gems/rugged-0.99.0 for inspection.
Results logged to /var/lib/gems/3.2.0/extensions/x86_64-linux-gnu/3.2.0/rugged-0.99.0/gem_make.out

Looking at the mkmf.log file shows no errors:

find_executable: checking for gmake... -------------------- yes

--------------------

find_executable: checking for cmake... -------------------- yes

--------------------

find_executable: checking for pkg-config... -------------------- yes

--------------------

The original poster suggested there could be a typo in the script where it should be "exist" but it's written as "exists". Not sure if that is the problem but the error message points in that direction.

Is anyone able to assist please?

Thanks in advance
Harri

@ylmrx
Copy link

ylmrx commented Aug 2, 2024

hitting the same wall here, and it's quite inconvenient : latest oxidized-web rely on ruby3.2, oxidized-script require ruby3.0, you can't have both.

building my container with ubuntu-jammy (carries ruby3.0) and downgrading oxidized-web to 0.13.1.

is ubuntu-noble a hard requirement for you ?

@bram-pangestu
Copy link

i also face the same issue. Waiting for update/good news

@robertcheramy
Copy link

If no one steps into maintaining oxidized-script, I'm sorry to say that the chances for good news are near zero.
I've stepped into maintaining oxidized and oxidized-web and there is more work than I can handle.

Ruby 3.0 is end of life and both oxidized and oxidized-web require ruby 3.1 as a minimal requirement.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants