1
0
mirror of https://github.com/cookiengineer/audacity synced 2025-06-15 07:40:23 +02:00

Make it easier to enforce the requirement that module version string exactly matches Audacity version string, by directly including Audacity.h and using AUDACITY_VERSION_STRING.

This commit is contained in:
v.audacity 2011-03-14 02:22:41 +00:00
parent 98182821d6
commit 6b6b495021
2 changed files with 7 additions and 16 deletions

View File

@ -13,6 +13,7 @@
#include <wx/wx.h>
#include "ScripterCallback.h"
//#include "../lib_widget_extra/ShuttleGuiBase.h"
#include "../../src/Audacity.h"
#include "../../src/ShuttleGui.h"
#ifdef NOT_DEFINED
@ -177,7 +178,12 @@ int SCRIPT_PIPE_DLL_API ExtensionModuleInit(int ix)
wxString SCRIPT_PIPE_DLL_API GetVersionString()
{
return SCRIPT_PIPE_VERSION_STRING;
// Make sure that this version of the module requires the version
// of Audacity it is built with.
// For now, the versions must match exactly for Audacity to
// agree to load the module.
return AUDACITY_VERSION_STRING;
}
} // End extern "C"

View File

@ -37,18 +37,3 @@
#endif
#endif
// This should be set to the version of Audacity that this version of
// mod-scipt-pipe is designed to work with. For now, the versions must match
// exactly for Audacity to agree to load the module.
#define SCRIPT_PIPE_VERSION 1
#define SCRIPT_PIPE_RELEASE 3
#define SCRIPT_PIPE_REVISION 10
#define SCRIPT_PIPE_SUFFIX wxT("-alpha-") __TDATE__
#define SCRIPT_PIPE_MAKESTR( x ) #x
#define SCRIPT_PIPE_QUOTE( x ) SCRIPT_PIPE_MAKESTR( x )
#define SCRIPT_PIPE_VERSION_STRING wxT( SCRIPT_PIPE_QUOTE( SCRIPT_PIPE_VERSION ) ) wxT(".") \
wxT( SCRIPT_PIPE_QUOTE( SCRIPT_PIPE_RELEASE ) ) wxT(".") \
wxT( SCRIPT_PIPE_QUOTE( SCRIPT_PIPE_REVISION ) ) \
SCRIPT_PIPE_SUFFIX