-
Notifications
You must be signed in to change notification settings - Fork 16
Development Environment Setup
Some users may want to build MythTV-Android-Frontend from source. This enables them to get the latest version of the code, use enhanced debugging tools and even make local changes to suit their needs.
In the following, there are references to ADT and Eclipse, which are:
- Android Developer Tools
- Eclipse IDE for Java Developers
Here's how to get started.
- Go to the Android SDK page
- Click on
Download
and select the properPackage
for the host'sPlatform
- Agree to the
terms and conditions
- In this Wiki the download directory will be
~/source
- Note that these instructions were written using *buntu platforms
cd ~/source
unzip adt-bundle-<os_platform>.zip
- Optional: For convenience, rename the directory just created:
mv adt-bundle-<os_platform> adt
- 64 bit Mythbuntu users may need to install 32 bit libraries:
sudo apt-get install ia32-libs
- Users may need to install their distribution's Java package:
sudo apt-get install java-common
- Edit the
~/source/adt/eclipse/eclipse.ini
file, see: Recommended Additions toeclipse.ini
below - Adjust the SDK user's $PATH variable, see: Suggested
$PATH
Configuration below - For additional detail, refer to Setting Up the ADT Bundle
- From the command line, type
eclipse
- Click on the
X
in the upper-left to dismiss the splash screen - Install the Maven, Eclipse Git and Simple Logging Facade for Java plugins
- From the
Help
menu, selectInstall New Software...
, - In the
Work with:
box, select--All Available Sites--
, - In the filter box under the above, enter
maven
- Wait until the
Name
box populates - Click on the
Select All
,Next
Next
andFinish
buttons - When asked to restart click
Yes
- Repeat the previous bullet points replacing
maven
withegit
andslf4j
-
N.B.: When installing
SLF4J
, choose only theMaven Integration for Eclipse
version
- Upload a copy of Mythtv Android Frontend from GitHub
- Select the
Open
Perspective (small box on the left side of the tab in the upper right of the screen), - Select
Git Repository Exploring
. - In the Left-hand pane, click on
Clone a Git Repository
- In the popup, select
GitHub
, click onNext
- In the
Search
box, enterMythTV-Android-Frontend
and click onSearch
- Select the entry that says:
MythTV-Clients/MythTV-Android-Frontend
- Click on
Next
and on the next page:Select All
,Next
on the next page:Finish
- In the upper-right, select the
Java
Perspective - From the menu, select
File
,Import...
- On the popup, expand
Maven
and chooseExisting Maven Projects
- On the next popup, search for the directory used above (probably
~/workspace/MythTV-Android-Frontend
- Click on
Next
and thenFinish
- In the next popup,
Select All
andFinish
- Expect to see a
Security Warning
- When asked if you want to restart, click on
Yes
- An automatic build will start, give it some time and errors will go away.
Not all of the steps listed below are required for any given change, however, they are listed here for convenience.
- Connect an Android device to a host USB port
- Switch to the
Git Repository Exploring
Perspective
- On the left-hand window, right click on
MythT-Android-Frontend
and selectPull
to get the latest commit(s)
- Switch to the
Java
Perspective
- From the menu bar, select
Project
thenClean...
, - Right click on
mythtv-android-frontend
and selectMaven
,Update Project...
andOK
- If desired, select file(s) under
MythTV-Android-Frontend
src
and edit, - Right click on
MythTV-Android-Frontend
and selectRun As
thenAndroid Application
- Select the device to use (there will likely be only one)
- For installation errors, see the
Console
window and follow its instructions - The first time the above is done, answer
Yes
toAutomatically Monitor LogCat
- To observe program flow, maximize the
LogCat
window (lower right)
- There is a
README
file included with the source. It has additional items of interest to developers.
As part of this Open Source project, most of underlying methods used to access the MythTV Services API have been placed in a separate repository and are available to any developer/project via the Maven plugin, and its source is also on GitHub.
This means that the source code for that portion of the project was not downloaded in the above instructions. Rather, it is read in at build time.
If the project changes the Maven release and references it in the source, builds can fail until the Maven libraries have been synced. To see their status, visit: The Central Repository
Note: Delete any existing properties that match the following:
-XX:-UseParallelGC -XX:-UseConcMarkSweepGC -XX:+UseFastAccessorMethods -DMAVEN_OPTS="-Xms64m –Xmx128m" -Xmn128m -Xss1m -XX:PermSize=128m -XX:MaxPermSize=384m -Xms768m -----> These 2 probably will already exist, choose 1 size -Xmx1024m ----->
The above should be adjusted based on the user's system memory size.
export ANDROID_HOME=~/source/adt/sdk type -P eclipse > /dev/null if [ $? -ne 0 ]; then PATH=~/source/adt/eclipse:$PATH fi type -P android > /dev/null if [ $? -ne 0 ]; then PATH=$ANDROID_HOME/tools:$PATH fi type -P adb > /dev/null if [ $? -ne 0 ]; then PATH=$ANDROID_HOME/platform-tools:$PATH fi
End of Life Notice:
Thanks for everyone that tested the MythTV Android Frontend project!
There will be no more development on it and a new MythTV Player For Android is now in development.
And for those that may think the new project will support Live TV, as of MythTV 0.28-pre, there is still no Services API interface for Live TV, so it still isn't possible.
MythTV Player for Android is going to focus solely on playing the media you have on your backend, forgoing all the rest of the frontend features that you would find on a traditional frontend.
Here is a short list of the goals for the project:
Recording Playback with no dependencies on external players
Video Playback with no dependencies on external players
Chromecast Support
Leanback interface for Android TV
You can follow the progress of the code here: https://github.com/MythTV-Clients/MythtvPlayerForAndroid
We are currently working out some minor layout issues and finalizing playback scenarios in the app and are hoping to release this for beta very soon.