[0.1.x] + version string

git-svn-id: https://pykd.svn.codeplex.com/svn@73229 9b283d60-5439-405e-af05-b73fd8c4d996
This commit is contained in:
SND\EreTIk_cp 2012-01-16 13:31:04 +00:00 committed by Mikhail I. Izmestev
parent 153766deb4
commit cee9b7f13d
5 changed files with 28 additions and 3 deletions

View File

@ -18,11 +18,16 @@
#include "dbgmem.h" #include "dbgmem.h"
#include "intbase.h" #include "intbase.h"
#include "process.h" #include "process.h"
#include "pykdver.h"
using namespace pykd; using namespace pykd;
//////////////////////////////////////////////////////////////////////////////// ////////////////////////////////////////////////////////////////////////////////
static const std::string pykdVersion = PYKD_VERSION_BUILD;
////////////////////////////////////////////////////////////////////////////////
BOOL WINAPI DllMain( BOOL WINAPI DllMain(
__in HINSTANCE /*hinstDLL*/, __in HINSTANCE /*hinstDLL*/,
__in DWORD fdwReason, __in DWORD fdwReason,
@ -99,6 +104,8 @@ BOOST_PYTHON_MEMBER_FUNCTION_OVERLOADS( pyDia_Symbol_findChildrenEx, pyDia::Symb
BOOST_PYTHON_MODULE( pykd ) BOOST_PYTHON_MODULE( pykd )
{ {
python::scope().attr("version") = pykdVersion;
python::class_<intBase>( "intBase", "intBase", python::no_init ) python::class_<intBase>( "intBase", "intBase", python::no_init )
.def( python::init<python::object&>() ) .def( python::init<python::object&>() )
.def( "__eq__", &intBase::eq ) .def( "__eq__", &intBase::eq )

View File

@ -8,6 +8,7 @@
// Generated from the TEXTINCLUDE 2 resource. // Generated from the TEXTINCLUDE 2 resource.
// //
#include "afxres.h" #include "afxres.h"
#include "pykdver.h"
///////////////////////////////////////////////////////////////////////////// /////////////////////////////////////////////////////////////////////////////
#undef APSTUDIO_READONLY_SYMBOLS #undef APSTUDIO_READONLY_SYMBOLS
@ -70,11 +71,11 @@ BEGIN
BLOCK "041904b0" BLOCK "041904b0"
BEGIN BEGIN
VALUE "FileDescription", "pykd - python extension for windbg" VALUE "FileDescription", "pykd - python extension for windbg"
VALUE "FileVersion", "0, 1, 0, 5" VALUE "FileVersion", PYKD_VERSION_BUILD
VALUE "InternalName", "pykd" VALUE "InternalName", "pykd"
VALUE "OriginalFilename", "pykd.dll" VALUE "OriginalFilename", "pykd.dll"
VALUE "ProductName", "pykd - python extension for windbg" VALUE "ProductName", "pykd - python extension for windbg"
VALUE "ProductVersion", "0, 1, 0, 5" VALUE "ProductVersion", PYKD_VERSION_BUILD
END END
END END
BLOCK "VarFileInfo" BLOCK "VarFileInfo"

View File

@ -563,6 +563,10 @@
RelativePath=".\pyaux.h" RelativePath=".\pyaux.h"
> >
</File> </File>
<File
RelativePath=".\pykdver.h"
>
</File>
<File <File
RelativePath=".\resource.h" RelativePath=".\resource.h"
> >

9
pykd/pykdver.h Normal file
View File

@ -0,0 +1,9 @@
#define __VER_STR2__(x) #x
#define __VER_STR1__(x) __VER_STR2__(x)
#define PYKD_VERSION_MAJOR 1
#define PYKD_VERSION_MINOR 5
#define PYKD_VERSION_BUILD \
"0." __VER_STR1__(PYKD_VERSION_MAJOR) ".0." __VER_STR1__(PYKD_VERSION_MINOR)

View File

@ -51,10 +51,12 @@ def getTestSuite( singleName = "" ):
if __name__ == "__main__": if __name__ == "__main__":
print "\nTesting PyKd " + pykd.version
target.appPath = sys.argv[1] target.appPath = sys.argv[1]
target.moduleName = os.path.splitext(os.path.basename(target.appPath))[0] target.moduleName = os.path.splitext(os.path.basename(target.appPath))[0]
print "\nTest module: %s" % target.appPath print "Test module: %s" % target.appPath
pykd.startProcess( target.appPath ) pykd.startProcess( target.appPath )
@ -63,6 +65,8 @@ if __name__ == "__main__":
pykd.go() pykd.go()
print ""
suite = getTestSuite() suite = getTestSuite()
#suite = getTestSuite( "typedvar.TypedVarTest.testBitField" ) #suite = getTestSuite( "typedvar.TypedVarTest.testBitField" )
#suite = getTestSuite( "typeinfo.TypeInfoTest.testBitField" ) #suite = getTestSuite( "typeinfo.TypeInfoTest.testBitField" )