| 1 | #! /usr/bin/env python
|
|---|
| 2 | """nm2def.py
|
|---|
| 3 |
|
|---|
| 4 | Helpers to extract symbols from Unix libs and auto-generate
|
|---|
| 5 | Windows definition files from them. Depends on nm(1). Tested
|
|---|
| 6 | on Linux and Solaris only (-p option to nm is for Solaris only).
|
|---|
| 7 |
|
|---|
| 8 | By Marc-Andre Lemburg, Aug 1998.
|
|---|
| 9 |
|
|---|
| 10 | Additional notes: the output of nm is supposed to look like this:
|
|---|
| 11 |
|
|---|
| 12 | acceler.o:
|
|---|
| 13 | 000001fd T PyGrammar_AddAccelerators
|
|---|
| 14 | U PyGrammar_FindDFA
|
|---|
| 15 | 00000237 T PyGrammar_RemoveAccelerators
|
|---|
| 16 | U _IO_stderr_
|
|---|
| 17 | U exit
|
|---|
| 18 | U fprintf
|
|---|
| 19 | U free
|
|---|
| 20 | U malloc
|
|---|
| 21 | U printf
|
|---|
| 22 |
|
|---|
| 23 | grammar1.o:
|
|---|
| 24 | 00000000 T PyGrammar_FindDFA
|
|---|
| 25 | 00000034 T PyGrammar_LabelRepr
|
|---|
| 26 | U _PyParser_TokenNames
|
|---|
|
|---|