|
|
@@ -29,6 +29,10 @@
|
|
|
# fibmap_mplayer \
|
|
|
# $RPM_BUILD_ROOT%{l_prefix}/bin/
|
|
|
|
|
|
+# package versions
|
|
|
+%define V_mplayer 0.90
|
|
|
+%define V_blue 1.0
|
|
|
+
|
|
|
# package information
|
|
|
Name: mplayer
|
|
|
Summary: Multimedia Player
|
|
|
@@ -38,22 +42,27 @@ Packager: The OpenPKG Project
|
|
|
Distribution: OpenPKG [EVAL]
|
|
|
Group: Video
|
|
|
License: GPL and others
|
|
|
-Version: 0.90
|
|
|
+Version: %{V_mplayer}
|
|
|
Release: 20030508
|
|
|
|
|
|
# build options
|
|
|
+%option with_gui yes
|
|
|
%option with_win32 yes
|
|
|
|
|
|
# list of sources
|
|
|
-Source0: ftp://ftp.mplayerhq.hu/MPlayer/releases/MPlayer-%{version}.tar.bz2
|
|
|
+Source0: ftp://ftp.mplayerhq.hu/MPlayer/releases/MPlayer-%{V_mplayer}.tar.bz2
|
|
|
Source1: ftp://ftp1.mplayerhq.hu/MPlayer/releases/fonts/font-arial-iso-8859-1.tar.bz2
|
|
|
-Source2: ftp://ftp.mplayerhq.hu/MPlayer/releases/win32codecs.tar.bz2
|
|
|
+Source2: ftp://ftp.mplayerhq.hu/MPlayer/releases/codecs/win32codecs.tar.bz2
|
|
|
+Source4: ftp://ftp.mplayerhq.hu/MPlayer/Skin/Blue-%{V_blue}.tar.bz2
|
|
|
|
|
|
# build information
|
|
|
Prefix: %{l_prefix}
|
|
|
BuildRoot: %{l_buildroot}
|
|
|
BuildPreReq: OpenPKG, openpkg >= 20030103, X11, zlib, libiconv, sdl, freetype, jpeg, png, vorbis-libs, lzo
|
|
|
PreReq: OpenPKG, openpkg >= 20030103, X11, zlib, libiconv, sdl, freetype, jpeg, png, vorbis-libs
|
|
|
+%if "%{with_gui}" == "yes"
|
|
|
+BuildPreReq: glib, gtk
|
|
|
+%endif
|
|
|
AutoReq: no
|
|
|
AutoReqProv: no
|
|
|
|
|
|
@@ -65,7 +74,7 @@ AutoReqProv: no
|
|
|
status display (OSD), which is also used for displaying subtitles.
|
|
|
|
|
|
%prep
|
|
|
- %setup -q -n MPlayer-%{version}
|
|
|
+ %setup -q -n MPlayer-%{V_mplayer}
|
|
|
|
|
|
%build
|
|
|
CC="%{l_cc}" \
|
|
|
@@ -77,6 +86,13 @@ AutoReqProv: no
|
|
|
./configure \
|
|
|
--prefix=%{l_prefix} \
|
|
|
--confdir=%{l_prefix}/etc/mplayer/ \
|
|
|
+%if "%{with_gui}" == "yes"
|
|
|
+ --enable-gui \
|
|
|
+ --with-glib-config=%{l_prefix}/bin/glib-config \
|
|
|
+ --with-gtk-config=%{l_prefix}/bin/gtk-config \
|
|
|
+%else
|
|
|
+ --disable-gui \
|
|
|
+%endif
|
|
|
%if "%{with_win32}" == "yes"
|
|
|
--with-win32libdir=%{l_prefix}/libexec/mplayer/win32codecs \
|
|
|
--enable-win32 \
|
|
|
@@ -114,6 +130,9 @@ AutoReqProv: no
|
|
|
$RPM_BUILD_ROOT%{l_prefix}/bin \
|
|
|
$RPM_BUILD_ROOT%{l_prefix}/etc/mplayer \
|
|
|
$RPM_BUILD_ROOT%{l_prefix}/man/man1 \
|
|
|
+%if "%{with_win32}" == "yes"
|
|
|
+ $RPM_BUILD_ROOT%{l_prefix}/share/mplayer/Skin \
|
|
|
+%endif
|
|
|
$RPM_BUILD_ROOT%{l_prefix}/share/mplayer/font
|
|
|
|
|
|
# install binaries
|
|
|
@@ -121,6 +140,9 @@ AutoReqProv: no
|
|
|
mplayer \
|
|
|
mencoder \
|
|
|
$RPM_BUILD_ROOT%{l_prefix}/bin/
|
|
|
+%if "%{with_win32}" == "yes"
|
|
|
+ %{l_shtool} mkln -sf mplayer $RPM_BUILD_ROOT%{l_prefix}/bin/gmplayer
|
|
|
+%endif
|
|
|
|
|
|
# install manpages
|
|
|
%{l_shtool} install -c -m 644 \
|
|
|
@@ -134,6 +156,14 @@ AutoReqProv: no
|
|
|
etc/codecs.conf \
|
|
|
$RPM_BUILD_ROOT%{l_prefix}/etc/mplayer/
|
|
|
|
|
|
+%if "%{with_win32}" == "yes"
|
|
|
+ # install a default skin
|
|
|
+ ( cd $RPM_BUILD_ROOT%{l_prefix}/share/mplayer/Skin
|
|
|
+ %{l_bzip2} -dc %{SOURCE Blue-%{V_blue}.tar.bz2} | %{l_tar} -xvf -
|
|
|
+ %{l_shtool} mkln -sf Blue default
|
|
|
+ )
|
|
|
+%endif
|
|
|
+
|
|
|
# install fonts for OSD and subtitles
|
|
|
%{l_bzip2} -dc %{SOURCE font-arial-iso-8859-1.tar.bz2} | %{l_tar} -xvf -
|
|
|
cp -f font-arial-24-iso-8859-1/* $RPM_BUILD_ROOT%{l_prefix}/share/mplayer/font/
|