Changes between Version 10 and Version 11 of BuildingExamples
- Timestamp:
- Apr 23, 2011, 1:27:29 PM (14 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
BuildingExamples
v10 v11 1 1 = Building examples applications = 2 2 3 MutekH comes with some examples applications available in [source: trunk/mutekh/examples].3 MutekH comes with some examples applications available in [source:hg/examples]. 4 4 This page briefly explains how to build these examples. 5 5 6 == Require d tools ==6 == Requirements == 7 7 8 Building MutekH requires the following standard software packages: 9 10 - A GNU compiler or cross-compiler. See below. 11 - GNU make (>=3.81), available in most GNU/Linux and BSD operating systems. 12 - A perl interpreter (>=5.8), available in most GNU/Linux and BSD operating systems. 13 - A python interpreter, available in most GNU/Linux and BSD operating systems. 14 15 Some builds may require the following additional tools 16 17 - The [FlattenedDeviceTree flattened device tree] compiler (dtc): http://git.jdl.com/gitweb/ . This tool is included in precompiled toolchains. 18 - The heterogeneous linker found in [source:trunk/mutekh/tools/hlink], for heterogeneous platforms only. 19 20 You may need real hardware or a simulator to run MutekH: 21 22 - [http://www.qemu.org/ Qemu] to run native x86 binaries, available in most GNU/Linux distributions. 23 - [https://www.soclib.fr/ SoCLib] to experiment with various multiprocessor platforms. A precompiled SoCLib platform is available [https://www.mutekh.org/www/tools/ here] for test purpose. We suggest building your own platforms by installing SoCLib (see soclib:InstallationNotes). 24 25 You may need extra tools to deals with kernel images for some targets: 26 27 - GNU mtools or mkisofs to create a x86 bootable disk images, available in most GNU/Linux distributions. 28 - GNU grub or etherboot to boot compiled kernel images, included in boot image in [source:trunk/mutekh/tools/] directory. 29 30 The [source:trunk/mutekh/tools/x86_cdrom.sh] and [source:trunk/mutekh/tools/x86_floppy.sh] scripts are available to easily create boot disk images. 31 32 === GNU toolchain === 33 34 MutekH comes with a script to build a complete cross-compilation toolchain for you. 35 Some precompiled toolchains are avaialble [https://www.mutekh.org/www/tools/ here] as static i386 Linux binaries for convenience and quick start purpose. It should work on any GNU/Linux i386 and x86_64 distributions. 36 37 We suggest building your own toolchain if you plan to work with MutekH. The [source:trunk/mutekh/tools/crossgen.mk tools/crossgen.mk] script is able to download, build and install toolchains for you. 38 39 There is an inline help: 40 {{{ 41 $ tools/crossgen.mk 42 [prints some help] 43 }}} 44 45 You can try a line like this one to get a Mips cross-compiler installed under `~/gnu`: 46 {{{ 47 $ tools/crossgen.mk all TARGET=mipsel-unknown-elf PREFIX=$HOME/gnu 48 }}} 8 Please read the [[Install]] page to obtain source code and development tools. 49 9 50 10 == Building examples == … … 56 16 Some other configuration options are related to target 57 17 architecture. Some ready to use configuration sets for specific 58 targets are factored in the [source: trunk/mutekh/examples/common] directory. These configuration18 targets are factored in the [source:hg/examples/common] directory. These configuration 59 19 files are organized in sections that can be enabled from the build 60 20 command line. Look at the chosen example config file to determine if 61 21 it contains custom standalone configuration or if it relies on common 62 configuration sets by including files from [source: trunk/mutekh/examples/common].22 configuration sets by including files from [source:hg/examples/common]. 63 23 64 24 Please refer to the BuildSystem page for in depth description of the build system. 65 25 66 Some working examples are listed in [source: trunk/mutekh/examples/README] file.26 Some working examples are listed in [source:hg/examples/README] file. 67 27 68 28 You are encouraged to read platform specific tutorials and subscribe to the [https://www.mutekh.org/wws/subscribe/mutekh-users mutekh-users] mailing list to get help or report issues. … … 70 30 === Using standalone and specific configuration file === 71 31 32 First ensure development tools are available from your current `PATH`. 33 72 34 Here is a make invocation for the hello example using a custom and 73 35 standalone config file which targets x86 Linux process (see QuickStartUnix): 74 36 75 37 {{{ 38 $ cd .../mutekh 76 39 $ make CONF=examples/hello/config_emu 77 40 }}} … … 81 44 Here are make invocations for various target architectures to build 82 45 examples which are using common configuration files: 83 84 46 85 47 - As [wiki:Arch/Emu unix user process], on x86_64 machine running Linux: … … 98 60 }}} 99 61 100 - Heterogeneous builds for SoCLib simulator, Mips32 and Arm processors for caba-vgmn-mutekh_kernel_tutorial platform:101 {{{102 $ make kernel-het CONF=examples/hello_het/config BUILD=pf-het EACH=soclib-mips32el:soclib-arm103 }}}