Project

General

Profile

DeprecatedInstallation » History » Version 28

Paul Kocialkowski, 02/05/2012 05:43 PM

1 27 Paul Kocialkowski
h1. Installation
2 1 Denis 'GNUtoo' Carikli
3 26 Paul Kocialkowski
{{toc}}
4 25 Paul Kocialkowski
5
h2. Detailed instructions to install Replicant
6
7 28 Paul Kocialkowski
1. *Make sure your phone is supported*
8 25 Paul Kocialkowski
9 28 Paul Kocialkowski
Replicant only supports a few phones. Make sure the phone you want to install Replicant on is on the [[ReplicantStatus]] list. If it's not, you won't be able to install Replicant on your device without at least a bit of software hacking.
10 25 Paul Kocialkowski
11 28 Paul Kocialkowski
2. *Make sure your phone allows non-official images*
12 25 Paul Kocialkowski
13
14
    Some phones come with software that allows the user to _flash_ the memory (replace the content of the memory partitions, like the system or the kernel one), but it's not always the case. Google-branded phones (Nexus One and Nexus S) come with this allowed but for some other devices, you'll certainly have to do some more operations to make this possible (it's required to flash Replicant).
15
16
    Please, refer to the "CyanogenMod wiki":http://wiki.cyanogenmod.com/wiki/Main_Page to find and follow the instructions to *root the phone*. Note that instructions for Replicant 2.2 correspond to [[CyanogenMod]] 6 and Replicant 2.3 correspond to [[CyanogenMod]] 7.
17
18
    For instance on the "HTC Dream":http://wiki.cyanogenmod.com/wiki/HTC_Dream page, you'll need to follow the instructions to *root the phone* and to install *DangerSPL*.
19
20
21
    *Note: all the radio images and bootloader images that are provided on these pages are not free software.*
22
23
24
 3. *Download the Replicant images and tools for your phone*
25
26
27
   a. *Find the codename of your phone*
28 1 Denis 'GNUtoo' Carikli
29 25 Paul Kocialkowski
      Each device we support has a codename. You can find the codenames on the [[ReplicantStatus]] page. 
30
31 27 Paul Kocialkowski
For instance, HTC Dream has Codename: dream_sapphire .
32 25 Paul Kocialkowski
33
34 1 Denis 'GNUtoo' Carikli
   b. *Find the latest usable Replicant image*
35 25 Paul Kocialkowski
36
      The [[ReplicantStatus]] page also shows the latest usable Replicant image for each device.
37
38 27 Paul Kocialkowski
For instance, HTC Dream/HTC Magic has Last usable image: Replicant 2.2 preview 0009 .
39 25 Paul Kocialkowski
40
41
   c. *Find the base location of the tools/images for your device*
42
43
44
      Replicant images are hosted at: http://ftp.osuosl.org/pub/replicant/images/ 
45
46
      From this page, select the Replicant version (replicant-2.2, replicant-2.3, etc) of the latest usable Replicant image for your device.
47 1 Denis 'GNUtoo' Carikli
48 25 Paul Kocialkowski
      Then, select the Replicant image type (preview or release) of the latest usable Replicant image for your device.
49
50
      Select the Replicant image number (0006 for example) of the latest usable Replicant image for your device.
51
52 27 Paul Kocialkowski
For instance, if the phone is HTC Dream and the latest image Replicant 2.2 preview 0009 , the base location will be: http://ftp.osuosl.org/pub/replicant/images/replicant-2.2/preview/0009/ .
53 25 Paul Kocialkowski
54
55
   d. *Download the tools to flash your device*
56
57
58
      From the base location we just found out, select the *tools* directory and download the *fastboot* utility to write Replicant on your device. 
59
60
61
   e. *Download the Replicant images for your device*
62
63
64 1 Denis 'GNUtoo' Carikli
      From the base location we just found out, select the *pieces* directory and then the directory corresponding to your phone codename and download the *boot.img* (kernel), *system.img* (OS) and *userdata.img* (data) files. It can take some time. 
65
66
67 25 Paul Kocialkowski
 4. *Setup the computer to flash Replicant*
68 1 Denis 'GNUtoo' Carikli
69
70 27 Paul Kocialkowski
71
Open a terminal and go to the location where you downloaded all the files (usually, ~/Downloads ). To do this, run the following command:
72
73
74 25 Paul Kocialkowski
    To do this, run the following command:
75
76 27 Paul Kocialkowski
cd ~/Downloads 
77 1 Denis 'GNUtoo' Carikli
78 27 Paul Kocialkowski
If you have downloaded the files in any other place, change ~/Downloads by the location where you downloaded the files.
79 25 Paul Kocialkowski
80
    Then, you need to get root on this terminal. Run:
81
82 27 Paul Kocialkowski
su 
83 25 Paul Kocialkowski
84
    This will ask you to type the superuser (root) password. Note that in most cases, the letters you type won't be shown.
85
86
    Now that you're root, you are able to use the *fastboot* utility. We first need to make it executable. To do this, run the following: 
87
88 27 Paul Kocialkowski
chmod a+x fastboot 
89 25 Paul Kocialkowski
90
    Keep this terminal open during the next step.
91
92
93
 5. *Setup the device to flash Replicant*
94 1 Denis 'GNUtoo' Carikli
95 25 Paul Kocialkowski
96
    Completely turn off your device. You can also remove and reinsert the battery then. 
97
98
    Now, you'll need to turn your device in fastboot mode. The usual way to do this is to hold a few buttons when booting. 
99
100
    A list of the buttons to hold for each (Google) device  is available at: http://source.android.com/source/building-devices.html#booting-into-fastboot-mode 
101
102
    Connect the USB cable to your PC, hold the appropriate keys and boot the phone. You should get on fastboot menu. 
103
104
    If it's the first time you flash an image and your phone is Google Nexus One or Google Nexus S, you'll need to unlock the bootloader. Switch back to the terminal we opened earlier and run: 
105
106 27 Paul Kocialkowski
./fastboot oem unlock Warning: on Nexus One, the operation voids the warranty and is irreversible. On Nexus S and Nexus S 4G, the bootloader can be locked back.
107 25 Paul Kocialkowski
108
109
 6. *Flash Replicant images*
110
111
112
    *WARNING: This step will erase every data stored on the phone, make sure you copied the data if you don't want to lose it.* 
113
114
    Switch back to the terminal we just opened and run the following commands: 
115
116
<pre>
117 17 Paul Kocialkowski
./fastboot flash system system.img
118 18 Paul Kocialkowski
./fastboot flash boot boot.img
119 19 Paul Kocialkowski
./fastboot flash userdata userdata.img 
120 25 Paul Kocialkowski
</pre>
121
    If you want to flash Recovery image:
122
123
<pre>
124 20 Paul Kocialkowski
./fastboot flash recovery recovery.img 
125 25 Paul Kocialkowski
</pre>
126 22 Paul Kocialkowski
    Then clean the cache and reboot:
127 25 Paul Kocialkowski
<pre>
128 23 Alexandre Oliva -
./fastboot erase cache
129 22 Paul Kocialkowski
./fastboot reboot
130 25 Paul Kocialkowski
</pre>
131 22 Paul Kocialkowski
    Your device should now reboot with Replicant running. Now you are done, Replicant is installed on your device!
132 20 Paul Kocialkowski
133
134 25 Paul Kocialkowski
h2. Summary of the instructions to install Replicant
135
 #installsummary
136 16 Paul Kocialkowski
137 8 Paul Kocialkowski
138 25 Paul Kocialkowski
h2. Requirements
139
140
* a rooted or unlocked phone
141
* fastboot(can be built or obtained "from our ftp":http://ftp.osuosl.org/pub/replicant/images/replicant-2.2/)
142
* the images(can be built or obtained "from our ftp":http://ftp.osuosl.org/pub/replicant/images/replicant-2.2/)
143
144
145
h2. Installation
146
147
148 10 Mark Holmquist -
Put the phone in fastboot mode (by holding the Camera button and the Power button, then following on-screen instructions), make sure it's connected to your computer, and run the following commands on your computer. You may need to use sudo.
149 4 Denis 'GNUtoo' Carikli
150 25 Paul Kocialkowski
*Note, if you don't have instructions for entering fastboot mode, you may need to install [[DangerSPL]] using the [[CyanogenMod]] instructions.*
151 1 Denis 'GNUtoo' Carikli
152 25 Paul Kocialkowski
*Note that it will erase everything on the phone* 
153
<pre>
154 1 Denis 'GNUtoo' Carikli
./fastboot flash system system.img
155
./fastboot flash boot boot.img
156
./fastboot flash userdata userdata.img 
157
./fastboot erase cache
158
./fastboot reboot
159 25 Paul Kocialkowski
</pre>