mirror of
https://gitlab.com/freepascal.org/lazarus/lazarus.git
synced 2025-04-08 03:58:09 +02:00
LazBuild: Change 'get-exe-path' to 'get-target-path'. Do not check ConsoleVerbosity in case of an error. Issue #29511.
This commit is contained in:
parent
90cb99dafd
commit
0d5579dc3f
@ -174,9 +174,11 @@ resourcestring
|
||||
'info file after build. If not specified, build number will be incremented '+
|
||||
'if configured.';
|
||||
|
||||
lisGetExpandText = 'Print the result of substituting macros in the text for the specified build mode. By default, active build mode is used.';
|
||||
lisGetExpandText = 'Print the result of substituting macros in the text for the specified build mode.'
|
||||
+' By default, active build mode is used.';
|
||||
lisGetBuildModes = 'Print a list of build modes in the project. Active mode is listed first.';
|
||||
lisGetExePath = 'Print the full path to the executable file in the specified build mode. By default, active build mode is used.';
|
||||
lisGetTargetPath = 'Print the full path to the executable file in the specified build mode.'
|
||||
+' By default, active build mode is used.';
|
||||
|
||||
lisLazbuildOptionsSyntax = 'lazbuild [options] <project/package filename or package name>';
|
||||
|
||||
@ -4484,7 +4486,7 @@ resourcestring
|
||||
lisPkgMangThePackageIsMarkedForInstallationButCanNotBeFound = 'The package "%s" '
|
||||
+'is marked for installation but cannot be found.'
|
||||
+'%sRemove dependency from the installation list of packages?';
|
||||
lisERRORInvalidBuildMode = 'Error: (lazarus) invalid build mode "%s"';
|
||||
lisERRORInvalidBuildMode = 'Error: invalid build mode "%s"';
|
||||
lisAvailableProjectBuildModes = 'Available project build modes';
|
||||
lisThisProjectHasOnlyTheDefaultBuildMode = 'This project has only the default build mode.';
|
||||
lisPkgMangstaticPackagesConfigFile = 'static packages config file';
|
||||
|
@ -289,18 +289,13 @@ end;
|
||||
procedure ShowBuildModeError(const aBuildModeOverride: string);
|
||||
begin
|
||||
WriteLn(Format(lisERRORInvalidBuildMode, [aBuildModeOverride]));
|
||||
if ConsoleVerbosity>=0 then
|
||||
if Project1.BuildModes.Count>1 then
|
||||
begin
|
||||
WriteLn;
|
||||
if Project1.BuildModes.Count>1 then
|
||||
begin
|
||||
WriteLn(lisAvailableProjectBuildModes);
|
||||
ShowBuildModes;
|
||||
end else begin
|
||||
WriteLn(lisThisProjectHasOnlyTheDefaultBuildMode);
|
||||
end;
|
||||
WriteLn;
|
||||
end;
|
||||
WriteLn(lisAvailableProjectBuildModes);
|
||||
ShowBuildModes;
|
||||
end else
|
||||
WriteLn(lisThisProjectHasOnlyTheDefaultBuildMode);
|
||||
WriteLn;
|
||||
Halt(ErrorBuildFailed);
|
||||
end;
|
||||
|
||||
@ -836,7 +831,7 @@ var
|
||||
end;
|
||||
|
||||
TargetExeName := Project1.CompilerOptions.CreateTargetFilename;
|
||||
if HasOption('get-exe-path') then begin
|
||||
if HasOption('get-target-path') then begin
|
||||
WriteLn(TargetExeName);
|
||||
exit(true);
|
||||
end;
|
||||
@ -1632,7 +1627,7 @@ begin
|
||||
LongOptions.Add('no-write-project');
|
||||
LongOptions.Add('get-expand-text:');
|
||||
LongOptions.Add('get-build-modes');
|
||||
LongOptions.Add('get-exe-path');
|
||||
LongOptions.Add('get-target-path');
|
||||
ErrorMsg:=RepairedCheckOptions('lBrdq',LongOptions,Options,NonOptions);
|
||||
if ErrorMsg<>'' then begin
|
||||
writeln(ErrorMsg);
|
||||
@ -1917,8 +1912,8 @@ begin
|
||||
writeln('--get-build-modes');
|
||||
w(lisGetBuildModes);
|
||||
writeln('');
|
||||
writeln('--get-exe-path');
|
||||
w(lisGetExePath);
|
||||
writeln('--get-target-path');
|
||||
w(lisGetTargetPath);
|
||||
writeln('');
|
||||
end;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user