aboutsummaryrefslogtreecommitdiffstats
path: root/multimedia/mplayerxp/Makefile
blob: b350a90e4ccdfc4d3cbe9fe68464b4a758abbc8f (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
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
# New ports collection makefile for:    mplayer
# Date created:     10 August 2001
# Whom:         Thomas E. Zander
#           with lots of help from Vladimir Kushnir
# $FreeBSD$
#

PORTNAME=   mplayer
PORTVERSION=    0.50.0.1
CATEGORIES= graphics
MASTER_SITES=   http://ftp.mplayerhq.hu/MPlayer/releases/ \
        http://www.stud.uni-karlsruhe.de/~uedc/mplayer/ \
        http://www.rrr.de/~riggs/mplayer/
DISTNAME=   MPlayer-0.50pre1

MAINTAINER= riggs@rrr.de

LIB_DEPENDS=    png.5:${PORTSDIR}/graphics/png \
        SDL-1.1.3:${PORTSDIR}/devel/sdl12
RUN_DEPENDS=    ${LOCALBASE}/share/mplayer/fonts:${PORTSDIR}/graphics/mplayer-fonts

USE_BZIP2=  yes
USE_GMAKE=  yes
USE_XLIB=   yes
GNU_CONFIGURE=  yes
CONFIGURE_ARGS+=    --disable-esd
CONFIGURE_ENV=  PTHREAD_CFLAGS="${PTHREAD_CFLAGS}" \
        PTHREAD_LIBS="${PTHREAD_LIBS}"

MAN1=       mplayer.1
MANCOMPRESSED=  no

CONFFILES=  codecs.conf example.conf
DOCFILES=       DVB bugreports.html cd-dvd.html codecs-in.html \
        codecs.html documentation.html faq.html skin-en.html \
        sound.html video.html tech/tech-eng.txt

.include <bsd.port.pre.mk>

.if exists(${WRKDIRPREFIX}${.CURDIR}/Makefile.inc)
.include "${WRKDIRPREFIX}${.CURDIR}/Makefile.inc"
.endif

# hack to cope with dmesg standard vs ports standard
.if (WITH_3DNow!)
WITH_3DNOW= yes
.endif

.if defined(WITH_OPTIMIZED_CFLAGS)
CFLAGS+=       -O3 -ffast-math -fomit-frame-pointer
.endif

.if defined(WITH_GUI)
USE_GTK=    yes
CONFIGURE_ARGS+=    --enable-gui
.endif

# "enable" build for other archs
.if ${ARCH} == "i386"
.if defined(WITH_MMX)
CONFIGURE_ARGS+=--enable-mmx
.endif
.if defined(WITH_3DNOW) && ${OSVERSION} >= 400021
CONFIGURE_ARGS+=--enable-3dnow
.endif
.if defined(WITH_DSP) && defined(WITH_3DNOW) && ${OSVERSION} >= 400021
CONFIGURE_ARGS+=--enable-3dnowex
.endif
.if defined(WITH_SSE)
CONFIGURE_ARGS+=--enable-mmx2 --enable-sse
.endif
.if !defined(WITHOUT_WIN32_CODECS)
RUN_DEPENDS+=   ${CODEC_DETECTION_FILE}:${CODEC_PORT}

CONFIGURE_ARGS+=    --with-win32libdir=${LOCALBASE}/lib/win32

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

pre-everything::
.if !defined(WITH_OPTIMIZED_CFLAGS)
    @${ECHO_MSG} "You can enable additional compilation optimizations"
    @${ECHO_MSG} "by defining WITH_OPTIMIZED_CFLAGS"
.endif
.if !defined(WITH_GUI)
    @${ECHO} "You can enable GTK GUI by defining WITH_GUI."
.endif
.if ${ARCH} == "i386"
.if !defined(WITHOUT_WIN32_CODECS)
    @${ECHO_MSG} "You can disable support (this turns this into a X86 only port)"
    @${ECHO_MSG} "for Win32 codecs"
.endif
.if defined(WITH_SSE)
    @${ECHO_MSG} "You have to enable \"options CPU_ENABLE_SSE\" in your kernel"
    @${ECHO_MSG} "config in order to enable kernel support for SSE/MMX2."
.endif
.endif # ARCH == i386

pre-configure:
    @${RM} -f "${WRKDIRPREFIX}${.CURDIR}/Makefile.inc"
    @${MKDIR} "${WRKDIRPREFIX}${.CURDIR}"
    @${SETENV} TEMPDIR="${WRKDIRPREFIX}${.CURDIR}" ${PERL} ${FILESDIR}/get-feat

post-configure:
    @${RM} -f "${WRKDIRPREFIX}${.CURDIR}/Makefile.inc"

post-install:
    @${MKDIR} ${DATADIR}
    @${CHMOD} 755 ${DATADIR}
.for conf in ${CONFFILES}
    ${INSTALL_DATA} ${WRKSRC}/etc/${conf} ${DATADIR}
.endfor
.if !defined(NOPORTDOCS)
    @${MKDIR} ${DOCSDIR}
    @${CHMOD} 755 ${DOCSDIR}
.for doc in ${DOCFILES}
    @${INSTALL_DATA} ${WRKSRC}/DOCS/${doc} ${DOCSDIR}
.endfor
.endif
    @${CAT} pkg-message

install-user:
    @${PERL} ${FILESDIR}/install-user

.include <bsd.port.post.mk>