moved most of config.h into SConstruct
git-svn-id: https://svn.code.sf.net/p/nsis/code/NSIS/trunk@4237 212acab6-be3b-0410-9dea-997c60f758d6
This commit is contained in:
parent
86ccf99b80
commit
d736ad8ce6
4 changed files with 19 additions and 225 deletions
19
SConstruct
19
SConstruct
|
@ -67,26 +67,35 @@ from time import strftime, gmtime
|
|||
cvs_version = strftime('%d-%b-%Y.cvs', gmtime())
|
||||
|
||||
opts = Options()
|
||||
|
||||
# version
|
||||
opts.Add(('VERSION', 'Version of NSIS', cvs_version))
|
||||
opts.Add(('VER_MAJOR', 'Major version of NSIS (recommended for dist-installer)', None))
|
||||
opts.Add(('VER_MINOR', 'Minor version of NSIS (recommended for dist-installer)', None))
|
||||
opts.Add(('VER_REVISION', 'Revision of NSIS (recommended for dist-installer)', None))
|
||||
opts.Add(('VER_BUILD', 'Build version of NSIS (recommended for dist-installer)', None))
|
||||
# installation
|
||||
opts.Add(PathOption('PREFIX', 'Installation prefix', None))
|
||||
opts.Add(BoolOption('MSTOOLKIT', 'Use Microsoft Visual C++ Toolkit', 'no'))
|
||||
opts.Add(BoolOption('DEBUG', 'Build executables with debugging information', 'no'))
|
||||
opts.Add(BoolOption('CHMDOCS', 'Build CHM documentation, requires hhc.exe', hhc))
|
||||
opts.Add(PathOption('CPPPATH', 'Path to search for include files', None))
|
||||
opts.Add(PathOption('LIBPATH', 'Path to search for libraries', None))
|
||||
opts.Add(ListOption('SKIPSTUBS', 'A list of stubs that will not be built', 'none', stubs))
|
||||
opts.Add(ListOption('SKIPPLUGINS', 'A list of plug-ins that will not be built', 'none', plugins))
|
||||
opts.Add(ListOption('SKIPUTILS', 'A list of utilities that will not be built', 'none', utils))
|
||||
opts.Add(ListOption('SKIPMISC', 'A list of plug-ins that will not be built', 'none', misc))
|
||||
# build tools
|
||||
opts.Add(BoolOption('MSTOOLKIT', 'Use Microsoft Visual C++ Toolkit', 'no'))
|
||||
opts.Add(BoolOption('CHMDOCS', 'Build CHM documentation, requires hhc.exe', hhc))
|
||||
opts.Add(PathOption('CPPPATH', 'Path to search for include files', None))
|
||||
opts.Add(PathOption('LIBPATH', 'Path to search for libraries', None))
|
||||
# build options
|
||||
opts.Add(BoolOption('DEBUG', 'Build executables with debugging information', 'no'))
|
||||
opts.Add(PathOption('CODESIGNER', 'A program used to sign executables', None))
|
||||
|
||||
opts.Update(defenv)
|
||||
|
||||
Help(opts.GenerateHelpText(defenv))
|
||||
|
||||
# build configuration
|
||||
SConscript('SCons/config.py')
|
||||
|
||||
######################################################################
|
||||
####### Functions ###
|
||||
######################################################################
|
||||
|
|
|
@ -66,6 +66,10 @@ for lib in libs:
|
|||
|
||||
conf.Finish()
|
||||
|
||||
##### Configuration defines
|
||||
|
||||
env.Append(CPPDEFINES = env['NSIS_CPPDEFINES'])
|
||||
|
||||
##### Set PCH
|
||||
|
||||
# XXX doesn't work
|
||||
|
|
|
@ -50,6 +50,7 @@ Import('env compression solid_compression')
|
|||
|
||||
env.Append(CPPDEFINES = ['EXEHEAD'])
|
||||
env.Append(CPPDEFINES = ['WIN32_LEAN_AND_MEAN'])
|
||||
env.Append(CPPDEFINES = env['NSIS_CPPDEFINES'])
|
||||
|
||||
if compression == 'bzip2':
|
||||
env.Append(CPPDEFINES = ['NSIS_COMPRESS_USE_BZIP2'])
|
||||
|
|
|
@ -3,226 +3,6 @@
|
|||
|
||||
#ifndef APSTUDIO_INVOKED // keep msdev's resource editor from mangling the .rc file
|
||||
|
||||
// NSIS_MAX_STRLEN defines the maximum string length for internal variables
|
||||
// and stack entries. 1024 should be plenty, but if you are doing crazy registry
|
||||
// shit, you might want to bump it up. Generally it adds about 16-32x the memory,
|
||||
// so setting this to 4096 from 1024 will add around 64k of memory usage (not
|
||||
// really a big deal, but not usually needed).
|
||||
#define NSIS_MAX_STRLEN 1024
|
||||
|
||||
// NSIS_MAX_INST_TYPES define the maximum install types.
|
||||
// note that this should not exceed 32, ever.
|
||||
#define NSIS_MAX_INST_TYPES 32
|
||||
|
||||
// NSIS_DEFAULT_LANG defines the default language id NSIS will use if nothing
|
||||
// else is defined in the script. Default value is 1033 which is English.
|
||||
#define NSIS_DEFAULT_LANG 1033
|
||||
|
||||
// NSIS_CONFIG_UNINSTALL_SUPPORT enables the uninstaller
|
||||
// support. Comment it out if your installers don't need
|
||||
// uninstallers
|
||||
// adds less than 1kb.
|
||||
#define NSIS_CONFIG_UNINSTALL_SUPPORT
|
||||
|
||||
// NSIS_CONFIG_LICENSEPAGE enables support for the installer to
|
||||
// present a license page.
|
||||
#define NSIS_CONFIG_LICENSEPAGE
|
||||
|
||||
// NSIS_CONFIG_COMPONENTPAGE enables support for the installer to
|
||||
// present a page where you can select what sections are installed.
|
||||
// with this disabled, all sections are installed.
|
||||
#define NSIS_CONFIG_COMPONENTPAGE
|
||||
|
||||
// NSIS_CONFIG_COMPONENTPAGE_ALTERNATIVE enables an alternative
|
||||
// components page behavior. Checkboxes will only be toggled when
|
||||
// clicking on the checkbox itself and not on its label.
|
||||
// .onMouseOverSection will only be called when the user selects
|
||||
// the component and not when moving the mouse pointer over it.
|
||||
// NOT ENABLED BY DEFAULT.
|
||||
// #define NSIS_CONFIG_COMPONENTPAGE_ALTERNATIVE
|
||||
|
||||
// NSIS_CONFIG_SILENT_SUPPORT enables support for making installers
|
||||
// that are completely silent.
|
||||
#define NSIS_CONFIG_SILENT_SUPPORT
|
||||
|
||||
// NSIS_CONFIG_VISIBLE_SUPPORT enables support for making installers
|
||||
// that are visible.
|
||||
#define NSIS_CONFIG_VISIBLE_SUPPORT
|
||||
|
||||
// NSIS_CONFIG_ENHANCEDUI_SUPPORT enables support for CreateFont,
|
||||
// SetCtlColors (used by some UIs), SetBrandingImage, .onGUIInit, etc
|
||||
#define NSIS_CONFIG_ENHANCEDUI_SUPPORT
|
||||
|
||||
// NSIS_CONFIG_COMPRESSION_SUPPORT enables support for making installers
|
||||
// that use compression (recommended).
|
||||
#define NSIS_CONFIG_COMPRESSION_SUPPORT
|
||||
// compression specific options
|
||||
|
||||
// if NSIS_COMPRESS_BZIP2_SMALLMODE is defined, bzip2's decompressor uses
|
||||
// bzip2's alternative decompression method that uses less runtime
|
||||
// memory, at the expense of speed (and executable size). not recommended.
|
||||
// #define NSIS_COMPRESS_BZIP2_SMALLMODE
|
||||
|
||||
// if NSIS_COMPRESS_BZIP2_LEVEL is defined, it overrides the default bzip2
|
||||
// compression window size of 9 (1-9 is valid)
|
||||
// 9 uses the most memory, but typically compresses best (recommended).
|
||||
// 1 uses the least memory, but typically compresses the worst.
|
||||
#define NSIS_COMPRESS_BZIP2_LEVEL 9
|
||||
|
||||
|
||||
// NSIS_CONFIG_CRC_SUPPORT enables support for installer verification.
|
||||
// HIGHLY recommended.
|
||||
#define NSIS_CONFIG_CRC_SUPPORT
|
||||
|
||||
// NSIS_CONFIG_CRC_ANAL makes the CRC verification extremely careful, meaning
|
||||
// extra bytes on the end of file, or the first 512 bytes changing, will give
|
||||
// error. Enable this if you are paranoid, otherwise leaving it off seems safe
|
||||
// (and is less prone to reporting virii). If you will be digitally signing your
|
||||
// installers, leave this off (the default).
|
||||
// #define NSIS_CONFIG_CRC_ANAL
|
||||
|
||||
|
||||
// NSIS_CONFIG_LOG enables the logging facility.
|
||||
// turning this on (by uncommenting it) adds about
|
||||
// 4kb, but can be useful in debugging your installers.
|
||||
// NOT ENABLED BY DEFAULT.
|
||||
// #define NSIS_CONFIG_LOG
|
||||
|
||||
// NSIS_CONFIG_LOG_ODS makes the logging facility
|
||||
// use OutputDebugString instead of a file.
|
||||
// NOT ENABLED BY DEFAULT.
|
||||
// #define NSIS_CONFIG_LOG_ODS
|
||||
|
||||
// NSIS_SUPPORT_BGBG enables support for the blue (well, whatever
|
||||
// color you want) gradient background window.
|
||||
#define NSIS_SUPPORT_BGBG
|
||||
|
||||
|
||||
// NSIS_SUPPORT_CODECALLBACKS enables support for installer code callbacks.
|
||||
// recommended, as it uses a minimum of space and allows for neat functionality.
|
||||
#define NSIS_SUPPORT_CODECALLBACKS
|
||||
|
||||
|
||||
// NSIS_SUPPORT_MOVEONREBOOT enables support for uninstallers that automatically
|
||||
// delete themselves from the temp directory, as well as the reboot moving/deleting
|
||||
// modes of Delete and Rename. Adds about 512 gay bytes..
|
||||
#define NSIS_SUPPORT_MOVEONREBOOT
|
||||
|
||||
/////////////// the following are instruction enabling defines ///////////////
|
||||
|
||||
// NSIS_SUPPORT_ACTIVEXREG enables activeX plug-in registration
|
||||
// and deregistration, as well as CallInstDLL
|
||||
#define NSIS_SUPPORT_ACTIVEXREG
|
||||
|
||||
// NSIS_SUPPORT_INTOPTS enables support for IntCmp, IntCmpU, IntOp, and IntFmt.
|
||||
#define NSIS_SUPPORT_INTOPTS
|
||||
|
||||
// NSIS_SUPPORT_STROPTS enables support for StrCmp, StrCpy, and StrLen, as well as Get*Local.
|
||||
#define NSIS_SUPPORT_STROPTS
|
||||
|
||||
// NSIS_SUPPORT_STACK enables support for the stack (Push, Pop, Exch)
|
||||
#define NSIS_SUPPORT_STACK
|
||||
|
||||
// NSIS_SUPPORT_FILEFUNCTIONS enables support for FileOpen,FileClose, FileSeek, FileRead, and FileWrite.
|
||||
#define NSIS_SUPPORT_FILEFUNCTIONS
|
||||
|
||||
// NSIS_SUPPORT_FINDFIRST enables support for FindFirst, FindNext, and FindClose.
|
||||
#define NSIS_SUPPORT_FINDFIRST
|
||||
|
||||
// NSIS_SUPPORT_CREATESHORTCUT enables support for CreateShortCut.
|
||||
#define NSIS_SUPPORT_CREATESHORTCUT
|
||||
|
||||
// NSIS_SUPPORT_INIFILES enables support for ReadINIStr and WriteINIStr.
|
||||
#define NSIS_SUPPORT_INIFILES
|
||||
|
||||
// NSIS_SUPPORT_REGISTRYFUNCTIONS enables support for ReadRegStr, ReadRegDWORD, WriteRegStr, etc etc etc.
|
||||
#define NSIS_SUPPORT_REGISTRYFUNCTIONS
|
||||
|
||||
// NSIS_SUPPORT_COPYFILES enables support for CopyFiles
|
||||
#define NSIS_SUPPORT_COPYFILES
|
||||
|
||||
// NSIS_SUPPORT_REBOOT enables support for Reboot, IfRebootFlag, SetRebootFlag
|
||||
#define NSIS_SUPPORT_REBOOT
|
||||
|
||||
// NSIS_SUPPORT_FNUTIL enables support for GetFullPathName, GetTempFileName, and SearchPath
|
||||
#define NSIS_SUPPORT_FNUTIL
|
||||
|
||||
// NSIS_SUPPORT_EXECUTE enables support for Exec and ExecWait
|
||||
#define NSIS_SUPPORT_EXECUTE
|
||||
|
||||
// NSIS_SUPPORT_SHELLEXECUTE enables support for ExecShell
|
||||
#define NSIS_SUPPORT_SHELLEXECUTE
|
||||
|
||||
// NSIS_SUPPORT_GETDLLVERSION enables support for GetDLLVersion
|
||||
#define NSIS_SUPPORT_GETDLLVERSION
|
||||
|
||||
// NSIS_SUPPORT_GETFILETIME enables support for GetFileTime
|
||||
#define NSIS_SUPPORT_GETFILETIME
|
||||
|
||||
// NSIS_SUPPORT_HWNDS enables support for FindWindow, SendMessage, and IsWindow
|
||||
#define NSIS_SUPPORT_HWNDS
|
||||
|
||||
// NSIS_SUPPORT_ENVIRONMENT enables support for ReadEnvStr and ExpandEnvStrings
|
||||
#define NSIS_SUPPORT_ENVIRONMENT
|
||||
|
||||
// NSIS_SUPPORT_RMDIR enables support for RMDir
|
||||
#define NSIS_SUPPORT_RMDIR
|
||||
|
||||
// NSIS_SUPPORT_FILE enables support for File (extracting files)
|
||||
#define NSIS_SUPPORT_FILE
|
||||
|
||||
// NSIS_SUPPORT_DELETE enables support for Delete (delete files)
|
||||
#define NSIS_SUPPORT_DELETE
|
||||
|
||||
// NSIS_SUPPORT_RENAME enables support for Rename (rename files)
|
||||
#define NSIS_SUPPORT_RENAME
|
||||
|
||||
// NSIS_SUPPORT_MESSAGEBOX enables support for MessageBox
|
||||
#define NSIS_SUPPORT_MESSAGEBOX
|
||||
|
||||
// Added by ramon 5 jun 2003
|
||||
// NSIS_SUPPORT_VERSION_INFO enables support for version information on final exe
|
||||
#define NSIS_SUPPORT_VERSION_INFO
|
||||
|
||||
// NSIS_FIX_DEFINES_IN_STRINGS fixes defines inside defines and handles chars $ perfectly
|
||||
// #define NSIS_FIX_DEFINES_IN_STRINGS
|
||||
|
||||
// NSIS_SUPPORT_STANDARD_PREDEFINES enables standard predefines in NSIS.
|
||||
// The defines enabled are:
|
||||
// __FILE__ - current script name
|
||||
// __LINE__ - current line number
|
||||
// __DATE__ - date according to the current locale
|
||||
// __TIME__ - time according to the current locale
|
||||
// __TIMESTAMP__ - date & time according to the current locale
|
||||
#define NSIS_SUPPORT_STANDARD_PREDEFINES
|
||||
|
||||
#define NSIS_LOCKWINDOW_SUPPORT
|
||||
|
||||
// Added by Ximon Eighteen 5th August 2002
|
||||
// If this is uncommented the following changes/new features are
|
||||
// turned on :-
|
||||
// - At the start of compilation a directory called dlls in
|
||||
// the directory where makensis.exe is running from will be
|
||||
// scanned for .dll files.
|
||||
// - Any functions in the detected dll files that are exported
|
||||
// by name will be remembered. These names are then legal
|
||||
// command keywords in an NSIS script.
|
||||
// - Any command that is unrecognised is checked against the
|
||||
// list of external dll command names. If matched the dll will
|
||||
// be packed into the installer.
|
||||
// - On the installer machine (rather than the build machine)
|
||||
// on first use of a command that requires a plugin dll that
|
||||
// dll will be extracted to the temporary directory with a
|
||||
// temporary file name.
|
||||
// - Any parameters following the command will be pushed onto
|
||||
// the stack in left to right order.
|
||||
// - The command will then be invoked in the dll as if
|
||||
// "CallInstDLL dll command" had been invoked.
|
||||
// - When the installer exits any extracted temporary dlls will
|
||||
// be deleted.
|
||||
#define NSIS_CONFIG_PLUGIN_SUPPORT
|
||||
|
||||
// fixes - do not edit past here
|
||||
#ifndef NSIS_CONFIG_VISIBLE_SUPPORT
|
||||
#ifdef NSIS_CONFIG_LICENSEPAGE
|
||||
#undef NSIS_CONFIG_LICENSEPAGE
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue