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

Cannot build on Mac os x Catalina #73

Open
rollyar opened this issue Apr 14, 2020 · 3 comments
Open

Cannot build on Mac os x Catalina #73

rollyar opened this issue Apr 14, 2020 · 3 comments

Comments

@rollyar
Copy link

rollyar commented Apr 14, 2020

Hello cannot build the gem, on mac os catalina

Firebird-3.0.5-33220-x86_64

sw_vers
ProductName: Mac OS X
ProductVersion: 10.15.4
BuildVersion: 19E287

/usr/sbin/pkgutil --packages | grep CL
com.apple.pkg.CLTools_Executables
com.apple.pkg.CLTools_SDK_macOS1015
com.apple.pkg.CLTools_SDK_macOS1014
com.apple.pkg.CLTools_macOS_SDK

/usr/sbin/pkgutil --pkg-info com.apple.pkg.CLTools_Executables
package-id: com.apple.pkg.CLTools_Executables
version: 11.4.0.0.1.1583798712
volume: /
location: /
install-time: 1586826514
groups: com.apple.FindSystemFiles.pkg-group

I have the next error:
Building native extensions. This could take a while...
/Users/rolando/.rvm/rubies/ruby-2.6.3/lib/ruby/2.6.0/open3.rb:213: warning: Insecure world writable dir /Library/Frameworks/Firebird.framework/Resources in PATH, mode 040777
ERROR: Error installing fb:
ERROR: Failed to build gem native extension.

current directory: /Users/rolando/.rvm/gems/ruby-2.6.3/gems/fb-0.9.2

/Users/rolando/.rvm/rubies/ruby-2.6.3/bin/ruby -I /Users/rolando/.rvm/rubies/ruby-2.6.3/lib/ruby/site_ruby/2.6.0 -r ./siteconf20200414-1402-141o5gw.rb extconf.rb
checking for isc_attach_database() in -lfbclient... *** 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
--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/rolando/.rvm/rubies/ruby-2.6.3/bin/$(RUBY_BASE_NAME)
--with-firebird-dir
--without-firebird-dir
--with-firebird-include
--without-firebird-include=${firebird-dir}/include
--with-firebird-lib
--without-firebird-lib=${firebird-dir}/lib
--with-fbclientlib
--without-fbclientlib
/Users/rolando/.rvm/rubies/ruby-2.6.3/lib/ruby/2.6.0/mkmf.rb:467:in try_do': The compiler failed to generate an executable file. (RuntimeError) You have to install development tools first. from /Users/rolando/.rvm/rubies/ruby-2.6.3/lib/ruby/2.6.0/mkmf.rb:552:in try_link0'
from /Users/rolando/.rvm/rubies/ruby-2.6.3/lib/ruby/2.6.0/mkmf.rb:570:in try_link' from /Users/rolando/.rvm/rubies/ruby-2.6.3/lib/ruby/2.6.0/mkmf.rb:782:in try_func'
from /Users/rolando/.rvm/rubies/ruby-2.6.3/lib/ruby/2.6.0/mkmf.rb:1016:in block in have_library' from /Users/rolando/.rvm/rubies/ruby-2.6.3/lib/ruby/2.6.0/mkmf.rb:959:in block in checking_for'
from /Users/rolando/.rvm/rubies/ruby-2.6.3/lib/ruby/2.6.0/mkmf.rb:361:in block (2 levels) in postpone' from /Users/rolando/.rvm/rubies/ruby-2.6.3/lib/ruby/2.6.0/mkmf.rb:331:in open'
from /Users/rolando/.rvm/rubies/ruby-2.6.3/lib/ruby/2.6.0/mkmf.rb:361:in block in postpone' from /Users/rolando/.rvm/rubies/ruby-2.6.3/lib/ruby/2.6.0/mkmf.rb:331:in open'
from /Users/rolando/.rvm/rubies/ruby-2.6.3/lib/ruby/2.6.0/mkmf.rb:357:in postpone' from /Users/rolando/.rvm/rubies/ruby-2.6.3/lib/ruby/2.6.0/mkmf.rb:958:in checking_for'
from /Users/rolando/.rvm/rubies/ruby-2.6.3/lib/ruby/2.6.0/mkmf.rb:1011:in have_library' from extconf.rb:90:in block in

'
from extconf.rb:90:in each' from extconf.rb:90:in find'
from extconf.rb:90:in `'

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

/Users/rolando/.rvm/gems/ruby-2.6.3/extensions/x86_64-darwin-19/2.6.0/fb-0.9.2/mkmf.log

extconf failed, exit code 1

Gem files will remain installed in /Users/rolando/.rvm/gems/ruby-2.6.3/gems/fb-0.9.2 for inspection.
Results logged to /Users/rolando/.rvm/gems/ruby-2.6.3/extensions/x86_64-darwin-19/2.6.0/fb-0.9.2/gem_make.out

Any help?

@rollyar
Copy link
Author

rollyar commented May 4, 2020

I solved as follow:
git clone https://github.com/rowland/fb.git
cd db
nano extcont.rb
change extcont.rb to

#!/usr/bin/env ruby
require 'mkmf'

$CFLAGS += " -DOS_UNIX"
dir_config("firebird")
have_library("fbclient","isc_attach_database", "ibase.h")
create_makefile("fb")

then build and install
gem build fb.gemspec
gem install fb-0.9.2.gem

@douweh
Copy link

douweh commented Jun 25, 2020

I have the same problem, when looking into mkmf.log it states framework not found Firebird.
However the framework is available on /Library/Frameworks/Firebird.framework.

Anyone got any clue?

@nik736
Copy link

nik736 commented Jul 29, 2024

Did anyone find a solution for this?

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

3 participants