summaryrefslogtreecommitdiff
path: root/graphics/avifile/Makefile
blob: 4cd178a250652237de86337c80735e39faac617f (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
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
# New ports collection makefile for:   avifile
# Date created: 	16 September 2000
# Whom: 		Holger Lamm
#
# $FreeBSD$
#

PORTNAME=	avifile
PORTVERSION=	0.60.20010920
CATEGORIES=	graphics
MASTER_SITES=	http://ernie.eit.uni-kl.de/avifile/ 
DISTNAME=	${PORTNAME}-${PORTVERSION}

MAINTAINER=	holger@eit.uni-kl.de

BUILD_DEPENDS=	nasm:${PORTSDIR}/devel/nasm
LIB_DEPENDS=	SDL-1.1.3:${PORTSDIR}/devel/sdl12
.if !defined(WITHOUT_VORBIS)
LIB_DEPENDS+=	ogg.2:${PORTSDIR}/audio/libogg \
		vorbis.0:${PORTSDIR}/audio/libvorbis
.endif
RUN_DEPENDS=	${CODEC_DETECTION_FILE}:${CODEC_PORT}

ONLY_FOR_ARCHS=	i386
USE_QT_VER=	2
USE_XLIB=	yes
USE_GMAKE=	yes
INSTALLS_SHLIB=	yes
WRKSRC=		${WRKDIR}/${PORTNAME}-0.6

USE_AUTOCONF=	yes
USE_AUTOMAKE=	yes
USE_LIBTOOL=	yes
LIBTOOLFILES=	acinclude.m4
CONFIGURE_ENV=	SDL_CONFIG="${SDL_CONFIG}" \
		CPPFLAGS="${CPPFLAGS} -I${LOCALBASE}/include -L${LOCALBASE}/lib"
CONFIGURE_ARGS=	--with-win32-path=${LOCALBASE}/lib/win32 \
		--enable-release --with-gnu-ld --enable-x86opt

PLIST_SUB=	LIB_VERSION="${LIB_VERSION}" VERSION="${VERSION}"
.if defined(WITHOUT_VORBIS)
PLIST_SUB+=	VORBIS="@comment "
.else
PLIST_SUB+=	VORBIS=""
.endif

#CODEC_PORT=	${PORTSDIR}/graphics/win32-codecs
CODEC_PORT=	${.CURDIR}/../win32-codecs
CODEC_DETECTION_FILE!=	${MAKE} -f ${CODEC_PORT}/Makefile -V CODEC_DETECTION_FILE

LIB_VERSION=	3
VERSION=	0.6
SDL_CONFIG?=	${LOCALBASE}/bin/sdl11-config
DIFF?=		/usr/bin/diff
FMT?=		/usr/bin/fmt

.include <bsd.port.pre.mk>

.if !defined(WITHOUT_VORBIS)
pre-everything::
	@${ECHO_MSG} "You can disable vorbis support by defining WITHOUT_VORBIS."
.endif

pre-extract:
	@if [ -f ${LOCALBASE}/lib/libpth.so ]; then \
	  ${ECHO_MSG} "Error: This packet does not compile when the \
packet 'pth' is installed.";\
	  ${FALSE};\
	fi
do-configure:
	(cd ${WRKSRC} && aclocal && ./autogen.sh &&\
	${CONFIGURE_ENV} ./configure ${CONFIGURE_ARGS})
# Libtool fix code kindly provided by Mr. Maxim Sobolev <sobomax@FreeBSD.org>
post-configure:
	@${PERL} -pi -e \
		's|^deplibs_check_method=.*|deplibs_check_method=pass_all|' \
			${WRKSRC}/libtool

post-install:
	@${FMT} < ${PKGMESSAGE}

.include <bsd.port.post.mk>