Fix test for Python 3 compat.
Add existential check for DT_SYMTAB.
Fix the logic when DT_SYMTAB is at the end of segment.

It was assumed that DT_SYMTAB would reside in the same segment as
PT_DYNAMIC. That is not the case. DT_SYMTAB resides in some PT_LOAD
segment. This commit finds the correct segment that houses DT_SYMTAB.
Make "Dynamic.get_table_offset" a public API.