@@ -1,43 +1,64 @@
1Building Unity 8
1Building Unity 8
2================
2================
4+Only Ubuntu 13.10 (saucy) is supported as a developement environment.
4download source
6download source
5---------------
7---------------
6−- the build requires some additional dependencies, so create the parent folder to not pollute your setup
8+- create a parent folder to not pollute your setup. so that you can have different unity
7− $ mkdir ~/unity
9+ branches there (trunk, WIP etc)
9- fetch Unity 8 source
13- fetch Unity 8 source
10 $ sudo apt-get install bzr
14 $ sudo apt-get install bzr
11− $ bzr branch lp:unity/8.0 ~/unity/unity8
15+ $ bzr branch lp:unity8 ~/unity8/trunk
12− $ cd ~/unity/unity8
16+ $ cd ~/unity8/trunk
20+If its your first time, install build dependencies
16−If its your first time, download & build deps
18 this will:
25 this will:
19− - add ppa:phablet-team/desktop-deps, ppa:canonical-qt5-edgers/qt5-proper, ppa:ubuntu-sdk-team
26+ - add the following PPA's
20− - build and install lp:libunity/phablet, lp:unity/phablet-mods, lp:hud/phablet locally
27+ - ppa:phablet-team/desktop-deps
21− - install build dependencies
28+ - ppa:canonical-qt5-edgers/qt5-proper
29+ - ppa:ubuntu-sdk-team
30+ - install the required dependencies to build, as well as run on the desktop
31+ - it should also install unity-scope-home and unity-lens-application which
32+ are technically "recommends", not strict dependencies
34+Note, once the PPA's are added, the script runs apt-get update, if you have
35+any failures associated with it, the build script will bail out of the setup
36+and fail to install all the required dependencies.
23build Unity 8
39build Unity 8
24-------------
40-------------
27−subsequent updates of the dependencies
42+$ cd ~/unity8/trunk
28−--------------------------------------
43+$ ./build
45+You may also rebuild with the -c for clean, which just deletes the build
33Running Unity 8 on your desktop
48Running Unity 8 on your desktop
34===============================
49===============================
36run the Unity 8 shell
51run the Unity 8 shell
37---------------------
52---------------------
38−$ cd ~/unity/unity8
53+$ cd ~/unity8/trunk
56+Options can be passed to test the lock screen
59+-p is for pin lock, for which the default prompt answer is "1234"
60+-k is for keylock passphrase, for which the default prompt answer is "password"
43- to navigate, utilize the mouse left button as you would your finger
64- to navigate, utilize the mouse left button as you would your finger
@@ -45,17 +66,29 @@ Notes
45 put the *.mo files into correct structure. We'll look for a better solution
66 put the *.mo files into correct structure. We'll look for a better solution
47 $ cd builddir; make install
68 $ cd builddir; make install
69+- if you wish to populate contacts
70+ $ sudo apt-get install gir1.2-ebook-1.2
71+ $ manage-address-book.py create
73+ - Create an EDS address book
74+ - Populate the address book with sample data
49Running Unity 8 on devices
76Running Unity 8 on devices
50==========================
77==========================
51- Ubuntu Touch builds are currently only available in 13.10 flavour
78- Ubuntu Touch builds are currently only available in 13.10 flavour
52−- supported hardware should match one those listed here https://wiki.ubuntu.com/Touch/Devices#Running_fine
79+- supported hardware should match one those listed here
53−- follow the Ubuntu Touch install instructions for your chosen device https://wiki.ubuntu.com/Touch/Install
80+ https://wiki.ubuntu.com/Touch/Devices#Running_fine
81+- follow the Ubuntu Touch install instructions for your chosen device
82+ https://wiki.ubuntu.com/Touch/Install
54- make sure your device is connected to a WiFi network
83- make sure your device is connected to a WiFi network
55−- also make sure you have your SSH key in ~/.ssh/id_rsa.pub (or install one on the device yourself)
84+- If you haven’t already or if you’ve just freshly flashed your device
56−
85+ make sure you run phablet-network-setup which will allow package updates to
57−$ cd ~/unity/unity8
86+ the device
58−$ ./run_on_device -s
87+- also make sure you have your SSH key in ~/.ssh/id_rsa.pub (or install one
88+ on the device yourself)
91+$ ./run_on_device --setup
59 this will:
92 this will:
60 - install your public SSH key on the device
93 - install your public SSH key on the device
61 - add ppa:canonical-qt5-edgers/qt5-proper and ppa:phablet-team
94 - add ppa:canonical-qt5-edgers/qt5-proper and ppa:phablet-team
@@ -67,19 +100,27 @@ $ ./run_on_device
67 - build on the device
100 - build on the device
68 - replace the running shell
101 - replace the running shell
103+Options can be passed to test the lock screen
104+$ ./run_on_device -p OR -k
106+-p is for pin lock, for which the default prompt answer is "1234"
107+-k is for keylock passphrase, for which the default prompt answer is "password"
72- using adb over TCP has some advantages, Google will be of help here
111- using adb over TCP has some advantages, Google will be of help here
73 - TL;DR: `adb tcpip 5555; adb connect $your_device_ip`
112 - TL;DR: `adb tcpip 5555; adb connect $your_device_ip`
74 - you can persist the above via `adb shell setprop persist.adb.tcp.port 5555`
113 - you can persist the above via `adb shell setprop persist.adb.tcp.port 5555`
75 - it's unsafe - anyone can connect to your device
114 - it's unsafe - anyone can connect to your device
76− - with TCP the Nexus 10 doesn't drop the adb connection when locking the screen
115+ - with TCP the Nexus 10 doesn't drop the adb connection when locking
77−- exporting ANDROID_SERIAL=$your_device_serial or ANDROID_SERIAL=$your_device_ip:5555
116+ the screen
78− will make adb not complain about multiple devices
117+- exporting ANDROID_SERIAL=$your_device_serial or
118+ ANDROID_SERIAL=$your_device_ip:5555 will make adb not complain about
79- you can export TARGET_IP=$your_device_ip TARGET_SSH_PORT=22 for run_on_device
120- you can export TARGET_IP=$your_device_ip TARGET_SSH_PORT=22 for run_on_device
80 to not use adb forwarding - useful if you use multiple devices
121 to not use adb forwarding - useful if you use multiple devices
81−- using Ninja (package ninja-build - run_on_device -s installs this now) will improve
122+- using Ninja (package ninja-build - run_on_device -s installs this now)
82− build times (especially in the nothing-to-build case)
123+ will improve build times (especially in the nothing-to-build case)
85Coding guidelines
126Coding guidelines
@@ -90,4 +131,9 @@ https://launchpad.net/canonical-client-development-guidelines
91Development Environment
132Development Environment
92=======================
133=======================
93−QtCreator (available via the Software Center) is the best IDE to hack on Unity 8.
134+QtCreator (available via the Software Center) is the best IDE to hack on
137+If using VIM, make sure you install some syntax highlighting for QML, like
138+https://github.com/peterhoeg/vim-qml