if {![have_spec x86]} { puts "\nThis runscript is supported on the x86 architecture only\n" exit 0 } # # Uncomment the following line when working on the VIM source code. Otherwise, # the package may get recompiled, yet it does not get reinstalled into 'bin/'. # #exec rm -rf noux-pkg/bash bin/bash set build_components { core init drivers/timer noux/net lib/libc_noux drivers/framebuffer drivers/pci drivers/input drivers/nic server/terminal server/ram_fs test/libc_resolv test/libports/libcrypto test/libports/libssl test/libports/ncurses test/libports/readline test/libports/zlib } # # Build Noux packages only once # set noux_pkgs "bash coreutils openssh noux-etc" foreach pkg $noux_pkgs { lappend_if [expr ![file exists bin/$pkg]] build_components noux-pkg/$pkg } build $build_components # strip all binaries prior archiving set find_args "" foreach pkg $noux_pkgs { append find_args " bin/$pkg/" } exec sh -c "find $find_args -type f | (xargs [cross_dev_prefix]strip || true) 2>/dev/null" # add bash as sh exec cp bin/bash/bin/bash bin/bash/bin/sh foreach pkg $noux_pkgs { exec tar cfv bin/$pkg.tar -h -C bin/$pkg . } create_boot_directory append config { } append_if [have_spec sdl] config { } append_if [have_spec pci] config { } append_if [have_spec framebuffer] config { } append_if [have_spec ps2] config { } append config { } foreach pkg $noux_pkgs { append config " " } append config { } install_config $config # # Boot modules # # generic modules set boot_modules { core init timer ld.lib.so noux_net nic_drv terminal ram_fs libc.lib.so libm.lib.so libc_noux.lib.so libc_resolv.lib.so lwip.lib.so ncurses.lib.so libcrypto.lib.so libssl.lib.so readline.lib.so zlib.lib.so } foreach pkg $noux_pkgs { lappend boot_modules "$pkg.tar" } # platform-specific modules lappend_if [have_spec linux] boot_modules fb_sdl lappend_if [have_spec pci] boot_modules pci_drv lappend_if [have_spec framebuffer] boot_modules fb_drv lappend_if [have_spec ps2] boot_modules ps2_drv build_boot_image $boot_modules if {[have_spec x86_64]} { # bash.tar is really huge when built for x86_64 append qemu_args " -m 320 " } append_if [have_spec x86] qemu_args " -net nic,model=e1000" append_if [have_spec lan9118] qemu_args " -net nic,model=lan9118 " append qemu_args " -net user " run_genode_until forever #exec rm bin/bash.tar