assert_spec platform_arndale # # Build # set build_components { app/cli_monitor app/gdb_monitor app/launchpad app/scout core drivers/ahci drivers/framebuffer drivers/platform drivers/sd_card drivers/timer drivers/uart drivers/usb init l4linux lib/libc_noux noux server/ffat_fs server/fs_rom server/nic_bridge server/liquid_framebuffer server/nitpicker server/part_blk server/tar_fs server/terminal server/terminal_crosslink server/terminal_log server/terminal_mux test/affinity test/blk/cli test/gdb_monitor test/input test/lwip/http_srv test/nitpicker } lappend build_components noux-pkg/vim lappend build_components noux-pkg/gdb_arm build $build_components create_boot_directory exec tar cfv bin/vim.tar -h -C bin/vim . # # Config # set config { } append config { } install_config $config set gdb_config_fd [open "bin/gdb_command_config" w] puts $gdb_config_fd { } close $gdb_config_fd set gdb_binaries { test-gdb_monitor testnit scout libc.lib.so ld.lib.so libc_log.lib.so } set gdb_stripped_binaries { expat.lib.so gdb_monitor init launchpad libc_lock_pipe.lib.so libc_noux.lib.so libc_terminal.lib.so libm.lib.so liquid_fb ncurses.lib.so noux terminal terminal_crosslink } exec sh -c "find bin/gdb_arm/ -type f | (xargs [cross_dev_prefix]strip || true) 2>/dev/null" exec mkdir -p bin/gdb/src foreach binary ${gdb_binaries} { set source_files [ exec [cross_dev_prefix]objdump -dl bin/${binary} | grep "^/.*:.*" | sed -e "s/:.*//" | uniq ] foreach source_file ${source_files} { # resolve '..' to avoid problems with 'tar' with parts like '/a/b/../' # where '/a' exists, but '/a/b' does not set source_file [file normalize ${source_file}] if [file exists ${source_file}] { set dirname [ exec dirname ${source_file}] exec mkdir -p bin/gdb/src${dirname} exec ln -sf ${source_file} bin/gdb/src${source_file} } } } foreach binary ${gdb_stripped_binaries} { exec sh -c "cp bin/${binary} bin/gdb/${binary}" exec sh -c "[cross_dev_prefix]strip bin/gdb/${binary}" } foreach binary ${gdb_binaries} { exec ln -s ../${binary} bin/gdb/${binary} } exec ln -s ../gdb_command_config bin/gdb/gdb_command_config exec tar cfh bin/gdb.tar -C bin gdb exec tar ufh bin/gdb.tar -C bin/gdb_arm bin exec rm -rf bin/gdb # # Boot modules # set boot_modules { ahci cli_monitor core fb_drv ffat_fs fs_rom init initrd.gz kdb_uart_drv l4linux ld.lib.so libc.lib.so libc_log.lib.so libc_noux.lib.so libc_terminal.lib.so libm.lib.so lwip.lib.so ncurses.lib.so nic_bridge liquid_fb nitpicker noux part_blk platform_drv sd_card_drv tar_fs terminal terminal_log terminal_mux test-affinity test-blk-cli timer usb_drv vim.tar gdb.tar } set uri "http://genode.org/files/l4linux/initrd-arm-mdev.gz" if {![file exists bin/initrd.gz]} { puts "Download initramfs ..." exec >& /dev/null wget -c -O bin/initrd.gz $uri } exec >& /dev/null wget -O bin/initrd.gz.md5 $uri.md5 cd bin exec md5sum -c initrd.gz.md5 cd .. set fiasco_serial_esc_arg "" build_boot_image [join $boot_modules " "] run_genode_until forever