Linux server.edchosting.com 4.18.0-553.79.1.lve.el7h.x86_64 #1 SMP Wed Oct 15 16:34:46 UTC 2025 x86_64
LiteSpeed
Server IP : 75.98.162.185 & Your IP : 216.73.216.163
Domains :
Cant Read [ /etc/named.conf ]
User : goons4good
Terminal
Auto Root
Create File
Create Folder
Localroot Suggester
Backdoor Destroyer
Readme
/
lib64 /
python2.7 /
site-packages /
numpy /
distutils /
Delete
Unzip
Name
Size
Permission
Date
Action
command
[ DIR ]
drwxr-xr-x
2021-09-16 10:54
fcompiler
[ DIR ]
drwxr-xr-x
2021-09-16 10:54
mingw
[ DIR ]
drwxr-xr-x
2021-09-16 10:54
tests
[ DIR ]
drwxr-xr-x
2021-09-16 10:54
__config__.py
1.55
KB
-rw-r--r--
2018-04-10 19:40
__config__.pyc
1.69
KB
-rw-r--r--
2018-04-10 19:40
__config__.pyo
1.69
KB
-rw-r--r--
2018-04-10 19:40
__init__.py
991
B
-rw-r--r--
2013-04-07 01:04
__init__.pyc
1001
B
-rw-r--r--
2018-04-10 19:40
__init__.pyo
1001
B
-rw-r--r--
2018-04-10 19:40
__version__.py
85
B
-rw-r--r--
2013-04-07 01:04
__version__.pyc
286
B
-rw-r--r--
2018-04-10 19:40
__version__.pyo
286
B
-rw-r--r--
2018-04-10 19:40
ccompiler.py
22.27
KB
-rw-r--r--
2013-04-07 01:04
ccompiler.pyc
19.94
KB
-rw-r--r--
2018-04-10 19:40
ccompiler.pyo
19.94
KB
-rw-r--r--
2018-04-10 19:40
compat.py
151
B
-rw-r--r--
2013-04-07 01:04
compat.pyc
474
B
-rw-r--r--
2018-04-10 19:40
compat.pyo
474
B
-rw-r--r--
2018-04-10 19:40
conv_template.py
9.4
KB
-rw-r--r--
2013-04-07 01:04
conv_template.pyc
9.37
KB
-rw-r--r--
2018-04-10 19:40
conv_template.pyo
9.37
KB
-rw-r--r--
2018-04-10 19:40
core.py
8.34
KB
-rw-r--r--
2013-04-07 01:04
core.pyc
6.34
KB
-rw-r--r--
2018-04-10 19:40
core.pyo
6.34
KB
-rw-r--r--
2018-04-10 19:40
cpuinfo.py
22.2
KB
-rw-r--r--
2013-04-07 01:04
cpuinfo.pyc
42.92
KB
-rw-r--r--
2018-04-10 19:40
cpuinfo.pyo
42.92
KB
-rw-r--r--
2018-04-10 19:40
environment.py
2.23
KB
-rw-r--r--
2013-04-07 01:04
environment.pyc
3.29
KB
-rw-r--r--
2018-04-10 19:40
environment.pyo
3.29
KB
-rw-r--r--
2018-04-10 19:40
exec_command.py
18.79
KB
-rw-r--r--
2013-04-07 01:04
exec_command.pyc
17.42
KB
-rw-r--r--
2018-04-10 19:40
exec_command.pyo
16.02
KB
-rw-r--r--
2018-04-10 19:40
extension.py
2.92
KB
-rw-r--r--
2013-04-07 01:04
extension.pyc
2.41
KB
-rw-r--r--
2018-04-10 19:40
extension.pyo
2.41
KB
-rw-r--r--
2018-04-10 19:40
from_template.py
7.62
KB
-rw-r--r--
2013-04-07 01:04
from_template.pyc
8.19
KB
-rw-r--r--
2018-04-10 19:40
from_template.pyo
8.19
KB
-rw-r--r--
2018-04-10 19:40
info.py
92
B
-rw-r--r--
2013-04-07 01:04
info.pyc
266
B
-rw-r--r--
2018-04-10 19:40
info.pyo
266
B
-rw-r--r--
2018-04-10 19:40
intelccompiler.py
1.67
KB
-rw-r--r--
2013-04-07 01:04
intelccompiler.pyc
2.18
KB
-rw-r--r--
2018-04-10 19:40
intelccompiler.pyo
2.18
KB
-rw-r--r--
2018-04-10 19:40
interactive.py
6
KB
-rw-r--r--
2013-04-07 01:04
interactive.pyc
5.64
KB
-rw-r--r--
2018-04-10 19:40
interactive.pyo
5.64
KB
-rw-r--r--
2018-04-10 19:40
lib2def.py
3.34
KB
-rw-r--r--
2013-04-07 01:04
lib2def.pyc
3.76
KB
-rw-r--r--
2018-04-10 19:40
lib2def.pyo
3.76
KB
-rw-r--r--
2018-04-10 19:40
line_endings.py
1.92
KB
-rw-r--r--
2013-04-07 01:04
line_endings.pyc
2.67
KB
-rw-r--r--
2018-04-10 19:40
line_endings.pyo
2.67
KB
-rw-r--r--
2018-04-10 19:40
log.py
2.53
KB
-rw-r--r--
2013-04-07 01:04
log.pyc
2.88
KB
-rw-r--r--
2018-04-10 19:40
log.pyo
2.88
KB
-rw-r--r--
2018-04-10 19:40
mingw32ccompiler.py
21.95
KB
-rw-r--r--
2013-04-07 01:04
mingw32ccompiler.pyc
16.39
KB
-rw-r--r--
2018-04-10 19:40
mingw32ccompiler.pyo
16.32
KB
-rw-r--r--
2018-04-10 19:40
misc_util.py
83.4
KB
-rw-r--r--
2013-04-07 01:04
misc_util.pyc
79.01
KB
-rw-r--r--
2018-04-10 19:40
misc_util.pyo
78.41
KB
-rw-r--r--
2018-04-10 19:40
npy_pkg_config.py
13.32
KB
-rw-r--r--
2013-04-07 01:04
npy_pkg_config.pyc
15.28
KB
-rw-r--r--
2018-04-10 19:40
npy_pkg_config.pyo
15.28
KB
-rw-r--r--
2018-04-10 19:40
numpy_distribution.py
634
B
-rw-r--r--
2013-04-07 01:04
numpy_distribution.pyc
981
B
-rw-r--r--
2018-04-10 19:40
numpy_distribution.pyo
981
B
-rw-r--r--
2018-04-10 19:40
pathccompiler.py
713
B
-rw-r--r--
2013-04-07 01:04
pathccompiler.pyc
1.08
KB
-rw-r--r--
2018-04-10 19:40
pathccompiler.pyo
1.08
KB
-rw-r--r--
2018-04-10 19:40
setup.py
561
B
-rw-r--r--
2013-04-07 01:04
setup.pyc
862
B
-rw-r--r--
2018-04-10 19:40
setup.pyo
862
B
-rw-r--r--
2018-04-10 19:40
setupscons.py
557
B
-rw-r--r--
2013-04-07 01:04
setupscons.pyc
905
B
-rw-r--r--
2018-04-10 19:40
setupscons.pyo
905
B
-rw-r--r--
2018-04-10 19:40
site.cfg
124
B
-rw-r--r--
2018-04-10 19:39
system_info.py
72.83
KB
-rw-r--r--
2013-04-07 01:04
system_info.pyc
70.07
KB
-rw-r--r--
2018-04-10 19:40
system_info.pyo
69.94
KB
-rw-r--r--
2018-04-10 19:40
unixccompiler.py
3.94
KB
-rw-r--r--
2013-04-07 01:04
unixccompiler.pyc
3.21
KB
-rw-r--r--
2018-04-10 19:40
unixccompiler.pyo
3.21
KB
-rw-r--r--
2018-04-10 19:40
Save
Rename
import re import sys import os import subprocess __doc__ = """This module generates a DEF file from the symbols in an MSVC-compiled DLL import library. It correctly discriminates between data and functions. The data is collected from the output of the program nm(1). Usage: python lib2def.py [libname.lib] [output.def] or python lib2def.py [libname.lib] > output.def libname.lib defaults to python<py_ver>.lib and output.def defaults to stdout Author: Robert Kern <kernr@mail.ncifcrf.gov> Last Update: April 30, 1999 """ __version__ = '0.1a' py_ver = "%d%d" % tuple(sys.version_info[:2]) DEFAULT_NM = 'nm -Cs' DEF_HEADER = """LIBRARY python%s.dll ;CODE PRELOAD MOVEABLE DISCARDABLE ;DATA PRELOAD SINGLE EXPORTS """ % py_ver # the header of the DEF file FUNC_RE = re.compile(r"^(.*) in python%s\.dll" % py_ver, re.MULTILINE) DATA_RE = re.compile(r"^_imp__(.*) in python%s\.dll" % py_ver, re.MULTILINE) def parse_cmd(): """Parses the command-line arguments. libfile, deffile = parse_cmd()""" if len(sys.argv) == 3: if sys.argv[1][-4:] == '.lib' and sys.argv[2][-4:] == '.def': libfile, deffile = sys.argv[1:] elif sys.argv[1][-4:] == '.def' and sys.argv[2][-4:] == '.lib': deffile, libfile = sys.argv[1:] else: print "I'm assuming that your first argument is the library" print "and the second is the DEF file." elif len(sys.argv) == 2: if sys.argv[1][-4:] == '.def': deffile = sys.argv[1] libfile = 'python%s.lib' % py_ver elif sys.argv[1][-4:] == '.lib': deffile = None libfile = sys.argv[1] else: libfile = 'python%s.lib' % py_ver deffile = None return libfile, deffile def getnm(nm_cmd = ['nm', '-Cs', 'python%s.lib' % py_ver]): """Returns the output of nm_cmd via a pipe. nm_output = getnam(nm_cmd = 'nm -Cs py_lib')""" f = subprocess.Popen(nm_cmd, shell=True, stdout=subprocess.PIPE) nm_output = f.stdout.read() f.stdout.close() return nm_output def parse_nm(nm_output): """Returns a tuple of lists: dlist for the list of data symbols and flist for the list of function symbols. dlist, flist = parse_nm(nm_output)""" data = DATA_RE.findall(nm_output) func = FUNC_RE.findall(nm_output) flist = [] for sym in data: if sym in func and (sym[:2] == 'Py' or sym[:3] == '_Py' or sym[:4] == 'init'): flist.append(sym) dlist = [] for sym in data: if sym not in flist and (sym[:2] == 'Py' or sym[:3] == '_Py'): dlist.append(sym) dlist.sort() flist.sort() return dlist, flist def output_def(dlist, flist, header, file = sys.stdout): """Outputs the final DEF file to a file defaulting to stdout. output_def(dlist, flist, header, file = sys.stdout)""" for data_sym in dlist: header = header + '\t%s DATA\n' % data_sym header = header + '\n' # blank line for func_sym in flist: header = header + '\t%s\n' % func_sym file.write(header) if __name__ == '__main__': libfile, deffile = parse_cmd() if deffile is None: deffile = sys.stdout else: deffile = open(deffile, 'w') nm_cmd = [str(DEFAULT_NM), str(libfile)] nm_output = getnm(nm_cmd) dlist, flist = parse_nm(nm_output) output_def(dlist, flist, DEF_HEADER, deffile)