9 pyexecpath
= os
.path
.realpath(sys
.executable
)
10 pkgsetuppy
= os
.path
.realpath("."+os
.path
.sep
+"setup.py")
11 pypkgenlistp
= subprocess
.Popen(
12 [pyexecpath
, pkgsetuppy
, "getversioninfo"], stdout
=subprocess
.PIPE
, stderr
=subprocess
.PIPE
)
13 pypkgenout
, pypkgenerr
= pypkgenlistp
.communicate()
14 if(sys
.version
[0] == "3"):
15 pypkgenout
= pypkgenout
.decode('utf-8')
16 pyconfiginfo
= json
.loads(pypkgenout
)