aboutsummaryrefslogtreecommitdiffstats
path: root/multimedia/linux-divxplayer/Makefile
blob: 92f620c39b57211efdc5fe4064e1327dc0b0ec02 (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
# New ports collection makefile for:    divx.com player
# Date created:             Sun May 19 22:17:41 BRT 2002
# Whom:         Mario Sergio Fujikawa Ferreira <lioux@FreeBSD.org>
#
# $FreeBSD$
#

PORTNAME=   divxplayer
PORTVERSION=    0.2.0
CATEGORIES= multimedia linux
MASTER_SITES=   http://download.divx.com/player/
PKGNAMEPREFIX=  linux-
DISTNAME=   divx-player-installer

MAINTAINER= lioux@FreeBSD.org
COMMENT=    DivX(TM) Video Player for Linux from DivX.com

ONLY_FOR_ARCHS= i386

USE_LINUX=  yes
USE_X_PREFIX=   yes
NO_BUILD=   yes
STRIP=
WRKSRC=     ${WRKDIR}/divx-player-installer
STRIP_CMD=  ${LINUXBASE}/usr/bin/strip

.if exists(/usr/bin/brandelf)
BRANDELF?=  /usr/bin/brandelf
.else
BRANDELF?=  brandelf
.endif

BINARY_NAME=    divxPlayer.bin

post-patch:
    @${SED} -e "s|%%DATADIR%%|${DATADIR}|" ${FILESDIR}/wrapper.sh \
        > ${WRKDIR}/wrapper.sh

do-install:
# skin files
    @${MKDIR} ${DATADIR}
    @${MKDIR} ${DATADIR}/Skins
    @${INSTALL_DATA} ${WRKSRC}/Skins/* ${DATADIR}/Skins
# player
    @${INSTALL_PROGRAM} ${WRKSRC}/${BINARY_NAME} ${PREFIX}/bin
    @${INSTALL_SCRIPT} ${WRKDIR}/wrapper.sh \
        ${PREFIX}/bin/${BINARY_NAME:S/.bin$//}
    @${CAT} ${PKGMESSAGE}

.include <bsd.port.pre.mk>

pre-install:
.if exists(${STRIP_CMD})
    @${STRIP_CMD} ${WRKSRC}/${BINARY_NAME}
.endif
    @${BRANDELF} -t Linux ${WRKSRC}/${BINARY_NAME}

.include <bsd.port.post.mk>