Giter Site home page Giter Site logo

Comments (12)

tmm1 avatar tmm1 commented on August 23, 2024

Can you gist the mkmf.log file?

from charlock_holmes.

sosedoff avatar sosedoff commented on August 23, 2024

Here it is: https://gist.github.com/1201710

from charlock_holmes.

tmm1 avatar tmm1 commented on August 23, 2024

Looks like file/libmagic is using sed with @ as a separator, and it gets confused because of rvm's use of @ in the directory name.

Not sure how to fix it, we might have to patch file.

from charlock_holmes.

tmm1 avatar tmm1 commented on August 23, 2024

Actually its happening during manpage generation, so maybe we can skip that since all we need is the library.

from charlock_holmes.

sosedoff avatar sosedoff commented on August 23, 2024

Thanks, i'll try to figure out the temp patch while you guys work on this issue.

from charlock_holmes.

tmm1 avatar tmm1 commented on August 23, 2024

This should fix it:

diff --git a/ext/charlock_holmes/extconf.rb b/ext/charlock_holmes/extconf.rb
index 8ac3631..dc5784c 100644
--- a/ext/charlock_holmes/extconf.rb
+++ b/ext/charlock_holmes/extconf.rb
@@ -58,8 +58,7 @@ Dir.chdir("#{CWD}/src") do
   sys("tar zxvf #{src}")
   Dir.chdir(dir) do
     sys("./configure --prefix=#{CWD}/dst/ --disable-shared --enable-static --with-pic")
-    sys("make")
-    sys("make install")
+    sys("make install-exec")
   end
 end

from charlock_holmes.

tmm1 avatar tmm1 commented on August 23, 2024

Can you confirm this change works?

from charlock_holmes.

sosedoff avatar sosedoff commented on August 23, 2024

The patch didnt solve the problem. After applying the patch i got a different error:

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

        /Users/sosedoff/.rvm/rubies/ruby-1.9.2-p290/bin/ruby extconf.rb --with-icu-dir=/usr/local/Cellar/icu4c/4.4.1
checking for main() in -licui18n... yes
checking for main() in -licui18n... yes
checking for unicode/ucnv.h... yes
  -- tar zxvf file-5.08.tar.gz
  -- ./configure --prefix=/Users/sosedoff/.rvm/gems/ruby-1.9.2-p290/gems/charlock_holmes-0.6.7/ext/charlock_holmes/dst/ --disable-shared --enable-static --with-pic
  -- make install-exec
checking for main() in -lmagic_ext... yes
checking for magic.h... no


***************************************************************************************
********* error compiling and linking libmagic. please report issue on github *********
***************************************************************************************
*** 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=/Users/sosedoff/.rvm/rubies/ruby-1.9.2-p290/bin/ruby
    --with-icu-dir
    --with-icu-include
    --without-icu-include=${icu-dir}/include
    --with-icu-lib
    --without-icu-lib=${icu-dir}/lib
    --with-icui18nlib
    --without-icui18nlib
    --with-icui18nlib
    --without-icui18nlib
    --with-magic-dir
    --without-magic-dir
    --with-magic-include
    --without-magic-include=${magic-dir}/include
    --with-magic-lib
    --without-magic-lib=${magic-dir}/lib
    --with-magic_extlib
    --without-magic_extlib


Gem files will remain installed in /Users/sosedoff/.rvm/gems/ruby-1.9.2-p290/gems/charlock_holmes-0.6.7 for inspection.
Results logged to /Users/sosedoff/.rvm/gems/ruby-1.9.2-p290/gems/charlock_holmes-0.6.7/ext/charlock_holmes/gem_make.out

from charlock_holmes.

tmm1 avatar tmm1 commented on August 23, 2024

Try this one:

diff --git a/ext/charlock_holmes/extconf.rb b/ext/charlock_holmes/extconf.rb
index 8ac3631..da83154 100644
--- a/ext/charlock_holmes/extconf.rb
+++ b/ext/charlock_holmes/extconf.rb
@@ -58,8 +58,7 @@ Dir.chdir("#{CWD}/src") do
   sys("tar zxvf #{src}")
   Dir.chdir(dir) do
     sys("./configure --prefix=#{CWD}/dst/ --disable-shared --enable-static --with-pic")
-    sys("make")
-    sys("make install")
+    sys("make -C src install")
   end
 end

from charlock_holmes.

sosedoff avatar sosedoff commented on August 23, 2024

This one worked out. Thanks!
I tried REE, 187, 192, all via custom gemset.

See #2, still fails.

from charlock_holmes.

tmm1 avatar tmm1 commented on August 23, 2024

What still fails?

I committed the patch to master.

from charlock_holmes.

sosedoff avatar sosedoff commented on August 23, 2024

Oh, my bad. I was referring to #3.

from charlock_holmes.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.