Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 16 Mar 2023 04:08:23 GMT
From:      Alexey Dokuchaev <danfe@FreeBSD.org>
To:        ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org
Subject:   git: e937590c1b0a - main - editors/mickey: new port had been added (+)
Message-ID:  <202303160408.32G48NHZ075634@gitrepo.freebsd.org>

next in thread | raw e-mail | index | archive | help
The branch main has been updated by danfe:

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

commit e937590c1b0a1944f5d6901aa02b83602ad1e004
Author:     Alexey Dokuchaev <danfe@FreeBSD.org>
AuthorDate: 2023-03-16 04:07:34 +0000
Commit:     Alexey Dokuchaev <danfe@FreeBSD.org>
CommitDate: 2023-03-16 04:07:34 +0000

    editors/mickey: new port had been added (+)
    
    Mickey is a hexadecimal/ASCII file viewer and editor that runs on all
    major operating systems thanks to FLTK.  It supports various integer
    and floating-point data types, and allows to work with multiple files
    simultaneously via well-known tabbed interface.
    
    WWW: https://mickey.sourceforge.net/
---
 editors/Makefile                       |  1 +
 editors/mickey/Makefile                | 27 +++++++++++++++
 editors/mickey/distinfo                |  3 ++
 editors/mickey/files/patch-hexEdit.cxx | 60 ++++++++++++++++++++++++++++++++++
 editors/mickey/pkg-descr               |  5 +++
 5 files changed, 96 insertions(+)

diff --git a/editors/Makefile b/editors/Makefile
index 1564f461f655..621b355ef608 100644
--- a/editors/Makefile
+++ b/editors/Makefile
@@ -205,6 +205,7 @@
     SUBDIR += lite-xl
     SUBDIR += marker
     SUBDIR += mg
+    SUBDIR += mickey
     SUBDIR += micro
     SUBDIR += mined
     SUBDIR += mle
diff --git a/editors/mickey/Makefile b/editors/mickey/Makefile
new file mode 100644
index 000000000000..a8b8250b38de
--- /dev/null
+++ b/editors/mickey/Makefile
@@ -0,0 +1,27 @@
+PORTNAME=	mickey
+PORTVERSION=	0.1.13
+CATEGORIES=	editors
+MASTER_SITES=	SF/${PORTNAME}/${PORTNAME}/${PORTNAME}-${PORTVERSION}
+DISTNAME=	${PORTNAME}-${PORTVERSION}.src
+
+MAINTAINER=	danfe@FreeBSD.org
+COMMENT=	Simple hexadecimal editor written in FLTK
+WWW=		https://mickey.sourceforge.net/
+
+LICENSE=	GPLv2
+
+LIB_DEPENDS=	libfltk.so:x11-toolkits/fltk
+
+USES=		zip
+WRKSRC=		${WRKDIR}/hexedit
+
+PLIST_FILES=	bin/${PORTNAME}
+
+do-build:
+	cd ${BUILD_WRKSRC} && ${CXX} ${CXXFLAGS} -I${LOCALBASE}/include \
+		hexEdit.cxx -o ${PORTNAME} -lfltk -L${LOCALBASE}/lib
+
+do-install:
+	${INSTALL_PROGRAM} ${WRKSRC}/${PORTNAME} ${STAGEDIR}${PREFIX}/bin
+
+.include <bsd.port.mk>
diff --git a/editors/mickey/distinfo b/editors/mickey/distinfo
new file mode 100644
index 000000000000..73f80110f762
--- /dev/null
+++ b/editors/mickey/distinfo
@@ -0,0 +1,3 @@
+TIMESTAMP = 1084813428
+SHA256 (mickey-0.1.13.src.zip) = 9a5a53e21c03c4ccd572a52f332cf88328109758efe97f9e3016c7a11f06e5b7
+SIZE (mickey-0.1.13.src.zip) = 22332
diff --git a/editors/mickey/files/patch-hexEdit.cxx b/editors/mickey/files/patch-hexEdit.cxx
new file mode 100644
index 000000000000..cfc9c78e6560
--- /dev/null
+++ b/editors/mickey/files/patch-hexEdit.cxx
@@ -0,0 +1,60 @@
+--- hexEdit.cxx.orig	2004-05-14 05:08:34 UTC
++++ hexEdit.cxx
+@@ -250,27 +250,27 @@ Fl_Menu_Item HeMenubar::itemList[] = {
+   {   UL"New", MM_CMD+'n', newCB, 0, 0, MM_MENUSTYLE },
+   {   UL"Open...", MM_CMD+'o', openCB, 0, FL_MENU_DIVIDER, MM_MENUSTYLE },
+   {   UL"Save", MM_CMD+'s', saveCB, 0, 0, MM_MENUSTYLE },
+-  {   "Save "UL"As...", FL_SHIFT+MM_CMD+'s', saveAsCB, 0, 0, MM_MENUSTYLE },
++  {   "Save " UL"As...", FL_SHIFT+MM_CMD+'s', saveAsCB, 0, 0, MM_MENUSTYLE },
+   {   UL"Close", MM_CMD+'w', closeCB, 0, FL_MENU_DIVIDER, MM_MENUSTYLE },
+-  {   "E"UL"xit mickey", MM_CMD+'q', quitCB, 0, 0, MM_MENUSTYLE },
++  {   "E" UL"xit mickey", MM_CMD+'q', quitCB, 0, 0, MM_MENUSTYLE },
+   {   0 },
+   { UL"Edit", 0, 0, 0, FL_SUBMENU, MM_MENUSTYLE },
+   {   UL"Undo", MM_CMD+'z', 0, 0, FL_MENU_INACTIVE, MM_MENUSTYLE },
+   {   UL"Redo", FL_SHIFT+MM_CMD+'z', 0, 0, FL_MENU_INACTIVE|FL_MENU_DIVIDER, 
+     MM_MENUSTYLE },
+-  {   "C"UL"ut", MM_CMD+'x', cutCB, 0, 0, MM_MENUSTYLE },
++  {   "C" UL"ut", MM_CMD+'x', cutCB, 0, 0, MM_MENUSTYLE },
+   {   UL"Copy", MM_CMD+'c', copyCB, 0, 0, MM_MENUSTYLE },
+   {   UL"Paste", MM_CMD+'v', pasteCB, 0, 0, MM_MENUSTYLE },
+   {   UL"Delete", 0, 0, 0, FL_MENU_INACTIVE, MM_MENUSTYLE },
+-  {   "Select "UL"All", MM_CMD+'a', 0, 0, FL_MENU_INACTIVE|FL_MENU_DIVIDER, 
++  {   "Select " UL"All", MM_CMD+'a', 0, 0, FL_MENU_INACTIVE|FL_MENU_DIVIDER,
+     MM_MENUSTYLE },
+   {   UL"Insert", MM_CMD+'i', insertModeCB, (void*)1, 0, MM_MENUSTYLE },
+   {   UL"Overwrite", FL_SHIFT+MM_CMD+'i', insertModeCB, 0, 0, MM_MENUSTYLE },
+   {   0 },
+   { UL"Find", 0, 0, 0, FL_SUBMENU, MM_MENUSTYLE },
+   {   UL"Find", MM_CMD+'f', 0, 0, FL_MENU_INACTIVE, MM_MENUSTYLE },
+-  {   "Find && "UL"Replace", MM_CMD+'h', 0, 0, FL_MENU_INACTIVE, MM_MENUSTYLE },
+-  {   "Find "UL"Next", MM_CMD+'g', 0, 0, FL_MENU_INACTIVE, MM_MENUSTYLE },
++  {   "Find && " UL"Replace", MM_CMD+'h', 0, 0, FL_MENU_INACTIVE, MM_MENUSTYLE },
++  {   "Find " UL"Next", MM_CMD+'g', 0, 0, FL_MENU_INACTIVE, MM_MENUSTYLE },
+   {   0 },
+   { UL"Help", 0, 0, 0, FL_SUBMENU, MM_MENUSTYLE },
+   {   UL"About mickey...", 0, aboutCB, 0, 0, MM_MENUSTYLE },
+@@ -342,12 +342,12 @@ void HeMenubar::pasteCB(Fl_Widget*, void*) {
+ void HeMenubar::insertModeCB(Fl_Widget*, void *userdata) {
+   //++ should the insert mode by per application or per document?
+   if (!app->document()) return;
+-  int i = (int)userdata;
++  int i = reinterpret_cast<intptr_t>(userdata);
+   app->document()->manager()->insertMode(i);
+ }
+ 
+ void HeMenubar::aboutCB(Fl_Widget*, void*) {
+-  fl_message("mickey "MM_VERSION"\n"MM_COPYRIGHT"\n\n"
++  fl_message("mickey " MM_VERSION"\n" MM_COPYRIGHT"\n\n"
+              "a free cross platform hex editor\n\n"
+              MM_WEB);
+ }
+@@ -1683,7 +1683,7 @@ HeCycleButton::HeCycleButton(int x, int y, int w, int 
+   box(FL_PLASTIC_UP_BOX);
+   choice = 0; nChoice = n;
+   warn = 0;
+-  labels = new (char*)[n];
++  labels = new char*[n];
+   labels[0] = t;
+   va_list va;
+   va_start(va, t);
diff --git a/editors/mickey/pkg-descr b/editors/mickey/pkg-descr
new file mode 100644
index 000000000000..e7ea9e87ca8b
--- /dev/null
+++ b/editors/mickey/pkg-descr
@@ -0,0 +1,5 @@
+Mickey is a hexadecimal/ASCII file viewer and editor that runs on all
+major operating systems thanks to FLTK.  It supports various integer
+and floating-point data types, and allows to work with multiple files
+simultaneously via well-known tabbed interface.  Unfortunately, there
+is no support for editing of very large files yet.



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202303160408.32G48NHZ075634>