khaledma
hi,
To create an gmplayer packages with arabic subtitle support,
here is the procedure for the fedora core 4:
Step [1]
download the Source RPM mplayer-1.0-0.lvn.0.33.pre7try2.4.src.rpm
to a folder in your home directory ( /home/khaled/TMP/ ) and install it.
link:
http://rpm.livna.org/fedora/4/i386/SRPMS.lvn/mplayer-1.0-0.lvn.0.33.pre7try2.4.src.rpm
Be root
[khaled@tiger ~]$ su -
Password: xxxxxxxx
[root@tiger ~]#cd /home/khaled/TMP
[root@tiger TMP]#rpm -ivh mplayer-1.0-0.lvn.0.33.pre7try2.4.src.rpm
Step [2]
Download the Arabic subtitle patch
Go to the http://phaeronix.net/patch/mplayer
and download the MPlayer-1.0pre7-arabic-subtitles.patch
rename it mplayer-1.0pre7-arabicsubtitles.patch
Copy it to /usr/src/redhat/SOURCES/
Step [3]
Checking the dependancies:
[root@tiger TMP]#cd /usr/src/redhat/SPECS/
then, open the mplayer.spec file in a text editor.
( disable word wrapping for the text editor before openning the file )
Now inspect the Requires section for the needed packages,
and make sure its already installed on your system, or go
and download it from the Internet.
------------------------Here is my checks------------
[root@tiger khaled]# rpm -qa | grep mplayer-fonts
mplayer-fonts-1.1-3.fc
[root@tiger khaled]# rpm -qa | grep desktop-file-utils
desktop-file-utils-0.10-1
[root@tiger khaled]# rpm -qa | grep alsa-lib-devel
alsa-lib-devel-1.0.9rf-2.FC4
[root@tiger khaled]# rpm -qa | grep SDL-devel
SDL-devel-1.2.8-3.2
[root@tiger khaled]# rpm -qa | grep freetype-devel
freetype-devel-2.1.9-2
[root@tiger khaled]# rpm -qa | grep fribidi-devel
fribidi-devel-0.10.4-8
[root@tiger khaled]# rpm -qa | grep libvorbis-devel
libvorbis-devel-1.1.0-2
[root@tiger khaled]# rpm -qa | grep libogg-devel
libogg-devel-1.1.2-2
[root@tiger khaled]# rpm -qa | grep esound-devel
esound-devel-0.2.35-5
[root@tiger khaled]# rpm -qa | grep aalib-devel
aalib-devel-1.4.0-0.rc5.4
[root@tiger khaled]# rpm -qa | grep xvidcore-devel
xvidcore-devel-1.0.3-1.2.fc4
[root@tiger khaled]# rpm -qa | grep arts-devel
arts-devel-1.4.2-0.fc4.1
[root@tiger khaled]# rpm -qa | grep libdvdread-devel
libdvdread-devel-0.9.4-7.2.fc4
[root@tiger khaled]# rpm -qa | grep cdparanoia-devel
cdparanoia-devel-alpha9.8-25
[root@tiger khaled]# rpm -qa | grep libmad-devel
libmad-devel-0.15.1b-3.2.fc4
[root@tiger khaled]# rpm -qa | grep faad2-devel
faad2-devel-2.0-4.2.fc4
[root@tiger khaled]# rpm -qa | grep xmms-devel
xmms-devel-1.2.10-16
[root@tiger khaled]# rpm -qa | grep libpng-devel
libpng-devel-1.2.8-2
[root@tiger khaled]# rpm -qa | grep libdv-devel
libdv-devel-0.103-4
[root@tiger khaled]# rpm -qa | grep lzo-devel
lzo-devel-1.08-4
[root@tiger khaled]# rpm -qa | grep libjpeg-devel
libjpeg-devel-6b-34
[root@tiger khaled]# rpm -qa | grep libungif-devel
libungif-devel-4.1.3-3
[root@tiger khaled]# rpm -qa | grep zlib-devel
zlib-devel-1.2.2.2-3
[root@tiger khaled]# rpm -qa | grep live-devel
live-devel-0-0.lvn.10.2005.08.09.4
[root@tiger khaled]# rpm -qa | grep ladspa-devel
ladspa-devel-1.12-5
[root@tiger khaled]# rpm -qa | grep libtheora-devel
libtheora-devel-1.0alpha4-2
[root@tiger khaled]# rpm -qa | grep lirc-devel
lirc-devel-0.7.2-1.1.fc4
[root@tiger khaled]# rpm -qa | grep libcaca-devel
libcaca-devel-0.9-5
[root@tiger khaled]# rpm -qa | grep enca-devel
enca-devel-1.9-1.fc4
[root@tiger khaled]#
---------------------------------------------------
Next, modify the mplayer.spec file as follows
add this line to the patch list:
Patch13: mplayer-1.0pre7-arabicsubtitles.patch
Add the following line to the end of the %prep section:
%patch13 -p1 -b .arabicsubtitles
In the %build section add the following:
--enable-arabic-shaping \
--enable-zr \
You may not need the second line ( --enable-zr ), i added it because i have
a pinnacle video capture card already installed in my system.
If you do not have such card do not add this line.
I have also made some minor changes to the mplayer.spec file to let the DXR3
support an optional....ok
----------- My mplayer.spec file is attched with this article --------------
Then Save & Exit
Next, run the following command:
# rpmbuild -ba --target i686 --without dxr3 --without directfb mplayer.spec
Here, I have a pentium 4 PC, I do not have DXR3 card,
and I do not need the frame buffer support.
If everything went well you will find the needed RPMS at:
/usr/src/redhat/RPMS/i686/
So, go and install them as usual
#rpm -Uvh mplayer-*
If the rpmbuild command failled, go and open the mplayer.spec file and make sure
that all the needed packages are already installed on your system.
Next,
Exit root,
Fire the mplayer or gmplayer to make sure its working good.
then go to .mplayer dir in your home directory and add the following items to
the file config , which is the mplayer config file:
------------
font=' '
utf8=yes
-----------
save & exit
delete the gui.conf file from the ~/.mplayer
do not worry mplayer will create another one.
$cd /usr/share/fonts/arabic/
and copy one of the fonts to your ~/.mplayer directory,
and rename it subfont.ttf
That is it.
One last note: The subtitles must be unicode utf8 to be displayed with mplayer.
Note:
I have attached here my mplayer.spec file , but i have renamed it mplayer-spec.txt, so you have to rename it back to mplayer.spec
and copy it to /usr/src/redhat/SPECS/ directory.
Also the config.txt is my mplayer config file, just rename it config and copy it
to .mplayer directory in your home directory
The same thing with gui-conf.txt , just rename it gui.conf and place it in your
.mplayer dir in your home directory.
thanks
Khaledma
To create an gmplayer packages with arabic subtitle support,
here is the procedure for the fedora core 4:
Step [1]
download the Source RPM mplayer-1.0-0.lvn.0.33.pre7try2.4.src.rpm
to a folder in your home directory ( /home/khaled/TMP/ ) and install it.
link:
http://rpm.livna.org/fedora/4/i386/SRPMS.lvn/mplayer-1.0-0.lvn.0.33.pre7try2.4.src.rpm
Be root
[khaled@tiger ~]$ su -
Password: xxxxxxxx
[root@tiger ~]#cd /home/khaled/TMP
[root@tiger TMP]#rpm -ivh mplayer-1.0-0.lvn.0.33.pre7try2.4.src.rpm
Step [2]
Download the Arabic subtitle patch
Go to the http://phaeronix.net/patch/mplayer
and download the MPlayer-1.0pre7-arabic-subtitles.patch
rename it mplayer-1.0pre7-arabicsubtitles.patch
Copy it to /usr/src/redhat/SOURCES/
Step [3]
Checking the dependancies:
[root@tiger TMP]#cd /usr/src/redhat/SPECS/
then, open the mplayer.spec file in a text editor.
( disable word wrapping for the text editor before openning the file )
Now inspect the Requires section for the needed packages,
and make sure its already installed on your system, or go
and download it from the Internet.
------------------------Here is my checks------------
[root@tiger khaled]# rpm -qa | grep mplayer-fonts
mplayer-fonts-1.1-3.fc
[root@tiger khaled]# rpm -qa | grep desktop-file-utils
desktop-file-utils-0.10-1
[root@tiger khaled]# rpm -qa | grep alsa-lib-devel
alsa-lib-devel-1.0.9rf-2.FC4
[root@tiger khaled]# rpm -qa | grep SDL-devel
SDL-devel-1.2.8-3.2
[root@tiger khaled]# rpm -qa | grep freetype-devel
freetype-devel-2.1.9-2
[root@tiger khaled]# rpm -qa | grep fribidi-devel
fribidi-devel-0.10.4-8
[root@tiger khaled]# rpm -qa | grep libvorbis-devel
libvorbis-devel-1.1.0-2
[root@tiger khaled]# rpm -qa | grep libogg-devel
libogg-devel-1.1.2-2
[root@tiger khaled]# rpm -qa | grep esound-devel
esound-devel-0.2.35-5
[root@tiger khaled]# rpm -qa | grep aalib-devel
aalib-devel-1.4.0-0.rc5.4
[root@tiger khaled]# rpm -qa | grep xvidcore-devel
xvidcore-devel-1.0.3-1.2.fc4
[root@tiger khaled]# rpm -qa | grep arts-devel
arts-devel-1.4.2-0.fc4.1
[root@tiger khaled]# rpm -qa | grep libdvdread-devel
libdvdread-devel-0.9.4-7.2.fc4
[root@tiger khaled]# rpm -qa | grep cdparanoia-devel
cdparanoia-devel-alpha9.8-25
[root@tiger khaled]# rpm -qa | grep libmad-devel
libmad-devel-0.15.1b-3.2.fc4
[root@tiger khaled]# rpm -qa | grep faad2-devel
faad2-devel-2.0-4.2.fc4
[root@tiger khaled]# rpm -qa | grep xmms-devel
xmms-devel-1.2.10-16
[root@tiger khaled]# rpm -qa | grep libpng-devel
libpng-devel-1.2.8-2
[root@tiger khaled]# rpm -qa | grep libdv-devel
libdv-devel-0.103-4
[root@tiger khaled]# rpm -qa | grep lzo-devel
lzo-devel-1.08-4
[root@tiger khaled]# rpm -qa | grep libjpeg-devel
libjpeg-devel-6b-34
[root@tiger khaled]# rpm -qa | grep libungif-devel
libungif-devel-4.1.3-3
[root@tiger khaled]# rpm -qa | grep zlib-devel
zlib-devel-1.2.2.2-3
[root@tiger khaled]# rpm -qa | grep live-devel
live-devel-0-0.lvn.10.2005.08.09.4
[root@tiger khaled]# rpm -qa | grep ladspa-devel
ladspa-devel-1.12-5
[root@tiger khaled]# rpm -qa | grep libtheora-devel
libtheora-devel-1.0alpha4-2
[root@tiger khaled]# rpm -qa | grep lirc-devel
lirc-devel-0.7.2-1.1.fc4
[root@tiger khaled]# rpm -qa | grep libcaca-devel
libcaca-devel-0.9-5
[root@tiger khaled]# rpm -qa | grep enca-devel
enca-devel-1.9-1.fc4
[root@tiger khaled]#
---------------------------------------------------
Next, modify the mplayer.spec file as follows
add this line to the patch list:
Patch13: mplayer-1.0pre7-arabicsubtitles.patch
Add the following line to the end of the %prep section:
%patch13 -p1 -b .arabicsubtitles
In the %build section add the following:
--enable-arabic-shaping \
--enable-zr \
You may not need the second line ( --enable-zr ), i added it because i have
a pinnacle video capture card already installed in my system.
If you do not have such card do not add this line.
I have also made some minor changes to the mplayer.spec file to let the DXR3
support an optional....ok
----------- My mplayer.spec file is attched with this article --------------
Then Save & Exit
Next, run the following command:
# rpmbuild -ba --target i686 --without dxr3 --without directfb mplayer.spec
Here, I have a pentium 4 PC, I do not have DXR3 card,
and I do not need the frame buffer support.
If everything went well you will find the needed RPMS at:
/usr/src/redhat/RPMS/i686/
So, go and install them as usual
#rpm -Uvh mplayer-*
If the rpmbuild command failled, go and open the mplayer.spec file and make sure
that all the needed packages are already installed on your system.
Next,
Exit root,
Fire the mplayer or gmplayer to make sure its working good.
then go to .mplayer dir in your home directory and add the following items to
the file config , which is the mplayer config file:
------------
font=' '
utf8=yes
-----------
save & exit
delete the gui.conf file from the ~/.mplayer
do not worry mplayer will create another one.
$cd /usr/share/fonts/arabic/
and copy one of the fonts to your ~/.mplayer directory,
and rename it subfont.ttf
That is it.
One last note: The subtitles must be unicode utf8 to be displayed with mplayer.
Note:
I have attached here my mplayer.spec file , but i have renamed it mplayer-spec.txt, so you have to rename it back to mplayer.spec
and copy it to /usr/src/redhat/SPECS/ directory.
Also the config.txt is my mplayer config file, just rename it config and copy it
to .mplayer directory in your home directory
The same thing with gui-conf.txt , just rename it gui.conf and place it in your
.mplayer dir in your home directory.
thanks
Khaledma