[LINUX] XBMC Setup Script - Automatic installation of XBMC for Linux
#1
Thumbs Up 
Updated post. (so I could write some more beneath)

Image


Background:
The script is intended for people who have ported from another XBMC platform to XBMC Linux, and might not have the knowledge (or patience) to learn how to do every step. The script is based upon a custom system installation, where you can make different paritions, install another Linux OS and other applications and so on, but still gives you the option to boot straight into XBMC with a minimal OS installation.

I would still advice "beginners" who just want a Medie Center out-of-the- box without advanced modifications, to install XBMC Live. But if you want more control over your system and maybe install another Linux OS on another partition, keep on reading...


What the script does:
  • Installs XBMC
  • Installs XBMC Skins
  • Installs XBMC Bootscreens
  • Installs SVN Repo Installer (used for downloading of new plugins & scripts)
  • Installs Generic NVIDIA drivers for all kernels
  • Installs Alsa sound and configures sound levels (manual)
  • Installs Tweaks for video
  • Makes XBMC bootable as default

Hardware Compatibility

TO-DO list:
  • Menu to choose from Stable Release or Bleeding Edge Release
  • Automatic adjustments of all volume channels in Alsamixer
  • Additional tweaks

UPDATES:
  • Enabled 1080p @ 24Hz (24.07.2009)
  • Added H264 acceleration fix (Disabled Composite in xorg.conf) (22.07.2009)
  • Added HWCursor fix (20.07.2009)

NOTES:
  • Do NOT uncomment the SVN Repositories during first time installation, or it will fail.


Installation:

  1. Install Minimal Ubuntu


  2. Log in with XBMC user account


  3. Download the script (or get the code below):
    Code:
    wget http://www.virtualdanny.net/downloads/setupXBMC.sh


  4. Make the script executable:
    Code:
    sudo chmod +x setupXBMC.sh

  5. Run the script with root:
    Code:
    sudo ./setupXBMC.sh




setupXBMC.sh code:
Code:
#!/bin/bash
#------------------------------------------------------------------------------------------------------------
# setupXBMC Version 0.6b - 23/07/2009
# XBMC Installation script - by VirtualDanny.net
# This script will provide an automatic installation of Xbox Media Center
#
# REQUIREMENTS:
# * Clean Ubuntu Jaunty Server Installation (https://help.ubuntu.com/community/Installation/MinimalCD)
# * XBMC Compatible Hardware (http://wiki.xbmc.org/?title=XBMC_for_Linux_specific_FAQ)
# * Internet access
# * Username must be set to 'XBMC' under Ubuntu installation
#
# TO-DO LIST:
# * Menu to choose from Stable Release or Bleeding Edge Release
# * Automatic adjustments of all volume channels in Alsamixer
# * Additional tweaks
#
# KNOWN BUGS:
# * Installation will fail if you uncomment SVN Repositories during first time installation.
#
# Remember to run this script with: sudo ./setupXBMC.sh
#------------------------------------------------------------------------------------------------------------
cd /


##--[ ADDING REPOSITORIES TO SOURCE LIST ]-------------------------------------------------------------------
##    Repositories make it easier to download and stay up-to-date with current releases of Linux applications

echo '#' XBMC Repositories >> /etc/apt/sources.list.d/xbmc.org.list
echo '#' SVN builds are commented out. Remove comment '#' to enable.  >> /etc/apt/sources.list.d/xbmc.org.list
echo '#' Please DO NOT use the SVN builds during first time installation  >> /etc/apt/sources.list.d/xbmc.org.list
echo deb http://ppa.launchpad.net/team-xbmc/ppa/ubuntu/ jaunty main >> /etc/apt/sources.list.d/xbmc.org.list
echo deb-src http://ppa.launchpad.net/team-xbmc/ppa/ubuntu/ jaunty main >> /etc/apt/sources.list.d/xbmc.org.list
echo deb http://ppa.launchpad.net/xbmc-addons/ppa/ubuntu jaunty main >> /etc/apt/sources.list.d/xbmc.org.list

echo '#'deb http://ppa.launchpad.net/team-xbmc-svn/ppa/ubuntu jaunty main >> /etc/apt/sources.list.d/xbmc.org.list
echo '#'deb-src http://ppa.launchpad.net/team-xbmc-svn/ppa/ubuntu jaunty main >> /etc/apt/sources.list.d/xbmc.org.list



##--[ ADDING NVIDIA REPOISOTIRES TO SOURCE LIST ]------------------------------------------------------------

echo   >> etc/apt/sources.list
echo '#' NVIDIA Repositories >> etc/apt/sources.list
echo deb http://ppa.launchpad.net/nvidia-vdpau/ppa/ubuntu jaunty main >> etc/apt/sources.list



##--[ ADDING PGP KEYS TO VERFIY VALID SOURCES ]--------------------------------------------------------------

apt-key adv --recv-keys --keyserver keyserver.ubuntu.com 318C7509 64234534 CEC06767 0x6D975C4791E7EE5E



##--[ RUNNING A SYSTEM UPDATE ]------------------------------------------------------------------------------

apt-get update



##--[ INSTALL GENERIC NVIDIA GRAPHIC DRIVERS ]---------------------------------------------------------------

apt-get install linux-headers-generic nvidia-glx-185 -y



##--[ INSTALLS XBMC Media Center ]---------------------------------------------------------------------------

apt-get install xbmc -y
apt-get install xbmc-skin-* -y
apt-get install xbmc-eventclients-* -y
apt-get install xbmc-scripts-* -y



##--[ INSTALL XBMC SVN Repo Installer ]----------------------------------------------------------------------

apt-get install unzip -y
cd /
cd /home/xbmc/.xbmc/plugins/programs
wget http://xbmc-addons.googlecode.com/svn/packages/plugins/programs/SVN_Repo_Installer.zip
unzip SVN_Repo_Installer.zip
rm SVN_Repo_Installer.zip
chown -R xbmc:xbmc "SVN Repo Installer"



##--[ INSTALL Additional software ]--------------------------------------------------------------------------

apt-get install fluxbox xterm xinit x11-xserver-utils -y




## --[ INSTALL AND CONFIGURE ALSA SOUND ]--------------------------------------------------------------------

apt-get install linux-sound-base alsa-base alsa-utils -y
usermod -a -G audio xbmc

echo
echo AlsaMixer will now start so that you can configre your volum levels.
echo
echo Press 'M' to activate/deactive, Arrows to adjust volume, and ESC to save/quit.
echo Press any Key to contiue, or wait 20 seconds to continue
read -n1 -t20 any_key

alsamixer
alsactl store 0



## --[ INSTALL XBMC Bootscreen ]-----------------------------------------------------------------------------

apt-get install usplash-theme-xbmc-* -y
update-alternatives --set usplash-artwork.so /usr/lib/usplash/xbmc-splash-spinner-black.so
echo xres=1024 >> /etc/usplash.conf
echo yres=768 >> /etc/usplash.conf

update-initramfs -u



## --[ INSTALL Linux IR Remote Control Support]--------------------------------------------------------------

#apt-get install lirc -y



## --[ FINAL SYSTEM UPGRADE ]--------------------------------------------------------------------------------

apt-get update
apt-get upgrade -y



## --[ GENERATE XORG.CONF ]----------------------------------------------------------------------------------

nvidia-xconfig -s --no-logo --force-generate



## --[ ADDING HWcursor fix ]---------------------------------------------------------------------------------

sed -i '40i\    Option         "HWCursor" "False"' /etc/X11/xorg.conf



## --[ ENABLE 1080p 24Hz]------------------------------------------------------------------------------------

sed -i '50i\    Option         "DynamicTwinView" "False"' /etc/X11/xorg.conf



## --[ Disable Composite for better H264 acceleration ]------------------------------------------------------
sed -i '30i\Section "Extensions"' /etc/X11/xorg.conf
sed -i '31i\    Option         "Composite" "Disable"' /etc/X11/xorg.conf
sed -i '32i\EndSection' /etc/X11/xorg.conf



## --[ INSTALLING XBMC HELPERS ]-----------------------------------------------------------------------------
apt-get install xbmc-live python-apt -y


#SYSTEM Reboot
pkill X
reboot


Final notes:

I made this script primarily for personal use and to my friends. I still hope this can be to use for someone else who don't have Linux knowledge and want to install XBMC Media Center in 1-2-3. I learned the Linux language 8 days ago, so feel free to post comments on how to optimize/change the script to get better.

Tested 100% working on ASRock ION 330. I hope it will work on other hardware aswell, but there is always a chance that you need to modify the script to suit your specific hardware (etc Multicard readers, Wireless, Remote Controls, Bluetooth). Please give a feedback on how it went on your system, and I will see what I can do to adapt the script to suit your hardware.

Credit and thanks goes to
joggs, vikjon0, rickx and Haggy who all have given me input or knowledge to make this script better.


Thank you, and good luck with the script!
Reply


Messages In This Thread
[LINUX] XBMC Setup Script - Automatic installation of XBMC for Linux - by cyberpark - 2009-07-24, 10:52
[No subject] - by cyberpark - 2009-07-24, 10:52
[No subject] - by cyberpark - 2009-07-24, 10:53
[No subject] - by solamnic - 2009-07-24, 14:54
[No subject] - by solamnic - 2009-07-28, 18:18
[No subject] - by solamnic - 2009-07-28, 19:05
[No subject] - by solamnic - 2009-07-28, 19:33
[No subject] - by cyberpark - 2009-07-28, 23:25
[No subject] - by cyberpark - 2009-07-28, 23:28
[No subject] - by solamnic - 2009-07-29, 01:31
[No subject] - by solamnic - 2009-07-29, 01:35
[No subject] - by solamnic - 2009-07-29, 02:05
[No subject] - by althekiller - 2009-07-29, 02:22
[No subject] - by solamnic - 2009-07-29, 07:38
[No subject] - by cyberpark - 2009-07-29, 09:37
[No subject] - by solamnic - 2009-07-29, 18:08
Keep going - by joggs - 2009-07-30, 21:50
[No subject] - by flobbes - 2009-07-31, 13:19
[No subject] - by ZIOLele - 2009-07-31, 13:44
[No subject] - by solamnic - 2009-07-31, 14:20
[No subject] - by wstewart - 2009-07-31, 17:31
[No subject] - by flobbes - 2009-07-31, 19:37
[No subject] - by Luckyboy - 2009-08-01, 10:55
[No subject] - by Frozone - 2009-08-03, 10:28
[No subject] - by solamnic - 2009-08-03, 14:26
[No subject] - by cyberpark - 2009-08-04, 16:29
[No subject] - by Mape - 2009-08-04, 23:18
[No subject] - by jochr - 2009-08-05, 10:56
[No subject] - by Mape - 2009-08-05, 16:14
[No subject] - by spawn101 - 2009-08-05, 23:42
[No subject] - by pko66 - 2009-08-06, 12:12
[No subject] - by Frozone - 2009-08-06, 13:07
[No subject] - by nonamez78 - 2009-08-07, 09:34
[No subject] - by Frozone - 2009-08-07, 19:43
thanks - by mcjohn87 - 2009-08-08, 05:51
sory - by mcjohn87 - 2009-08-10, 04:37
Works on Acer Revo r3600 - by r3600 - 2009-08-10, 12:58
[No subject] - by vikjon0 - 2009-08-10, 14:39
[No subject] - by Burning-Ranger - 2009-08-10, 19:13
[No subject] - by vikjon0 - 2009-08-10, 21:41
[No subject] - by pko66 - 2009-08-14, 03:04
[No subject] - by vikjon0 - 2009-08-14, 07:27
[No subject] - by pko66 - 2009-08-14, 13:45
[No subject] - by LeechNL - 2009-08-16, 18:10
[No subject] - by pko66 - 2009-08-17, 00:22
[No subject] - by LeechNL - 2009-08-17, 07:27
[No subject] - by vikjon0 - 2009-08-20, 13:32
[No subject] - by kees667 - 2009-08-21, 18:35
[No subject] - by MartijnKooi - 2009-08-21, 22:16
[No subject] - by kees667 - 2009-08-23, 12:38
[No subject] - by kees667 - 2009-08-23, 14:23
great script - by rowstu - 2009-08-25, 15:59
[No subject] - by cyberpark - 2009-08-26, 13:38
[No subject] - by kees667 - 2009-08-26, 18:30
[No subject] - by rowstu - 2009-08-27, 10:21
[No subject] - by rowstu - 2009-08-27, 10:23
[No subject] - by kees667 - 2009-08-28, 08:29
[No subject] - by pko66 - 2009-08-28, 14:24
[No subject] - by vikjon0 - 2009-08-28, 16:17
[No subject] - by kees667 - 2009-08-28, 23:48
[No subject] - by vikjon0 - 2009-08-29, 09:46
[No subject] - by Captain_Morgan - 2009-08-29, 14:04
[No subject] - by Rusti - 2009-08-30, 13:13
[No subject] - by pko66 - 2009-08-31, 13:26
[No subject] - by vikjon0 - 2009-08-31, 14:25
[No subject] - by nhterra - 2009-09-01, 21:39
[No subject] - by kees667 - 2009-09-01, 23:02
[No subject] - by flxfxp - 2009-09-07, 18:14
[No subject] - by mexman - 2009-09-08, 16:36
[No subject] - by pko66 - 2009-09-09, 18:08
[No subject] - by wstewart - 2009-09-09, 18:25
[No subject] - by pko66 - 2009-09-09, 20:39
[No subject] - by vikjon0 - 2009-09-09, 20:48
[No subject] - by pko66 - 2009-09-10, 01:22
[No subject] - by pko66 - 2009-09-10, 01:52
[No subject] - by flxfxp - 2009-09-11, 18:27
[No subject] - by vikjon0 - 2009-09-11, 18:39
[No subject] - by kalojero - 2009-09-13, 23:23
[No subject] - by vikjon0 - 2009-09-14, 17:19
[No subject] - by phrehdd - 2009-09-20, 21:16
[No subject] - by flxfxp - 2009-09-21, 16:24
[No subject] - by User 54031 - 2009-09-22, 10:28
[No subject] - by vikjon0 - 2009-09-23, 08:27
[No subject] - by Txori82 - 2009-10-01, 15:31
[No subject] - by rcrh - 2009-10-02, 17:52
[No subject] - by Txori82 - 2009-10-02, 20:08
[No subject] - by rcrh - 2009-10-03, 18:09
[No subject] - by kees667 - 2009-10-04, 10:02
[No subject] - by kees667 - 2009-10-06, 07:50
[No subject] - by kees667 - 2009-10-06, 20:11
[No subject] - by d3CoY - 2009-10-13, 11:56
[No subject] - by Txori82 - 2009-10-13, 12:01
[No subject] - by stokedfish - 2009-10-14, 16:24
[No subject] - by vikjon0 - 2009-10-14, 18:37
[No subject] - by mardyhardy - 2009-10-14, 22:16
Revo 3600 and this script - by Andrewishy - 2009-10-15, 15:45
[No subject] - by rcrh - 2009-10-16, 17:38
[No subject] - by vikjon0 - 2009-10-16, 18:11
[No subject] - by pecinko - 2009-10-17, 00:44
[No subject] - by Zapata - 2009-10-19, 18:45
Revo 3600 and this script - by Andrewishy - 2009-10-19, 22:26
ubuntu full - by poirwilliam - 2009-10-20, 12:39
seems to be simple - by poirwilliam - 2009-10-20, 21:43
even cannot install - by poirwilliam - 2009-10-20, 21:48
[No subject] - by TORGULL - 2009-10-20, 21:52
[No subject] - by Pietrux - 2009-10-21, 17:00
[No subject] - by Methanoid - 2009-10-27, 21:53
[No subject] - by Shadowsoul - 2009-10-29, 00:29
[No subject] - by TORGULL - 2009-11-05, 17:48
[No subject] - by phrehdd - 2009-11-07, 05:07
[No subject] - by dazex - 2009-11-10, 22:00
[No subject] - by Txori82 - 2009-11-11, 23:16
[No subject] - by thor.magnus - 2009-11-12, 09:46
[No subject] - by Txori82 - 2009-11-12, 10:33
[No subject] - by thor.magnus - 2009-11-12, 11:12
[No subject] - by Txori82 - 2009-11-12, 11:16
[No subject] - by chunkhead - 2009-11-17, 16:25
UPDATED Version - by biptn - 2009-11-21, 04:34
[No subject] - by reticent - 2009-11-22, 07:56
[No subject] - by XBMCBert - 2009-11-22, 11:41
[No subject] - by reticent - 2009-11-23, 21:38
[No subject] - by biptn - 2009-11-23, 22:29
[No subject] - by Txori82 - 2009-11-23, 22:36
[No subject] - by Methanoid - 2009-11-24, 16:07
[No subject] - by kizer - 2009-11-24, 18:35
[No subject] - by X3lectric - 2009-11-24, 20:13
[No subject] - by biptn - 2009-11-26, 21:33
[No subject] - by biptn - 2009-11-26, 21:35
[No subject] - by Valfar - 2009-11-26, 22:42
[No subject] - by User 43642 - 2009-11-28, 17:05
[No subject] - by arielgr - 2009-11-29, 14:20
[No subject] - by prupert - 2009-11-29, 21:54
[No subject] - by kizer - 2009-11-30, 20:12
[No subject] - by prupert - 2009-11-30, 20:18
[No subject] - by kizer - 2009-11-30, 20:34
[No subject] - by prupert - 2009-11-30, 21:49
[No subject] - by kizer - 2009-11-30, 23:40
[No subject] - by Txori82 - 2009-12-01, 14:11
[No subject] - by XBMCBert - 2009-12-01, 23:18
[No subject] - by prupert - 2009-12-05, 23:44
[No subject] - by biptn - 2009-12-07, 06:10
[No subject] - by prupert - 2009-12-07, 12:01
[No subject] - by biptn - 2009-12-08, 02:25
[No subject] - by prupert - 2009-12-08, 09:24
[No subject] - by Txori82 - 2009-12-08, 10:19
[No subject] - by Gooner14 - 2009-12-08, 22:16
[No subject] - by Txori82 - 2009-12-11, 23:03
[No subject] - by Txori82 - 2009-12-12, 13:09
[No subject] - by Txori82 - 2009-12-12, 19:06
[No subject] - by prupert - 2009-12-12, 22:25
[No subject] - by biptn - 2009-12-13, 05:14
[No subject] - by Txori82 - 2009-12-13, 10:32
[No subject] - by prupert - 2009-12-13, 13:00
Wonderful - by dirkieh - 2009-12-13, 17:19
[No subject] - by biptn - 2009-12-13, 17:51
[No subject] - by prupert - 2009-12-14, 12:27
[No subject] - by biptn - 2009-12-14, 22:41
[No subject] - by Txori82 - 2009-12-14, 22:45
[No subject] - by prupert - 2009-12-14, 23:02
[No subject] - by prupert - 2009-12-15, 12:20
[No subject] - by prupert - 2009-12-15, 14:09
[No subject] - by biptn - 2009-12-15, 20:20
[No subject] - by prupert - 2009-12-15, 22:34
[No subject] - by biptn - 2009-12-15, 23:15
[No subject] - by prupert - 2009-12-15, 23:22
[No subject] - by biptn - 2009-12-15, 23:23
[No subject] - by prupert - 2009-12-15, 23:29
[No subject] - by Txori82 - 2009-12-15, 23:54
[No subject] - by biptn - 2009-12-15, 23:58
[No subject] - by Txori82 - 2009-12-16, 00:09
[No subject] - by biptn - 2009-12-16, 01:01
[No subject] - by Txori82 - 2009-12-16, 11:21
[No subject] - by harryzimm - 2009-12-16, 11:28
[No subject] - by Txori82 - 2009-12-16, 11:31
[No subject] - by Txori82 - 2009-12-16, 13:30
[No subject] - by biptn - 2009-12-16, 17:09
[No subject] - by fishyguy - 2009-12-18, 05:29
[No subject] - by biptn - 2009-12-19, 01:41
[No subject] - by levster - 2009-12-22, 02:16
[No subject] - by mightydrake - 2009-12-22, 07:01
[No subject] - by Vanguard - 2009-12-22, 08:54
[No subject] - by biptn - 2009-12-22, 18:37
[No subject] - by fishyguy - 2009-12-22, 21:55
[No subject] - by biptn - 2009-12-24, 20:05
[No subject] - by fishyguy - 2009-12-24, 20:49
[No subject] - by Txori82 - 2009-12-25, 09:31
[No subject] - by biptn - 2009-12-25, 09:49
[No subject] - by Txori82 - 2009-12-25, 12:38
Feedback (working) - by amissner - 2009-12-25, 23:52
[No subject] - by d_schrute - 2009-12-28, 13:58
[No subject] - by osirisjem - 2010-01-04, 01:43
[No subject] - by osirisjem - 2010-01-04, 03:10
[No subject] - by osirisjem - 2010-01-04, 04:02
[No subject] - by prupert - 2010-01-04, 10:57
[No subject] - by prupert - 2010-01-04, 10:59
[No subject] - by prupert - 2010-01-04, 11:04
[No subject] - by prupert - 2010-01-04, 11:06
[No subject] - by AlFakher1987 - 2010-01-08, 14:23
[No subject] - by prupert - 2010-01-08, 14:56
[No subject] - by AlFakher1987 - 2010-01-08, 15:03
[No subject] - by prupert - 2010-01-08, 16:09
[No subject] - by AlFakher1987 - 2010-01-08, 16:28
[No subject] - by prupert - 2010-01-08, 16:45
[No subject] - by surre - 2010-01-11, 22:56
[No subject] - by prupert - 2010-01-11, 23:39
[No subject] - by Methanoid - 2010-01-12, 11:43
[No subject] - by prupert - 2010-01-12, 14:08
[No subject] - by Methanoid - 2010-01-12, 14:40
[No subject] - by prupert - 2010-01-12, 14:57
[No subject] - by rflores2323 - 2010-01-12, 20:19
[No subject] - by prupert - 2010-01-12, 22:13
[No subject] - by Burning-Ranger - 2010-01-17, 02:08
[No subject] - by d_schrute - 2010-01-26, 02:20
[No subject] - by BurningSky - 2010-01-26, 02:59
[No subject] - by eluSive_NZ - 2010-01-26, 03:22
[No subject] - by BurningSky - 2010-01-26, 14:19
[No subject] - by d_schrute - 2010-01-26, 21:28
Preseed? - by pashdown - 2010-01-26, 22:44
[No subject] - by BurningSky - 2010-01-26, 23:19
[No subject] - by d_schrute - 2010-01-27, 00:33
[No subject] - by d_schrute - 2010-01-29, 06:38
[No subject] - by biptn - 2010-02-06, 04:41
[No subject] - by d_schrute - 2010-02-06, 09:13
[No subject] - by Ardo - 2010-02-06, 18:11
[No subject] - by biptn - 2010-02-06, 21:16
[No subject] - by d_schrute - 2010-02-07, 05:23
[No subject] - by d_schrute - 2010-02-07, 05:47
[No subject] - by Valfar - 2010-02-07, 15:06
[No subject] - by biptn - 2010-02-08, 07:38
[No subject] - by Valfar - 2010-02-09, 00:17
[No subject] - by X3lectric - 2010-02-09, 18:55
[No subject] - by biptn - 2010-02-10, 01:26
Issue after installation - by engineuity - 2010-04-13, 03:55
[No subject] - by engineuity - 2010-04-13, 04:08
[No subject] - by engineuity - 2010-04-13, 04:21
Zotac mag nd01 - by ^tWiSt^ - 2010-05-11, 23:00
doesn´t work with my acer revo - by zenman - 2010-07-04, 00:06
[No subject] - by Flomaster - 2010-07-13, 00:50
[No subject] - by X3lectric - 2010-07-15, 15:46
[No subject] - by Stigy - 2010-08-02, 20:42
[No subject] - by X3lectric - 2010-08-02, 20:48
[No subject] - by xzibiz - 2010-10-13, 20:33
[No subject] - by nero12 - 2010-12-04, 13:30
Logout Mark Read Team Forum Stats Members Help
[LINUX] XBMC Setup Script - Automatic installation of XBMC for Linux4