compiling PS3 Media Server on Mac OS X

Recently I decided to explore a new world. I was playing around with Mac OS X 10.6 in a VMware Workstation virtual machine on Microsoft Windows 7. I also tried to compile and test PS3 Media Server on OS X. Here’s how I did it.

prerequisites

You may need some tools to compile PMS.

  1. terminal app
  2. SVN client
  3. Java
  4. Apache ant
  5. text editor
  6. jarbundler

You are free to use command line or GUI. You may have a favourite Text editor or shell. OS X already contains most tools needed for compiling.

terminal application

OS X already contains a terminal app.There’s a good howto from O’Reilly if it’s your first time working with shell commands. You can also use iTerm (Open Source).

SVN client

OS X already contains a command line SVN client. There’s a good howto on Murky’s blog. You may also use GUI based free SVN clients like Bazaar, iSVN or svnX.

Java

OS X already contains Java JDK. There’s no need to change anything.

Apache ant

OS X already contains Apache ant. There’s no need to change anything.

Text editor

OS X already contains the command line text edititors nano and vim. OS X also contains a GUI based text editor, the TextEdit app which can cause trouble. But there’s a howto from Apple for setting up TextEdit correctly for working with plain text files. I suggest to use free and powerful TextWrangler if you prefer a GUI based editor.

advanced developement

You may get a free apple developer account. Then you can download Xcode and other developer downloads for Java, C, … XCode contains a text editor with syntax highlighting, a SVN GUI, …

jarbundler

In order to create jar-bundles during compiling PMS you have to install jarbundler first. Download it and install it via Terminal app:

users-mac-2:~ User$ cd $HOME/Downloads/jarbundler-2.2.0/
users-mac-2:jarbundler-2.2.0 User$ ls -l
total 72
-rw-r--r--@  1 User  staff  11358 19 Jan  2008 LICENSE.TXT
-rw-r--r--@  1 User  staff   3924 27 Dez 11:43 build.xml
drwxr-xr-x@ 10 User  staff    340  6 Feb 14:35 dox
drwxr-xr-x@  6 User  staff    204  6 Feb 14:35 example
-rw-r--r--@  1 User  staff  18509 27 Dez 11:52 jarbundler-2.2.0.jar
drwxr-xr-x@  3 User  staff    102 19 Jan  2008 src
users-mac-2:jarbundler-2.2.0 User$ sudo cp jarbundler-2.2.0.jar /usr/share/ant/lib/
WARNING: Improper use of the sudo command could lead to data loss
or the deletion of important system files. Please double-check your
typing when using sudo. Type "man sudo" for more information.
To proceed, enter your password, or type Ctrl-C to abort.
Password:

checkout PMS source code from svn

You have to crete a download directory and checkout PMS (download source code) from http://ps3mediaserver.googlecode.com/svn/trunk/

via terminal

users-mac-2:jarbundler-2.2.0 User$ cd $HOME
users-mac-2:svn User$ svn checkout http://ps3mediaserver.googlecode.com/svn/trunk/ svn
A    svn/ps3mediaserver
A    svn/ps3mediaserver/MediaInfo64.dll
A    svn/ps3mediaserver/plugins
A    svn/ps3mediaserver/plugins/plugins.txt
A    svn/ps3mediaserver/dist-archive

A    svn/ps3mediaserver/.settings
A    svn/ps3mediaserver/.settings/org.eclipse.jdt.core.prefs
A    svn/ps3mediaserver/.settings/org.eclipse.core.resources.prefs
Checked out revision 480.

via finder and iSVN

compile PMS source code

After downloading source code you can start changing it or just compile it in order to create a DMG install image for OS X.

workaround for non English languages

Open text file svn/ps3mediaserver/osx/build.xml and change line from

<arg value="${user.home}/Desktop/Applications"/>

to

<arg value="${user.home}/Desktop/Programme"/>

This was an example for German language.

compiling PMS

users-mac-2:svn User$ cd svn/ps3mediaserver/osx/
users-mac-2:osx User$ ant DMG
Buildfile: build.xml
[echo] IMPORTANT! THIS SCRIPT MUST USE MAC OS X 10.5 OR HIGHER AND JDK 1.6 TO PRODUCE A VALID PMS.JAR
[echo] Java Version: 1.6.0_15
...
DMG:
[mkdir] Created dir: /Users/User/svn/ps3mediaserver/osx/PS3 Media Server
[exec] alias file Programme of folder Desktop of folder User of folder Users of startup disk
[exec] created: /Users/User/svn/ps3mediaserver/osx/pms-macosx-1.21.0.dmg
BUILD SUCCESSFUL
Total time: 1 minute 3 seconds
users-mac-2:osx User$ ls -l *dmg
-rw-r--r--@ 1 User  staff  29125760  6 Feb 15:52 pms-macosx-1.21.0.dmg
users-mac-2:osx User$

o.k. now you can install PMS by dragging the DMG file to the applications folder. That’s it! Have fun ;)

If you want to do some testing you can also start PMS directly without installing it first. Start terminal, change to PMS app folder where pms.jar is located and start it directly with several options…

This entry was posted in Media Server, VMware and tagged , , , . Bookmark the permalink.

One Response to compiling PS3 Media Server on Mac OS X

  1. Ygor Soares says:

    Perfect :)

    Thaks otmanix :)

Leave a Reply

Your email address will not be published. Required fields are marked *

*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>