aboutsummaryrefslogtreecommitdiffstats
path: root/devel/udis86/Makefile
blob: 071a66e0d89876533f85c9b3f5af03c55031a57e (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
# Created by: Lutz Boehne <lboehne@damogran.de>
# $FreeBSD$

PORTNAME=   udis86
PORTVERSION=    1.7.1
CATEGORIES= devel
MASTER_SITES=   SF
MASTER_SITE_SUBDIR= ${PORTNAME:L}/${PORTNAME:L}/${PORTVERSION:R}

MAINTAINER= bf@FreeBSD.org
COMMENT=    Minimalistic x86 and x86-64 disassembler library

LICENSE=    BSD

USE_GMAKE=  yes

GNU_CONFIGURE=  yes
CONFIGURE_ARGS= --without-sphinx-build

INFO=       udis86
PORTDOCS=   x86

.include <bsd.port.options.mk>

post-patch:
.if ${PORT_OPTIONS:MDOCS}
    @${REINPLACE_CMD} -e '\|docdir =|s|/docs/|/doc/|' \
        ${WRKSRC}/docs/manual/Makefile.in \
        ${WRKSRC}/docs/x86/Makefile.in
.else
    @${REINPLACE_CMD} -e '/SUBDIRS \=/s/ docs//' ${WRKSRC}/Makefile.in
.endif

.if defined(MAINTAINER_MODE) || defined(PACKAGE_BUILDING)
BUILD_DEPENDS+=     ${LOCALBASE}/bin/yasm:${PORTSDIR}/devel/yasm
CONFIGURE_ENV+=     PYTHON="${PYTHON_CMD}" YASM="${LOCALBASE}/bin/yasm"
USE_PYTHON_BUILD=   yes

check regression-test test: build
    @cd ${WRKSRC} ; ${SETENV} ${MAKE_ENV} ${GMAKE} ${MAKE_ARGS} check

.else
CONFIGURE_ARGS+=    --without-yasm
CONFIGURE_ENV+=     PYTHON="${FALSE}"
.endif

post-install:
    @${INSTALL_DATA} ${WRKSRC}/docs/manual/udis86.info ${PREFIX}/${INFO_PATH}/

.include <bsd.port.mk>