~unity-team/unity8/ota9.5

« back to all changes in this revision

Viewing changes to CODING

  • Committer: Michał Sawicz
  • Date: 2013-06-05 22:03:08 UTC
  • Revision ID: michal.sawicz@canonical.com-20130605220308-yny8fv3futtr04fg
Inital unity8 commit.

Previous history can be found at https://code.launchpad.net/~unity-team/unity/phablet

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
Building UnityNext
 
2
==================
 
3
 
 
4
download source
 
5
---------------
 
6
- the build requires some additional dependencies, so create the parent folder to not pollute your setup
 
7
  $ mkdir ~/unity
 
8
 
 
9
- fetch Unity Next source
 
10
  $ sudo apt-get install bzr
 
11
  $ bzr branch lp:unity/phablet ~/unity/unity-next
 
12
  $ cd ~/unity/unity-next
 
13
 
 
14
build dependencies
 
15
------------------
 
16
If its your first time, download & build deps
 
17
$ ./build -s
 
18
  this will:
 
19
  - add ppa:phablet-team/desktop-deps, ppa:canonical-qt5-edgers/qt5-proper, ppa:ubuntu-sdk-team
 
20
  - build and install lp:libunity/phablet, lp:unity/phablet-mods, lp:hud/phablet and lp:unity-lens-people locally
 
21
  - install build dependencies
 
22
 
 
23
build UnityNext
 
24
---------------
 
25
$ ./build
 
26
 
 
27
subsequent updates of the dependencies
 
28
--------------------------------------
 
29
$ ./build_unity -u
 
30
$ ./build_unity
 
31
 
 
32
 
 
33
Running UnityNext on your desktop
 
34
=================================
 
35
 
 
36
run the People lens daemon
 
37
--------------------------
 
38
$ ~/unity/unity_build/libexec/unity-people-daemon
 
39
 
 
40
run the UnityNext shell
 
41
-----------------------
 
42
$ cd ~/unity/unity-next
 
43
$ ./run
 
44
 
 
45
Notes
 
46
-----
 
47
- to navigate, utilize the mouse left button as you would your finger
 
48
- if your contacts are empty
 
49
  $ sudo apt-get install gir1.2-ebook-1.2
 
50
  $ manage-address-book.py create
 
51
    this will:
 
52
    - create an EDS address book
 
53
    - populate the address book with sample data
 
54
- to get the translations work, currently you have to do make install to
 
55
  put the *.mo files into correct structure. We'll look for a better solution
 
56
  later.
 
57
  $ cd builddir; make install
 
58
 
 
59
Running UnityNext on devices
 
60
============================
 
61
- Ubuntu Touch builds are currently only available in 13.10 flavour
 
62
- supported hardware should match one those listed here https://wiki.ubuntu.com/Touch/Devices#Running_fine
 
63
- follow the Ubuntu Touch install instructions for your chosen device https://wiki.ubuntu.com/Touch/Install
 
64
- make sure your device is connected to a WiFi network
 
65
- also make sure you have your SSH key in ~/.ssh/id_rsa.pub (or install one on the device yourself)
 
66
 
 
67
$ cd ~/unity/unity-next
 
68
$ ./run_on_device -s
 
69
  this will:
 
70
  - install your public SSH key on the device
 
71
  - add ppa:canonical-qt5-edgers/qt5-proper and ppa:phablet-team
 
72
  - install the needed dependencies
 
73
 
 
74
$ ./run_on_device
 
75
  this will:
 
76
  - rsync the code to the device
 
77
  - build on the device
 
78
  - replace the running shell
 
79
 
 
80
Notes
 
81
-----
 
82
- using adb over TCP has some advantages, Google will be of help here
 
83
  - TL;DR: `adb tcpip 5555; adb connect $your_device_ip`
 
84
  - you can persist the above via `adb shell setprop persist.adb.tcp.port 5555`
 
85
  - it's unsafe - anyone can connect to your device
 
86
  - with TCP the Nexus 10 doesn't drop the adb connection when locking the screen
 
87
- exporting ANDROID_SERIAL=$your_device_serial or ANDROID_SERIAL=$your_device_ip:5555
 
88
  will make adb not complain about multiple devices 
 
89
- you can export TARGET_IP=$your_device_ip TARGET_SSH_PORT=22 for run_on_device
 
90
  to not use adb forwarding - useful if you use multiple devices
 
91
- using Ninja (package ninja-build - run_on_device -s installs this now) will improve
 
92
  build times (especially in the nothing-to-build case)
 
93
 
 
94
 
 
95
Coding guidelines
 
96
=================
 
97
The work-in-progress coding guidelines are available under:
 
98
https://launchpad.net/canonical-client-development-guidelines
 
99
 
 
100
 
 
101
Development Environment
 
102
=======================
 
103
QtCreator (available via the Software Center) is the best IDE to hack on UnityNext.