summaryrefslogtreecommitdiff
path: root/app-editors
diff options
context:
space:
mode:
authorMart Raudsepp <leio@gentoo.org>2018-01-05 02:18:09 +0200
committerMart Raudsepp <leio@gentoo.org>2018-01-05 02:36:40 +0200
commitce7af7ddc191da1193a220c050d094c657c9658b (patch)
tree054471d3e414a0642d35658ae975c97095f1aa0d /app-editors
parent27a83a252dcdf19df21da8a2ed842a9212120f48 (diff)
downloadgentoo-ce7af7ddc191da1193a220c050d094c657c9658b.tar.gz
gentoo-ce7af7ddc191da1193a220c050d094c657c9658b.tar.xz
app-editors/wxhexeditor: bump to 0.24, use gtk3, other improvements
* Update HOMEPAGE * Use wxGTK:3.0-gtk3, seems to work on a fast test, please report any regressions * Port to EAPI-6 * Update syslibs patch to apply against 0.24 and not add hardcoded -O2 to build * Remove l10n.eclass usage as intended during LINGUAS IUSE deEXPANDing * The upstream bump itself fixes compilation failure with gcc7 Closes: https://bugs.gentoo.org/639740 Package-Manager: Portage-2.3.19, Repoman-2.3.6
Diffstat (limited to 'app-editors')
-rw-r--r--app-editors/wxhexeditor/Manifest1
-rw-r--r--app-editors/wxhexeditor/files/wxhexeditor-0.24-syslibs.patch76
-rw-r--r--app-editors/wxhexeditor/wxhexeditor-0.24.ebuild40
3 files changed, 117 insertions, 0 deletions
diff --git a/app-editors/wxhexeditor/Manifest b/app-editors/wxhexeditor/Manifest
index c81cb377963..2ed195788c7 100644
--- a/app-editors/wxhexeditor/Manifest
+++ b/app-editors/wxhexeditor/Manifest
@@ -1 +1,2 @@
DIST wxHexEditor-v0.23-src.tar.bz2 2534659 BLAKE2B 932b2d9ab14dee71b5f5f57d89bc71c190c136c106339563ade44ea47e47819c4fdb32511296c14b3bebdfedd55a331c74e9a722e1d54e22ba53d203f753b57d SHA512 abbd2338c2d0d7d514342f5c330ea42c9ee1f3489c4661426927f51c802a7806e4ee965fa5d467c7b928ba87395eb6c351ab5f43f18d5fce836adede5f1d6be4
+DIST wxHexEditor-v0.24-src.tar.xz 900868 BLAKE2B 6748249d75e7570197a6c78378a8f3109bfa4c72bf32fe63e2abd31734d97fda3d56ecddb52ac5f9a18cc77b2c727f8277688f1bf75ef8f665a3a9cefd1cb8a6 SHA512 8589da169c90cca5abf6ba957d5c5e17e4211123dbdbaf0e04d31757113e7e302d40df58144ec25d431c7c4ce2fa2721b16621d03630ac8b90478c704a8c5b09
diff --git a/app-editors/wxhexeditor/files/wxhexeditor-0.24-syslibs.patch b/app-editors/wxhexeditor/files/wxhexeditor-0.24-syslibs.patch
new file mode 100644
index 00000000000..af874128eac
--- /dev/null
+++ b/app-editors/wxhexeditor/files/wxhexeditor-0.24-syslibs.patch
@@ -0,0 +1,76 @@
+Use system copies of mhash and udis86.
+Also pass -fopenmp when linking to avoid build errors.
+Remove -O2 from forced CXXFLAGS.
+
+--- a/Makefile
++++ b/Makefile
+@@ -1,9 +1,9 @@
+ WXCONFIG ?= wx-config
+ HOST=
+-WXCXXFLAGS= `$(WXCONFIG) --cxxflags` -Iudis86 -Imhash/include -MMD -fopenmp -Wall -O2
++WXCXXFLAGS= `$(WXCONFIG) --cxxflags` -MMD -fopenmp -Wall
+ WXLDFLAGS = `$(WXCONFIG) --libs` `$(WXCONFIG) --libs aui` `$(WXCONFIG) --libs core`
+ WXCXXFLAGS += -fopenmp
+-LDFLAGS += -lgomp
++LDFLAGS += -fopenmp -lgomp
+ #add this ldflags for WinConsole "-Wl,--subsystem,console -mconsole" for win-debug
+ #LDFLAGS += -Wl,--subsystem,console -mconsole
+ RC = `$(WXCONFIG) --rescomp`
+@@ -22,7 +22,7 @@ SOURCES= src/HexEditorGui.cpp \
+ src/HexEditorCtrl/wxHexCtrl/Tag.cpp\
+ src/HexEditorCtrl/HexEditorCtrlGui.cpp\
+ src/HexEditorFrame.cpp
+-LIBS = udis86/libudis86/.libs/libudis86.a mhash/lib/.libs/libmhash.a
++LIBS = -ludis86 -lmhash
+ OBJECTS=$(SOURCES:.cpp=.o)
+ DEPENDS=$(OBJECTS:.o=.d)
+ LANGUAGEDIRS=`ls -l ./locale | grep ^d | sed s/.*\ //g;`
+@@ -68,15 +68,6 @@ langs: $(MOBJECTS)
+ %.mo : %.po
+ $(MSGFMT) $< -o $@
+
+-udis86/libudis86/.libs/libudis86.a:
+- cd udis86;./autogen.sh
+- cd udis86;./configure --host=$(HOST) CC="$(CC)" CXX="$(CXX)" CFLAGS="$(CFLAGS) ${OPTFLAGS}" CXXFLAGS="$(CXXFLAGS) ${OPTFLAGS}" CPPFLAGS="$(CPPFLAGS)"
+- cd udis86/libudis86; $(MAKE) $(MFLAGS)
+-
+-mhash/lib/.libs/libmhash.a:
+- cd mhash; ./configure --host=$(HOST) CC="$(CC)" CXX="$(CXX)" CFLAGS="$(CFLAGS) ${OPTFLAGS}" CXXFLAGS="$(CXXFLAGS) ${OPTFLAGS}" CPPFLAGS="$(CPPFLAGS)"
+- cd mhash; $(MAKE) $(MFLAGS)
+-
+ src/windrv.o:
+ $(CXX) $(LIBS) ${CXXFLAGS} ${OPTFLAGS} $(WXCXXFLAGS) $(WXLDFLAGS) ${LDFLAGS} -c src/windrv.cpp -o src/windrv.o
+
+--- a/src/HexDialogs.cpp
++++ b/src/HexDialogs.cpp
+@@ -24,7 +24,7 @@
+ #define NANINT 0xFFFFFFFFFFFFFFFFLL
+ #include "HexDialogs.h"
+ #include <wx/progdlg.h>
+-#include "../mhash/include/mhash.h"
++#include <mhash.h>
+
+ #ifdef __SSE2__
+ #include <emmintrin.h>
+--- a/src/HexEditor.h
++++ b/src/HexEditor.h
+@@ -25,7 +25,7 @@
+ #ifndef _wxHexEditor_h_
+ #define _wxHexEditor_h_
+
+-#include "../mhash/include/mhash.h"
++#include <mhash.h>
+
+ #include <wx/ffile.h>
+ #include <wx/clipbrd.h>
+--- a/src/HexPanels.h
++++ b/src/HexPanels.h
+@@ -27,7 +27,7 @@
+ #include "HexEditorFrame.h"
+ #include "HexEditorCtrl/HexEditorCtrl.h"
+ #include "HexEditorCtrl/wxHexCtrl/wxHexCtrl.h"
+-#include "../udis86/udis86.h"
++#include <udis86.h>
+
+ #ifdef WX_GCH
+ #include <wx_pch.h>
diff --git a/app-editors/wxhexeditor/wxhexeditor-0.24.ebuild b/app-editors/wxhexeditor/wxhexeditor-0.24.ebuild
new file mode 100644
index 00000000000..a9a2abcec25
--- /dev/null
+++ b/app-editors/wxhexeditor/wxhexeditor-0.24.ebuild
@@ -0,0 +1,40 @@
+# Copyright 1999-2018 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=6
+WX_GTK_VER=3.0-gtk3
+
+inherit toolchain-funcs wxwidgets
+
+MY_PN="wxHexEditor"
+
+DESCRIPTION="A cross-platform hex editor designed specially for large files"
+HOMEPAGE="http://www.wxhexeditor.org/"
+SRC_URI="mirror://sourceforge/${PN}/${MY_PN}-v${PV}-src.tar.xz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~x86"
+IUSE=""
+
+DEPEND="
+ app-crypt/mhash
+ dev-libs/udis86
+ x11-libs/wxGTK:${WX_GTK_VER}[X]"
+RDEPEND="${DEPEND}"
+
+S="${WORKDIR}/${MY_PN}"
+
+PATCHES=(
+ "${FILESDIR}"/${P}-syslibs.patch
+)
+
+pkg_pretend() {
+ tc-has-openmp \
+ || die "${PN} uses OpenMP libraries. Please use an OpenMP-capable compiler."
+}
+
+src_prepare() {
+ setup-wxwidgets
+ default
+}