From f216eb9a6da69db8b9545effb27796116166d5ec Mon Sep 17 00:00:00 2001 From: "elias.bachaalany" Date: Tue, 10 Aug 2010 11:44:59 +0000 Subject: [PATCH] - IDAPython 1.4.2: should work now with Python 2.7 - Hide the Python plugin from the plugins menu (it already installs the run statement functionality in the File menu) --- build.py | 2 +- python.cpp | 12 +++++++----- python/init.py | 2 +- 3 files changed, 9 insertions(+), 7 deletions(-) diff --git a/build.py b/build.py index 852a0ea..e82a48c 100644 --- a/build.py +++ b/build.py @@ -36,7 +36,7 @@ else: # IDAPython version VERSION_MAJOR = 1 VERSION_MINOR = 4 -VERSION_PATCH = 1 +VERSION_PATCH = 2 # Determine Python version PYTHON_MAJOR_VERSION = int(platform.python_version()[0]) diff --git a/python.cpp b/python.cpp index ad882c0..2ae2820 100644 --- a/python.cpp +++ b/python.cpp @@ -55,6 +55,12 @@ static const char S_IDC_RUNPYTHON_STATEMENT[] = "RunPythonStatement"; static const char S_HOTKEY_RUNSTATEMENT[] = "Alt-8"; static const char S_IDAPYTHON_DATA_NODE[] = "IDAPython_Data"; +#ifdef PLUGINFIX + #define PLUGIN_FLAGS PLUGIN_FIX +#else + #define PLUGIN_FLAGS 0 +#endif + //------------------------------------------------------------------------- // Types @@ -1389,11 +1395,7 @@ void idaapi run(int arg) plugin_t PLUGIN = { IDP_INTERFACE_VERSION, -#ifdef PLUGINFIX - PLUGIN_FIX, // plugin flags -#else - 0, // plugin flags -#endif + PLUGIN_FLAGS | PLUGIN_HIDE, // plugin flags init, // initialize term, // terminate. this pointer may be NULL. run, // invoke plugin diff --git a/python/init.py b/python/init.py index 6402ac3..53d7873 100644 --- a/python/init.py +++ b/python/init.py @@ -56,7 +56,7 @@ def runscript(script): # ----------------------------------------------------------------------- def print_banner(): banner = [ - "Python %d.%d.%d %s (serial %d) (c) 1990-2010 Python Software Foundation" % sys.version_info, + "Python %s " % sys.version, "IDAPython" + (" 64-bit" if __EA64__ else "") + " v%d.%d.%d %s (serial %d) (c) The IDAPython Team " % IDAPYTHON_VERSION ] sepline = '-' * (max([len(s) for s in banner])+1)