summaryrefslogtreecommitdiff
path: root/devel/libmpeg3/Makefile
blob: f56c70aea497de5f7fb707825f46770a7e499644 (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
55
56
57
58
59
60
61
62
# $NetBSD: Makefile,v 1.10 2003/05/02 11:54:37 wiz Exp $
#

DISTNAME=	libmpeg3-1.3
PKGREVISION=	4
CATEGORIES=	devel audio graphics
MASTER_SITES=	http://heroines.sourceforge.net/

MAINTAINER=	packages@netbsd.org
HOMEPAGE=	http://heroines.sourceforge.net/libmpeg3.php3
COMMENT=	MPEG decoding library

.if (${MACHINE_ARCH} == "i386")
BUILD_DEPENDS+=	nasm-[0-9]*:../../devel/nasm
.else
CONFIGURE_ARGS+= --no-mmx --no-css
.endif

USE_BUILDLINK2=	yes
HAS_CONFIGURE=	yes
USE_GMAKE=	yes

PTHREAD_OPTS+=	require

post-configure:
	${ECHO} "CFLAGS+=-O2" >>${WRKSRC}/global_config
	${ECHO} "CFLAGS+=-I${BUILDLINK_DIR}/include" >>${WRKSRC}/global_config
	${ECHO} "CFLAGS+=-D_FILE_OFFSET_BITS=64" >>${WRKSRC}/global_config

INSTHDRS=	bitstream.h libmpeg3.h mpeg3atrack.h mpeg3css.h \
		mpeg3demux.h mpeg3io.h mpeg3private.h \
		mpeg3private.inc mpeg3title.h mpeg3vtrack.h timecode.h
AINSTHDRS=	ac3.h mpeg3audio.h
VINSTHDRS=	idct.h mpeg3video.h slice.h
INSTBINS=	mpeg3cat mpeg3toc mpeg3split

do-install:
	${INSTALL_PROGRAM} ${WRKSRC}/work/dump ${PREFIX}/bin/mpeg3dump
	for f in ${INSTBINS}; do \
		${INSTALL_PROGRAM} ${WRKSRC}/work/$$f ${PREFIX}/bin; \
	done
	${INSTALL_DATA_DIR} ${PREFIX}/include/mpeg3
	for f in ${INSTHDRS}; do \
		${INSTALL_DATA} ${WRKSRC}/$$f ${PREFIX}/include/mpeg3; \
	done
	${INSTALL_DATA_DIR} ${PREFIX}/include/mpeg3/audio
	for f in ${AINSTHDRS}; do \
		${INSTALL_DATA} ${WRKSRC}/audio/$$f \
			${PREFIX}/include/mpeg3/audio; \
	done
	${INSTALL_DATA_DIR} ${PREFIX}/include/mpeg3/video
	for f in ${VINSTHDRS}; do \
		${INSTALL_DATA} ${WRKSRC}/video/$$f \
			${PREFIX}/include/mpeg3/video; \
	done
	${INSTALL_DATA} ${WRKSRC}/work/libmpeg3.a ${PREFIX}/lib
	${INSTALL_DATA_DIR} ${PREFIX}/share/doc/html/libmpeg3
	${INSTALL_DATA} ${WRKSRC}/docs/index.html \
		${PREFIX}/share/doc/html/libmpeg3

.include "../../mk/pthread.buildlink2.mk"
.include "../../mk/bsd.pkg.mk"