The Android Open Source Project | 52d4c30 | 2009-03-03 19:29:09 -0800 | [diff] [blame] | 1 | Building the pdk (platform development kit) |
| 2 | |
The Android Open Source Project | 6ffae01 | 2009-03-18 17:39:43 -0700 | [diff] [blame] | 3 | 1) get a cupcake source tree with all the normal tools... and add doxygen |
| 4 | (We currently support version 1.4.6) |
| 5 | |
| 6 | sudo apt-get install doxygen |
Mike Ritter | dfa5494 | 2009-04-01 17:30:12 -0700 | [diff] [blame^] | 7 | |
| 8 | Make sure that you are using the right version of java |
| 9 | |
| 10 | sudo update-java-alternatives -s java-1.5.0-sun |
| 11 | |
| 12 | If that doesn't work, go through the instructions on |
| 13 | |
| 14 | http://source.android.com/download again. |
| 15 | |
The Android Open Source Project | 52d4c30 | 2009-03-03 19:29:09 -0800 | [diff] [blame] | 16 | |
| 17 | 2) from the root |
| 18 | . build/envsetup.sh |
| 19 | |
The Android Open Source Project | 52d4c30 | 2009-03-03 19:29:09 -0800 | [diff] [blame] | 20 | |
| 21 | 4) mkdir dist |
| 22 | mkdir logs |
Mike Ritter | dfa5494 | 2009-04-01 17:30:12 -0700 | [diff] [blame^] | 23 | |
| 24 | then build everything: |
The Android Open Source Project | 52d4c30 | 2009-03-03 19:29:09 -0800 | [diff] [blame] | 25 | |
Mike Ritter | dfa5494 | 2009-04-01 17:30:12 -0700 | [diff] [blame^] | 26 | time make -j4 pdk pdk_all dist DIST_DIR=dist 2>&1 | tee logs/`date +%y%m%d-%H%M%S` |
The Android Open Source Project | 52d4c30 | 2009-03-03 19:29:09 -0800 | [diff] [blame] | 27 | |
Mike Ritter | dfa5494 | 2009-04-01 17:30:12 -0700 | [diff] [blame^] | 28 | so you can have a record of the build commands in the logs directory. |
The Android Open Source Project | 52d4c30 | 2009-03-03 19:29:09 -0800 | [diff] [blame] | 29 | |
The Android Open Source Project | 52d4c30 | 2009-03-03 19:29:09 -0800 | [diff] [blame] | 30 | |
| 31 | 5) the pdk tar file is put in the dist directory. |
| 32 | |
Mike Ritter | dfa5494 | 2009-04-01 17:30:12 -0700 | [diff] [blame^] | 33 | 6) the pdk-docs are in |
| 34 | |
| 35 | out/target |
| 36 | |
The Android Open Source Project | 52d4c30 | 2009-03-03 19:29:09 -0800 | [diff] [blame] | 37 | |
| 38 | The build target 'pdk' brings in the pdk/ndk make files into the build system. |
Mike Ritter | dfa5494 | 2009-04-01 17:30:12 -0700 | [diff] [blame^] | 39 | Then there are three targets: |
| 40 | pdk_docs - which builds just the pdk documentation |
| 41 | ndk - which builds the native development kit (native compiler, linker, etc.) |
| 42 | pdk_all - which builds the above two targets |
The Android Open Source Project | 52d4c30 | 2009-03-03 19:29:09 -0800 | [diff] [blame] | 43 | |
Mike Ritter | dfa5494 | 2009-04-01 17:30:12 -0700 | [diff] [blame^] | 44 | To chnage which version of doxygen runs you can pass in the variable: |
| 45 | doxygen_version='<path/name_of_doxygen_executable>' |
The Android Open Source Project | 52d4c30 | 2009-03-03 19:29:09 -0800 | [diff] [blame] | 46 | on the make line. |
| 47 | |
| 48 | -------------------------------------------------------------------------------- |
Mike Ritter | dfa5494 | 2009-04-01 17:30:12 -0700 | [diff] [blame^] | 49 | # Testing |
| 50 | You must install google appengine. See: http://code.google.com/appengine/downloads.html |
| 51 | |
| 52 | Here's the command to run the pdk-docs server locally: |
| 53 | python <path_to_appengine_installation>/dev_appserver.py --address 0.0.0.0 \ |
| 54 | <path_to_cupcake_code>/android/out/target/common/docs/online-pdk |
| 55 | |
| 56 | To verify it is working you can access it with a browser loacally on port 8080: |
| 57 | |
| 58 | http://localhost:8080/index.html |
| 59 | TODO: index.html needs correct links. |
| 60 | TODO: app.yaml not working for redirecting, getting extra '.' in html names... |
| 61 | |
| 62 | -------------------------------------------------------------------------------- |
| 63 | # Deployment |
| 64 | To host the pdk docs on the interanl appengine run: |
| 65 | /home/build/static/projects/apphosting/devtools/appcfg.py update <path_to_cupcake_src>/out/common/docs |
| 66 | where the docs directory contains: pdk.py, app.yaml, and the online-pdk directory, |
| 67 | all of which are tarred up by the Pdk.mk file when using the target pdk_docs. |
| 68 | |
| 69 | # Deployment |
| 70 | To host the pdk docs on the external appengine run: |
| 71 | /home/build/static/projects/apphosting/devtools/appcfg.py -s pdk-docs.appspot.com update <path_to_cupcake_src>/out/common/docs |
| 72 | where the docs directory contains: pdk.py, app.yaml, and the online-pdk directory, |
| 73 | all of which are tarred up by the Pdk.mk file when using the target pdk_docs. |
| 74 | |
| 75 | |