mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-04-18 04:49:43 +02:00
IDE: debug/complier-options dialog. revert default to -g
git-svn-id: trunk@32468 -
This commit is contained in:
parent
ae67ba05c7
commit
2aee52f6f3
@ -450,7 +450,6 @@ type
|
||||
fMsgFileName: String; // messages file name
|
||||
fCompilerMessages: TCompilerMessagesList;
|
||||
|
||||
function GetDbgSymbolTypeDefault: TCompilerDbgSymbolType;
|
||||
procedure OnItemChanged(Sender: TObject);
|
||||
protected
|
||||
function GetCompilerPath: String;
|
||||
@ -574,7 +573,6 @@ type
|
||||
property BaseDirectory: string read GetBaseDirectory write SetBaseDirectory;
|
||||
property DefaultMakeOptionsFlags: TCompilerCmdLineOptions
|
||||
read FDefaultMakeOptionsFlags write SetDefaultMakeOptionsFlags;
|
||||
property DbgSymbolTypeDefault: TCompilerDbgSymbolType read GetDbgSymbolTypeDefault;
|
||||
|
||||
// for dialog only
|
||||
property UseAsDefault: Boolean read FUseAsDefault write FUseAsDefault;
|
||||
@ -1161,34 +1159,6 @@ begin
|
||||
IncreaseChangeStamp;
|
||||
end;
|
||||
|
||||
function TBaseCompilerOptions.GetDbgSymbolTypeDefault: TCompilerDbgSymbolType;
|
||||
begin
|
||||
// set defaults
|
||||
{$IFDEF darwin}
|
||||
Result := dsStabs;
|
||||
{$ELSE}
|
||||
Result := dsDwarf2Set;
|
||||
{$ENDIF}
|
||||
// check current settings
|
||||
|
||||
if CompareText(copy(TargetOS,1,3), 'win') = 0
|
||||
then Result := dsDwarf2Set
|
||||
else if CompareText(TargetOS, 'darwin') = 0
|
||||
then Result := dsStabs
|
||||
else if (CompareText(TargetOS, 'linux') = 0)
|
||||
or (CompareText(TargetOS, 'freebsd') = 0)
|
||||
or (CompareText(TargetOS, 'openbsd') = 0)
|
||||
or (CompareText(TargetOS, 'netbsd') = 0)
|
||||
or (CompareText(TargetOS, 'haiku') = 0)
|
||||
then Result := dsDwarf2Set;
|
||||
|
||||
if Result <> dsStabs then begin
|
||||
if SysUtils.CompareText(TargetCPU,'x86_64')=0
|
||||
then Result := dsStabs;
|
||||
// powerpc sparc m68k alpha arm
|
||||
end;
|
||||
end;
|
||||
|
||||
function TBaseCompilerOptions.GetCompilerPath: String;
|
||||
begin
|
||||
Result:=ParsedOpts.UnparsedValues[pcosCompilerPath];
|
||||
@ -2651,8 +2621,8 @@ begin
|
||||
if (GenerateDebugInfo) then begin
|
||||
|
||||
dit := DebugInfoType;
|
||||
if dit = dsAuto then dit := DbgSymbolTypeDefault;
|
||||
case dit of
|
||||
dsAuto: switches := switches + ' -g';
|
||||
dsStabs: switches := switches + ' -gs';
|
||||
dsDwarf2: switches := switches + ' -gw2';
|
||||
dsDwarf2Set: switches := switches + ' -gw2 -godwarfsets';
|
||||
@ -3059,7 +3029,7 @@ begin
|
||||
|
||||
// linking
|
||||
fGenDebugInfo := false;
|
||||
fDebugInfoType := DbgSymbolTypeDefault;
|
||||
fDebugInfoType := dsAuto;
|
||||
fUseLineInfoUnit := true;
|
||||
fUseHeaptrc := false;
|
||||
fUseValgrind := false;
|
||||
|
@ -3,12 +3,11 @@ inherited CompilerLinkingOptionsFrame: TCompilerLinkingOptionsFrame
|
||||
Width = 701
|
||||
ClientHeight = 552
|
||||
ClientWidth = 701
|
||||
TabOrder = 0
|
||||
DesignLeft = 346
|
||||
DesignTop = 181
|
||||
object chkDebugGDB: TCheckBox[0]
|
||||
Left = 6
|
||||
Height = 22
|
||||
Height = 19
|
||||
Top = 6
|
||||
Width = 689
|
||||
Align = alTop
|
||||
@ -24,21 +23,21 @@ inherited CompilerLinkingOptionsFrame: TCompilerLinkingOptionsFrame
|
||||
AnchorSideRight.Control = Owner
|
||||
AnchorSideRight.Side = asrBottom
|
||||
Left = 0
|
||||
Height = 55
|
||||
Top = 301
|
||||
Height = 49
|
||||
Top = 270
|
||||
Width = 701
|
||||
Anchors = [akTop, akLeft, akRight]
|
||||
AutoSize = True
|
||||
BorderSpacing.Top = 6
|
||||
Caption = 'grpLinkLibraries'
|
||||
ClientHeight = 34
|
||||
ClientWidth = 693
|
||||
ClientHeight = 31
|
||||
ClientWidth = 697
|
||||
TabOrder = 0
|
||||
object chkLinkSmart: TCheckBox
|
||||
Left = 6
|
||||
Height = 22
|
||||
Height = 19
|
||||
Top = 6
|
||||
Width = 681
|
||||
Width = 685
|
||||
Align = alTop
|
||||
BorderSpacing.Around = 6
|
||||
Caption = 'chkLinkSmart'
|
||||
@ -52,21 +51,21 @@ inherited CompilerLinkingOptionsFrame: TCompilerLinkingOptionsFrame
|
||||
AnchorSideRight.Control = Owner
|
||||
AnchorSideRight.Side = asrBottom
|
||||
Left = 0
|
||||
Height = 55
|
||||
Top = 362
|
||||
Height = 49
|
||||
Top = 325
|
||||
Width = 701
|
||||
Anchors = [akTop, akLeft, akRight]
|
||||
AutoSize = True
|
||||
BorderSpacing.Top = 6
|
||||
Caption = 'TargetSpecificsGrpBox'
|
||||
ClientHeight = 34
|
||||
ClientWidth = 693
|
||||
ClientHeight = 31
|
||||
ClientWidth = 697
|
||||
TabOrder = 1
|
||||
object chkWin32GraphicApp: TCheckBox
|
||||
Left = 6
|
||||
Height = 22
|
||||
Height = 19
|
||||
Top = 6
|
||||
Width = 681
|
||||
Width = 685
|
||||
Align = alTop
|
||||
BorderSpacing.Around = 6
|
||||
Caption = 'chkWin32GraphicApp'
|
||||
@ -80,21 +79,21 @@ inherited CompilerLinkingOptionsFrame: TCompilerLinkingOptionsFrame
|
||||
AnchorSideRight.Control = Owner
|
||||
AnchorSideRight.Side = asrBottom
|
||||
Left = 0
|
||||
Height = 88
|
||||
Top = 423
|
||||
Height = 78
|
||||
Top = 380
|
||||
Width = 701
|
||||
Anchors = [akTop, akLeft, akRight]
|
||||
AutoSize = True
|
||||
BorderSpacing.Top = 6
|
||||
Caption = 'grpOptions'
|
||||
ClientHeight = 67
|
||||
ClientWidth = 693
|
||||
ClientHeight = 60
|
||||
ClientWidth = 697
|
||||
TabOrder = 2
|
||||
object chkOptionsLinkOpt: TCheckBox
|
||||
Left = 6
|
||||
Height = 22
|
||||
Height = 19
|
||||
Top = 6
|
||||
Width = 681
|
||||
Width = 685
|
||||
Align = alTop
|
||||
BorderSpacing.Around = 6
|
||||
Caption = 'chkOptionsLinkOpt'
|
||||
@ -102,9 +101,9 @@ inherited CompilerLinkingOptionsFrame: TCompilerLinkingOptionsFrame
|
||||
end
|
||||
object edtOptionsLinkOpt: TEdit
|
||||
Left = 6
|
||||
Height = 27
|
||||
Top = 34
|
||||
Width = 681
|
||||
Height = 23
|
||||
Top = 31
|
||||
Width = 685
|
||||
Align = alTop
|
||||
BorderSpacing.Around = 6
|
||||
TabOrder = 1
|
||||
@ -118,14 +117,14 @@ inherited CompilerLinkingOptionsFrame: TCompilerLinkingOptionsFrame
|
||||
AnchorSideRight.Control = Owner
|
||||
AnchorSideRight.Side = asrBottom
|
||||
Left = 0
|
||||
Height = 144
|
||||
Top = 34
|
||||
Height = 128
|
||||
Top = 31
|
||||
Width = 701
|
||||
Anchors = [akTop, akLeft, akRight]
|
||||
AutoSize = True
|
||||
Caption = 'grpDebugging'
|
||||
ClientHeight = 123
|
||||
ClientWidth = 693
|
||||
ClientHeight = 110
|
||||
ClientWidth = 697
|
||||
TabOrder = 3
|
||||
object chkUseLineInfoUnit: TCheckBox
|
||||
AnchorSideLeft.Control = grpDebugging
|
||||
@ -134,9 +133,9 @@ inherited CompilerLinkingOptionsFrame: TCompilerLinkingOptionsFrame
|
||||
AnchorSideRight.Control = grpDebugging
|
||||
AnchorSideRight.Side = asrBottom
|
||||
Left = 6
|
||||
Height = 22
|
||||
Top = 39
|
||||
Width = 681
|
||||
Height = 19
|
||||
Top = 35
|
||||
Width = 685
|
||||
Anchors = [akTop, akLeft, akRight]
|
||||
BorderSpacing.Around = 6
|
||||
Caption = 'chkUseLineInfoUnit'
|
||||
@ -149,9 +148,9 @@ inherited CompilerLinkingOptionsFrame: TCompilerLinkingOptionsFrame
|
||||
AnchorSideRight.Control = grpDebugging
|
||||
AnchorSideRight.Side = asrBottom
|
||||
Left = 6
|
||||
Height = 22
|
||||
Top = 67
|
||||
Width = 681
|
||||
Height = 19
|
||||
Top = 60
|
||||
Width = 685
|
||||
Anchors = [akTop, akLeft, akRight]
|
||||
BorderSpacing.Around = 6
|
||||
Caption = 'chkUseValgrind'
|
||||
@ -164,9 +163,9 @@ inherited CompilerLinkingOptionsFrame: TCompilerLinkingOptionsFrame
|
||||
AnchorSideRight.Control = grpDebugging
|
||||
AnchorSideRight.Side = asrBottom
|
||||
Left = 6
|
||||
Height = 22
|
||||
Top = 95
|
||||
Width = 681
|
||||
Height = 19
|
||||
Top = 85
|
||||
Width = 685
|
||||
Anchors = [akTop, akLeft, akRight]
|
||||
BorderSpacing.Around = 6
|
||||
Caption = 'chkUseExternalDbgSyms'
|
||||
@ -178,13 +177,13 @@ inherited CompilerLinkingOptionsFrame: TCompilerLinkingOptionsFrame
|
||||
AnchorSideTop.Control = lblEmpty
|
||||
AnchorSideRight.Control = grpDebugging
|
||||
AnchorSideRight.Side = asrBottom
|
||||
Left = 140
|
||||
Height = 27
|
||||
Left = 114
|
||||
Height = 23
|
||||
Top = 6
|
||||
Width = 547
|
||||
Width = 577
|
||||
Anchors = [akTop, akLeft, akRight]
|
||||
BorderSpacing.Around = 6
|
||||
ItemHeight = 0
|
||||
ItemHeight = 15
|
||||
Style = csDropDownList
|
||||
TabOrder = 2
|
||||
end
|
||||
@ -193,9 +192,9 @@ inherited CompilerLinkingOptionsFrame: TCompilerLinkingOptionsFrame
|
||||
AnchorSideTop.Control = dropDbgSymbolType
|
||||
AnchorSideTop.Side = asrCenter
|
||||
Left = 6
|
||||
Height = 18
|
||||
Top = 10
|
||||
Width = 128
|
||||
Height = 16
|
||||
Top = 9
|
||||
Width = 102
|
||||
BorderSpacing.Around = 6
|
||||
Caption = 'lblDbgSymbolType'
|
||||
ParentColor = False
|
||||
@ -204,7 +203,7 @@ inherited CompilerLinkingOptionsFrame: TCompilerLinkingOptionsFrame
|
||||
Left = 0
|
||||
Height = 1
|
||||
Top = 0
|
||||
Width = 693
|
||||
Width = 697
|
||||
Align = alTop
|
||||
ParentColor = False
|
||||
end
|
||||
@ -216,21 +215,21 @@ inherited CompilerLinkingOptionsFrame: TCompilerLinkingOptionsFrame
|
||||
AnchorSideRight.Control = Owner
|
||||
AnchorSideRight.Side = asrBottom
|
||||
Left = 0
|
||||
Height = 111
|
||||
Top = 184
|
||||
Height = 99
|
||||
Top = 165
|
||||
Width = 701
|
||||
Anchors = [akTop, akLeft, akRight]
|
||||
AutoSize = True
|
||||
BorderSpacing.Top = 6
|
||||
Caption = 'grpDebug2'
|
||||
ClientHeight = 90
|
||||
ClientWidth = 693
|
||||
ClientHeight = 81
|
||||
ClientWidth = 697
|
||||
TabOrder = 5
|
||||
object chkUseHeaptrc: TCheckBox
|
||||
Left = 6
|
||||
Height = 22
|
||||
Height = 19
|
||||
Top = 6
|
||||
Width = 681
|
||||
Width = 685
|
||||
Align = alTop
|
||||
BorderSpacing.Around = 6
|
||||
Caption = 'chkUseHeaptrc'
|
||||
@ -242,9 +241,9 @@ inherited CompilerLinkingOptionsFrame: TCompilerLinkingOptionsFrame
|
||||
AnchorSideRight.Control = grpDebug2
|
||||
AnchorSideRight.Side = asrBottom
|
||||
Left = 6
|
||||
Height = 22
|
||||
Top = 34
|
||||
Width = 681
|
||||
Height = 19
|
||||
Top = 31
|
||||
Width = 685
|
||||
Anchors = [akTop, akLeft, akRight]
|
||||
BorderSpacing.Around = 6
|
||||
Caption = 'chkGenGProfCode'
|
||||
@ -256,9 +255,9 @@ inherited CompilerLinkingOptionsFrame: TCompilerLinkingOptionsFrame
|
||||
AnchorSideRight.Control = grpDebug2
|
||||
AnchorSideRight.Side = asrBottom
|
||||
Left = 6
|
||||
Height = 22
|
||||
Top = 62
|
||||
Width = 681
|
||||
Height = 19
|
||||
Top = 56
|
||||
Width = 685
|
||||
Anchors = [akTop, akLeft, akRight]
|
||||
BorderSpacing.Around = 6
|
||||
Caption = 'chkSymbolsStrip'
|
||||
|
@ -101,7 +101,7 @@ begin
|
||||
lblDbgSymbolType.Caption := dlgCOSymbolType;
|
||||
dropDbgSymbolType.Items.Clear;
|
||||
// Adjust constants above, if re-ordering
|
||||
dropDbgSymbolType.Items.Add(dlgCOSymbolTypeAuto); // 0: automatic
|
||||
dropDbgSymbolType.Items.Add(dlgCOSymbolTypeAuto+' (-g)'); // 0: automatic
|
||||
dropDbgSymbolType.Items.Add(dlgCOSymbolTypeDwarf2Set+ '(-gw -godwarfsets)'); // 1: dwarf2 + set
|
||||
dropDbgSymbolType.Items.Add(dlgCOSymbolTypeDwarf2+ '(-gw2)'); // 2: dwarf2
|
||||
dropDbgSymbolType.Items.Add(dlgCOSymbolTypeStabs+ '(-gs)'); // 3: stabs
|
||||
@ -146,9 +146,6 @@ begin
|
||||
chkWin32GraphicApp.Checked := Win32GraphicApp;
|
||||
chkWin32GraphicApp.Enabled := NeedsLinkerOpts;
|
||||
grpOptions.Enabled := NeedsLinkerOpts;
|
||||
|
||||
dropDbgSymbolType.Items[0] := dlgCOSymbolTypeAuto
|
||||
+ ' (' + dropDbgSymbolType.Items[SymbolToIndex(DbgSymbolTypeDefault)] + ')';
|
||||
end;
|
||||
|
||||
grpDebugging.Enabled := chkDebugGDB.Checked;
|
||||
|
Loading…
Reference in New Issue
Block a user