ไม่สามารถเล่นวิดีโอนี้
ขออภัยในความไม่สะดวก

Making Minimal Linux Distro with Buildroot

แชร์
ฝัง
  • เผยแพร่เมื่อ 4 ก.ย. 2024
  • In this video I will demonstrate how you can use Buildroot to create a simple x64 Linux distro
    Dependencies (Ubuntu packages):
    apt install g++ make libncurses-dev unzip bc bzip2 libelf-dev libssl-dev extlinux

ความคิดเห็น • 115

  • @batlink3764
    @batlink3764 4 หลายเดือนก่อน +55

    Dang, my man makes building an entire operating system look easy between this and his last custom Linux episode.

  • @854Daryl
    @854Daryl 4 หลายเดือนก่อน +84

    I had no idea this even existed. I started LinuxFromScratch and just lost interest. But this is 10 minutes start to finish.

    • @Maxjoker98
      @Maxjoker98 4 หลายเดือนก่อน +13

      Haha, true. Although you learn a lot more by doing LinuxFromScratch, for example how all the compilers, build systems, etc. work.

    • @Nunya58294
      @Nunya58294 4 หลายเดือนก่อน +4

      Yeah man LFS is if you really want to get into how GNU and Linux works

    • @Maxjoker98
      @Maxjoker98 4 หลายเดือนก่อน

      ​@@Nunya58294 It's true, but as said before, it's a lot since explains every step and you build a very conventional distro/installation(glibc, dynamic linked, etc.). This is both a strength and a weakness. If you just want to **create** a minimal bootable Linux image with some tools, probably choose buildroot. If you want to learn how to do it, I'd recommend statically compiling busybox and creating an initrd first. Way less effort for a basic DIY bootable system(just compile this one application and create a file system). But if you want a deep understanding(no shortcuts) of how everything comes together in a Linux distro, LFS is the way to go.
      I've personally never sat through the entire LFS from start to finish, but I've used it as a reference a lot, for example for setting up toolchains, filesystem hierarchy, etc., and I've created lots of single-purpose Linux distros/initds, from bootable games to rescue tools and testing android kernels.

    • @trickeddev
      @trickeddev 3 หลายเดือนก่อน

      i think this is compiling the entire linux kernel too so 10 minutes + like 2 hours lol

  • @aviinl1
    @aviinl1 4 หลายเดือนก่อน +63

    It has been 0 days since I recompiled the Linux kernel.

    • @AggamRahamim-fs2zm
      @AggamRahamim-fs2zm 3 หลายเดือนก่อน +4

      gentoo user spotted

    • @_lun4r_
      @_lun4r_ 2 หลายเดือนก่อน

      @@AggamRahamim-fs2zm gentoo/LFS/custom distro user* as all of those need to compile kernel

    • @mehdiyahiacherif2326
      @mehdiyahiacherif2326 16 วันที่ผ่านมา

      Can you please help me create an LFS aarch version ?

    • @_lun4r_
      @_lun4r_ 16 วันที่ผ่านมา

      @@mehdiyahiacherif2326 can you not use JHALFS on an arm64 host system with dependencies met and several days worth of compile time

  • @Maxjoker98
    @Maxjoker98 4 หลายเดือนก่อน +21

    Buildroot is pretty fun, a while ago I used a buildroot-based system as my "game engine"(Linux kernel, Lua "userland" using framebuffer graphics, uinput).
    You should have included some mention of the various ways you can include files in the final rootfs, for example overlay directories or custom buildroot packages. Also you don't have to manually create a bootable disk image, buildroot has support for creating grub(2)/extlinux/isolinux(including needed configs), or you could directly boot a kernel+initramfs in QEMU(no bootloader).

    • @_lun4r_
      @_lun4r_ 2 หลายเดือนก่อน +1

      I tried to do that but syslinux failed to compile cuz the source code was missing an include

    • @Maxjoker98
      @Maxjoker98 2 หลายเดือนก่อน +1

      ​@@_lun4r_ I've had some issues with syslinux in buildroot as well. I just switched to GRUB, but as far as I can recall, it was just missing a configuration step. Syslinux is a way simpler bootloader that grub, I don't even think it can read files from disk, only static offset lists(that you need to generate somehow).

  • @connorspruit6002
    @connorspruit6002 4 หลายเดือนก่อน +22

    finally, a way to utilize my computer truely bloatless.

    • @thestickmahn2446
      @thestickmahn2446 3 หลายเดือนก่อน +7

      vi is bloat, manually edit the files by using a magnet next to your hdd.

    • @connorspruit6002
      @connorspruit6002 3 หลายเดือนก่อน

      @@thestickmahn2446 you have just invented more than you realize. using this method we dont need an os at all anymore. heck. we dont need a computer anymore all we need is a hard drive, a magnet, a sata breakout board, a power supply and a piece of mettle, just connect the power and then bride the pins of the sata to write. and maybe use some led's to read.
      or just use paper

    • @DeVibe.
      @DeVibe. 3 หลายเดือนก่อน

      ​@@thestickmahn2446or zap his SSD

  • @welly7973
    @welly7973 4 หลายเดือนก่อน +11

    It's incredible what can be done nowadays with Linux and the way Linux is designed, keeping its simplicity makes it all much more comfortable when you really understand the concepts

  • @Sevenisko
    @Sevenisko 4 หลายเดือนก่อน +1

    This is actually pretty interesting.
    It all began with Linux from Scratch, now we're just 10 minutes to make a simple distro.

  • @SotchNam
    @SotchNam 29 วันที่ผ่านมา

    Thanks for the dependencies install command, the documentation providing them individually is pretty inconvenient.

  • @matan-h
    @matan-h 4 หลายเดือนก่อน +11

    would you do a video about custom compiling Debian?

    • @nirlichtman
      @nirlichtman  4 หลายเดือนก่อน +13

      Planned :)

    • @nou712
      @nou712 4 หลายเดือนก่อน

      @@nirlichtman Can't wait :)

  • @TurntableTV
    @TurntableTV 4 หลายเดือนก่อน +3

    So glad I found this channel. Somehow, youtube algo got it right this time and recommended me something really good.

  • @Paolog_
    @Paolog_ 4 หลายเดือนก่อน +2

    You are a perfect programmer!!
    I didn't see anybody do video like this, making a lot of video on C, or debugging Windows Kernel.
    Please continue your videos!!!

  • @c2vi_dev
    @c2vi_dev 4 หลายเดือนก่อน +1

    Amazing video as always!!
    I didn't know before, that you can boot linux without an initrd...... but it makes sense, that you can, if all drivers to mount the rootfs are in the kernel. Learned something new today😃

  • @newsgo1876
    @newsgo1876 หลายเดือนก่อน

    Concise and right on target! Thank you!

  • @danielwoodard4931
    @danielwoodard4931 4 หลายเดือนก่อน +2

    this is one of the first tutorials I've ever seen that gets straight to the point and shows you every single detail you need and nothing that you don't. I wish this guy did tutorials on everything , it would save so much time.

  • @twobob
    @twobob 4 หลายเดือนก่อน +2

    Love me some buildroot. did the arm kindle stuff a decade? back. Top work

  • @kieferhendricks6680
    @kieferhendricks6680 4 หลายเดือนก่อน

    Another fun, easy to follow tutorial on building a minimal distro and yet another project I will be completing in the near future. Thanks and keep up the great work, Nir!

  • @kousheralam8657
    @kousheralam8657 4 หลายเดือนก่อน +1

    Love your video, i work as a web dev, but i watch your video for fun.

  • @anon_y_mousse
    @anon_y_mousse 4 หลายเดือนก่อน

    That was even faster and easier than Rob Landley's video on a minimal Linux, nice!

  • @NTSuperbyte
    @NTSuperbyte 4 หลายเดือนก่อน +3

    Hi future me, you are proud that you subscribed before 50k subscribers to the best tutorial channel.

  • @pranavbadrinathan6693
    @pranavbadrinathan6693 4 หลายเดือนก่อน

    Oh damnnn I was recently looking to perhaps make my own very lightweight distro for an ARM based SBC. This looks really really simple too! Thank you very much :)

  • @tek_broz
    @tek_broz 2 หลายเดือนก่อน

    You my friend are a magician!

  • @mohitkumar-jv2bx
    @mohitkumar-jv2bx 4 หลายเดือนก่อน +1

    I have said it earlier. i will say it again. THIS CHANNEL IS A GOLDMINE.

  • @claudemods
    @claudemods หลายเดือนก่อน

    Thank you mate much respect i make my own respins and now i want to try new things you helped alot with what i want todo now

  • @baranjan6969
    @baranjan6969 4 หลายเดือนก่อน +1

    Why is buildroot suddenly a minor trend 90% of my recommendations are about buildroot

  • @medidstuff
    @medidstuff 4 หลายเดือนก่อน +1

    holy holy i want to absolutly do dispicable things i finally got my own distro thank you thank you thank you

  • @divyeshpatel9103
    @divyeshpatel9103 2 หลายเดือนก่อน

    It would also be interesting to see minimal distro using yocto build system. Thank you.

  • @nichtgestalt
    @nichtgestalt 4 หลายเดือนก่อน +3

    This is super cool! But how are you going to manage packages? I would love to see this series continued, thank you very much!

    • @nirlichtman
      @nirlichtman  4 หลายเดือนก่อน +1

      You can add packages during the build by customizing the buildroot settings, I think you can also add a simple package manager with the buildroot settings but I haven't tried that yet.

  • @learnwithcode4211
    @learnwithcode4211 3 หลายเดือนก่อน +1

    One of the best video on internet

  • @protonspeed
    @protonspeed หลายเดือนก่อน +1

    Hey, hope you are doing well. I was trying to build a buildroot to simply stream a USB camera on HDMI. I have one error that I'm stuck to. /dev/video0 no such file or directory. Either I use vlc to capture, gstreamer , ffmpeg everywhere. I'm making this on my windows using wsl. Can you help me with this? Please 😊

  • @Jonathan-ru9zl
    @Jonathan-ru9zl 3 หลายเดือนก่อน +1

    Amazing!

  • @xyzabc123-o1l
    @xyzabc123-o1l 4 หลายเดือนก่อน +2

    Could you run top on the guest machine you made? What was the RAM usage?

  • @Matt-ht8mc
    @Matt-ht8mc 3 หลายเดือนก่อน

    cool. no flashy splashes or stalling. subscribing

  • @illusbyk
    @illusbyk หลายเดือนก่อน

    i tried this but selected few more applications and utils along with xorg and wayland and few other sutffs, now im getting one single error that says `execstack.c:138:17: error: passing argument 1 of ‘asprintf’ from incompatible pointer type [-Wincompatible-pointer-types]
    ` i honestly have no clue whats causing this

  • @Ozla102
    @Ozla102 4 หลายเดือนก่อน

    Underrated Channel for sure 👍

  • @soheibmemes2594
    @soheibmemes2594 2 หลายเดือนก่อน

    very cool video but can u mention how to get GUI like some kind of minimal version of Xorg (microwindows didnt work at all)

  • @david_2912
    @david_2912 3 หลายเดือนก่อน

    You should make a guide on how to make a Wayland compositor with c.

  • @ronalerquinigoagurto555
    @ronalerquinigoagurto555 4 หลายเดือนก่อน

    Always wondered how distro mantainers like debian or canonical manage all their package and build stable versiones. What kind of integration testing they do

  • @lettd0wn
    @lettd0wn 4 หลายเดือนก่อน

    On the dead homies this is some cool shit. Subscribed

  • @mythacker4365
    @mythacker4365 4 หลายเดือนก่อน +3

    What is the difference between buildbox and buildroot?

    • @nirlichtman
      @nirlichtman  4 หลายเดือนก่อน +5

      You mean BusyBox? The difference is that Buildroot is a system to help build full Linux systems and BusyBox is a minimal all in one program that contains a bunch of standard Unix tools in one executable

    • @mythacker4365
      @mythacker4365 4 หลายเดือนก่อน +2

      @@nirlichtman oh yeah my bad! Thanks for the explanation ❤️

  • @newsgo1876
    @newsgo1876 หลายเดือนก่อน

    Once we have the boot.img, I guess the next thing to do is to stuff various application binaries into it. Then we get a full-fledged distribution. Am I right?

  • @rohitnangare1655
    @rohitnangare1655 หลายเดือนก่อน

    Bro I was installing buildroot got stuck on error after watching only 2min I fixed it. It was dependency error. Thanks

  • @batboy49
    @batboy49 4 หลายเดือนก่อน

    What boggles my mind is how yocto took over when buildroot was out there. Super easy buildroot, yocto SUPER TOUGH to master.

  • @Tux-tech-tips
    @Tux-tech-tips 4 หลายเดือนก่อน +1

    can you show us how to install a package manager on such a distro like this

  • @nastykerb34
    @nastykerb34 3 หลายเดือนก่อน

    Fun fact . The build time is from 9:56pm to 11:06 pm, aka 70 minutes. Only do this if you have time to spare

  • @Cyber_Gas
    @Cyber_Gas 3 หลายเดือนก่อน

    Make series where you eventualy make a complete desktop usable distro

  • @DanelonNicolas
    @DanelonNicolas 4 หลายเดือนก่อน

    Love it. Definitely gonna try to substitute busybox with uutils/coreutils. any recommendations?

  • @maximood-tired
    @maximood-tired 4 หลายเดือนก่อน

    great video as always!

  • @TheMLXProj-Linux
    @TheMLXProj-Linux หลายเดือนก่อน

    Can we create or add a package manager? (I need to add an desktop environment)

  • @franciszek5831
    @franciszek5831 4 หลายเดือนก่อน +1

    Does this mean I can "make" my own Linux distribution for my old Pentium 2 ??

    • @nathanb011
      @nathanb011 4 หลายเดือนก่อน +2

      Naturally!

  • @waldmensch2010
    @waldmensch2010 4 หลายเดือนก่อน

    Nice, how to install security fixed and upgrades on this distro?

  • @i-onedarksnow9288
    @i-onedarksnow9288 4 หลายเดือนก่อน

    buildroot very good toolkit, but i have 1 question - how change default prefix in buildroot from / to /opt as it changed in entware?

  • @ProSureString
    @ProSureString 4 หลายเดือนก่อน +1

    after running `make make`, the /output/images dir is empty

    • @samuelhulme8347
      @samuelhulme8347 4 หลายเดือนก่อน

      You have to run `make`. `make make` won’t do anything and was not demonstrated in this video.

    • @ProSureString
      @ProSureString 4 หลายเดือนก่อน

      @@samuelhulme8347 yeah, sorry.
      I misunderstood.

  • @pavlebn
    @pavlebn 4 หลายเดือนก่อน

    Any plans on covering the basics of the yocto project in the future?

  • @tijuthomas6793
    @tijuthomas6793 4 หลายเดือนก่อน

    Awesome Video. I just want to know about, how i add UI stuffs into this ?

  • @wahabfiles6260
    @wahabfiles6260 4 หลายเดือนก่อน

    Awsome! Thanks!!!!

  • @YourLocalMedic
    @YourLocalMedic 4 หลายเดือนก่อน

    This is quite neat though never practical for a desktop. Which is unfortunate given how neat it sounds to fully build your own distro

  • @random4955
    @random4955 2 หลายเดือนก่อน

    Does any one know how to fix the error:
    sudo mount boot.img mounted/
    [sudo] password for user:
    mount: mounted/: mount failed: Operation not permitted.
    using Ubuntu WSL as well
    tried root still didn't work

  • @Tux-tech-tips
    @Tux-tech-tips 4 หลายเดือนก่อน

    Super cool video :)

  • @RocktCityTim
    @RocktCityTim 4 หลายเดือนก่อน

    Beats using loopback and lilo!

  • @RiccardoPalombo
    @RiccardoPalombo 4 หลายเดือนก่อน

    Thanks!

  • @Chris-rm1pn
    @Chris-rm1pn 4 หลายเดือนก่อน +1

    So what's next? Yocto?

  • @Monkeyindatrees
    @Monkeyindatrees 4 หลายเดือนก่อน

    What about just cooking up a gentoo and then just use qemu to squeeze it down and push it?

  • @bennguyen1313
    @bennguyen1313 4 หลายเดือนก่อน

    Any thoughts on T2 Linux 24.5?

  • @neolifium586
    @neolifium586 4 หลายเดือนก่อน

    how can we implement uefi boot using buildroot?

    • @neolifium586
      @neolifium586 4 หลายเดือนก่อน

      i am currently compiling buildroot after navigating cluelessly through the menuconfig and enabling support for iw(,d), nano, uefi using grub, ext4 filesystem, htop, git, and other stuff i forgot. I hope i can succeed.

  • @bramfran4326
    @bramfran4326 4 หลายเดือนก่อน

    What is the difference between bzImage and rootfs?

    • @nirlichtman
      @nirlichtman  4 หลายเดือนก่อน +1

      bzImage is the kernel binary compressed and rootfs is the tar archive of the files of the distro

  • @ProSureString
    @ProSureString 4 หลายเดือนก่อน +1

    Yey :D

    • @ProSureString
      @ProSureString 4 หลายเดือนก่อน +1

      Another great video for me to watch :D

  • @dtikvxcdgjbv7975
    @dtikvxcdgjbv7975 4 หลายเดือนก่อน

    Cool

  • @hbibamrani9890
    @hbibamrani9890 4 หลายเดือนก่อน +1

    Make a minimal mail server, please!

    • @nirlichtman
      @nirlichtman  4 หลายเดือนก่อน +3

      Planned :)

  • @dimaryk11
    @dimaryk11 4 หลายเดือนก่อน

    How big is the image?

  • @ChandrashekarCN
    @ChandrashekarCN 4 หลายเดือนก่อน

    💖💖💖💖

  • @farzi-ye2wb
    @farzi-ye2wb หลายเดือนก่อน

    bro qemu is not working

  • @WHAT-GRINDS-MY-GEARS
    @WHAT-GRINDS-MY-GEARS 4 หลายเดือนก่อน

    cool

  • @skilz8098
    @skilz8098 4 หลายเดือนก่อน

    You got your shell up and running, but can it run DOOM?

  • @trwwrt5687
    @trwwrt5687 4 หลายเดือนก่อน +1

    Sending email with c please 😢

  • @Yggdra666
    @Yggdra666 4 หลายเดือนก่อน

    Next up, how to implement networking into TempleOS.

  • @d_sanu
    @d_sanu 18 วันที่ผ่านมา

    Small distro makes biggest step 😂

  • @Game7Red
    @Game7Red 4 หลายเดือนก่อน

    how to install distro ?

    • @shellgecko
      @shellgecko 4 หลายเดือนก่อน

      make or grab an installer (calamares, anaconda, etc) to make it copy all the files and configs to a storage device
      or make a chroot env like arch or gentoo and do it manually

  • @canadiannomad2330
    @canadiannomad2330 4 หลายเดือนก่อน

    Fix you path? No you fix escape.

  • @mzakyr342
    @mzakyr342 4 หลายเดือนก่อน

    make a package manager and repository now

  • @tedchirvasiu
    @tedchirvasiu 4 หลายเดือนก่อน

    I run my own distro > I run arch btw

  • @bluescorpian
    @bluescorpian 4 หลายเดือนก่อน

    why are you using windows & edge? kinda cringe

    • @jackkendall6420
      @jackkendall6420 4 หลายเดือนก่อน

      Presumably because WSL means that it's easier to do Linux things on a Windows install than it is to do Windows things on a Linux install. And he's clearly interested in both OSs

  • @defautluser0
    @defautluser0 4 หลายเดือนก่อน

    please dont use msedge

  • @gavyeah9866
    @gavyeah9866 หลายเดือนก่อน

    when i run 'make menuconfig' it gives this 'Makefile:157: support/misc/utils.mk: No such file or directory'

  • @mathcale
    @mathcale 4 หลายเดือนก่อน

    Amazing!