Add custom software to rootfs
This commit is contained in:
parent
a589a0099a
commit
0853648920
|
@ -1,4 +1,5 @@
|
||||||
devicetree/devicetree.dtb
|
devicetree/devicetree.dtb
|
||||||
|
buildroot_overlay/opt/
|
||||||
downloads/
|
downloads/
|
||||||
buildroot-2023.02.8/
|
buildroot-2023.02.8/
|
||||||
u-boot/
|
u-boot/
|
||||||
|
|
|
@ -7,6 +7,7 @@ set -e
|
||||||
make -C "$BUILDROOT_DIR" clean
|
make -C "$BUILDROOT_DIR" clean
|
||||||
|
|
||||||
cp -a config/buildroot_puzzlefw_defconfig "$BUILDROOT_DIR/.config"
|
cp -a config/buildroot_puzzlefw_defconfig "$BUILDROOT_DIR/.config"
|
||||||
|
|
||||||
make -C "$BUILDROOT_DIR" olddefconfig
|
make -C "$BUILDROOT_DIR" olddefconfig
|
||||||
make -C "$BUILDROOT_DIR"
|
make -C "$BUILDROOT_DIR"
|
||||||
|
|
||||||
|
|
|
@ -11,7 +11,7 @@ make -C "$UBOOT_DIR" CROSS_COMPILE=arm-linux- distclean
|
||||||
# It contains the init code for the U-Boot SPL image.
|
# It contains the init code for the U-Boot SPL image.
|
||||||
if [ ! -f "$XSA_FILE" ]; then
|
if [ ! -f "$XSA_FILE" ]; then
|
||||||
echo "ERROR: $XSA_FILE not found" >&2
|
echo "ERROR: $XSA_FILE not found" >&2
|
||||||
echo "Build the FPGA image before building U-Boot."
|
echo " Build the FPGA image before building U-Boot." >&2
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
|
|
@ -5,17 +5,10 @@ set -e
|
||||||
. script_env
|
. script_env
|
||||||
setup_toolchain
|
setup_toolchain
|
||||||
|
|
||||||
#if [ ! -x "$TOOLCHAIN_DIR/arm-linux-gcc" ]; then
|
|
||||||
# echo "ERROR: Missing $TOOLCHAIN_DIR/arm-linux-gcc" >&2
|
|
||||||
# echo " Build buildroot to prepare the arm-linux toolchain" >&2
|
|
||||||
# exit 1
|
|
||||||
#fi
|
|
||||||
#
|
|
||||||
#export PATH="$TOOLCHAIN_DIR:$PATH"
|
|
||||||
|
|
||||||
make -C "$LINUX_DIR" ARCH=arm mrproper
|
make -C "$LINUX_DIR" ARCH=arm mrproper
|
||||||
|
|
||||||
cp -a config/linux_redpitaya_puzzlefw_defconfig "$LINUX_DIR/.config"
|
cp -a config/linux_redpitaya_puzzlefw_defconfig "$LINUX_DIR/.config"
|
||||||
|
|
||||||
make -C "$LINUX_DIR" ARCH=arm CROSS_COMPILE=arm-linux- olddefconfig
|
make -C "$LINUX_DIR" ARCH=arm CROSS_COMPILE=arm-linux- olddefconfig
|
||||||
make -C "$LINUX_DIR" ARCH=arm CROSS_COMPILE=arm-linux- zImage
|
make -C "$LINUX_DIR" ARCH=arm CROSS_COMPILE=arm-linux- zImage
|
||||||
make -C "$LINUX_DIR" ARCH=arm CROSS_COMPILE=arm-linux- modules
|
make -C "$LINUX_DIR" ARCH=arm CROSS_COMPILE=arm-linux- modules
|
||||||
|
|
|
@ -0,0 +1,19 @@
|
||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
set -e
|
||||||
|
|
||||||
|
. script_env
|
||||||
|
setup_toolchain
|
||||||
|
|
||||||
|
TARGET=buildroot_overlay
|
||||||
|
|
||||||
|
# Add kernel driver to rootfs image.
|
||||||
|
mkdir -p "$TARGET/opt/puzzlefw/driver"
|
||||||
|
cp -a src/linux_driver/puzzlefw.ko "$TARGET/opt/puzzlefw/driver"
|
||||||
|
|
||||||
|
# Add userspace software to rootfs image.
|
||||||
|
mkdir -p "$TARGET/opt/puzzlefw/bin"
|
||||||
|
cp -a src/userspace/puzzlecmd "$TARGET/opt/puzzlefw/bin"
|
||||||
|
|
||||||
|
make -C "$BUILDROOT_DIR"
|
||||||
|
|
Loading…
Reference in New Issue