Some checks failed
Periodic Merges (6h) / master → staging-nixos (push) Failing after 12m50s
Periodic Merges (6h) / master → staging-next (push) Failing after 12m54s
Periodic Merges (24h) / merge-base(master,staging) → haskell-updates (push) Failing after 11m54s
Periodic Merges (6h) / staging-next → staging (push) Failing after 12m13s
Periodic Merges (24h) / staging-next-25.05 → staging-25.05 (push) Failing after 13m24s
Periodic Merges (24h) / release-25.05 → staging-next-25.05 (push) Failing after 14m28s
34 lines
780 B
Plaintext
34 lines
780 B
Plaintext
# encoding: utf-8
|
|
# Install the xapian binaries into the lib folder of the gem
|
|
require 'rbconfig'
|
|
|
|
c = RbConfig::CONFIG
|
|
|
|
source_dir = 'xapian_source'
|
|
bindings = Dir["#{source_dir}/xapian-bindings-*"].first
|
|
bindings = File.basename(bindings, ".tar.xz")
|
|
|
|
task :default do
|
|
sh "tar -xJf #{source_dir}/#{bindings}.tar.xz"
|
|
|
|
prefix = Dir.pwd
|
|
ENV['LDFLAGS'] = "-L#{prefix}/lib"
|
|
|
|
sh "mkdir -p lib"
|
|
|
|
Dir.chdir bindings do
|
|
ENV['RUBY'] ||= "#{c['bindir']}/#{c['RUBY_INSTALL_NAME']}"
|
|
sh "./configure --prefix=#{prefix} --exec-prefix=#{prefix} --with-ruby"
|
|
sh "make clean all"
|
|
end
|
|
|
|
sh "cp -r #{bindings}/ruby/.libs/_xapian.* lib"
|
|
sh "cp #{bindings}/ruby/xapian.rb lib"
|
|
|
|
sh "rm lib/*.la"
|
|
sh "rm lib/*.lai"
|
|
|
|
sh "rm -R #{bindings}"
|
|
sh "rm -R #{source_dir}"
|
|
end
|