README
1 Using the Eclipse project DDMS
2 ------------------------------
3
4 DDMS requires some external libraries to compile.
5 If you build DDMS using the makefile, you have nothing to configure.
6 However if you want to develop on DDMS using Eclipse, you need to
7 perform the following configuration.
8
9
10 -------
11 1- Projects required in Eclipse
12 -------
13
14 To run DDMS from Eclipse, you need to import the following 5 projects:
15
16 - sdk/androidpprefs: project AndroidPrefs
17 - sdk/sdkstats: project SdkStatsService
18 - sdk/ddms/app: project Ddms
19 - sdk/ddms/libs/ddmlib: project Ddmlib
20 - sdk/ddms/libs/ddmuilib: project Ddmuilib
21
22
23 -------
24 2- DDMS requires some SWT and OSGI JARs to compile.
25 -------
26
27 SWT is available in the tree under prebuild/<platform>/swt
28
29 Because the build path cannot contain relative path that are not inside
30 the project directory, the .classpath file references a user library
31 called ANDROID_SWT.
32 SWT depends on OSGI, so we'll also create an ANDROID_OSGI library for that.
33
34 In order to compile the project:
35 - Open Preferences > Java > Build Path > User Libraries
36
37 - Create a new user library named ANDROID_SWT
38 - Add the following 4 JAR files:
39
40 - prebuilt/<platform>/swt/swt.jar
41 - prebuilt/common/eclipse/org.eclipse.core.commands_3.*.jar
42 - prebuilt/common/eclipse/org.eclipse.equinox.common_3.*.jar
43 - prebuilt/common/eclipse/org.eclipse.jface_3.*.jar
44
45 - Create a new user library named ANDROID_OSGI
46 - Add the following JAR file:
47
48 - prebuilt/common/eclipse/org.eclipse.osgi_3.*.jar
49
50
51 -------
52 3- DDMS also requires the compiled SwtMenuBar library.
53 -------
54
55 Build the swtmenubar library:
56 $ cd $TOP (top of Android tree)
57 $ . build/envsetup.sh && lunch sdk-eng
58 $ sdk/eclipse/scripts/create_sdkman_symlinks.sh
59
60 Define a classpath variable in Eclipse:
61 - Open Preferences > Java > Build Path > Classpath Variables
62 - Create a new classpath variable named ANDROID_OUT_FRAMEWORK
63 - Set its folder value to <Android tree>/out/host/<platform>/framework
64 - Create a new classpath variable named ANDROID_SRC
65 - Set its folder value to <Android tree>
66
67 You might need to clean the ddms project (Project > Clean...) after
68 you add the new classpath variable, otherwise previous errors might not
69 go away automatically.
70
71 The ANDROID_SRC part should be optional. It allows you to have access to
72 the SwtMenuBar generic parts from the Java editor.
73
74 --
75 EOF
76