Top Level Namespace

Defined Under Namespace

Classes: File

Constant Summary collapse

EXTCONFIG =
Object.const_get(defined?(RbConfig) ? :RbConfig : :Config)::CONFIG
LIBSTEMMER =
File.expand_path(File.join(File.dirname(__FILE__), 'libstemmer_c'))

Instance Method Summary collapse

Instance Method Details

#apt_install_hint(pkg) ⇒ Object



28
29
30
# File 'ext/extconf.rb', line 28

def apt_install_hint pkg
  "sudo apt-get install #{pkg}"
end

#library_installed?(name, hint) ⇒ Boolean

Returns:

  • (Boolean)


32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
# File 'ext/extconf.rb', line 32

def library_installed? name, hint
  if find_library(name, 'main', *%w(/usr/lib /usr/local/lib /opt/lib /opt/local/lib /sw/lib))
    true
  else
    $stderr.puts "\n      Unable to find required library: \#{name}.\n      On debian systems, it can be installed as,\n\n      \#{hint}\n\n    ERROR\n    false\n  end\nend\n"