git: 244b1d01f757 - main - deskutils/notepadnext-devel: Add new port

From: Cy Schubert <cy_at_FreeBSD.org>
Date: Tue, 06 Feb 2024 05:08:32 UTC
The branch main has been updated by cy:

URL: https://cgit.FreeBSD.org/ports/commit/?id=244b1d01f757f217b403f48b25caeeeb059f9bed

commit 244b1d01f757f217b403f48b25caeeeb059f9bed
Author:     Cy Schubert <cy@FreeBSD.org>
AuthorDate: 2024-02-06 04:40:17 +0000
Commit:     Cy Schubert <cy@FreeBSD.org>
CommitDate: 2024-02-06 05:00:41 +0000

    deskutils/notepadnext-devel: Add new port
    
    This new port tracks the NotepadNext development branch. The development
    branch includes new features such as peristent bookmarks (as is in
    notepad++).
---
 editors/Makefile                                   |  1 +
 editors/notepadnext-devel/Makefile                 | 45 ++++++++++++++++++++++
 editors/notepadnext-devel/distinfo                 | 13 +++++++
 .../files/patch-src_NotepadNext_ScintillaNext.cpp  | 11 ++++++
 ...ch-src_ads_src_linux_FloatingWidgetTitleBar.cpp | 11 ++++++
 editors/notepadnext-devel/files/patch-src_i18n.pri | 31 +++++++++++++++
 editors/notepadnext-devel/pkg-descr                |  1 +
 7 files changed, 113 insertions(+)

diff --git a/editors/Makefile b/editors/Makefile
index afc08b6fb362..83c8645fed0a 100644
--- a/editors/Makefile
+++ b/editors/Makefile
@@ -216,6 +216,7 @@
     SUBDIR += neovim-gtk
     SUBDIR += neovim-qt
     SUBDIR += notepadnext
+    SUBDIR += notepadnext-devel
     SUBDIR += novelwriter
     SUBDIR += nvi-m17n
     SUBDIR += nvi2
diff --git a/editors/notepadnext-devel/Makefile b/editors/notepadnext-devel/Makefile
new file mode 100644
index 000000000000..3a1185e47429
--- /dev/null
+++ b/editors/notepadnext-devel/Makefile
@@ -0,0 +1,45 @@
+PORTNAME=	notepadnext
+DISTVERSIONPREFIX=	v
+PORTVERSION=	${NPNEXT_COMMIT_DATE}
+CATEGORIES=	editors
+PKGNAMESUFFIX=	-devel
+
+MAINTAINER=	cy@FreeBSD.org
+COMMENT=	Reimplementation of Notepad++
+WWW=		https://github.com/dail8859/NotepadNext
+
+LICENSE=	GPLv3
+LICENSE_FILE=	${WRKSRC}/LICENSE
+
+CONFLICTS=	notepadnext-[0-9]*
+
+LIB_DEPENDS=	libuchardet.so:textproc/uchardet
+
+USES=		desktop-file-utils gl qmake qt:5 xorg
+USE_QT=		core gui network printsupport widgets buildtools:build linguisttools:build
+USE_GL=		gl
+USE_XORG=	xcb
+
+USE_GITHUB=	yes
+GH_ACCOUNT=	dail8859
+GH_PROJECT=	NotepadNext
+GH_TAGNAME=	9b541cf
+NPNEXT_COMMIT_DATE=	2024.02.02
+
+GH_TUPLE=	alex-spataru:QSimpleUpdater:e4d8c73847d02eeafa1052ccb5cb5631ba3c40ae:alex_spataru_QSimpleUpdater/src/QSimpleUpdater \
+		editorconfig:editorconfig-core-qt:ee967262db4fdbd735f9971cc0c90cf4f3100d3a:editorconfig_editorconfig_core_qt/src/editorconfig-core-qt \
+			editorconfig:editorconfig-core-test:5ca0b296dc31124d0303895c163013450bd97958:editorconfig_editorconfig_core_test/src/editorconfig-core-qt/tests \
+		githubuser0xFFFF:Qt-Advanced-Docking-System:644c828f007fba8dda4292dde432f29f69793362:githubuser0xFFFF_Qt_Advanced_Docking_System/src/ads \
+		itay-grudev:SingleApplication:494772e98cef0aa88124f154feb575cc60b08b38:itay_grudev_SingleApplication/src/singleapplication
+
+QMAKE_SOURCE_PATH=	${WRKSRC}/src/NotepadNext.pro
+
+CXXFLAGS+=	-I${LOCALBASE}/include/uchardet
+LDFLAGS+=	-luchardet
+
+PLIST_FILES=	bin/NotepadNext \
+		share/applications/NotepadNext.desktop \
+		share/icons/hicolor/scalable/apps/NotepadNext.svg \
+		share/icons/hicolor/scalable/mimetypes/NotepadNext.svg
+
+.include <bsd.port.mk>
diff --git a/editors/notepadnext-devel/distinfo b/editors/notepadnext-devel/distinfo
new file mode 100644
index 000000000000..acb8f45d34d4
--- /dev/null
+++ b/editors/notepadnext-devel/distinfo
@@ -0,0 +1,13 @@
+TIMESTAMP = 1707195393
+SHA256 (dail8859-NotepadNext-v2024.02.02-9b541cf_GH0.tar.gz) = f351d5f88526b3177c37805d28f7509c612f9e5329bc0033c85f3cabaf74b9f7
+SIZE (dail8859-NotepadNext-v2024.02.02-9b541cf_GH0.tar.gz) = 5213935
+SHA256 (alex-spataru-QSimpleUpdater-e4d8c73847d02eeafa1052ccb5cb5631ba3c40ae_GH0.tar.gz) = 04d88d7dc3441fc18dbc008e43051947e7b2b53dd08ec07aa09dc2231f75bf47
+SIZE (alex-spataru-QSimpleUpdater-e4d8c73847d02eeafa1052ccb5cb5631ba3c40ae_GH0.tar.gz) = 298758
+SHA256 (editorconfig-editorconfig-core-qt-ee967262db4fdbd735f9971cc0c90cf4f3100d3a_GH0.tar.gz) = 7fe4a44b96676b08d446d22785ac078434138f4e0d834d9f44464a8fb3d0aa22
+SIZE (editorconfig-editorconfig-core-qt-ee967262db4fdbd735f9971cc0c90cf4f3100d3a_GH0.tar.gz) = 7309
+SHA256 (editorconfig-editorconfig-core-test-5ca0b296dc31124d0303895c163013450bd97958_GH0.tar.gz) = a1ca71c8f099c6ffc4fc1c0214732d4e27168fb2a5fbf2da47b5bc50fb7b5e79
+SIZE (editorconfig-editorconfig-core-test-5ca0b296dc31124d0303895c163013450bd97958_GH0.tar.gz) = 13689
+SHA256 (githubuser0xFFFF-Qt-Advanced-Docking-System-644c828f007fba8dda4292dde432f29f69793362_GH0.tar.gz) = d29e023d5dd4380b2f245e6bffa628c70e95577aee8a22b2ff01a9cf46ef276c
+SIZE (githubuser0xFFFF-Qt-Advanced-Docking-System-644c828f007fba8dda4292dde432f29f69793362_GH0.tar.gz) = 21521553
+SHA256 (itay-grudev-SingleApplication-494772e98cef0aa88124f154feb575cc60b08b38_GH0.tar.gz) = e1a3625c3e60413847b1e74d2e2fabcabe5863686d26b16ee76f011f0521e535
+SIZE (itay-grudev-SingleApplication-494772e98cef0aa88124f154feb575cc60b08b38_GH0.tar.gz) = 23324
diff --git a/editors/notepadnext-devel/files/patch-src_NotepadNext_ScintillaNext.cpp b/editors/notepadnext-devel/files/patch-src_NotepadNext_ScintillaNext.cpp
new file mode 100644
index 000000000000..cc17f4d44a2e
--- /dev/null
+++ b/editors/notepadnext-devel/files/patch-src_NotepadNext_ScintillaNext.cpp
@@ -0,0 +1,11 @@
+--- src/NotepadNext/ScintillaNext.cpp.orig	2022-05-26 23:25:10 UTC
++++ src/NotepadNext/ScintillaNext.cpp
+@@ -20,7 +20,7 @@
+ #include "ScintillaNext.h"
+ #include "ScintillaCommenter.h"
+ 
+-#include "uchardet.h"
++#include <uchardet.h>
+ #include <cinttypes>
+ 
+ #include <QDir>
diff --git a/editors/notepadnext-devel/files/patch-src_ads_src_linux_FloatingWidgetTitleBar.cpp b/editors/notepadnext-devel/files/patch-src_ads_src_linux_FloatingWidgetTitleBar.cpp
new file mode 100644
index 000000000000..e4f4d46cf8df
--- /dev/null
+++ b/editors/notepadnext-devel/files/patch-src_ads_src_linux_FloatingWidgetTitleBar.cpp
@@ -0,0 +1,11 @@
+--- src/ads/src/linux/FloatingWidgetTitleBar.cpp.orig	2023-04-08 00:42:57 UTC
++++ src/ads/src/linux/FloatingWidgetTitleBar.cpp
+@@ -194,7 +194,7 @@ void CFloatingWidgetTitleBar::mouseMoveEvent(QMouseEve
+ 	{
+ 		if(d->FloatingWidget->isMaximized())
+ 		{
+-			d->FloatingWidget->showNormal(true);
++			d->FloatingWidget->showNormal();
+ 		}
+ 		d->FloatingWidget->moveFloating();
+ 		Super::mouseMoveEvent(ev);
diff --git a/editors/notepadnext-devel/files/patch-src_i18n.pri b/editors/notepadnext-devel/files/patch-src_i18n.pri
new file mode 100644
index 000000000000..e49687b102c5
--- /dev/null
+++ b/editors/notepadnext-devel/files/patch-src_i18n.pri
@@ -0,0 +1,31 @@
+--- src/i18n.pri.orig	2023-10-20 04:05:44 UTC
++++ src/i18n.pri
+@@ -18,16 +18,16 @@
+ 
+ CONFIG += lrelease embed_translations
+ 
+-TRANSLATIONS = \
+-    ../../i18n/NotepadNext_zh_CN.ts \
+-    ../../i18n/NotepadNext_zh_TW.ts \
+-    ../../i18n/NotepadNext_sv_SE.ts \
+-    ../../i18n/NotepadNext_uk_UA.ts \
+-    ../../i18n/NotepadNext_tr_TR.ts
++#TRANSLATIONS = \
++#    ../../i18n/NotepadNext_zh_CN.ts \
++#    ../../i18n/NotepadNext_zh_TW.ts \
++#    ../../i18n/NotepadNext_sv_SE.ts \
++#    ../../i18n/NotepadNext_uk_UA.ts \
++#    ../../i18n/NotepadNext_tr_TR.ts
+ 
+-EXTRA_TRANSLATIONS = \
+-    $$[QT_INSTALL_TRANSLATIONS]/qt_zh_CN.qm \
+-    $$[QT_INSTALL_TRANSLATIONS]/qt_zh_TW.qm \
+-    $$[QT_INSTALL_TRANSLATIONS]/qt_sv.qm \
+-    $$[QT_INSTALL_TRANSLATIONS]/qt_uk.qm \
+-    $$[QT_INSTALL_TRANSLATIONS]/qt_tr.qm
++#EXTRA_TRANSLATIONS = \
++#    $$[QT_INSTALL_TRANSLATIONS]/qt_zh_CN.qm \
++#    $$[QT_INSTALL_TRANSLATIONS]/qt_zh_TW.qm \
++#    $$[QT_INSTALL_TRANSLATIONS]/qt_sv.qm \
++#    $$[QT_INSTALL_TRANSLATIONS]/qt_uk.qm \
++#    $$[QT_INSTALL_TRANSLATIONS]/qt_tr.qm
diff --git a/editors/notepadnext-devel/pkg-descr b/editors/notepadnext-devel/pkg-descr
new file mode 100644
index 000000000000..9fa3dc40787c
--- /dev/null
+++ b/editors/notepadnext-devel/pkg-descr
@@ -0,0 +1 @@
+Notepad Next is a cross-platform reimplementation of Notepad++.