Skip to content

Commit

Permalink
conditionally install xapian-ruby gem based on an environment variable
Browse files Browse the repository at this point in the history
... instead of checking if the host is OpenBSD. There are other
situations where the xapian-ruby gem may be broken and the user may
prefer to install it themselves, such as on recent MacOS.
  • Loading branch information
danc86 committed Apr 13, 2024
1 parent d996908 commit 492091a
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions ext/mkrf_conf_xapian.rb
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
inst = Gem::DependencyInstaller.new(:install_dir => destination)
begin

if !RbConfig::CONFIG['arch'].include?('openbsd')
if not ENV.include? "SUP_SKIP_XAPIAN_GEM_INSTALL"
# update version in Gemfile as well
name = "xapian-ruby"
version =
Expand All @@ -37,7 +37,7 @@

end
else
STDERR.puts "xapian: openbsd: you have to install xapian-core and xapian-bindings manually, have a look at: https://github.com/sup-heliotrope/sup/wiki/Installation%3A-OpenBSD"
STDERR.puts "xapian: you have to install xapian-core and xapian-bindings manually"
end

rescue StandardError => e
Expand Down

0 comments on commit 492091a

Please sign in to comment.