结合了linuxsir.org的相关的文章,做了些修改,适用于fc6简体中文板,(只能在线安装)。
把下面的代码另存为sh文件保存即可运行。
或者点击下面的连接下载。(需将.txt修改成.sh)
[file]http://www.icnote.com/attachment/1174973778_0.txt[/file]
#!/bin/bash
#RedHat Fedora Core 常用软件安装脚本,添加多媒体格式的支持,优化字体,安装常用软件。
#创建日期:2007.03.26 19:30
#创建人:leo
#参考linuxsir相关的文章
#下载yum配置文件
wget http://tel.gandong.net/FC6/yumrepo-1.0-FC6.noarch.rpm
rpm -ivh yumrepo-1.0-FC6.noarch.rpm
rm yumrepo-1.0-FC6.noarch.rpm
rpm -ivh http://rpm.livna.org/fedora/6/i386/livna-release-6-1.noarch.rpm
rpm -ivh ftp://ftp.fedora.cn/pub/fedora-cn/linux/6/i386/fedora-cn-release-6-1.y0.noarch.rpm
if [ ! -e thomas.pubkey ];then
wget http://thomas.apestaart.org/pkg/thomas.pubkey
fi
if [ ! -e thomas.fingerprint ];then
wget http://thomas.apestaart.org/pkg/thomas.fingerprint
fi
#导入key
rpm –import http://freshrpms.net/RPM-GPG-KEY-freshrpms
rpm –import http://dries.ulyssis.org/rpm/RPM-GPG-KEY.dries.txt
rpm –import http://newrpms.sunsite.dk/gpg-pubkey-newrpms.txt
rpm –import /usr/share/doc/fedora-release-*/*GPG-KEY*
gpg –with-fingerprint thomas.pubkey | head -n 3 | diff – thomas.fingerprint
gpg –keyserver pgp.mit.edu –recv-keys 55f3aa6f
gpg –list-keys | grep Stichele
gpg –fingerprint 55f3aa6f | head -n 3 > thomas.fingerprint.tmp
diff thomas.fingerprint.tmp thomas.fingerprint
rpm –import thomas.pubkey
echo “开始安装gstreamer解码器,完成后你可以使用RhythmBox播放mp3、wma和aac等格式的音乐了”
yum install gstreamer-universe
yum -y install ffmpeg
yum -y install mjpegtools
echo “gstreamer解码器安装完成,开始安装mplayer”
#安装mplayer
yum -y install mplayer-gui
yum -y install mplayerplug-in
cd /root
wget http://www4.mplayerhq.hu/MPlayer/releases/codecs/all-20061022.tar.bz2
tar jxvf all-20061022.tar.bz2
mkdir /usr/lib/codecs
mv all-20061022/* /usr/lib/codecs
chmod 755 /usr/lib/codecs/*
if [ ! -e /root/.mplayer ];then
mkdir /root/.mplayer
fi
#安装mplayer的中文支持配置文件,包括繁体中文,如选英语,则不安装。
if [ ! -e /root/.mplayer ];then
mkdir /root/.mplayer
fi
cd /root/.mplayer
if [ ! -e gui.conf ];then
wget http://tel.gandong.net/FC6/gui.conf
elif [ -e gui.conf ];then
mv gui.conf gui.conf~
wget http://tel.gandong.net/FC6/gui.conf
fi
echo “下面为mplayer添加中文字幕支持,如果你只有一个root帐户,请输入n跳过”
until [ “$opt” = “N” ] || [ “$opt” = “n” ]
do
echo “请输入你的帐户名,如果没有其他帐户请输入n跳过”
echo “请输入你的帐户名,如果没有其他帐户请输入n跳过”
read zhanghu
if [ “$opt” = “N” ] || [ “$opt” = “n” ]; then
echo “已跳过”
else
if [ ! -e /home/$opt/.mplayer ];then
mkdir /home/$opt/.mplayer
fi
if [ ! -e /home/$opt/.mplayer/gui.conf ];then
cp /root/.mplayer/gui.conf /home/$opt/.mplayer/gui.conf
elif [ -e /home/$opt/.mplayer/gui.conf ];then
mv /home/$opt/.mplayer/gui.conf /home/$opt/.mplayer/gui.conf~
cp /root/.mplayer/gui.conf /home/$opt/.mplayer/gui.conf
fi
fi
done
#安装方正宋体及NTFS-3g
echo “mplayer安装完成,开始安装方正宋体”
cd /usr/share/fonts/chinese/TrueType
wget http://tel.gandong.net/FC5/FZSongTi.ttf.tar.gz
tar -zxf FZSongTi.ttf.tar.gz
rm FZSongTi.ttf.tar.gz
fi
echo “方正宋体安装完成,开始安装NTFS-3g”
yum -y install ntfs-3g-devel ntfs-3g
echo “NTFS-3g安装完成,开始安装可选软件”
echo “准备安装Audacious音乐播放器,继续请输入y,取消请输入n”
read yn
if [ “$yn” = “y” ] || [ “$yn” = “Y” ]; then
echo “开始安装Audacious”
yum -y install audacious
echo “安装完成”
else
echo “安装被取消”
fi
echo “准备安装amaroK音乐播放器,继续请输入y,取消请输入n”
read yn
if [ “$yn” = “y” ] || [ “$yn” = “Y” ]; then
echo “开始安装amaroK”
yum -y install amarok
echo “安装完成”
else
echo “安装被取消”
fi
echo “准备安装Realplayer 10,继续请输入y,取消请输入n”
read yn
if [ “$yn” = “y” ] || [ “$yn” = “Y” ]; then
echo “开始安装Realplayer 10”
cd /root
wget http://software-dl.real.com/09daec5e386397c3a004/unix/RealPlayer10GOLD.rpm
yum -y install compat-libstdc++-33
rpm -ivh RealPlayer10GOLD.rpm
rm -rf RealPlayer10GOLD.rpm
echo “安装完成”
else
echo “安装被取消”
fi
echo “准备安装totem-xine,totem-xine可以支持更多的格式,继续请输入y,取消请输入n”
read yn
if [ “$yn” = “y” ] || [ “$yn” = “Y” ]; then
echo “开始安装totem-xine”
yum -y install totem-xine
echo “安装完成”
else
echo “安装被取消”
fi
echo “准备安装eva,eva是KDE下的QQ客户端,继续请输入y,取消请输入n”
read yn
if [ “$yn” = “y” ] || [ “$yn” = “Y” ]; then
echo “开始安装eva”
yum -y install eva
echo “安装完成”
else
echo “安装被取消”
fi
echo “安装全部完成,开始fc6快乐之旅吧!”