How to modify the source of Buildroot packages for package development?

前端 未结 2 1836
既然无缘
既然无缘 2020-12-04 03:35

I\'ve been using buildroot in order to build a toolchain using uclibc. Now, buildroot downloads all the packages, extract

相关标签:
2条回答
  • 2020-12-04 03:49

    Minimal git submodule + *_OVERRIDE_SRCDIR example

    Docs explain it, but here is a faster to parse version.

    Directory structure:

    • buildroot/: git submodule with buildroot 2017.02

    • linux/: git submodule with Linux kernel pointing to your fork at https://github.com/you/linux

    • buildroot_override: contains:

      LINUX_OVERRIDE_SRCDIR = ../linux
      

    Build and run:

    cd buildroot
    make qemu_x86_64_defconfig
    echo 'BR2_PACKAGE_OVERRIDE_FILE=../buildroot_override' >> .config
    make
    qemu-system-x86_64 -M pc -kernel output/images/bzImage -drive file=output/images/rootfs.ext2,if=virtio,format=raw -append root=/dev/vda -net nic,model=virtio -net user
    

    Here is an example project using it.

    0 讨论(0)
  • 2020-12-04 03:55

    Please read the Buildroot manual about the <pkg>_OVERRIDE_SRCDIR functionality. It does exactly what you are looking for.

    0 讨论(0)
提交回复
热议问题