Build fails on ARM
Original Reporter info from Mantis: vo.x
-
Reporter name: Vít Ondruch
Original Reporter info from Mantis: vo.x
- Reporter name: Vít Ondruch
Description:
Build of Lazarus 1.4 fails in Fedora Rawhide with following message:
/builddir/build/BUILD/lazarus-1.4/lazarus/components/tachart/./editors/tasubcomponentseditor.pas(60,29) Hint: (5024) Parameter "Sender" not used
(9009) Assembling tasubcomponentseditor
(1010) Writing Resource String Table file: tatransformations.rst
(9009) Assembling tatransformations
/builddir/build/BUILD/lazarus-1.4/lazarus/components/tachart/tachartaxis.pas(588,64) Hint: (5057) Local variable "rng" does not seem to be initialized
/builddir/build/BUILD/lazarus-1.4/lazarus/components/tachart/tachartaxis.pas(824,27) Error: (3035) range check error while evaluating constants
tachartaxis.pas(1253) Fatal: (10026) There were 1 errors compiling module, stopping
Fatal: (1018) Compilation aborted
Makefile:2587: recipe for target 'tachartlazaruspkg.ppu' failed
make[2]: Leaving directory '/builddir/build/BUILD/lazarus-1.4/lazarus/components/tachart'
Makefile:1568: recipe for target 'bigide' failed
make[1]: Leaving directory '/builddir/build/BUILD/lazarus-1.4/lazarus/components'
make[2]: *** [tachartlazaruspkg.ppu] Error 1
make[1]: *** [bigide] Error 2
make: *** [bigidecomponents] Error 2
Makefile:2314: recipe for target 'bigidecomponents' failed
I was able to fix the issues with following patch:
diff --git a/lazarus-1.4.0-fix-infinity.patch b/lazarus-1.4.0-fix-infinity.patch
new file mode 100644
index 0000000..8b1d036
--- /dev/null
+++ b/lazarus-1.4.0-fix-infinity.patch
@@ -0,0 +1,28 @@
+diff --git a/components/tachart/tachartaxis.pas b/components/tachart/tachartaxis.pas
+index c28374a..fb028b5 100644
+--- a/lazarus/components/tachart/tachartaxis.pas
++++ b/lazarus/components/tachart/tachartaxis.pas
+@@ -822,8 +822,8 @@ begin
+ FHelper.FZOffset.Y := Min(ZPosition, AMaxZPosition);
+ FHelper.FZOffset.X := -FHelper.FZOffset.Y;
+ FHelper.FAtDataOnly := AtDataOnly;
+- FHelper.FMaxForMarks := -infinity;
+- FHelper.FMinForMarks := infinity;
++ FHelper.FMaxForMarks := NegInfinity;
++ FHelper.FMinForMarks := SafeInfinity;
+ end;
+
+ procedure TChartAxis.SetAlignment(AValue: TChartAxisAlignment);
+diff --git a/components/tachart/tagraph.pas b/components/tachart/tagraph.pas
+index 73aad72..8d59b67 100644
+--- a/lazarus/components/tachart/tagraph.pas
++++ b/lazarus/components/tachart/tagraph.pas
+@@ -995,7 +995,7 @@ var
+ s: TBasicChartSeries;
+ mn, mx: Double;
+ begin
+- Result.FStart := Infinity;
++ Result.FStart := SafeInfinity;
+ Result.FEnd := NegInfinity;
+ for s in Series do
+ if s.Active and s.GetAxisBounds(AAxis, mn, mx) then begin
This patch fixes the issue for me, not sure if that is correct though.
Mantis conversion info:
- Mantis ID: 28386
- Version: 1.4
- Target version: 1.4.2