19 lines
379 B
Ruby
19 lines
379 B
Ruby
|
#!/usr/bin/ruby -w
|
||
|
|
||
|
# Licensed under GPL-2 or later
|
||
|
# Author: Petteri Räty <betelgeuse@gentoo.org>
|
||
|
|
||
|
$: << File.dirname(__FILE__)
|
||
|
require "@LIBDIR@/@PACKAGE@/go-pkgutil.rb"
|
||
|
|
||
|
elf = ARGV[0]
|
||
|
|
||
|
if ! elf || ! is_elf(elf)
|
||
|
$stderr.puts 'This program takes one arguments that should be an elf file.'
|
||
|
exit 1
|
||
|
end
|
||
|
|
||
|
run_scanelf(elf) do | lib |
|
||
|
puts lib
|
||
|
puts "\t" + get_pkg_of_lib(lib)
|
||
|
end
|