git: 17d6b4bb0dd7 - main - graphics/lazpaint: Add aarch64 support

Jose Alonso Cardenas Marquez <[email protected]>
Newsgroups gmane.os.freebsd.devel.cvs.ports
Message-ID <[email protected]>
The branch main has been updated by acm:

URL: https://cgit.FreeBSD.org/ports/commit/?id=17d6b4bb0dd7e1c4c5b4203e72372c9ec6f7cb75

commit 17d6b4bb0dd7e1c4c5b4203e72372c9ec6f7cb75
Author:     Jose Alonso Cardenas Marquez <[email protected]>
AuthorDate: 2026-08-18 22:09:36 +0000
Commit:     Jose Alonso Cardenas Marquez <[email protected]>
CommitDate: 2026-08-18 22:09:36 +0000

    graphics/lazpaint: Add aarch64 support
    
    - Bump PORTREVISION
    
    Reported by:    fluffy
    Obtained from:  https://people.freebsd.org/~fluffy/-patches/graphics_lazpaint-7.3_10.diff
---
 graphics/lazpaint/Makefile                         |  6 ++---
 .../files/patch-lazpaint_getfilesindir.inc         | 29 ++++++++++++++++++++++
 graphics/lazpaint/files/patch-lazpaint_uconfig.pas | 20 +++++++++++++++
 graphics/lazpaint/files/patch-lazpaint_ugraph.pas  |  6 ++---
 .../lazpaint/files/patch-lazpaint_utranslation.pas | 22 +++++++++++++---
 5 files changed, 74 insertions(+), 9 deletions(-)

diff --git a/graphics/lazpaint/Makefile b/graphics/lazpaint/Makefile
index 3ed06ed432e0..0dac79bd6a85 100644
--- a/graphics/lazpaint/Makefile
+++ b/graphics/lazpaint/Makefile
@@ -1,7 +1,7 @@
 PORTNAME=	lazpaint
 PORTVERSION=	7.3
 DISTVERSIONPREFIX=	v
-PORTREVISION=	10
+PORTREVISION=	11
 CATEGORIES=	graphics
 PKGNAMESUFFIX=	${LAZARUS_PKGNAMESUFFIX}
 
@@ -11,7 +11,7 @@ WWW=		https://wiki.freepascal.org/LazPaint
 
 LICENSE=	GPLv3
 
-ONLY_FOR_ARCHS=	amd64 i386
+ONLY_FOR_ARCHS=	aarch64 amd64 i386
 
 gtk2_CONFLICTS_INSTALL=	${PORTNAME}-qt5 ${PORTNAME}-qt6
 qt5_CONFLICTS_INSTALL=	${PORTNAME}-gtk2 ${PORTNAME}-qt6
@@ -19,7 +19,7 @@ qt6_CONFLICTS_INSTALL=	${PORTNAME}-gtk2 ${PORTNAME}-qt5
 
 USES=		desktop-file-utils dos2unix fpc gnome lazarus:flavors xorg
 USE_XORG=	x11
-DOS2UNIX_REGEX=	.*\.([txt]|pas|lpi|txt)
+DOS2UNIX_REGEX=	.*\.([txt]|pas|lpi|txt|inc)
 USE_GITHUB=	yes
 GH_TAGNAME=	a11930b
 GH_ACCOUNT=	bgrabitmap
diff --git a/graphics/lazpaint/files/patch-lazpaint_getfilesindir.inc b/graphics/lazpaint/files/patch-lazpaint_getfilesindir.inc
new file mode 100644
index 000000000000..85a3e394168e
--- /dev/null
+++ b/graphics/lazpaint/files/patch-lazpaint_getfilesindir.inc
@@ -0,0 +1,29 @@
+--- lazpaint/getfilesindir.inc.orig	2026-08-18 21:04:48 UTC
++++ lazpaint/getfilesindir.inc
+@@ -56,7 +56,7 @@ var
+   MaskList: TMaskList = nil;
+   Files: TList;
+   FileItem: TFileItem;
+-  MaskOptions: TMaskOptions;
++  MaskOptions: TMaskOpCodes;
+   {$if defined(windows) and not defined(wince)}
+   ErrMode : LongWord;
+   {$endif}
+@@ -86,15 +86,8 @@ begin
+       //this behaviour would be incompatible with the situation if no MaskList was used
+       //and it would break backwards compatibilty and could raise unexpected EConvertError where it did not in the past.
+       //If you need sets in the MaskList, use the OnAddItem event for that. (BB)
+-      MaskOptions := [moDisableSets];
+-      {$ifdef NotLiteralFilenames}
+-      if (ACaseSensitivity = mcsCaseSensitive) then
+-        MaskOptions := [moDisableSets, moCaseSensitive];
+-      {$else}
+-      if (ACaseSensitivity <> mcsCaseInsensitive) then
+-        MaskOptions := [moDisableSets, moCaseSensitive];
+-      {$endif}
+-      MaskList := TMaskList.Create(AMask, ';', MaskOptions);  //False by default
++      MaskOptions := MaskOpCodesDisableRange;
++      MaskList := TMaskList.Create(AMask, ';', True, MaskOptions);  //False by default
+     end;
+ 
+     try
diff --git a/graphics/lazpaint/files/patch-lazpaint_uconfig.pas b/graphics/lazpaint/files/patch-lazpaint_uconfig.pas
new file mode 100644
index 000000000000..44816329992c
--- /dev/null
+++ b/graphics/lazpaint/files/patch-lazpaint_uconfig.pas
@@ -0,0 +1,20 @@
+--- lazpaint/uconfig.pas.orig	2026-08-18 19:34:32 UTC
++++ lazpaint/uconfig.pas
+@@ -371,7 +371,7 @@ implementation
+ 
+ implementation
+ 
+-uses uparse, LCLProc, BGRAUTF8, LazFileUtils, UFileSystem, UDarkTheme;
++uses uparse, LCLProc, BGRAUTF8, LazFileUtils, UFileSystem, UDarkTheme, GraphMath;
+ 
+ const maxRecentFiles = 10;
+       maxRecentDirectories = 10;
+@@ -1841,7 +1841,7 @@ begin
+ begin
+   currentScreenSize := rect(0,0,screen.Width,screen.Height);
+   previousScreenSize := DefaultScreenSize;
+-  if not CompareRect(@previousScreenSize,@currentScreenSize.left) then
++  if not SameRect(@previousScreenSize,@currentScreenSize.left) then
+   begin
+     SetDefaultScreenSize(currentScreenSize);
+     result := true;
diff --git a/graphics/lazpaint/files/patch-lazpaint_ugraph.pas b/graphics/lazpaint/files/patch-lazpaint_ugraph.pas
index 14726d6d64ad..79f8fe662150 100644
--- a/graphics/lazpaint/files/patch-lazpaint_ugraph.pas
+++ b/graphics/lazpaint/files/patch-lazpaint_ugraph.pas
@@ -1,6 +1,6 @@
---- lazpaint/ugraph.pas	2025-06-03 00:14:12.239399000 -0700
-+++ lazpaint/ugraph.pas	2025-06-03 00:14:45.095187000 -0700
-@@ -1206,7 +1206,7 @@
+--- lazpaint/ugraph.pas.orig	2026-08-18 19:05:41 UTC
++++ lazpaint/ugraph.pas
+@@ -1206,7 +1206,7 @@ begin
    w := FramePenWidth*ACanvasScale/10 / 2 + 1;
    rF := EmptyRectF;
    for pt in APoints do
diff --git a/graphics/lazpaint/files/patch-lazpaint_utranslation.pas b/graphics/lazpaint/files/patch-lazpaint_utranslation.pas
index fffd78029ac3..57c01249eb94 100644
--- a/graphics/lazpaint/files/patch-lazpaint_utranslation.pas
+++ b/graphics/lazpaint/files/patch-lazpaint_utranslation.pas
@@ -1,6 +1,6 @@
---- lazpaint/utranslation.pas	2021-02-18 08:49:03.053438000 -0500
-+++ lazpatin/utranslation.pas	2021-02-18 09:04:38.021589000 -0500
-@@ -85,7 +85,11 @@
+--- lazpaint/utranslation.pas.orig	2026-08-18 19:05:41 UTC
++++ lazpaint/utranslation.pas
+@@ -85,7 +85,11 @@ begin
        else
        {$ENDIF}
      {$ENDIF}
@@ -13,3 +13,19 @@
    {$ENDIF}
  end;
  
+@@ -164,12 +168,10 @@ function FallbackLanguage: string;
+ end;
+ 
+ function FallbackLanguage: string;
+-var Lang,FallbackLang: string;
++var LanguageInfo: TLanguageID;
+ begin
+-  Lang:='';
+-  FallbackLang:='';
+-  LazGetLanguageIDs(Lang,FallbackLang);
+-  result := FallbackLang;
++  LanguageInfo := GetLanguageID;
++  result := LanguageInfo.LanguageCode;
+ end;
+ 
+ //translate program
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.