Methods
Instance Public methods
each_export(objs)
Link
# File win32/mkexports.rb, line 105 def each_export(objs) noprefix = ($arch ||= nil and /^(sh|i\d86)/ !~ $arch) objs = objs.collect {|s| s.tr('/', '\')} filetype = nil objdump(objs) do |l| if (filetype = l[/^File Type: (.+)/, 1])..(/^\f/ =~ l) case filetype when /OBJECT/, /LIBRARY/ next if /^[[:xdigit:]]+ 0+ UNDEF / =~ l next unless /External/ =~ l next unless l.sub!(/.*?\s(\(\)\s+)?External\s+\|\s+/, '') is_data = !$1 if noprefix or /^[@_]/ =~ l next if /(?!^)@.*@/ =~ l || /@[[:xdigit:]]{8,32}$/ =~ l || /^_?(?:Init_|.*_threadptr_|DllMain\b)/ =~ l l.sub!(/^[@_]/, '') if /@\d+$/ !~ l elsif !l.sub!(/^(\S+) \([^@?\`\]*\)$/, '\1') next end when /DLL/ next unless l.sub!(/^\s*\d+\s+[[:xdigit:]]+\s+[[:xdigit:]]+\s+/, '') else next end yield l.strip, is_data end end yield "strcasecmp", "msvcrt.stricmp" yield "strncasecmp", "msvcrt.strnicmp" end