- Build instructions
- Short instructions
- Full instructions
- Cross-compilation
- Instructions for developers
The latest release of PS3 Media Server can be downloaded from: http://www.ps3mediaserver.org/
This document describes how to build PS3 Media Server from the source files. The following software packages are required:
- The Java JDK (the JRE is not enough)
- Git
- Maven
- External libraries
Read the Full instructions section for a complete explanation of how to install all required software and how to build PMS for each operating system.
If all required software packages are installed, the following commands will download the latest sources and build PMS:
git clone git://github.com/ps3mediaserver/ps3mediaserver.git
cd ps3mediaserver
mvn package
The result will be built in the "target" directory:
- Windows:
PMS-setup.exe
- Linux:
pms-linux-generic-x.xx.x.tar.gz
- Mac OS X:
pms-macosx-x.xx.x.dmg
First all required software has to be installed:
Note: the JRE is not enough.
See http://www.oracle.com/technetwork/java/javase/downloads/index.html
Be sure to remember the install location.
sudo apt-get install openjdk-7-jdk
See https://developer.apple.com/downloads/index.action?name=for%20Xcode%20-
Look for the Java Developer Package.
See http://code.google.com/p/msysgit/downloads/list
For the "Adjusting your PATH environment" section, select "Run Git from the Windows Command Prompt".
For the "Configuring the line ending conversions" section, select "Checkout Windows-style, commit Unix-style line endings".
sudo apt-get install git-core git-gui git-doc
If you are using brew (http://mxcl.github.com/homebrew/) you just have to do:
brew install git
See http://maven.apache.org/download.html
sudo apt-get install maven3
Nothing to do, automatically installed with Java for XCode in step 1.
Be sure to remember the extract location.
Create new variables or append the value if the variable already exists:
- Level: System, variable:
JAVA_HOME
, value: JDK install location - Level: User, variable
M2_HOME
, value: Maven extract location - Level: User, variable
M2
, value:%M2_HOME%\bin
- Level: User, variable
PATH
, value%M2%
Nothing to do.
Nothing to do.
git clone git://github.com/ps3mediaserver/ps3mediaserver.git
cd ps3mediaserver
These are needed by the build process:
mvn com.savage7.maven.plugins:maven-external-dependency-plugin:resolve-external
mvn com.savage7.maven.plugins:maven-external-dependency-plugin:install-external
At this point all required software packages are present. PMS is now ready to be built.
git pull
mvn package
The resulting binaries will be built in the "target" directory:
- Windows:
PMS-setup.exe
- Linux:
pms-linux-generic-x.xx.x.tar.gz
- Mac OS X:
pms-macosx-x.xx.x.dmg
These last two commands can easily be automated using a script e.g.:
rem build-pms.bat
start /D ps3mediaserver /wait /b git pull
start /D ps3mediaserver /wait /b mvn package
#!/bin/sh
# build-pms.sh
cd ps3mediaserver
git pull
mvn package
By default, mvn package
builds an installer or distibution file for the
platform it is being compiled on e.g. PMS-setup.exe
on Windows and a tarball on Linux.
As an optional step, releases for other platforms can be built.
The Windows installer (PMS-setup.exe
) and Windows executable
(PMS.exe
) can be built on non-Windows platforms.
First of all, you'll need to have the makensis
binary installed. On Debian/Ubuntu,
this can be done with:
sudo apt-get install nsis
Then the NSISDIR
environment needs to be set to the absolute path to the
nsis
directory. This can either be set per-command:
NSISDIR=$PWD/src/main/external-resources/third-party/nsis mvn ...
- temporarily in the current shell:
export NSISDIR=$PWD/src/main/external-resources/third-party/nsis
mvn ...
- or permanently:
# these two commands only need to be run once
echo "export NSISDIR=$PWD/src/main/external-resources/third-party/nsis" >> ~/.bashrc
source ~/.bashrc
mvn...
For the sake of brevity, the following examples assume it has already been set.
The Windows installer can now be built with one of the following commands:
mvn package -P system-makensis,windows
mvn package -P system-makensis,windows,-osx
mvn package -P linux,-windows
mvn package -P linux,-osx
Currently, the Mac OS X distribution can only be built on Mac OS X e.g. with the default profile:
mvn package
Or it can be specified explicitly:
mvn package -P osx
Now that you have a build environment set up, you can start hacking on PMS. Instructions and tips for developing/patching PMS can be found here.