summaryrefslogtreecommitdiffstats
path: root/multimedia/y4mscaler/Makefile
blob: 1b92f82c9215bafac50c94af8bea3ecb24fdf256 (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
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
# New ports collection makefile for:	y4mscaler
# Date created:		Mon Mar  8 21:36:23 EST 2004
# Whom:			michael johnson <ahze@ahze.net>
#
# $FreeBSD$
#

PORTNAME=	y4mscaler
PORTVERSION=	0.6.1
CATEGORIES=	multimedia
MASTER_SITES=	http://www.mir.com/DMG/Software/
DISTNAME=	${PKGNAME}-src
EXTRACT_SUFX=	.tgz

MAINTAINER=	ahze@ahze.net
COMMENT=	Y4mscaler scales, crops, and shifts Y'CbCr video

LIB_DEPENDS=	lavjpeg-1.6.1:${PORTSDIR}/multimedia/mjpegtools

USE_REINPLACE=	yes
USE_GMAKE=	yes

WRKSRC=		${WRKDIR}/${PKGNAME}

PORTDOCS=	COPYING ChangeLog INSTALL README TODO
MAN1=		y4mscaler.1
PLIST_FILES=	bin/y4mscaler
MAKE_ENV=	CXX="${CXX}"

.include <bsd.port.pre.mk>

post-patch:
	@${REINPLACE_CMD} -e 's|/usr/local|${LOCALBASE}|' \
		${WRKSRC}/Makefile
	@${REINPLACE_CMD} -e 's|COPT = -O2|#|' \
		${WRKSRC}/Makefile
	@${REINPLACE_CMD} -e 's|CXXFLAGS =|CXXFLAGS = ${CXXFLAGS} |' \
		${WRKSRC}/Makefile
.if ${OSVERSION} < 500000
	@${REINPLACE_CMD} -e 's|#define HAVE_STDINT_H 1|#undef HAVE_STDINT_H 1|' \
		${WRKSRC}/y4m-config.h
.endif

do-install:
	@${INSTALL_PROGRAM} ${WRKSRC}/y4mscaler ${PREFIX}/bin/y4mscaler
	@${INSTALL_MAN} ${WRKSRC}/y4mscaler.1 ${MANPREFIX}/man/man1/
.if !defined(NOPORTDOCS)
	@${MKDIR} ${DOCSDIR}
.for docfile in ${PORTDOCS}
	@${INSTALL_DATA} ${WRKSRC}/${docfile} ${DOCSDIR}
.endfor
.endif

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