The source code for a work means the preferred form of the work for making modifications to it. For an executable work, complete source code means all the source code for all modules it contains, plus any associated interface definition files, plus the scripts used to control compilation and installation of the executable. However, as a special exception, the source code distributed need not include anything that is normally distributed (in either source or binary form) with the major components (compiler, kernel, and so on) of the operating system on which the executable runs, unless that component itself accompanies the executable.
build.sh
that extracts/runs bitbake
build.sh
one could use with Yocto:
#!/bin/bash mkdir build cd build tar --posix -jxpvf ../poky-edison-6.0.tar.bz2 cd poky-edison-6.0 source ./oe-init-build-env routerstationpro cp -p ../../../local.conf conf tar --posix -xpvf ../../../downloads-routerstationpro.tar bitbake core-image-minimal cp -p tmp/deploy/images/core-image-*.tar.bz2 ../../.. cp -p tmp/deploy/images/vmlinux-routerstationpro.bin ../../..
BUILD instructions for GPL/LGPL software This software distribution consists of seven GPL and LGPL components used in the device: * gcc: gcc 4.2.0, GPL v2 * glibc: glibc-2.5.90, LGPL v2.1 * binutils: binutils 2.15.94, GPL v2 / LGPL v2 or later * linux: The linux 2.6.18 kernel, GPL v2 * busybox: BusyBox 1.1.3, GPL v2 * libgphoto2: libgphoto2 2.3.1, LGPL v2.1 * libusb: libusb 0.1.12, LGPL v2 or later * uBoot: uboot, GPL V2 * wireless_tools: wireless_tools.28, GPL v2 * rungetty: rungetty-1.2, GPL v2 * rt73: rt73-cvs, GPL v2 System requirement (Strongly recommended) * OS: RHEL 5.0 or CentOS 5.0/4.0 The device has an ARM processor; the software is normally cross-compiled for that processor. All of those softwares have to be built with the MontaVista ARM toolchain gcc version 4.2.0 20070514 (GPL2) (SELP 4.2.0-3.0.5.custom 2007-11-13(18:29)) * Toolchain Installation (not necessary if you already done 'TOOLCHAIN_BUILD') Copy the toolchain file into '/opt/' and unpack the zipped tool chain file Execute "export PATH=$PATH:/opt/unziped_toolchain_name/bin" Or add "export PATH=$PATH:/opt/unziped_toolchain_name/bin" line into the file '.bashrc' in the '/root/' directory. * Building linux * Unpack the linux tarball and cd into it. * Copy amber.rel.config to .config . (cp amber.rel.config .config) * "make oldconfig" and "make Image" 1. Kernel Module Script # su # cd /work/linux/selp_kernel-2.6.18.p0.mb_arm_v5t_le/ # make modules # cd /T-AMBAUSC/image # unsquashfs -d rootfs rootfs.img # cd /work/linux/selp_kernel-2.6.18.p0.mb_arm_v5t_le/ # cp drivers/net/8139too.ko /T-AMBAUSC/image/rootfs/lib/modules/ # cp drivers/net/cs89x0.ko /T-AMBAUSC/image/rootfs/lib/modules/ # cp drivers/usb/host/ehci-hcd.ko /T-AMBAUSC/image/rootfs/lib/modules/ # cp drivers/usb/host/ohci-hcd.ko /T-AMBAUSC/image/rootfs/lib/modules/ # cp drivers/usb/storage/usb-storage.ko /T-AMBAUSC/image/rootfs/lib/modules/ # cp drivers/usb/core/usbcore.ko /T-AMBAUSC/image/rootfs/lib/modules/ # cd /T-AMBAUSC/image # mksquashfs ./rootfs rootfs.img # rm -rf ./rootfs
2. rt73 Kernel Module Script * Unpack the rt73 tarball and cd into it. # cd /work/rt73-cvs-2009041204/Module # make # su # cd /T-AMBAUSC/image # unsquashfs -d rootfs rootfs.img # cd /work/linux/selp_kernel-2.6.18.p0.mb_arm_v5t_le/ # cp /work/rt73-cvs-2009041204/Module/rt73.ko /T-AMBAUSC/image/rootfs/lib/modules/ # cd /T-AMBAUSC/image/rootfs/lib/modules # arm_v5t_le-strip -g -S -d --strip-debug ./rt73.ko # cd /T-AMBAUSC/image # mksquashfs ./rootfs rootfs.img # rm -rf ./rootfs * Building busybox * Unpack the busybox tarball and cd into it. * "make CROSS_COMPILE=arm-v5t-le-". * Building binutils: * Unpack the binutils tarball and cd into it. * "./configure --host=i686-pc-linux-gnu --build=i686-pc-linux-gnu --target=armv5tl-montavista-linux-gnueabi --program-prefix=arm_v5t_le- \ --enable-install-libbfd --disable-werror --disable-nls --enable-poison-system-directories". where "x86_64-unknown-linux-gnu" is replaced with your host type, * Run "make". * Building target gcc (gcc_s, libstdc++): * Unpack the gcc tarball and cd into it. * set and modify CROSS_COMPILE_DIR var with installed toolchain path in build script - change directory into "/work/gcc/selp_cross-gcc-4.2.0-4.0.9" (ex: CROSS_COMPILE_DIR=/opt/mvl.500.pro.arm.v5t.le/pro/devkit/arm/v5t_le in the file 'build-gcc-arm_v5t_le.sh') * Run "sh build-gcc-arm_v5t_le.sh absolute-dir-to-install"(ex:"sh build-gcc-arm_v5t_le.sh /home/yourid/gccbuild.1025") * Building glibc: * Unpack the glibc tarball and cd into it. * Run "sh build-glibc-arm_v5t_le.sh absolute-dir-to-install"(ex:"sh build-glibc-arm_v5t_le.sh /home/yourid/glibcbuild.1025") * Building uboot.bin: * Unpack the u-boot tarball and cd into it. * Run "sh darth.sh" * Building wireless tools * Unpack the wireless tools tarball and cd into it.(tar -zxvf wireless_tools.28.tar.gz) * cd wireless_tools.28 * Run "make". * Building rungetty * Unpack the rungetty tarball and cd into it.(tar -zxvf rungetty-1.2.orig.tar) * cd rungetty-1.2.orig * Run "make".
build.sh
in root directory that builds, produces imagemake clean
before shipping (smaller source); re-test