Skip to content

Cortlet/Sample-Operating-System

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

15 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Sample Operating System

Operating System for learning about the fundamentals, This includes all the necessary files.

Prerequisites

If you dont have these, you can go to the Extra Steps secton.

  1. Visual Studio 2022 with Desktop development with C++ workload installed.
  2. QEMU (x64 or x86 is fine depending on your arcitecture)
  3. Optional: Git, winget

1. Downloading the Repo

First, find a green button called 'Code'. You will find a dropdown. Click the button 'Download ZIP', or open Git (if installed) and type this command:

git clone https://github.com/Krishna-Developer5000/Sample-Operating-System.git

Depending on your internet connection, cloning or downloading may take sometime. After its installed, you are ready for Step 2.

2. Opening the Repository

Now, we can open the Repository. In Visual Studio 2022:

  1. Open Visual Studio 2022 via Windows Key + S, then search 'Visual Studio 2022'

  2. Click 'Create Project'

  3. Click 'CMake Project' (this requires the C++ Workload to be installed. If not, go to Extra Steps section. Also, you can delete CMakeLists.txt if already one is generated.)

  4. Name your project (e.g: Sample OS Project) image

  5. Click 'File', then in dropdown, select 'Open' -> Project/Solution image

  6. Select the Repository (if ZIP, usually C:\Users<Your-Name>\Downloads, if Cloned, it should be wherever you typed the command from (example: If you opened Git Bash, without cd "path", then it will be in same spot.))

  7. Find 'run.bat'

  8. Add it to your PATH: a. Windows + S, then search 'env'

    b. Click 'Environment Variables...'

    c. Double Click 'Path

    d. Click 'New'

    e. Type the Absolute PATH to your run.bat file (if VS 2022, C:\Users<your-name>\source\repos.)

    f. Click 'OK', then 'OK' again, then 'OK'.

    g. Restart your terminal and run this (preferrably Command Prompt or Developer Command Prompt for VS 2022):

    run.bat

    h. You should see 'K' in QEMU (if not installed, go to Extra Steps section)

Extra Steps

If you did not install Visual Studio 2022, you can follow this steps:

  1. In your search engine, type 'Visual Studio 2022 Download' on the search bar. (or go to this direct download: https://visualstudio.microsoft.com/thank-you-downloading-visual-studio/?sku=Community&channel=Release&version=VS2022&source=VSLandingPage&cid=2030&passive=false)
  2. Find something that says 'Visual Studio & VS Code Downloads for WIndows, Mac, Linux'
  3. In the section 'Visual Studio 2022', click 'Free download'
  4. You might see 'VisualStudioSetup.exe', Click the arrow button which has a square combined
  5. Wait for the Visual Studio installer to do its thing.
  6. Now, click 'Desktop developement with C++' workload.
  7. It will give a UAC (User Account Control) prompt since its touching 'Program Files', just click 'Yes'.
  8. It will take some time to install depending on your internet connection.
  9. Restart VS
  10. Go to Step 2.

If you did not install QEMU, follow these steps:

  1. Go to this site: https://qemu.eu/w64/2021/
  2. Click 'qemu-w64-setup-20210203.exe'
  3. Open the installer.
  4. Finish the installation wizard.
  5. Go to Step 2 to run the OS.

WARNING: Do not edit kernel.c or boot.asm as it could corrupt your system. If you want to edit, understand the code.

This is optional. But if you want to have Git Installed, follow these steps:

  1. In your search engine, type 'Git Download' (or go to this direct link: https://git-scm.com/downloads)
  2. Click 'Windows' above 'Downloads' image
  3. Download the standalone installer (do not select x64 if you are in ARM64, do not select ARM64 if you are on x64.)
  4. After download, open the Git installer (ususally named as 'Git-2.51.0-64-bit.exe')
  5. Finish the Setup Wizard

If you want to use winget (only if you have it installed):

  1. Open Powershell

  2. Type this command:

    winget install --id Git.Git -e --source winget

  3. Wait for it to finish installing.

  4. See if you have all of these installed: a. Git Bash b. Git GUI c. Git CMD If you dont have all of these, installation might be corrupted. Consider reinstalling or use the Standalone Installer.

  5. In Command prompt, type this:

    git --version

  6. You should see something like: git version <version><os><version> a. Simple example: git version 2.123.windows.456

  7. If it shows, you are ready to clone the repo via the Downloading the Repo step.

About

Operating System for learning about the fundamentals, This includes all the necessary files.

Resources

License

Security policy

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published