summaryrefslogtreecommitdiffstats
path: root/archivers/dzip/Makefile
blob: 66fdb0675dabebef0c6e6a78bb22ad0bf66a7042 (plain)
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
# Created by: Alexey Dokuchaev <danfe@FreeBSD.org>
# $FreeBSD$

PORTNAME=	dzip
PORTVERSION=	2.9
CATEGORIES=	archivers games
MASTER_SITES=	http://speeddemosarchive.com/dzip/
DISTNAME=	dz${PORTVERSION:S/.//g}src

MAINTAINER=	ports@FreeBSD.org
COMMENT=	File compression utility specializing in Quake demo compression

LICENSE=	ZLIB

NO_STAGE=	yes
USE_ZIP=	yes
USE_DOS2UNIX=	yes

NO_WRKSUBDIR=	yes
MAKEFILE=	${WRKSRC}/Makefile.linux
MAKE_ARGS=	CC="${CC}" CFLAGS="${CFLAGS}"
ALL_TARGET=	${PORTNAME}

PLIST_FILES=	bin/${PORTNAME}

post-extract: .SILENT
	${REINPLACE_CMD} -e 's/ifdef BIG_ENDIAN/if BYTE_ORDER == BIG_ENDIAN/' \
		-e 's/ifndef BIG_ENDIAN/if BYTE_ORDER == LITTLE_ENDIAN/' \
			${WRKSRC}/dzip.h ${WRKSRC}/conmain.c
	${REINPLACE_CMD} -e '4s,^,#include <machine/endian.h>,' \
		${WRKSRC}/dzip.h
	${REINPLACE_CMD} -e 's/) $$(OBJECTS/&:T/' ${MAKEFILE}
	${REINPLACE_CMD} -e '21d;23d' ${WRKSRC}/dzipcon.h

do-install:
	${INSTALL_PROGRAM} ${WRKSRC}/${PORTNAME} ${PREFIX}/bin

.include <bsd.port.mk>
OpenPOWER on IntegriCloud