aboutsummaryrefslogtreecommitdiff
path: root/editors/imhex/Makefile
blob: abdfe8f9f757c179bb8f5be5a57af4e089d42fbc (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
# $FreeBSD$

PORTNAME=	imhex
PORTVERSION=	1.7.0
DISTVERSIONPREFIX=	v
PORTREVISION=	1
CATEGORIES=	editors

MAINTAINER=	nobutaka@FreeBSD.org
COMMENT=	Hex editor for reverse engineers and programmers

LICENSE=	GPLv2
LICENSE_FILE=	${WRKSRC}/LICENSE

NOT_FOR_ARCHS=	i386
NOT_FOR_ARCHS_REASON=	__uint128_t and __int128_t are not supported

BUILD_DEPENDS=	c++10:lang/gcc10 \
		glm>0:math/glm \
		nlohmann-json>0:devel/nlohmann-json
LIB_DEPENDS=	libcapstone.so:devel/capstone4 \
		libmbedtls.so:security/mbedtls \
		libfreetype.so:print/freetype2 \
		libglfw.so:graphics/glfw \
		libstdc++.so:lang/gcc10 \
		libtre.so:textproc/libtre

USES=		cmake pkgconfig python:3.8+ xorg
USE_XORG=	x11 xcb xau xdmcp
USE_GITHUB=	yes
GH_ACCOUNT=	WerWolv
GH_PROJECT=	ImHex

CC=	${LOCALBASE}/bin/gcc10
CXX=	${LOCALBASE}/bin/c++10

PORTDOCS=	README.md

OPTIONS_DEFINE=	DOCS NLS
NLS_USES=	gettext

post-patch:
	${REINPLACE_CMD} -e "s|%%PREFIX%%|${PREFIX}|" ${WRKSRC}/source/window.cpp

post-install:
	${STRIP_CMD} ${STAGEDIR}${PREFIX}/share/imhex/plugins/builtin.hexplug
	${STRIP_CMD} ${STAGEDIR}${PREFIX}/share/imhex/plugins/example.hexplug

post-install-DOCS-on:
	${MKDIR} ${STAGEDIR}${DOCSDIR}
	${INSTALL_DATA} ${WRKSRC}/README.md ${STAGEDIR}${DOCSDIR}

.include <bsd.port.mk>