It's going to depend largely on exactly what hardware you are using: "basic OSes" exist, but they are understandably targeted at a specific hardware setup, and will not work for different hardware.
OSes have to interact directly with the hardware, so they need to know all about it. And the C compiler needs to be specifically for that OS, or it can't run on it!
What I'd suggest is that you get yourself a Raspberry Pi and have a look at FreeDOS:
Running DOS on the Raspberry Pi | Opensource.com[
^] - it runs in an emulator which "Pretends" to be a basic PC, but that gives you pretty much the bottom end of OSes together with the support you might need.