9 Commits

Author SHA1 Message Date
Wesley Shields
b867946050 Implement relocations.
This still needs testing.
2013-11-30 22:44:30 -05:00
Wesley Shields
5e86f97c96 Implement a bunch of parsed attributes.
These are all the things the dump-prog pulls out already.
2013-11-30 22:21:10 -05:00
Wesley Shields
7abab7bd2e Implement imports and exports.
Might as well do some general cleanup too:

Rename the len attribute of a section to length.

The section, import and export callbacks return 0 on success and anything else
on failure.

Whitespace fixes.

Fix a bunch of copy/paste mistakes in the test script.
2013-11-30 21:36:05 -05:00
Wesley Shields
2083f6f358 Sections are now their own type.
Do not return a list of dictionaries from get_sections(). Now it returns a
list of section objects, which expose the information via attributes.
2013-11-29 23:32:32 -05:00
Wesley Shields
b4ad87819e Support section, symbols and characteristics.
While here, make it easier to extend by providing macros to eliminate
the mundane that goes into writing getset members.
2013-11-29 21:56:12 -05:00
Wesley Shields
860fbff4e4 Don't store parsed values in python objects.
Convert the PyObject pointers used inside pepy_parsed into their corresponding
native types and use those. Teach the members array to return them accordingly.

While here might as well add support for signature and machine values.

Also, convert test.py to have shorter output by not using pprint.
2013-11-29 14:28:39 -05:00
Wesley Shields
b816e1cbf9 Remove unused import. 2013-11-29 14:12:37 -05:00
Wesley Shields
ed77443f31 Implement timedatestamp member.
While here, DECREF the string used in init. Also, make a note that I really
want to use a bytearray instead of a list for get_bytes().
2013-11-29 14:11:01 -05:00
Wesley Shields
14e2848aa2 Add a test file that uses the bindings. 2013-11-27 15:53:20 -05:00