mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-08-16 00:19:32 +02:00
IDE: compiler options: replaced obsolete -S mode flags with -M flag
git-svn-id: trunk@16144 -
This commit is contained in:
parent
12518f5618
commit
1e87ce80b9
@ -504,7 +504,7 @@ procedure SaveXMLCompileReasons(const AConfig: TXMLConfig; const APath: String;
|
||||
implementation
|
||||
|
||||
const
|
||||
CompilerOptionsVersion = 5;
|
||||
CompilerOptionsVersion = 6;
|
||||
Config_Filename = 'compileroptions.xml';
|
||||
|
||||
function ParseString(Options: TParsedCompilerOptions;
|
||||
@ -1070,18 +1070,28 @@ begin
|
||||
p:=Path+'Parsing/SyntaxOptions/'
|
||||
else
|
||||
p:=Path+'SymantecChecking/';
|
||||
Delphi2Extensions := XMLConfigFile.GetValue(p+'D2Extensions/Value', true);
|
||||
if FileVersion<5 then begin
|
||||
if XMLConfigFile.GetValue(p+'D2Extensions/Value', true) then
|
||||
FSyntaxMode:='ObjFPC';
|
||||
if XMLConfigFile.GetValue(p+'TPCompatible/Value', false) then
|
||||
FSyntaxMode:='TP';
|
||||
if XMLConfigFile.GetValue(p+'DelphiCompat/Value', false) then
|
||||
FSyntaxMode:='Delphi';
|
||||
if XMLConfigFile.GetValue(p+'GPCCompat/Value', false) then
|
||||
FSyntaxMode:='GPC';
|
||||
end else begin
|
||||
FSyntaxMode:=XMLConfigFile.GetValue(p+'SyntaxMode/Value', '');
|
||||
if FSyntaxMode='' then
|
||||
FSyntaxMode:='ObjFPC';
|
||||
end;
|
||||
CStyleOperators := XMLConfigFile.GetValue(p+'CStyleOperator/Value', true);
|
||||
IncludeAssertionCode := XMLConfigFile.GetValue(p+'IncludeAssertionCode/Value', false);
|
||||
AllowLabel := XMLConfigFile.GetValue(p+'AllowLabel/Value', true);
|
||||
CPPInline := XMLConfigFile.GetValue(p+'CPPInline/Value', true);
|
||||
CStyleMacros := XMLConfigFile.GetValue(p+'CStyleMacros/Value', false);
|
||||
TPCompatible := XMLConfigFile.GetValue(p+'TPCompatible/Value', false);
|
||||
InitConstructor := XMLConfigFile.GetValue(p+'InitConstructor/Value', false);
|
||||
StaticKeyword := XMLConfigFile.GetValue(p+'StaticKeyword/Value', false);
|
||||
DelphiCompat := XMLConfigFile.GetValue(p+'DelphiCompat/Value', false);
|
||||
UseAnsiStrings := XMLConfigFile.GetValue(p+'UseAnsiStrings/Value', false);
|
||||
GPCCompat := XMLConfigFile.GetValue(p+'GPCCompat/Value', false);
|
||||
|
||||
{ CodeGeneration }
|
||||
p:=Path+'CodeGeneration/';
|
||||
@ -1221,19 +1231,16 @@ begin
|
||||
|
||||
{ Syntax Options }
|
||||
p:=Path+'Parsing/SyntaxOptions/';
|
||||
XMLConfigFile.SetDeleteValue(p+'D2Extensions/Value', Delphi2Extensions,true);
|
||||
XMLConfigFile.SetDeleteValue(p+'SyntaxMode/Value', SyntaxMode,'ObjFPC');
|
||||
XMLConfigFile.SetDeleteValue(p+'CStyleOperator/Value', CStyleOperators,true);
|
||||
XMLConfigFile.SetDeleteValue(p+'IncludeAssertionCode/Value', IncludeAssertionCode,false);
|
||||
XMLConfigFile.SetDeleteValue(p+'AllowLabel/Value', AllowLabel,true);
|
||||
XMLConfigFile.SetDeleteValue(p+'CPPInline/Value', CPPInline,true);
|
||||
XMLConfigFile.SetDeleteValue(p+'CStyleMacros/Value', CStyleMacros,false);
|
||||
XMLConfigFile.SetDeleteValue(p+'TPCompatible/Value', TPCompatible,false);
|
||||
XMLConfigFile.SetDeleteValue(p+'InitConstructor/Value', InitConstructor,false);
|
||||
XMLConfigFile.SetDeleteValue(p+'StaticKeyword/Value', StaticKeyword,false);
|
||||
XMLConfigFile.SetDeleteValue(p+'DelphiCompat/Value', DelphiCompat,false);
|
||||
XMLConfigFile.SetDeleteValue(p+'UseAnsiStrings/Value', UseAnsiStrings,false);
|
||||
XMLConfigFile.SetDeleteValue(p+'GPCCompat/Value', GPCCompat,false);
|
||||
|
||||
|
||||
{ CodeGeneration }
|
||||
p:=Path+'CodeGeneration/';
|
||||
XMLConfigFile.SetDeleteValue(p+'SmartLinkUnit/Value', SmartLinkUnit,false);
|
||||
@ -1731,6 +1738,8 @@ end;
|
||||
const MainSourceFilename: string;
|
||||
Globals: TGlobalCompilerOptions;
|
||||
Flags: TCompilerCmdLineOptions): String;
|
||||
|
||||
Get all the options and create a string that can be passed to the compiler
|
||||
------------------------------------------------------------------------------}
|
||||
function TBaseCompilerOptions.MakeOptionsString(
|
||||
const MainSourceFilename: string; Globals: TGlobalCompilerOptions;
|
||||
@ -1756,147 +1765,210 @@ begin
|
||||
|
||||
switches := '';
|
||||
|
||||
{ Get all the options and create a string that can be passed to the compiler }
|
||||
|
||||
{ options of fpc 1.1 :
|
||||
{ options of fpc 2.2.2 :
|
||||
|
||||
put + after a boolean switch option to enable it, - to disable it
|
||||
-a the compiler doesn't delete the generated assembler file
|
||||
-al list sourcecode lines in assembler file
|
||||
-ar list register allocation/release info in assembler file
|
||||
-at list temp allocation/release info in assembler file
|
||||
-b generate browser info
|
||||
-bl generate local symbol info
|
||||
-B build all modules
|
||||
-C<x> code generation options:
|
||||
-CD create also dynamic library (not supported)
|
||||
Put + after a boolean switch option to enable it, - to disable it
|
||||
-a The compiler doesn't delete the generated assembler file
|
||||
-al List sourcecode lines in assembler file
|
||||
-an List node info in assembler file
|
||||
-ap Use pipes instead of creating temporary assembler files
|
||||
-ar List register allocation/release info in assembler file
|
||||
-at List temp allocation/release info in assembler file
|
||||
-A<x> Output format:
|
||||
-Adefault Use default assembler
|
||||
-Aas Assemble using GNU AS
|
||||
-Anasmcoff COFF (Go32v2) file using Nasm
|
||||
-Anasmelf ELF32 (Linux) file using Nasm
|
||||
-Anasmwin32Win32 object file using Nasm
|
||||
-AnasmwdosxWin32/WDOSX object file using Nasm
|
||||
-Awasm Obj file using Wasm (Watcom)
|
||||
-Anasmobj Obj file using Nasm
|
||||
-Amasm Obj file using Masm (Microsoft)
|
||||
-Atasm Obj file using Tasm (Borland)
|
||||
-Aelf ELF (Linux) using internal writer
|
||||
-Acoff COFF (Go32v2) using internal writer
|
||||
-Apecoff PE-COFF (Win32) using internal writer
|
||||
-b Generate browser info
|
||||
-bl Generate local symbol info
|
||||
-B Build all modules
|
||||
-C<x> Code generation options:
|
||||
-Cc<x> Set default calling convention to <x>
|
||||
-CD Create also dynamic library (not supported)
|
||||
-Ce Compilation with emulated floating point opcodes
|
||||
-Cf<x> Select fpu instruction set to use, see fpc -i for possible values
|
||||
-CF<x> Minimal floating point constant precision (default, 32, 64)
|
||||
-Cg Generate PIC code
|
||||
-Ch<n> <n> bytes heap (between 1023 and 67107840)
|
||||
-Ci IO-checking
|
||||
-Cn omit linking stage
|
||||
-Co check overflow of integer operations
|
||||
-Cr range checking
|
||||
-CR verify object method call validity
|
||||
-Cs<n> set stack size to <n>
|
||||
-Ct stack checking
|
||||
-CX create also smartlinked library
|
||||
-d<x> defines the symbol <x>
|
||||
-e<x> set path to executable
|
||||
-E same as -Cn
|
||||
-F<x> set file names and paths:
|
||||
-FD<x> sets the directory where to search for compiler utilities
|
||||
-Fe<x> redirect error output to <x>
|
||||
-FE<x> set exe/unit output path to <x>
|
||||
-Fi<x> adds <x> to include path
|
||||
-Fl<x> adds <x> to library path
|
||||
-FL<x> uses <x> as dynamic linker
|
||||
-Fo<x> adds <x> to object path
|
||||
-Fr<x> load error message file <x>
|
||||
-Fu<x> adds <x> to unit path
|
||||
-FU<x> set unit output path to <x>, overrides -FE
|
||||
-g generate debugger information:
|
||||
-gg use gsym
|
||||
-gd use dbx
|
||||
-gh use heap trace unit (for memory leak debugging)
|
||||
-gl use line info unit to show more info for backtraces
|
||||
-gc generate checks for pointers
|
||||
-i information
|
||||
-iD return compiler date
|
||||
-iV return compiler version
|
||||
-iSO return compiler OS
|
||||
-iSP return compiler processor
|
||||
-iTO return target OS
|
||||
-iTP return target processor
|
||||
-I<x> adds <x> to include path
|
||||
-Cn Omit linking stage
|
||||
-Co Check overflow of integer operations
|
||||
-CO Check for possible overflow of integer operations
|
||||
-Cp<x> Select instruction set, see fpc -i for possible values
|
||||
-CP<x>=<y> packing settings
|
||||
-CPPACKSET=<y> <y> set allocation: 0, 1 or DEFAULT or NORMAL, 2, 4 and 8
|
||||
-Cr Range checking
|
||||
-CR Verify object method call validity
|
||||
-Cs<n> Set stack size to <n>
|
||||
-Ct Stack checking
|
||||
-CX Create also smartlinked library
|
||||
-d<x> Defines the symbol <x>
|
||||
-D Generate a DEF file
|
||||
-Dd<x> Set description to <x>
|
||||
-Dv<x> Set DLL version to <x>
|
||||
-e<x> Set path to executable
|
||||
-E Same as -Cn
|
||||
-fPIC Same as -Cg
|
||||
-F<x> Set file names and paths:
|
||||
-Fa<x>[,y] (for a program) load units <x> and [y] before uses is parsed
|
||||
-Fc<x> Set input codepage to <x>
|
||||
-FC<x> Set RC compiler binary name to <x>
|
||||
-FD<x> Set the directory where to search for compiler utilities
|
||||
-Fe<x> Redirect error output to <x>
|
||||
-Ff<x> Add <x> to framework path (Darwin only)
|
||||
-FE<x> Set exe/unit output path to <x>
|
||||
-Fi<x> Add <x> to include path
|
||||
-Fl<x> Add <x> to library path
|
||||
-FL<x> Use <x> as dynamic linker
|
||||
-Fm<x> Load unicode conversion table from <x>.txt in the compiler dir
|
||||
-Fo<x> Add <x> to object path
|
||||
-Fr<x> Load error message file <x>
|
||||
-FR<x> Set resource (.res) linker to <x>
|
||||
-Fu<x> Add <x> to unit path
|
||||
-FU<x> Set unit output path to <x>, overrides -FE
|
||||
-g Generate debug information (default format for target)
|
||||
-gc Generate checks for pointers
|
||||
-gh Use heaptrace unit (for memory leak/corruption debugging)
|
||||
-gl Use line info unit (show more info with backtraces)
|
||||
-go<x> Set debug information options
|
||||
-godwarfsets Enable Dwarf set debug information (breaks gdb < 6.5)
|
||||
-gp Preserve case in stabs symbol names
|
||||
-gs Generate stabs debug information
|
||||
-gt Trash local variables (to detect uninitialized uses)
|
||||
-gv Generates programs traceable with valgrind
|
||||
-gw Generate dwarf-2 debug information (same as -gw2)
|
||||
-gw2 Generate dwarf-2 debug information
|
||||
-gw3 Generate dwarf-3 debug information
|
||||
-i Information
|
||||
-iD Return compiler date
|
||||
-iV Return short compiler version
|
||||
-iW Return full compiler version
|
||||
-iSO Return compiler OS
|
||||
-iSP Return compiler host processor
|
||||
-iTO Return target OS
|
||||
-iTP Return target processor
|
||||
-I<x> Add <x> to include path
|
||||
-k<x> Pass <x> to the linker
|
||||
-l write logo
|
||||
-n don't read the default config file
|
||||
-o<x> change the name of the executable produced to <x>
|
||||
-pg generate profile code for gprof (defines FPC_PROFILE)
|
||||
-P use pipes instead of creating temporary assembler files
|
||||
-S<x> syntax options:
|
||||
-S2 switch some Delphi 2 extensions on
|
||||
-Sc supports operators like C (*=,+=,/= and -=)
|
||||
-Sa include assertion code.
|
||||
-Sd tries to be Delphi compatible
|
||||
-Se<x> compiler stops after the <x> errors (default is 1)
|
||||
-Sg allow LABEL and GOTO
|
||||
-Sh Use ansistrings
|
||||
-Si support C++ styled INLINE
|
||||
-Sm support macros like C (global)
|
||||
-So tries to be TP/BP 7.0 compatible
|
||||
-Sp tries to be gpc compatible
|
||||
-Ss constructor name must be init (destructor must be done)
|
||||
-St allow static keyword in objects
|
||||
-s don't call assembler and linker (only with -a)
|
||||
-st Generate script to link on target
|
||||
-l Write logo
|
||||
-M<x> Set language mode to <x>
|
||||
-Mfpc Free Pascal dialect (default)
|
||||
-Mobjfpc FPC mode with Object Pascal support
|
||||
-Mdelphi Delphi 7 compatibility mode
|
||||
-Mtp TP/BP 7.0 compatibility mode
|
||||
-Mmacpas Macintosh Pascal dialects compatibility mode
|
||||
-n Do not read the default config files
|
||||
-N<x> Node tree optimizations
|
||||
-Nu Unroll loops
|
||||
-o<x> Change the name of the executable produced to <x>
|
||||
-O<x> Optimizations:
|
||||
-O- Disable optimizations
|
||||
-O1 Level 1 optimizations (quick and debugger friendly)
|
||||
-O2 Level 2 optimizations (-O1 + quick optimizations)
|
||||
-O3 Level 3 optimizations (-O2 + slow optimizations)
|
||||
-Oa<x>=<y> Set alignment
|
||||
-Oo[NO]<x> Enable or disable optimizations, see fpc -i for possible values
|
||||
-Op<x> Set target cpu for optimizing, see fpc -i for possible values
|
||||
-Os Optimize for size rather than speed
|
||||
-pg Generate profile code for gprof (defines FPC_PROFILE)
|
||||
-R<x> Assembler reading style:
|
||||
-Rdefault Use default assembler for target
|
||||
-Ratt Read AT&T style assembler
|
||||
-Rintel Read Intel style assembler
|
||||
-S<x> Syntax options:
|
||||
-S2 Same as -Mobjfpc
|
||||
-Sc Support operators like C (*=,+=,/= and -=)
|
||||
-Sa Turn on assertions
|
||||
-Sd Same as -Mdelphi
|
||||
-Se<x> Error options. <x> is a combination of the following:
|
||||
<n> : Compiler halts after the <n> errors (default is 1)
|
||||
w : Compiler also halts after warnings
|
||||
n : Compiler also halts after notes
|
||||
h : Compiler also halts after hints
|
||||
-Sg Enable LABEL and GOTO (default in -Mtp and -Mdelphi)
|
||||
-Sh Use ansistrings by default instead of shortstrings
|
||||
-Si Turn on inlining of procedures/functions declared as "inline"
|
||||
-Sk Load fpcylix unit
|
||||
-SI<x> Set interface style to <x>
|
||||
-SIcom COM compatible interface (default)
|
||||
-SIcorba CORBA compatible interface
|
||||
-Sm Support macros like C (global)
|
||||
-So Same as -Mtp
|
||||
-Ss Constructor name must be init (destructor must be done)
|
||||
-St Allow static keyword in objects
|
||||
-Sx Enable exception keywords (default in Delphi/ObjFPC modes)
|
||||
-s Do not call assembler and linker
|
||||
-sh Generate script to link on host
|
||||
-u<x> undefines the symbol <x>
|
||||
-U unit options:
|
||||
-Un don't check the unit name
|
||||
-Ur generate release unit files
|
||||
-Us compile a system unit
|
||||
-st Generate script to link on target
|
||||
-sr Skip register allocation phase (use with -alr)
|
||||
-T<x> Target operating system:
|
||||
-Temx OS/2 via EMX (including EMX/RSX extender)
|
||||
-Tfreebsd FreeBSD
|
||||
-Tgo32v2 Version 2 of DJ Delorie DOS extender
|
||||
-Tlinux Linux
|
||||
-Tnetbsd NetBSD
|
||||
-Tnetware Novell Netware Module (clib)
|
||||
-Tnetwlibc Novell Netware Module (libc)
|
||||
-Topenbsd OpenBSD
|
||||
-Tos2 OS/2 / eComStation
|
||||
-Tsunos SunOS/Solaris
|
||||
-Tsymbian Symbian OS
|
||||
-Twatcom Watcom compatible DOS extender
|
||||
-Twdosx WDOSX DOS extender
|
||||
-Twin32 Windows 32 Bit
|
||||
-Twince Windows CE
|
||||
-u<x> Undefines the symbol <x>
|
||||
-U Unit options:
|
||||
-Un Do not check where the unit name matches the file name
|
||||
-Ur Generate release unit files (never automatically recompiled)
|
||||
-Us Compile a system unit
|
||||
-v<x> Be verbose. <x> is a combination of the following letters:
|
||||
e : Show errors (default) d : Show debug info
|
||||
e : Show errors (default) 0 : Show nothing (except errors)
|
||||
w : Show warnings u : Show unit info
|
||||
n : Show notes t : Show tried/used files
|
||||
h : Show hints m : Show defined macros
|
||||
i : Show general info p : Show compiled procedures
|
||||
l : Show linenumbers c : Show conditionals
|
||||
a : Show everything 0 : Show nothing (except errors)
|
||||
b : Show all procedure r : Rhide/GCC compatibility mode
|
||||
declarations if an error x : Executable info (Win32 only)
|
||||
occurs
|
||||
-V write fpcdebug.txt file with lots of debugging info
|
||||
-X executable options:
|
||||
-Xc link with the c library
|
||||
-Xs strip all symbols from executable
|
||||
-XD try to link dynamic (defines FPC_LINK_DYNAMIC)
|
||||
-XS try to link static (default) (defines FPC_LINK_STATIC)
|
||||
-XX try to link smart (defines FPC_LINK_SMART)
|
||||
h : Show hints c : Show conditionals
|
||||
i : Show general info d : Show debug info
|
||||
l : Show linenumbers r : Rhide/GCC compatibility mode
|
||||
a : Show everything x : Executable info (Win32 only)
|
||||
b : Write file names messages with full path
|
||||
v : Write fpcdebug.txt with p : Write tree.log with parse tree
|
||||
lots of debugging info
|
||||
-W<x> Target-specific options (targets)
|
||||
-Wb Create a bundle instead of a library (Darwin)
|
||||
-WB Create a relocatable image (Windows)
|
||||
-WC Specify console type application (EMX, OS/2, Windows)
|
||||
-WD Use DEFFILE to export functions of DLL or EXE (Windows)
|
||||
-WF Specify full-screen type application (EMX, OS/2)
|
||||
-WG Specify graphic type application (EMX, OS/2, Windows)
|
||||
-WN Do not generate relocation code, needed for debugging (Windows)
|
||||
-WR Generate relocation code (Windows)
|
||||
-X Executable options:
|
||||
-Xc Pass --shared/-dynamic to the linker (BeOS, Darwin, FreeBSD, Linux)
|
||||
-Xd Do not use standard library search path (needed for cross compile)
|
||||
-Xe Use external linker
|
||||
-Xg Create debuginfo in a separate file and add a debuglink section to executable
|
||||
-XD Try to link units dynamically (defines FPC_LINK_DYNAMIC)
|
||||
-Xi Use internal linker
|
||||
-Xm Generate link map
|
||||
-XM<x> Set the name of the 'main' program routine (default is 'main')
|
||||
-XP<x> Prepend the binutils names with the prefix <x>
|
||||
-Xr<x> Set library search path to <x> (needed for cross compile) (BeOS, Linux)
|
||||
-XR<x> Prepend <x> to all linker search paths (BeOS, Darwin, FreeBSD, Linux, Mac OS, Solaris)
|
||||
-Xs Strip all symbols from executable
|
||||
-XS Try to link units statically (default, defines FPC_LINK_STATIC)
|
||||
-Xt Link with static libraries (-static is passed to linker)
|
||||
-XX Try to smartlink units (defines FPC_LINK_SMART)
|
||||
|
||||
Processor specific options:
|
||||
-A<x> output format:
|
||||
-Aas assemble using GNU AS
|
||||
-Anasmcoff coff (Go32v2) file using Nasm
|
||||
-Anasmelf elf32 (Linux) file using Nasm
|
||||
-Anasmobj obj file using Nasm
|
||||
-Amasm obj file using Masm (Microsoft)
|
||||
-Atasm obj file using Tasm (Borland)
|
||||
-Acoff coff (Go32v2) using internal writer
|
||||
-Apecoff pecoff (Win32) using internal writer
|
||||
-R<x> assembler reading style:
|
||||
-Ratt read AT&T style assembler
|
||||
-Rintel read Intel style assembler
|
||||
-Rdirect copy assembler text directly to assembler file
|
||||
-O<x> optimizations:
|
||||
-Og generate smaller code
|
||||
-OG generate faster code (default)
|
||||
-Or keep certain variables in registers
|
||||
-Ou enable uncertain optimizations (see docs)
|
||||
-O1 level 1 optimizations (quick optimizations)
|
||||
-O2 level 2 optimizations (-O1 + slower optimizations)
|
||||
-O3 level 3 optimizations (-O2 repeatedly, max 5 times)
|
||||
-Op<x> target processor:
|
||||
-Op1 set target processor to 386/486
|
||||
-Op2 set target processor to Pentium/PentiumMMX (tm)
|
||||
-Op3 set target processor to PPro/PII/c6x86/K6 (tm)
|
||||
-T<x> Target operating system:
|
||||
-TGO32V2 version 2 of DJ Delorie DOS extender
|
||||
- 3*2TWDOSX DOS 32 Bit Extender
|
||||
-TLINUX Linux
|
||||
-Tnetware Novell Netware Module (experimental)
|
||||
-TOS2 OS/2 2.x
|
||||
-TSUNOS SunOS/Solaris
|
||||
-TWin32 Windows 32 Bit
|
||||
-W<x> Win32 target options
|
||||
-WB<x> Set Image base to Hexadecimal <x> value
|
||||
-WC Specify console type application
|
||||
-WD Use DEFFILE to export functions of DLL or EXE
|
||||
-WF Specify full-screen type application (OS/2 only)
|
||||
-WG Specify graphic type application
|
||||
-WN Do not generate relocation code (necessary for debugging)
|
||||
-WR Generate relocation code
|
||||
-? Show this help
|
||||
-h Shows this help without waiting
|
||||
}
|
||||
|
||||
|
||||
@ -1910,55 +1982,10 @@ Processor specific options:
|
||||
3: switches := switches + '-Rdirect';
|
||||
end;
|
||||
|
||||
{ Syntax Options
|
||||
|
||||
-S2 switch some Delphi 2 extensions on
|
||||
-Sc supports operators like C (*=,+=,/= and -=)
|
||||
-sa include assertion code.
|
||||
-Sd tries to be Delphi compatible
|
||||
-Se<x> compiler stops after the <x> errors (default is 1)
|
||||
-Sg allow LABEL and GOTO
|
||||
-Sh Use ansistrings
|
||||
-Si support C++ styled INLINE
|
||||
-Sm support macros like C (global)
|
||||
-So tries to be TP/BP 7.0 compatible
|
||||
-Sp tries to be gpc compatible
|
||||
-Ss constructor name must be init (destructor must be done)
|
||||
-St allow static keyword in objects
|
||||
|
||||
}
|
||||
tempsw := '';
|
||||
|
||||
if (Delphi2Extensions) then
|
||||
tempsw := tempsw + '2';
|
||||
if (CStyleOperators) then
|
||||
tempsw := tempsw + 'c';
|
||||
if (IncludeAssertionCode) then
|
||||
tempsw := tempsw + 'a';
|
||||
if (DelphiCompat) then
|
||||
tempsw := tempsw + 'd';
|
||||
if (AllowLabel) then
|
||||
tempsw := tempsw + 'g';
|
||||
if (UseAnsiStrings) then
|
||||
tempsw := tempsw + 'h';
|
||||
if (CPPInline) then
|
||||
tempsw := tempsw + 'i';
|
||||
if (CStyleMacros) then
|
||||
tempsw := tempsw + 'm';
|
||||
if (TPCompatible) then
|
||||
tempsw := tempsw + 'o';
|
||||
if (GPCCompat) then
|
||||
tempsw := tempsw + 'p';
|
||||
if (InitConstructor) then
|
||||
tempsw := tempsw + 's';
|
||||
if (StaticKeyword) then
|
||||
tempsw := tempsw + 't';
|
||||
|
||||
if (tempsw <> '') then begin
|
||||
tempsw := '-S' + tempsw;
|
||||
switches := switches + ' ' + tempsw;
|
||||
end;
|
||||
// Syntax Options
|
||||
tempsw:=GetSyntaxOptionsString;
|
||||
if (tempsw <> '') then
|
||||
switches := switches + ' ' + tempsw;
|
||||
|
||||
{ TODO: Implement the following switches. They need to be added
|
||||
to the dialog. }
|
||||
@ -2303,10 +2330,8 @@ var
|
||||
begin
|
||||
{ Syntax Options
|
||||
-S<x> Syntax options:
|
||||
-S2 Same as -Mobjfpc
|
||||
-Sc Support operators like C (*=,+=,/= and -=)
|
||||
-Sa Turn on assertions
|
||||
-Sd Same as -Mdelphi
|
||||
-Se<x> Error options. <x> is a combination of the following:
|
||||
<n> : Compiler halts after the <n> errors (default is 1)
|
||||
w : Compiler also halts after warnings
|
||||
@ -2320,21 +2345,24 @@ begin
|
||||
-SIcom COM compatible interface (default)
|
||||
-SIcorba CORBA compatible interface
|
||||
-Sm Support macros like C (global)
|
||||
-So Same as -Mtp
|
||||
-Ss Constructor name must be init (destructor must be done)
|
||||
-St Allow static keyword in objects
|
||||
-Sx Enable exception keywords (default in Delphi/ObjFPC modes)
|
||||
|
||||
-M<x> Set language mode to <x>
|
||||
-Mfpc Free Pascal dialect (default)
|
||||
-Mobjfpc FPC mode with Object Pascal support
|
||||
-Mdelphi Delphi 7 compatibility mode
|
||||
-Mtp TP/BP 7.0 compatibility mode
|
||||
-Mmacpas Macintosh Pascal dialects compatibility mode
|
||||
|
||||
}
|
||||
tempsw := '';
|
||||
|
||||
if (Delphi2Extensions) then
|
||||
tempsw := tempsw + '2';
|
||||
if (CStyleOperators) then
|
||||
tempsw := tempsw + 'c';
|
||||
if (IncludeAssertionCode) then
|
||||
tempsw := tempsw + 'a';
|
||||
if (DelphiCompat) then
|
||||
tempsw := tempsw + 'd';
|
||||
if (AllowLabel) then
|
||||
tempsw := tempsw + 'g';
|
||||
if (UseAnsiStrings) then
|
||||
@ -2343,10 +2371,6 @@ begin
|
||||
tempsw := tempsw + 'i';
|
||||
if (CStyleMacros) then
|
||||
tempsw := tempsw + 'm';
|
||||
if (TPCompatible) then
|
||||
tempsw := tempsw + 'o';
|
||||
if (GPCCompat) then
|
||||
tempsw := tempsw + 'p';
|
||||
if (InitConstructor) then
|
||||
tempsw := tempsw + 's';
|
||||
if (StaticKeyword) then
|
||||
@ -2356,6 +2380,12 @@ begin
|
||||
Result := '-S' + tempsw
|
||||
else
|
||||
Result:='';
|
||||
|
||||
if SyntaxMode<>'' then begin
|
||||
if Result<>'' then
|
||||
Result:=Result+' ';
|
||||
Result:=Result+'-M'+SyntaxMode;
|
||||
end;
|
||||
end;
|
||||
|
||||
{------------------------------------------------------------------------------
|
||||
@ -2393,20 +2423,17 @@ begin
|
||||
fLCLWidgetType := '';
|
||||
|
||||
// parsing
|
||||
FSyntaxMode:='ObjFPC';
|
||||
fAssemblerStyle := 0;
|
||||
fDelphi2Ext := true;
|
||||
fCStyleOp := true;
|
||||
fIncludeAssertionCode := false;
|
||||
fAllowLabel := true;
|
||||
fCPPInline := true;
|
||||
fCMacros := false;
|
||||
fTPCompat := false;
|
||||
fInitConst := false;
|
||||
fStaticKeyword := false;
|
||||
fDelphiCompat := false;
|
||||
fUseAnsiStr := false;
|
||||
fGPCCompat := false;
|
||||
|
||||
|
||||
// code generation
|
||||
fSmartLinkUnit := false;
|
||||
fIOChecks := false;
|
||||
@ -2497,19 +2524,16 @@ begin
|
||||
DebugPath := CompOpts.DebugPath;
|
||||
|
||||
// Parsing
|
||||
FSyntaxMode := CompOpts.FSyntaxMode;
|
||||
fAssemblerStyle := CompOpts.fAssemblerStyle;
|
||||
fDelphi2Ext := CompOpts.fDelphi2Ext;
|
||||
fCStyleOp := CompOpts.fCStyleOp;
|
||||
fIncludeAssertionCode := CompOpts.fIncludeAssertionCode;
|
||||
fAllowLabel := CompOpts.fAllowLabel;
|
||||
fCPPInline := CompOpts.fCPPInline;
|
||||
fCMacros := CompOpts.fCMacros;
|
||||
fTPCompat := CompOpts.fTPCompat;
|
||||
fInitConst := CompOpts.fInitConst;
|
||||
fStaticKeyword := CompOpts.fStaticKeyword;
|
||||
fDelphiCompat := CompOpts.fDelphiCompat;
|
||||
fUseAnsiStr := CompOpts.fUseAnsiStr;
|
||||
fGPCCompat := CompOpts.fGPCCompat;
|
||||
|
||||
// Code Generation
|
||||
fSmartLinkUnit := CompOpts.SmartLinkUnit;
|
||||
@ -2630,19 +2654,16 @@ begin
|
||||
|
||||
// parsing
|
||||
Tool.Path:='Parsing';
|
||||
Tool.AddDiff('SyntaxMode',FSyntaxMode,CompOpts.FSyntaxMode);
|
||||
Tool.AddDiff('AssemblerStyle',fAssemblerStyle,CompOpts.fAssemblerStyle);
|
||||
Tool.AddDiff('Delphi2Ext',fDelphi2Ext,CompOpts.fDelphi2Ext);
|
||||
Tool.AddDiff('CStyleOp',fCStyleOp,CompOpts.fCStyleOp);
|
||||
Tool.AddDiff('IncludeAssertionCode',fIncludeAssertionCode,CompOpts.fIncludeAssertionCode);
|
||||
Tool.AddDiff('AllowLabel',fAllowLabel,CompOpts.fAllowLabel);
|
||||
Tool.AddDiff('CPPInline',fCPPInline,CompOpts.fCPPInline);
|
||||
Tool.AddDiff('CMacros',fCMacros,CompOpts.fCMacros);
|
||||
Tool.AddDiff('TPCompat',fTPCompat,CompOpts.fTPCompat);
|
||||
Tool.AddDiff('InitConst',fInitConst,CompOpts.fInitConst);
|
||||
Tool.AddDiff('StaticKeyword',fStaticKeyword,CompOpts.fStaticKeyword);
|
||||
Tool.AddDiff('DelphiCompat',fDelphiCompat,CompOpts.fDelphiCompat);
|
||||
Tool.AddDiff('UseAnsiStr',fUseAnsiStr,CompOpts.fUseAnsiStr);
|
||||
Tool.AddDiff('GPCCompat',fGPCCompat,CompOpts.fGPCCompat);
|
||||
|
||||
// code generation
|
||||
Tool.Path:='Code';
|
||||
|
@ -11,7 +11,6 @@ object frmCompilerOptions: TfrmCompilerOptions
|
||||
Constraints.MinHeight = 500
|
||||
Constraints.MinWidth = 600
|
||||
OnClose = frmCompilerOptionsClose
|
||||
OnResize = FormResize
|
||||
Position = poScreenCenter
|
||||
LCLVersion = '0.9.25'
|
||||
object MainNotebook: TNotebook
|
||||
@ -24,13 +23,13 @@ object frmCompilerOptions: TfrmCompilerOptions
|
||||
TabOrder = 0
|
||||
object PathPage: TPage
|
||||
Caption = 'PathPage'
|
||||
ClientWidth = 665
|
||||
ClientHeight = 449
|
||||
ClientWidth = 667
|
||||
ClientHeight = 453
|
||||
object lblOtherUnits: TLabel
|
||||
Left = 6
|
||||
Height = 20
|
||||
Top = 6
|
||||
Width = 653
|
||||
Width = 655
|
||||
Align = alTop
|
||||
BorderSpacing.Left = 6
|
||||
BorderSpacing.Top = 6
|
||||
@ -130,7 +129,7 @@ object frmCompilerOptions: TfrmCompilerOptions
|
||||
Left = 6
|
||||
Height = 23
|
||||
Top = 26
|
||||
Width = 653
|
||||
Width = 655
|
||||
Anchors = [akTop, akLeft, akRight]
|
||||
BorderSpacing.Left = 6
|
||||
BorderSpacing.Right = 6
|
||||
@ -147,7 +146,7 @@ object frmCompilerOptions: TfrmCompilerOptions
|
||||
Left = 6
|
||||
Height = 23
|
||||
Top = 75
|
||||
Width = 653
|
||||
Width = 655
|
||||
Anchors = [akTop, akLeft, akRight]
|
||||
BorderSpacing.Left = 6
|
||||
BorderSpacing.Right = 6
|
||||
@ -164,7 +163,7 @@ object frmCompilerOptions: TfrmCompilerOptions
|
||||
Left = 6
|
||||
Height = 23
|
||||
Top = 124
|
||||
Width = 653
|
||||
Width = 655
|
||||
Anchors = [akTop, akLeft, akRight]
|
||||
BorderSpacing.Left = 6
|
||||
BorderSpacing.Right = 6
|
||||
@ -181,7 +180,7 @@ object frmCompilerOptions: TfrmCompilerOptions
|
||||
Left = 6
|
||||
Height = 23
|
||||
Top = 173
|
||||
Width = 653
|
||||
Width = 655
|
||||
Anchors = [akTop, akLeft, akRight]
|
||||
BorderSpacing.Left = 6
|
||||
BorderSpacing.Right = 6
|
||||
@ -198,7 +197,7 @@ object frmCompilerOptions: TfrmCompilerOptions
|
||||
Left = 6
|
||||
Height = 23
|
||||
Top = 222
|
||||
Width = 653
|
||||
Width = 655
|
||||
Anchors = [akTop, akLeft, akRight]
|
||||
BorderSpacing.Left = 6
|
||||
BorderSpacing.Right = 6
|
||||
@ -215,7 +214,7 @@ object frmCompilerOptions: TfrmCompilerOptions
|
||||
Left = 6
|
||||
Height = 23
|
||||
Top = 271
|
||||
Width = 653
|
||||
Width = 655
|
||||
Anchors = [akTop, akLeft, akRight]
|
||||
BorderSpacing.Left = 6
|
||||
BorderSpacing.Right = 6
|
||||
@ -241,13 +240,13 @@ object frmCompilerOptions: TfrmCompilerOptions
|
||||
end
|
||||
object ParsingPage: TPage
|
||||
Caption = 'ParsingPage'
|
||||
ClientWidth = 665
|
||||
ClientHeight = 449
|
||||
ClientWidth = 667
|
||||
ClientHeight = 453
|
||||
object grpAsmStyle: TRadioGroup
|
||||
Left = 6
|
||||
Height = 40
|
||||
Top = 6
|
||||
Width = 653
|
||||
Width = 655
|
||||
Align = alTop
|
||||
AutoFill = True
|
||||
BorderSpacing.Around = 6
|
||||
@ -267,7 +266,7 @@ object frmCompilerOptions: TfrmCompilerOptions
|
||||
Left = 6
|
||||
Height = 258
|
||||
Top = 52
|
||||
Width = 653
|
||||
Width = 655
|
||||
Align = alTop
|
||||
AutoFill = True
|
||||
BorderSpacing.Around = 6
|
||||
@ -280,14 +279,38 @@ object frmCompilerOptions: TfrmCompilerOptions
|
||||
ChildSizing.ShrinkVertical = crsScaleChilds
|
||||
ChildSizing.Layout = cclLeftToRightThenTopToBottom
|
||||
ChildSizing.ControlsPerLine = 1
|
||||
OnItemClick = grpSyntaxOptionsItemClick
|
||||
TabOrder = 1
|
||||
end
|
||||
object grpSyntaxMode: TGroupBox
|
||||
Left = 6
|
||||
Height = 60
|
||||
Top = 316
|
||||
Width = 655
|
||||
Align = alTop
|
||||
AutoSize = True
|
||||
BorderSpacing.Around = 6
|
||||
Caption = 'grpSyntaxMode'
|
||||
ClientHeight = 41
|
||||
ClientWidth = 651
|
||||
TabOrder = 2
|
||||
object cmbSyntaxMode: TComboBox
|
||||
Left = 6
|
||||
Height = 29
|
||||
Top = 6
|
||||
Width = 337
|
||||
Align = alLeft
|
||||
AutoCompleteText = [cbactEndOfLineComplete, cbactSearchAscending]
|
||||
BorderSpacing.Around = 6
|
||||
MaxLength = 0
|
||||
TabOrder = 0
|
||||
Text = 'cmbSyntaxMode'
|
||||
end
|
||||
end
|
||||
end
|
||||
object CodeGenPage: TPage
|
||||
Caption = 'CodeGenPage'
|
||||
ClientWidth = 665
|
||||
ClientHeight = 449
|
||||
ClientWidth = 667
|
||||
ClientHeight = 453
|
||||
object grpSmartLinkUnit: TGroupBox
|
||||
AnchorSideLeft.Control = grpChecks
|
||||
AnchorSideLeft.Side = asrBottom
|
||||
@ -298,21 +321,21 @@ object frmCompilerOptions: TfrmCompilerOptions
|
||||
Left = 174
|
||||
Height = 53
|
||||
Top = 6
|
||||
Width = 485
|
||||
Width = 487
|
||||
Anchors = [akTop, akLeft, akRight]
|
||||
AutoSize = True
|
||||
BorderSpacing.Left = 6
|
||||
BorderSpacing.Top = 6
|
||||
BorderSpacing.Right = 6
|
||||
Caption = 'grpSmartLinkUnit'
|
||||
ClientHeight = 34
|
||||
ClientWidth = 481
|
||||
ClientHeight = 49
|
||||
ClientWidth = 483
|
||||
TabOrder = 0
|
||||
object chkSmartLinkUnit: TCheckBox
|
||||
Left = 6
|
||||
Height = 22
|
||||
Top = 6
|
||||
Width = 469
|
||||
Width = 471
|
||||
Align = alTop
|
||||
BorderSpacing.Around = 6
|
||||
Caption = 'chkSmartLinkUnit'
|
||||
@ -384,19 +407,19 @@ object frmCompilerOptions: TfrmCompilerOptions
|
||||
Left = 174
|
||||
Height = 54
|
||||
Top = 65
|
||||
Width = 485
|
||||
Width = 487
|
||||
Anchors = [akTop, akLeft, akRight]
|
||||
AutoSize = True
|
||||
BorderSpacing.Around = 6
|
||||
Caption = 'grpHeapSize'
|
||||
ClientHeight = 35
|
||||
ClientWidth = 481
|
||||
ClientHeight = 50
|
||||
ClientWidth = 483
|
||||
TabOrder = 2
|
||||
object edtHeapSize: TEdit
|
||||
Left = 6
|
||||
Height = 23
|
||||
Top = 6
|
||||
Width = 469
|
||||
Width = 471
|
||||
Align = alTop
|
||||
BorderSpacing.Around = 6
|
||||
TabOrder = 0
|
||||
@ -465,13 +488,13 @@ object frmCompilerOptions: TfrmCompilerOptions
|
||||
Left = 148
|
||||
Height = 130
|
||||
Top = 149
|
||||
Width = 511
|
||||
Width = 513
|
||||
Anchors = [akTop, akLeft, akRight]
|
||||
AutoSize = True
|
||||
BorderSpacing.Around = 6
|
||||
Caption = 'grpTargetPlatform'
|
||||
ClientHeight = 111
|
||||
ClientWidth = 507
|
||||
ClientHeight = 126
|
||||
ClientWidth = 509
|
||||
TabOrder = 4
|
||||
object lblTargetOS: TLabel
|
||||
AnchorSideLeft.Control = grpTargetPlatform
|
||||
@ -517,7 +540,7 @@ object frmCompilerOptions: TfrmCompilerOptions
|
||||
Left = 91
|
||||
Height = 29
|
||||
Top = 6
|
||||
Width = 410
|
||||
Width = 412
|
||||
Anchors = [akTop, akLeft, akRight]
|
||||
AutoCompleteText = [cbactEndOfLineComplete, cbactSearchAscending]
|
||||
BorderSpacing.Left = 6
|
||||
@ -536,7 +559,7 @@ object frmCompilerOptions: TfrmCompilerOptions
|
||||
Left = 99
|
||||
Height = 29
|
||||
Top = 41
|
||||
Width = 402
|
||||
Width = 404
|
||||
Anchors = [akTop, akLeft, akRight]
|
||||
AutoCompleteText = [cbactEndOfLineComplete, cbactSearchAscending]
|
||||
BorderSpacing.Left = 6
|
||||
@ -556,7 +579,7 @@ object frmCompilerOptions: TfrmCompilerOptions
|
||||
Left = 127
|
||||
Height = 29
|
||||
Top = 76
|
||||
Width = 374
|
||||
Width = 376
|
||||
Anchors = [akTop, akLeft, akRight]
|
||||
AutoCompleteText = [cbactEndOfLineComplete, cbactSearchAscending]
|
||||
BorderSpacing.Left = 6
|
||||
@ -575,14 +598,14 @@ object frmCompilerOptions: TfrmCompilerOptions
|
||||
AnchorSideBottom.Control = CodeGenPage
|
||||
AnchorSideBottom.Side = asrBottom
|
||||
Left = 6
|
||||
Height = 158
|
||||
Height = 162
|
||||
Top = 285
|
||||
Width = 653
|
||||
Width = 655
|
||||
Anchors = [akTop, akLeft, akRight, akBottom]
|
||||
BorderSpacing.Around = 6
|
||||
Caption = 'grpOptimizations'
|
||||
ClientHeight = 139
|
||||
ClientWidth = 649
|
||||
ClientHeight = 158
|
||||
ClientWidth = 651
|
||||
TabOrder = 5
|
||||
OnResize = grpOptimizationsResize
|
||||
object radOptLevelNone: TRadioButton
|
||||
@ -659,25 +682,25 @@ object frmCompilerOptions: TfrmCompilerOptions
|
||||
end
|
||||
object LinkingPage: TPage
|
||||
Caption = 'LinkingPage'
|
||||
ClientWidth = 665
|
||||
ClientHeight = 449
|
||||
ClientWidth = 667
|
||||
ClientHeight = 453
|
||||
object grpLinkLibraries: TGroupBox
|
||||
Left = 6
|
||||
Height = 53
|
||||
Top = 233
|
||||
Width = 653
|
||||
Width = 655
|
||||
Align = alTop
|
||||
AutoSize = True
|
||||
BorderSpacing.Around = 6
|
||||
Caption = 'grpLinkLibraries'
|
||||
ClientHeight = 34
|
||||
ClientWidth = 649
|
||||
ClientHeight = 49
|
||||
ClientWidth = 651
|
||||
TabOrder = 0
|
||||
object chkLinkSmart: TCheckBox
|
||||
Left = 6
|
||||
Height = 22
|
||||
Top = 6
|
||||
Width = 637
|
||||
Width = 639
|
||||
Align = alTop
|
||||
BorderSpacing.Around = 6
|
||||
Caption = 'chkLinkSmart'
|
||||
@ -688,19 +711,19 @@ object frmCompilerOptions: TfrmCompilerOptions
|
||||
Left = 6
|
||||
Height = 53
|
||||
Top = 292
|
||||
Width = 653
|
||||
Width = 655
|
||||
Align = alTop
|
||||
AutoSize = True
|
||||
BorderSpacing.Around = 6
|
||||
Caption = 'TargetSpecificsGrpBox'
|
||||
ClientHeight = 34
|
||||
ClientWidth = 649
|
||||
ClientHeight = 49
|
||||
ClientWidth = 651
|
||||
TabOrder = 1
|
||||
object chkWin32GraphicApp: TCheckBox
|
||||
Left = 6
|
||||
Height = 22
|
||||
Top = 6
|
||||
Width = 637
|
||||
Width = 639
|
||||
Align = alTop
|
||||
BorderSpacing.Around = 6
|
||||
Caption = 'chkWin32GraphicApp'
|
||||
@ -711,19 +734,19 @@ object frmCompilerOptions: TfrmCompilerOptions
|
||||
Left = 6
|
||||
Height = 82
|
||||
Top = 351
|
||||
Width = 653
|
||||
Width = 655
|
||||
Align = alTop
|
||||
AutoSize = True
|
||||
BorderSpacing.Around = 6
|
||||
Caption = 'grpOptions'
|
||||
ClientHeight = 63
|
||||
ClientWidth = 649
|
||||
ClientHeight = 78
|
||||
ClientWidth = 651
|
||||
TabOrder = 2
|
||||
object chkOptionsLinkOpt: TCheckBox
|
||||
Left = 6
|
||||
Height = 22
|
||||
Top = 6
|
||||
Width = 637
|
||||
Width = 639
|
||||
Align = alTop
|
||||
BorderSpacing.Around = 6
|
||||
Caption = 'chkOptionsLinkOpt'
|
||||
@ -733,7 +756,7 @@ object frmCompilerOptions: TfrmCompilerOptions
|
||||
Left = 6
|
||||
Height = 23
|
||||
Top = 34
|
||||
Width = 637
|
||||
Width = 639
|
||||
Align = alTop
|
||||
BorderSpacing.Around = 6
|
||||
TabOrder = 1
|
||||
@ -744,19 +767,19 @@ object frmCompilerOptions: TfrmCompilerOptions
|
||||
Left = 6
|
||||
Height = 221
|
||||
Top = 6
|
||||
Width = 653
|
||||
Width = 655
|
||||
Align = alTop
|
||||
AutoSize = True
|
||||
BorderSpacing.Around = 6
|
||||
Caption = 'grpDebugging'
|
||||
ClientHeight = 202
|
||||
ClientWidth = 649
|
||||
ClientHeight = 217
|
||||
ClientWidth = 651
|
||||
TabOrder = 3
|
||||
object chkDebugGDB: TCheckBox
|
||||
Left = 6
|
||||
Height = 22
|
||||
Top = 6
|
||||
Width = 637
|
||||
Width = 639
|
||||
Align = alTop
|
||||
BorderSpacing.Around = 6
|
||||
Caption = 'chkDebugGDB'
|
||||
@ -766,7 +789,7 @@ object frmCompilerOptions: TfrmCompilerOptions
|
||||
Left = 6
|
||||
Height = 22
|
||||
Top = 34
|
||||
Width = 637
|
||||
Width = 639
|
||||
Align = alTop
|
||||
BorderSpacing.Around = 6
|
||||
Caption = 'chkDebugDBX'
|
||||
@ -776,7 +799,7 @@ object frmCompilerOptions: TfrmCompilerOptions
|
||||
Left = 6
|
||||
Height = 22
|
||||
Top = 62
|
||||
Width = 637
|
||||
Width = 639
|
||||
Align = alTop
|
||||
BorderSpacing.Around = 6
|
||||
Caption = 'chkUseLineInfoUnit'
|
||||
@ -786,7 +809,7 @@ object frmCompilerOptions: TfrmCompilerOptions
|
||||
Left = 6
|
||||
Height = 22
|
||||
Top = 90
|
||||
Width = 637
|
||||
Width = 639
|
||||
Align = alTop
|
||||
BorderSpacing.Around = 6
|
||||
Caption = 'chkUseHeaptrc'
|
||||
@ -796,7 +819,7 @@ object frmCompilerOptions: TfrmCompilerOptions
|
||||
Left = 6
|
||||
Height = 22
|
||||
Top = 118
|
||||
Width = 637
|
||||
Width = 639
|
||||
Align = alTop
|
||||
BorderSpacing.Around = 6
|
||||
Caption = 'chkUseValgrind'
|
||||
@ -806,7 +829,7 @@ object frmCompilerOptions: TfrmCompilerOptions
|
||||
Left = 6
|
||||
Height = 22
|
||||
Top = 146
|
||||
Width = 637
|
||||
Width = 639
|
||||
Align = alTop
|
||||
BorderSpacing.Around = 6
|
||||
Caption = 'chkGenGProfCode'
|
||||
@ -816,7 +839,7 @@ object frmCompilerOptions: TfrmCompilerOptions
|
||||
Left = 6
|
||||
Height = 22
|
||||
Top = 174
|
||||
Width = 637
|
||||
Width = 639
|
||||
Align = alTop
|
||||
BorderSpacing.Around = 6
|
||||
Caption = 'chkSymbolsStrip'
|
||||
@ -826,13 +849,13 @@ object frmCompilerOptions: TfrmCompilerOptions
|
||||
end
|
||||
object MsgPage: TPage
|
||||
Caption = 'MsgPage'
|
||||
ClientWidth = 665
|
||||
ClientHeight = 449
|
||||
ClientWidth = 667
|
||||
ClientHeight = 453
|
||||
object grpVerbosity: TCheckGroup
|
||||
Left = 6
|
||||
Height = 196
|
||||
Top = 6
|
||||
Width = 653
|
||||
Width = 655
|
||||
Align = alTop
|
||||
AutoFill = True
|
||||
BorderSpacing.Around = 6
|
||||
@ -852,19 +875,19 @@ object frmCompilerOptions: TfrmCompilerOptions
|
||||
Left = 6
|
||||
Height = 54
|
||||
Top = 208
|
||||
Width = 653
|
||||
Width = 655
|
||||
Align = alTop
|
||||
AutoSize = True
|
||||
BorderSpacing.Around = 6
|
||||
Caption = 'grpErrorCnt'
|
||||
ClientHeight = 35
|
||||
ClientWidth = 649
|
||||
ClientHeight = 50
|
||||
ClientWidth = 651
|
||||
TabOrder = 1
|
||||
object edtErrorCnt: TEdit
|
||||
Left = 6
|
||||
Height = 23
|
||||
Top = 6
|
||||
Width = 637
|
||||
Width = 639
|
||||
Align = alTop
|
||||
BorderSpacing.Around = 6
|
||||
TabOrder = 0
|
||||
@ -874,25 +897,25 @@ object frmCompilerOptions: TfrmCompilerOptions
|
||||
end
|
||||
object OtherPage: TPage
|
||||
Caption = 'OtherPage'
|
||||
ClientWidth = 665
|
||||
ClientHeight = 449
|
||||
ClientWidth = 667
|
||||
ClientHeight = 453
|
||||
object grpConfigFile: TGroupBox
|
||||
Left = 6
|
||||
Height = 110
|
||||
Top = 6
|
||||
Width = 653
|
||||
Width = 655
|
||||
Align = alTop
|
||||
AutoSize = True
|
||||
BorderSpacing.Around = 6
|
||||
Caption = 'grpConfigFile'
|
||||
ClientHeight = 91
|
||||
ClientWidth = 649
|
||||
ClientHeight = 106
|
||||
ClientWidth = 651
|
||||
TabOrder = 0
|
||||
object chkConfigFile: TCheckBox
|
||||
Left = 6
|
||||
Height = 22
|
||||
Top = 6
|
||||
Width = 637
|
||||
Width = 639
|
||||
Align = alTop
|
||||
BorderSpacing.Around = 6
|
||||
Caption = 'chkConfigFile'
|
||||
@ -902,7 +925,7 @@ object frmCompilerOptions: TfrmCompilerOptions
|
||||
Left = 6
|
||||
Height = 22
|
||||
Top = 34
|
||||
Width = 637
|
||||
Width = 639
|
||||
Align = alTop
|
||||
BorderSpacing.Around = 6
|
||||
Caption = 'chkCustomConfigFile'
|
||||
@ -913,7 +936,7 @@ object frmCompilerOptions: TfrmCompilerOptions
|
||||
Left = 6
|
||||
Height = 23
|
||||
Top = 62
|
||||
Width = 637
|
||||
Width = 639
|
||||
Align = alTop
|
||||
BorderSpacing.Around = 6
|
||||
TabOrder = 2
|
||||
@ -922,20 +945,20 @@ object frmCompilerOptions: TfrmCompilerOptions
|
||||
end
|
||||
object grpCustomOptions: TGroupBox
|
||||
Left = 6
|
||||
Height = 321
|
||||
Height = 325
|
||||
Top = 122
|
||||
Width = 653
|
||||
Width = 655
|
||||
Align = alClient
|
||||
BorderSpacing.Around = 6
|
||||
Caption = 'grpCustomOptions'
|
||||
ClientHeight = 302
|
||||
ClientWidth = 649
|
||||
ClientHeight = 321
|
||||
ClientWidth = 651
|
||||
TabOrder = 1
|
||||
object memCustomOptions: TMemo
|
||||
Left = 6
|
||||
Height = 290
|
||||
Height = 309
|
||||
Top = 6
|
||||
Width = 637
|
||||
Width = 639
|
||||
Align = alClient
|
||||
BorderSpacing.Around = 6
|
||||
TabOrder = 0
|
||||
@ -944,13 +967,13 @@ object frmCompilerOptions: TfrmCompilerOptions
|
||||
end
|
||||
object InheritedPage: TPage
|
||||
Caption = 'InheritedPage'
|
||||
ClientWidth = 665
|
||||
ClientHeight = 449
|
||||
ClientWidth = 667
|
||||
ClientHeight = 453
|
||||
object InhNoteLabel: TLabel
|
||||
Left = 6
|
||||
Height = 20
|
||||
Top = 6
|
||||
Width = 653
|
||||
Width = 655
|
||||
Align = alTop
|
||||
BorderSpacing.Around = 6
|
||||
Caption = 'InhNoteLabel'
|
||||
@ -960,7 +983,7 @@ object frmCompilerOptions: TfrmCompilerOptions
|
||||
Left = 6
|
||||
Height = 247
|
||||
Top = 32
|
||||
Width = 653
|
||||
Width = 655
|
||||
Align = alTop
|
||||
BorderSpacing.Left = 6
|
||||
BorderSpacing.Right = 6
|
||||
@ -970,9 +993,9 @@ object frmCompilerOptions: TfrmCompilerOptions
|
||||
end
|
||||
object InhItemMemo: TMemo
|
||||
Left = 6
|
||||
Height = 159
|
||||
Height = 163
|
||||
Top = 284
|
||||
Width = 653
|
||||
Width = 655
|
||||
Align = alClient
|
||||
BorderSpacing.Left = 6
|
||||
BorderSpacing.Right = 6
|
||||
@ -985,20 +1008,20 @@ object frmCompilerOptions: TfrmCompilerOptions
|
||||
Cursor = crVSplit
|
||||
Height = 5
|
||||
Top = 279
|
||||
Width = 665
|
||||
Width = 667
|
||||
Align = alTop
|
||||
ResizeAnchor = akTop
|
||||
end
|
||||
end
|
||||
object CompilationPage: TPage
|
||||
Caption = 'CompilationPage'
|
||||
ClientWidth = 665
|
||||
ClientHeight = 449
|
||||
ClientWidth = 667
|
||||
ClientHeight = 453
|
||||
object chkCreateMakefile: TCheckBox
|
||||
Left = 6
|
||||
Height = 22
|
||||
Top = 6
|
||||
Width = 653
|
||||
Width = 655
|
||||
Align = alTop
|
||||
BorderSpacing.Around = 6
|
||||
Caption = 'chkCreateMakefile'
|
||||
@ -1008,13 +1031,13 @@ object frmCompilerOptions: TfrmCompilerOptions
|
||||
Left = 6
|
||||
Height = 108
|
||||
Top = 233
|
||||
Width = 653
|
||||
Width = 655
|
||||
Align = alTop
|
||||
AutoSize = True
|
||||
BorderSpacing.Around = 6
|
||||
Caption = 'ExecuteAfterGroupBox'
|
||||
ClientHeight = 89
|
||||
ClientWidth = 649
|
||||
ClientHeight = 104
|
||||
ClientWidth = 651
|
||||
TabOrder = 1
|
||||
object lblRunIfExecAfter: TLabel
|
||||
AnchorSideLeft.Control = ExecuteAfterGroupBox
|
||||
@ -1088,7 +1111,7 @@ object frmCompilerOptions: TfrmCompilerOptions
|
||||
Left = 208
|
||||
Height = 23
|
||||
Top = 32
|
||||
Width = 435
|
||||
Width = 437
|
||||
Anchors = [akTop, akLeft, akRight]
|
||||
BorderSpacing.Left = 12
|
||||
BorderSpacing.Around = 6
|
||||
@ -1140,13 +1163,13 @@ object frmCompilerOptions: TfrmCompilerOptions
|
||||
Left = 6
|
||||
Height = 79
|
||||
Top = 148
|
||||
Width = 653
|
||||
Width = 655
|
||||
Align = alTop
|
||||
AutoSize = True
|
||||
BorderSpacing.Around = 6
|
||||
Caption = 'grpCompiler'
|
||||
ClientHeight = 60
|
||||
ClientWidth = 649
|
||||
ClientHeight = 75
|
||||
ClientWidth = 651
|
||||
TabOrder = 2
|
||||
object lblRunIfCompiler: TLabel
|
||||
AnchorSideLeft.Control = grpCompiler
|
||||
@ -1223,7 +1246,7 @@ object frmCompilerOptions: TfrmCompilerOptions
|
||||
Left = 96
|
||||
Height = 23
|
||||
Top = 31
|
||||
Width = 547
|
||||
Width = 549
|
||||
Anchors = [akTop, akLeft, akRight]
|
||||
BorderSpacing.Left = 12
|
||||
BorderSpacing.Around = 6
|
||||
@ -1235,13 +1258,13 @@ object frmCompilerOptions: TfrmCompilerOptions
|
||||
Left = 6
|
||||
Height = 108
|
||||
Top = 34
|
||||
Width = 653
|
||||
Width = 655
|
||||
Align = alTop
|
||||
AutoSize = True
|
||||
BorderSpacing.Around = 6
|
||||
Caption = 'ExecuteBeforeGroupBox'
|
||||
ClientHeight = 89
|
||||
ClientWidth = 649
|
||||
ClientHeight = 104
|
||||
ClientWidth = 651
|
||||
TabOrder = 3
|
||||
object lblRunIfExecBefore: TLabel
|
||||
AnchorSideLeft.Control = ExecuteBeforeGroupBox
|
||||
@ -1315,7 +1338,7 @@ object frmCompilerOptions: TfrmCompilerOptions
|
||||
Left = 219
|
||||
Height = 23
|
||||
Top = 32
|
||||
Width = 424
|
||||
Width = 426
|
||||
Anchors = [akTop, akLeft, akRight]
|
||||
BorderSpacing.Left = 12
|
||||
BorderSpacing.Around = 6
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -38,8 +38,9 @@ interface
|
||||
|
||||
uses
|
||||
Forms, Classes, Math, LCLProc, SysUtils, InterfaceBase,
|
||||
ComCtrls, Buttons, StdCtrls, ExtCtrls,
|
||||
Graphics, LResources, FileUtil, Dialogs, Controls, GraphType,
|
||||
ComCtrls, Buttons, StdCtrls, ExtCtrls, Graphics, LResources, FileUtil,
|
||||
Dialogs, Controls, GraphType,
|
||||
LinkScanner,
|
||||
MacroIntf, ProjectIntf, IDEWindowIntf, IDEContextHelpEdit,
|
||||
TransferMacros, PathEditorDlg, LazarusIDEStrConsts, IDEOptionDefs, LazConf,
|
||||
IDEProcs, IDEImagesIntf, ShowCompilerOpts, Project, PackageDefs,
|
||||
@ -95,6 +96,8 @@ type
|
||||
ParsingPage: TPage;
|
||||
grpAsmStyle: TRadioGroup;
|
||||
grpSyntaxOptions: TCheckGroup;
|
||||
grpSyntaxMode: TGroupBox;
|
||||
cmbSyntaxMode: TComboBox;
|
||||
|
||||
{ Code Generation Controls }
|
||||
CodeGenPage: TPage;
|
||||
@ -224,8 +227,6 @@ type
|
||||
procedure ButtonLoadSaveClick(Sender: TObject);
|
||||
procedure ButtonShowOptionsClicked(Sender: TObject);
|
||||
procedure FileBrowseBtnClick(Sender: TObject);
|
||||
procedure FormResize(Sender: TObject);
|
||||
procedure grpSyntaxOptionsItemClick(Sender: TObject; Index: integer);
|
||||
procedure HelpButtonClick(Sender: TObject);
|
||||
procedure InhTreeViewSelectionChanged(Sender: TObject);
|
||||
procedure chkCustomConfigFileClick(Sender: TObject);
|
||||
@ -277,6 +278,9 @@ type
|
||||
var
|
||||
TestCompilerOptions: TNotifyEvent = nil;
|
||||
|
||||
function SyntaxModeToCaption(const Mode: string): string;
|
||||
function CaptionToSyntaxMode(const Caption: string): string;
|
||||
|
||||
implementation
|
||||
|
||||
type
|
||||
@ -286,6 +290,36 @@ type
|
||||
end;
|
||||
PInheritedNodeData = ^TInheritedNodeData;
|
||||
|
||||
function SyntaxModeToCaption(const Mode: string): string;
|
||||
begin
|
||||
if SysUtils.CompareText(Mode,'ObjFPC')=0 then
|
||||
Result:=lisObjectPascalDefault+' (-Mobjfpc)'
|
||||
else if SysUtils.CompareText(Mode,'Delphi')=0 then
|
||||
Result:=lisDelphi+' (-Mdelphi)'
|
||||
else if SysUtils.CompareText(Mode,'tp')=0 then
|
||||
Result:=lisTurboPascal+' (-Mtp)'
|
||||
else if SysUtils.CompareText(Mode,'fpc')=0 then
|
||||
Result:=lisFreePascal+' (-Mfpc)'
|
||||
else if SysUtils.CompareText(Mode,'macpas')=0 then
|
||||
Result:=lisMacPascal+' (-Mmacpas)'
|
||||
else
|
||||
Result:='';
|
||||
end;
|
||||
|
||||
function CaptionToSyntaxMode(const Caption: string): string;
|
||||
begin
|
||||
if System.Pos('-Mdelphi',Caption)>0 then
|
||||
Result:='Delphi'
|
||||
else if System.Pos('-Mtp',Caption)>0 then
|
||||
Result:='tp'
|
||||
else if System.Pos('-Mmacpas',Caption)>0 then
|
||||
Result:='macpas'
|
||||
else if System.Pos('-Mfpc',Caption)>0 then
|
||||
Result:='fpc'
|
||||
else
|
||||
Result:='ObjFPC';
|
||||
end;
|
||||
|
||||
{------------------------------------------------------------------------------
|
||||
TfrmCompilerOptions Constructor
|
||||
------------------------------------------------------------------------------}
|
||||
@ -425,24 +459,6 @@ begin
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCompilerOptions.FormResize(Sender: TObject);
|
||||
begin
|
||||
end;
|
||||
|
||||
procedure TfrmCompilerOptions.grpSyntaxOptionsItemClick(Sender: TObject;
|
||||
Index: integer);
|
||||
begin
|
||||
case Index of
|
||||
0,6,9,11:
|
||||
if grpSyntaxOptions.Checked[Index] then begin
|
||||
grpSyntaxOptions.Checked[0]:=Index=0; // objfpc mode
|
||||
grpSyntaxOptions.Checked[6]:=Index=6; // tp mode
|
||||
grpSyntaxOptions.Checked[9]:=Index=9; // delphi mode
|
||||
grpSyntaxOptions.Checked[11]:=Index=11;// gpc mode
|
||||
end;
|
||||
end;
|
||||
end;
|
||||
|
||||
procedure TfrmCompilerOptions.HelpButtonClick(Sender: TObject);
|
||||
begin
|
||||
ShowContextHelpForIDE(Self);
|
||||
@ -518,20 +534,18 @@ begin
|
||||
|
||||
with grpSyntaxOptions do
|
||||
begin
|
||||
Checked[0] := Options.Delphi2Extensions;
|
||||
Checked[1] := Options.CStyleOperators;
|
||||
Checked[2] := Options.IncludeAssertionCode;
|
||||
Checked[3] := Options.AllowLabel;
|
||||
Checked[4] := Options.CPPInline;
|
||||
Checked[5] := Options.CStyleMacros;
|
||||
Checked[6] := Options.TPCompatible;
|
||||
Checked[7] := Options.InitConstructor;
|
||||
Checked[8] := Options.StaticKeyword;
|
||||
Checked[9] := Options.DelphiCompat;
|
||||
Checked[10] := Options.UseAnsiStrings;
|
||||
Checked[11] := Options.GPCCompat;
|
||||
Checked[0] := Options.CStyleOperators;
|
||||
Checked[1] := Options.IncludeAssertionCode;
|
||||
Checked[2] := Options.AllowLabel;
|
||||
Checked[3] := Options.CPPInline;
|
||||
Checked[4] := Options.CStyleMacros;
|
||||
Checked[5] := Options.InitConstructor;
|
||||
Checked[6] := Options.StaticKeyword;
|
||||
Checked[7] := Options.UseAnsiStrings;
|
||||
end;
|
||||
|
||||
cmbSyntaxMode.Text:=SyntaxModeToCaption(Options.SyntaxMode);
|
||||
|
||||
// code generation
|
||||
chkSmartLinkUnit.Checked := Options.SmartLinkUnit;
|
||||
|
||||
@ -832,20 +846,18 @@ begin
|
||||
|
||||
with grpSyntaxOptions do
|
||||
begin
|
||||
Options.Delphi2Extensions := Checked[0];
|
||||
Options.CStyleOperators := Checked[1];
|
||||
Options.IncludeAssertionCode := Checked[2];
|
||||
Options.AllowLabel := Checked[3];
|
||||
Options.CPPInline := Checked[4];
|
||||
Options.CStyleMacros := Checked[5];
|
||||
Options.TPCompatible := Checked[6];
|
||||
Options.InitConstructor := Checked[7];
|
||||
Options.StaticKeyword := Checked[8];
|
||||
Options.DelphiCompat := Checked[9];
|
||||
Options.UseAnsiStrings := Checked[10];
|
||||
Options.GPCCompat := Checked[11];
|
||||
Options.CStyleOperators := Checked[01];
|
||||
Options.IncludeAssertionCode := Checked[1];
|
||||
Options.AllowLabel := Checked[2];
|
||||
Options.CPPInline := Checked[3];
|
||||
Options.CStyleMacros := Checked[4];
|
||||
Options.InitConstructor := Checked[5];
|
||||
Options.StaticKeyword := Checked[6];
|
||||
Options.UseAnsiStrings := Checked[7];
|
||||
end;
|
||||
|
||||
Options.SyntaxMode:=CaptionToSyntaxMode(cmbSyntaxMode.Text);
|
||||
|
||||
// code generation
|
||||
Options.SmartLinkUnit := chkSmartLinkUnit.Checked;
|
||||
|
||||
@ -1133,6 +1145,9 @@ end;
|
||||
TfrmCompilerOptions SetupParsingTab
|
||||
------------------------------------------------------------------------------}
|
||||
procedure TfrmCompilerOptions.SetupParsingTab(Page: integer);
|
||||
var
|
||||
m: TCompilerMode;
|
||||
s: String;
|
||||
begin
|
||||
MainNoteBook.Page[Page].Caption:= dlgCOParsing;
|
||||
|
||||
@ -1153,19 +1168,25 @@ begin
|
||||
AutoSize:=true;
|
||||
Caption := dlgSyntaxOptions;
|
||||
|
||||
Items.Add(dlgDelphi2Ext+' (-S2)');
|
||||
Items.Add(dlgCOCOps+' (-Sc)');
|
||||
Items.Add(dlgAssertCode+' (-Sa)');
|
||||
Items.Add(dlgLabelGoto+' (-Sg)');
|
||||
Items.Add(dlgCppInline+' (-Si)');
|
||||
Items.Add(dlgCMacro+' (-Sm)');
|
||||
Items.Add(dlgBP7Cptb+' (-So)');
|
||||
Items.Add(dlgInitDoneOnly+' (-Ss)');
|
||||
Items.Add(dlgStaticKeyword+' (-St)');
|
||||
Items.Add(dlgDeplhiComp+' (-Sd)');
|
||||
Items.Add(dlgCOAnsiStr+' (-Sh)');
|
||||
Items.Add(dlgGPCComp+' (-Sp)');
|
||||
end;
|
||||
|
||||
grpSyntaxMode.Caption:=lisSyntaxMode+' (-M)';
|
||||
cmbSyntaxMode.Items.BeginUpdate;
|
||||
cmbSyntaxMode.Items.Clear;
|
||||
for m:=Low(TCompilerMode) to High(TCompilerMode) do begin
|
||||
s:=SyntaxModeToCaption(CompilerModeNames[m]);
|
||||
if s<>'' then
|
||||
cmbSyntaxMode.Items.Add(s);
|
||||
end;
|
||||
cmbSyntaxMode.Items.EndUpdate;
|
||||
end;
|
||||
|
||||
|
||||
|
@ -228,23 +228,35 @@ begin
|
||||
}
|
||||
|
||||
// FPC modes ----------------------------------------------------------------
|
||||
if CompOpts.DelphiCompat then begin
|
||||
if SysUtils.CompareText(CompOpts.SyntaxMode,'Delphi')=0 then begin
|
||||
// set mode DELPHI
|
||||
Result:=Result or
|
||||
ReplaceAutoGeneratedDefine(ParentTemplate,FPCModeDefTemplName,
|
||||
lisEdtDefsetFPCModeToDELPHI, CompilerModeVars[cmDELPHI], '1',
|
||||
RecursiveDefines);
|
||||
end else if CompOpts.TPCompatible then begin
|
||||
end else if SysUtils.CompareText(CompOpts.SyntaxMode,'TP')=0 then begin
|
||||
// set mode TP
|
||||
Result:=Result or
|
||||
ReplaceAutoGeneratedDefine(ParentTemplate,FPCModeDefTemplName,
|
||||
lisEdtDefsetFPCModeToTP, CompilerModeVars[cmTP], '1', RecursiveDefines);
|
||||
end else if CompOpts.GPCCompat then begin
|
||||
end else if SysUtils.CompareText(CompOpts.SyntaxMode,'GPC')=0 then begin
|
||||
// set mode GPC
|
||||
Result:=Result or
|
||||
ReplaceAutoGeneratedDefine(ParentTemplate,FPCModeDefTemplName,
|
||||
lisEdtDefsetFPCModeToGPC, CompilerModeVars[cmGPC], '1', RecursiveDefines
|
||||
);
|
||||
end else if SysUtils.CompareText(CompOpts.SyntaxMode,'MacPas')=0 then begin
|
||||
// set mode MacPas
|
||||
Result:=Result or
|
||||
ReplaceAutoGeneratedDefine(ParentTemplate,FPCModeDefTemplName,
|
||||
lisEdtDefsetFPCModeToMacPas, CompilerModeVars[cmMacPas], '1', RecursiveDefines
|
||||
);
|
||||
end else if SysUtils.CompareText(CompOpts.SyntaxMode,'FPC')=0 then begin
|
||||
// set mode FPC
|
||||
Result:=Result or
|
||||
ReplaceAutoGeneratedDefine(ParentTemplate,FPCModeDefTemplName,
|
||||
lisEdtDefsetFPCModeToFPC, CompilerModeVars[cmFPC], '1', RecursiveDefines
|
||||
);
|
||||
end else begin
|
||||
// set no mode
|
||||
Result:=Result or
|
||||
|
@ -2660,6 +2660,8 @@ resourcestring
|
||||
lisEdtDefsetFPCModeToDELPHI = 'set FPC mode to DELPHI';
|
||||
lisEdtDefsetFPCModeToTP = 'set FPC mode to TP';
|
||||
lisEdtDefsetFPCModeToGPC = 'set FPC mode to GPC';
|
||||
lisEdtDefsetFPCModeToMacPas = 'set FPC mode to MacPas';
|
||||
lisEdtDefsetFPCModeToFPC = 'set FPC mode to FPC';
|
||||
lisEdtDefsetIOCHECKSOn = 'set IOCHECKS on';
|
||||
lisEdtDefsetRANGECHECKSOn = 'set RANGECHECKS on';
|
||||
lisEdtDefsetOVERFLOWCHECKSOn = 'set OVERFLOWCHECKS on';
|
||||
@ -3807,6 +3809,12 @@ resourcestring
|
||||
+'sIdentifier%sTMyEnum.Enum%sUnitname.Identifier%s#PackageName.UnitName.'
|
||||
+'Identifier';
|
||||
lisTitleLeaveEmptyForDefault = 'Title (leave empty for default)';
|
||||
lisSyntaxMode = 'Syntax mode';
|
||||
lisObjectPascalDefault = 'Object Pascal - default';
|
||||
lisDelphi = 'Delphi';
|
||||
lisTurboPascal = 'Turbo Pascal';
|
||||
lisMacPascal = 'Mac Pascal';
|
||||
lisFreePascal = 'Free Pascal';
|
||||
|
||||
implementation
|
||||
|
||||
|
@ -357,8 +357,8 @@ end;
|
||||
|
||||
procedure TActionListEditor.OnRefreshPropertyValues;
|
||||
function ValidCategory: Boolean;
|
||||
// spr. czy wszystkie kategorie w ListBox'sie istniejš w TActionList
|
||||
// inaczej: czy istnieje kategoria elementu wywolujšcego zdarzenie
|
||||
// spr. czy wszystkie kategorie w ListBox'sie istniej¹ w TActionList
|
||||
// inaczej: czy istnieje kategoria elementu wywoluj¹cego zdarzenie
|
||||
var
|
||||
i, j: Integer;
|
||||
bool: Boolean;
|
||||
@ -420,12 +420,12 @@ begin
|
||||
tmpIsActCategory := IsCategory(CurSelect.Category);
|
||||
|
||||
if tmpCategory = '' then tmpCategory := cActionListEditorUnknownCategory;
|
||||
// jeżeli nie ma tej kategorii na liscie
|
||||
// je¿eli nie ma tej kategorii na liscie
|
||||
if ((curSelect.Category <> '') and not tmpIsActCategory)
|
||||
// nie wszystkie kategorie z lstCategory istniejš w FActionList
|
||||
// nie wszystkie kategorie z lstCategory istniej¹ w FActionList
|
||||
// (usuniecie kategorii)
|
||||
or not tmpValidCategory
|
||||
// jeżeli kategoria jest inna od oznaczonej
|
||||
// je¿eli kategoria jest inna od oznaczonej
|
||||
// oraz nie jest to kategoria '(All)' ani '(Unknown)'
|
||||
or ((tmpCategory <> lstCategory.Items[lstCategory.Items.IndexOf(tmpCategory)])
|
||||
and ((lstCategory.Items.IndexOf(cActionListEditorAllCategory) >= 0)
|
||||
@ -434,7 +434,7 @@ begin
|
||||
then FillCategories;
|
||||
|
||||
tmpIndex := lstCategory.Items.IndexOf(tmpCategory); // ???
|
||||
// sš kategorie (nie tylko Unknown) rownież All i inne
|
||||
// s¹ kategorie (nie tylko Unknown) rownie¿ All i inne
|
||||
if (lstCategory.Items.Count > 1)
|
||||
// nie istniala nowa kategoria
|
||||
// nie istniala zaznaczona kategoria
|
||||
|
@ -92,16 +92,13 @@ type
|
||||
fAssemblerStyle: Integer;
|
||||
|
||||
// syntax options
|
||||
fDelphi2Ext: Boolean;
|
||||
FSyntaxMode: string;
|
||||
fCStyleOp: Boolean;
|
||||
fIncludeAssertionCode: Boolean;
|
||||
fDelphiCompat: Boolean;
|
||||
fAllowLabel: Boolean;
|
||||
fUseAnsiStr: Boolean;
|
||||
fCPPInline: Boolean;
|
||||
fCMacros: Boolean;
|
||||
fTPCompat: Boolean;
|
||||
fGPCCompat: Boolean;
|
||||
fInitConst: Boolean;
|
||||
fStaticKeyword: Boolean;
|
||||
|
||||
@ -198,18 +195,15 @@ type
|
||||
property LCLWidgetType: string read fLCLWidgetType write fLCLWidgetType;
|
||||
|
||||
// parsing:
|
||||
property SyntaxMode: string read FSyntaxMode write FSyntaxMode;
|
||||
property AssemblerStyle: Integer read fAssemblerStyle write fAssemblerStyle;
|
||||
property Delphi2Extensions: Boolean read fDelphi2Ext write fDelphi2Ext;
|
||||
property CStyleOperators: Boolean read fCStyleOp write fCStyleOp;
|
||||
property IncludeAssertionCode: Boolean
|
||||
read fIncludeAssertionCode write fIncludeAssertionCode;
|
||||
property DelphiCompat: Boolean read fDelphiCompat write fDelphiCompat;
|
||||
property AllowLabel: Boolean read fAllowLabel write fAllowLabel;
|
||||
property UseAnsiStrings: Boolean read fUseAnsiStr write fUseAnsiStr;
|
||||
property CPPInline: Boolean read fCPPInline write fCPPInline;
|
||||
property CStyleMacros: Boolean read fCMacros write fCMacros;
|
||||
property TPCompatible: Boolean read fTPCompat write fTPCompat;
|
||||
property GPCCompat: Boolean read fGPCCompat write fGPCCompat;
|
||||
property InitConstructor: Boolean read fInitConst write fInitConst;
|
||||
property StaticKeyword: Boolean read fStaticKeyword write fStaticKeyword;
|
||||
|
||||
|
@ -18,7 +18,7 @@ object AddToPackageDlg: TAddToPackageDlg
|
||||
Height = 300
|
||||
Width = 500
|
||||
Align = alClient
|
||||
PageIndex = 5
|
||||
PageIndex = 4
|
||||
TabOrder = 0
|
||||
object NewFilePage: TPage
|
||||
Caption = 'New File'
|
||||
@ -630,7 +630,8 @@ object AddToPackageDlg: TAddToPackageDlg
|
||||
ChildSizing.ShrinkHorizontal = crsScaleChilds
|
||||
ChildSizing.ShrinkVertical = crsScaleChilds
|
||||
ChildSizing.Layout = cclLeftToRightThenTopToBottom
|
||||
ChildSizing.ControlsPerLine = 1
|
||||
ChildSizing.ControlsPerLine = 2
|
||||
Columns = 2
|
||||
Constraints.MinHeight = 30
|
||||
Constraints.MinWidth = 100
|
||||
TabOrder = 3
|
||||
|
@ -8,7 +8,7 @@ LazarusResources.Add('TAddToPackageDlg','FORMDATA',[
|
||||
+'e'#9'OnDestroy'#7#11'FormDestroy'#9'OnKeyDown'#7#22'AddToPackageDlgKeyDown'
|
||||
+#8'Position'#7#14'poScreenCenter'#10'LCLVersion'#6#6'0.9.25'#0#9'TNotebook'#8
|
||||
+'NoteBook'#6'Height'#3','#1#5'Width'#3#244#1#5'Align'#7#8'alClient'#9'PageIn'
|
||||
+'dex'#2#5#8'TabOrder'#2#0#0#5'TPage'#11'NewFilePage'#7'Caption'#6#8'New File'
|
||||
+'dex'#2#4#8'TabOrder'#2#0#0#5'TPage'#11'NewFilePage'#7'Caption'#6#8'New File'
|
||||
+#11'ClientWidth'#3#242#1#12'ClientHeight'#3#17#1#8'OnResize'#7#17'NewFilePag'
|
||||
+'eResize'#0#9'TTreeView'#15'NewFileTreeView'#24'AnchorSideBottom.Control'#7
|
||||
+#15'NewFileOkButton'#6'Height'#3#218#0#5'Width'#3#249#0#5'Align'#7#6'alLeft'
|
||||
@ -217,38 +217,38 @@ LazarusResources.Add('TAddToPackageDlg','FORMDATA',[
|
||||
+'ldResize'#27'ChildSizing.EnlargeVertical'#7#24'crsHomogenousChildResize'#28
|
||||
+'ChildSizing.ShrinkHorizontal'#7#14'crsScaleChilds'#26'ChildSizing.ShrinkVer'
|
||||
+'tical'#7#14'crsScaleChilds'#18'ChildSizing.Layout'#7#29'cclLeftToRightThenT'
|
||||
+'opToBottom'#27'ChildSizing.ControlsPerLine'#2#1#21'Constraints.MinHeight'#2
|
||||
+#30#20'Constraints.MinWidth'#2'd'#8'TabOrder'#2#3#0#0#7'TButton'#13'AddFileB'
|
||||
+'utton'#21'AnchorSideTop.Control'#7#21'AddFileTypeRadioGroup'#18'AnchorSideT'
|
||||
+'op.Side'#7#9'asrBottom'#4'Left'#2#5#6'Height'#2#29#3'Top'#2']'#5'Width'#2'd'
|
||||
+#8'AutoSize'#9#17'BorderSpacing.Top'#2#25#7'Caption'#6#13'AddFileButton'#7'O'
|
||||
+'nClick'#7#18'AddFileButtonClick'#8'TabOrder'#2#4#0#0#7'TButton'#19'CancelAd'
|
||||
+'dFileButton'#22'AnchorSideLeft.Control'#7#13'AddFileButton'#19'AnchorSideLe'
|
||||
+'ft.Side'#7#9'asrBottom'#21'AnchorSideTop.Control'#7#13'AddFileButton'#4'Lef'
|
||||
+'t'#2'o'#6'Height'#2#29#3'Top'#2']'#5'Width'#3#143#0#8'AutoSize'#9#18'Border'
|
||||
+'Spacing.Left'#2#6#7'Caption'#6#19'CancelAddFileButton'#7'OnClick'#7#24'Canc'
|
||||
+'elAddFileButtonClick'#8'TabOrder'#2#5#0#0#0#5'TPage'#12'AddFilesPage'#7'Cap'
|
||||
+'tion'#6#9'Add Files'#11'ClientWidth'#3#242#1#12'ClientHeight'#3#17#1#0#9'TL'
|
||||
+'istView'#13'FilesListView'#24'AnchorSideBottom.Control'#7#17'FilesBrowseBut'
|
||||
+'ton'#6'Height'#3#227#0#5'Width'#3#242#1#5'Align'#7#8'alClient'#20'BorderSpa'
|
||||
+'cing.Bottom'#2#5#7'Columns'#14#1#7'Caption'#6#8'Filename'#5'Width'#3#200#0#0
|
||||
+#1#7'Caption'#6#4'Type'#5'Width'#3#24#1#0#0#11'MultiSelect'#9#8'TabOrder'#2#0
|
||||
+#9'ViewStyle'#7#8'vsReport'#0#0#6'TPanel'#16'AddFilesBtnPanel'#6'Height'#2')'
|
||||
+#3'Top'#3#232#0#5'Width'#3#242#1#5'Align'#7#8'alBottom'#8'AutoSize'#9#10'Bev'
|
||||
+'elOuter'#7#6'bvNone'#12'ClientHeight'#2')'#11'ClientWidth'#3#242#1#8'TabOrd'
|
||||
+'er'#2#1#0#7'TButton'#17'FilesBrowseButton'#21'AnchorSideBottom.Side'#7#9'as'
|
||||
+'rBottom'#4'Left'#3#25#1#6'Height'#2#29#3'Top'#2#6#5'Width'#3#128#0#5'Align'
|
||||
+#7#6'alLeft'#8'AutoSize'#9#20'BorderSpacing.Around'#2#6#7'Caption'#6#17'File'
|
||||
+'sBrowseButton'#7'OnClick'#7#22'FilesBrowseButtonClick'#8'TabOrder'#2#0#0#0#7
|
||||
+'TButton'#14'FilesAddButton'#19'AnchorSideLeft.Side'#7#9'asrBottom'#4'Left'#3
|
||||
+#159#1#6'Height'#2#29#3'Top'#2#6#5'Width'#2'k'#5'Align'#7#6'alLeft'#8'AutoSi'
|
||||
+'ze'#9#20'BorderSpacing.Around'#2#6#7'Caption'#6#14'FilesAddButton'#7'OnClic'
|
||||
+'k'#7#19'FilesAddButtonClick'#8'TabOrder'#2#1#0#0#7'TBitBtn'#18'FilesShorten'
|
||||
+'Button'#19'AnchorSideLeft.Side'#7#9'asrBottom'#4'Left'#3#139#0#6'Height'#2
|
||||
+#29#3'Top'#2#6#5'Width'#3#136#0#5'Align'#7#6'alLeft'#8'AutoSize'#9#20'Border'
|
||||
+'Spacing.Around'#2#6#7'Caption'#6#18'FilesShortenButton'#9'NumGlyphs'#2#0#8
|
||||
+'TabOrder'#2#2#0#0#7'TBitBtn'#17'FilesDeleteButton'#19'AnchorSideLeft.Side'#7
|
||||
+#9'asrBottom'#4'Left'#2#6#6'Height'#2#29#3'Top'#2#6#5'Width'#2''#5'Align'#7
|
||||
+#6'alLeft'#8'AutoSize'#9#20'BorderSpacing.Around'#2#6#7'Caption'#6#17'FilesD'
|
||||
+'eleteButton'#9'NumGlyphs'#2#0#8'TabOrder'#2#3#0#0#0#0#0#0
|
||||
+'opToBottom'#27'ChildSizing.ControlsPerLine'#2#2#7'Columns'#2#2#21'Constrain'
|
||||
+'ts.MinHeight'#2#30#20'Constraints.MinWidth'#2'd'#8'TabOrder'#2#3#0#0#7'TBut'
|
||||
+'ton'#13'AddFileButton'#21'AnchorSideTop.Control'#7#21'AddFileTypeRadioGroup'
|
||||
+#18'AnchorSideTop.Side'#7#9'asrBottom'#4'Left'#2#5#6'Height'#2#29#3'Top'#2']'
|
||||
+#5'Width'#2'd'#8'AutoSize'#9#17'BorderSpacing.Top'#2#25#7'Caption'#6#13'AddF'
|
||||
+'ileButton'#7'OnClick'#7#18'AddFileButtonClick'#8'TabOrder'#2#4#0#0#7'TButto'
|
||||
+'n'#19'CancelAddFileButton'#22'AnchorSideLeft.Control'#7#13'AddFileButton'#19
|
||||
+'AnchorSideLeft.Side'#7#9'asrBottom'#21'AnchorSideTop.Control'#7#13'AddFileB'
|
||||
+'utton'#4'Left'#2'o'#6'Height'#2#29#3'Top'#2']'#5'Width'#3#143#0#8'AutoSize'
|
||||
+#9#18'BorderSpacing.Left'#2#6#7'Caption'#6#19'CancelAddFileButton'#7'OnClick'
|
||||
+#7#24'CancelAddFileButtonClick'#8'TabOrder'#2#5#0#0#0#5'TPage'#12'AddFilesPa'
|
||||
+'ge'#7'Caption'#6#9'Add Files'#11'ClientWidth'#3#242#1#12'ClientHeight'#3#17
|
||||
+#1#0#9'TListView'#13'FilesListView'#24'AnchorSideBottom.Control'#7#17'FilesB'
|
||||
+'rowseButton'#6'Height'#3#227#0#5'Width'#3#242#1#5'Align'#7#8'alClient'#20'B'
|
||||
+'orderSpacing.Bottom'#2#5#7'Columns'#14#1#7'Caption'#6#8'Filename'#5'Width'#3
|
||||
+#200#0#0#1#7'Caption'#6#4'Type'#5'Width'#3#24#1#0#0#11'MultiSelect'#9#8'TabO'
|
||||
+'rder'#2#0#9'ViewStyle'#7#8'vsReport'#0#0#6'TPanel'#16'AddFilesBtnPanel'#6'H'
|
||||
+'eight'#2')'#3'Top'#3#232#0#5'Width'#3#242#1#5'Align'#7#8'alBottom'#8'AutoSi'
|
||||
+'ze'#9#10'BevelOuter'#7#6'bvNone'#12'ClientHeight'#2')'#11'ClientWidth'#3#242
|
||||
+#1#8'TabOrder'#2#1#0#7'TButton'#17'FilesBrowseButton'#21'AnchorSideBottom.Si'
|
||||
+'de'#7#9'asrBottom'#4'Left'#3#25#1#6'Height'#2#29#3'Top'#2#6#5'Width'#3#128#0
|
||||
+#5'Align'#7#6'alLeft'#8'AutoSize'#9#20'BorderSpacing.Around'#2#6#7'Caption'#6
|
||||
+#17'FilesBrowseButton'#7'OnClick'#7#22'FilesBrowseButtonClick'#8'TabOrder'#2
|
||||
+#0#0#0#7'TButton'#14'FilesAddButton'#19'AnchorSideLeft.Side'#7#9'asrBottom'#4
|
||||
+'Left'#3#159#1#6'Height'#2#29#3'Top'#2#6#5'Width'#2'k'#5'Align'#7#6'alLeft'#8
|
||||
+'AutoSize'#9#20'BorderSpacing.Around'#2#6#7'Caption'#6#14'FilesAddButton'#7
|
||||
+'OnClick'#7#19'FilesAddButtonClick'#8'TabOrder'#2#1#0#0#7'TBitBtn'#18'FilesS'
|
||||
+'hortenButton'#19'AnchorSideLeft.Side'#7#9'asrBottom'#4'Left'#3#139#0#6'Heig'
|
||||
+'ht'#2#29#3'Top'#2#6#5'Width'#3#136#0#5'Align'#7#6'alLeft'#8'AutoSize'#9#20
|
||||
+'BorderSpacing.Around'#2#6#7'Caption'#6#18'FilesShortenButton'#9'NumGlyphs'#2
|
||||
+#0#8'TabOrder'#2#2#0#0#7'TBitBtn'#17'FilesDeleteButton'#19'AnchorSideLeft.Si'
|
||||
+'de'#7#9'asrBottom'#4'Left'#2#6#6'Height'#2#29#3'Top'#2#6#5'Width'#2''#5'Al'
|
||||
+'ign'#7#6'alLeft'#8'AutoSize'#9#20'BorderSpacing.Around'#2#6#7'Caption'#6#17
|
||||
+'FilesDeleteButton'#9'NumGlyphs'#2#0#8'TabOrder'#2#3#0#0#0#0#0#0
|
||||
]);
|
||||
|
@ -1308,10 +1308,9 @@ begin
|
||||
coptParsedPlatformIndependent);
|
||||
CustomOptions:=APackage.CompilerOptions.GetCustomOptions(
|
||||
coptParsedPlatformIndependent);
|
||||
if APackage.CompilerOptions.Delphi2Extensions then
|
||||
CustomOptions:=CustomOptions+' -S2';
|
||||
if APackage.CompilerOptions.UseLineInfoUnit then
|
||||
CustomOptions:=CustomOptions+' -gl';
|
||||
s:=APackage.CompilerOptions.GetSyntaxOptionsString;
|
||||
if s<>'' then
|
||||
CustomOptions:=CustomOptions+' '+s;
|
||||
// TODO: other options
|
||||
|
||||
//DebugLn('TPkgManager.DoWriteMakefile ',APackage.Name,' makefile UnitPath="',UnitPath,'"');
|
||||
|
Loading…
Reference in New Issue
Block a user