OLD | NEW |
(Empty) | |
| 1 This is a README file describing how to build Dart for Fuchsia. It assumes that |
| 2 you have built the magenta kernel under //magenta, its toolchains are |
| 3 under //toolchains, and that you have a Dart checkout under //dart. It is early |
| 4 days and this is crufty. The process will improve from here. |
| 5 |
| 6 1. First, set up some symlinks in your Dart checkout: |
| 7 |
| 8 //dart/third_party/fuchsia_tools/toolchains |
| 9 -> symlinked to //toolchains |
| 10 //dart/third_party/fuchsia_tools/sysroot/x86_64/usr |
| 11 -> symlinked to //magenta/build-magenta-qemu-x86-64/sysroot/ |
| 12 |
| 13 Also, copy the linker script: |
| 14 |
| 15 //magenta$ cp kernel/arch/x86/64/user.ld build-magenta-qemu-x86-64/sysroot/ |
| 16 |
| 17 and similarly for arm64. |
| 18 |
| 19 2. Build: |
| 20 |
| 21 //dart$ tools/build.py -m product -a x64 --os=fuchsia fuchsia_test |
| 22 |
| 23 This will produce //dart/out/ProductFuchsiaX64/fuchsia_test |
| 24 |
| 25 3. Strip it: |
| 26 |
| 27 //dart$ third_party/fuchsia_tools/toolchains/x86_64-elf-5.3.0-Linux-x86_64/bin
/x86_64-elf-strip out/ProductFuchsiaX64/fuchsia_test -o out/ProductFuchsiaX64/fu
chsia_test.stripped |
| 28 |
| 29 4. Make a file //magenta/fuchsia_test.manifest containing: |
| 30 |
| 31 bin/fuchsia_test=//dart/out/ProductFuchsiaX64/fuchsia_test.stripped |
| 32 |
| 33 Where //dart is the actual path to your Dart checkout. |
| 34 |
| 35 5. Make an extra bootfs: |
| 36 |
| 37 //magenta$ build-magenta-qemu-x86-64/tools/mkbootfs -o fuchsia_test.bootfs fuc
hsia_test.manifest |
| 38 |
| 39 6. Run: |
| 40 |
| 41 //magenta$ ./scripts/run-magenta-x86-64 -x fuchsia_test.bootfs |
OLD | NEW |