suketa / ruby-duckdb

Ruby binding for DuckDB
https://github.com/suketa/ruby-duckdb
MIT License
162 stars 25 forks source link

Install fails if your Homebrew directory is not /opt/homebrew #784

Open haydenk opened 1 month ago

haydenk commented 1 month ago

https://github.com/suketa/ruby-duckdb/blob/main/ext/duckdb/extconf.rb#L10

I setup my homebrew installation in my user home directory ~/.brew with an environment variable of $BREW_HOME to specify where it is.

While creating a symbolic link /opt/homebrew -> ~/.brew did "fix" it so the gem installed, a better option to override and specify my own paths would be nice.

Maybe there is one and I have overlooked it or am unaware.

suketa commented 1 month ago
  1. Find your directory path having duckdb.h.
  2. Find your directory path having libduckdb.dylib.
  3. gem install duckdb with --with-duckdb-include and --with-duckdb-lib option.
gem install duckdb --with-duckdb-include=your_duckdb.h_directory_path --with-duckdb-lib=your_libduckdb.dylib_directory_path