Skip to content

Commit

Permalink
Update build-with-llvm.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
netflexs authored Nov 14, 2024
1 parent eaefba7 commit 392e046
Showing 1 changed file with 17 additions and 2 deletions.
19 changes: 17 additions & 2 deletions .github/workflows/build-with-llvm.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,13 +43,15 @@ jobs:
- name: Build Root Filesystem
run: |
mkdir -p rootfs/{bin,sbin,etc,proc,sys,usr/{bin,sbin}}
sudo apt-get install -y busybox-static
cp /bin/busybox rootfs/bin/
# Install Neofetch dependencies
sudo apt-get install -y neofetch
# Copy Neofetch to rootfs
cp /usr/bin/neofetch rootfs/usr/bin/
# Modify the init script to run neofetch on boot
cat << 'EOF' > rootfs/init
#!/bin/sh
Expand All @@ -76,17 +78,30 @@ jobs:
- name: Create Bootable ISO
run: |
mkdir -p iso/boot/grub
# Copy kernel and initramfs
cp arch/x86/boot/bzImage iso/boot/
cp initramfs.img iso/boot/
# Install GRUB files if they are not installed already
sudo apt-get install -y grub-pc-bin
# Copy GRUB stage2_eltorito and other necessary files
cp /usr/lib/grub/i386-pc/stage2_eltorito iso/boot/grub/
cp /usr/lib/grub/i386-pc/*_stage2.iso iso/boot/grub/
# Create GRUB configuration file
cat << EOF > iso/boot/grub/grub.cfg
set default=0
set timeout=5
menuentry "FOS OS" {
linux /boot/bzImage
initrd /boot/initramfs.img
}
EOF
# Create the ISO image
genisoimage -U -r -J -V "FOS_OS" -b boot/grub/stage2_eltorito -no-emul-boot -boot-load-size 4 -boot-info-table -o fos_os.iso iso
- name: Archive the ISO Artifact
Expand Down

0 comments on commit 392e046

Please sign in to comment.