Discuss Scratch
- Chiroyce
-
1000+ posts
Can we run Linux on scratch
somewhat, im no linux nerd so i cannot verify if this is in fact “Linux” but such a thing does exist
https://github.com/Its-Jakey/Linux-On-Scratch
Download the project from here - https://raw.githubusercontent.com/Its-Jakey/Linux-On-Scratch/main/rv32ima.sb3

https://github.com/Its-Jakey/Linux-On-Scratch
Download the project from here - https://raw.githubusercontent.com/Its-Jakey/Linux-On-Scratch/main/rv32ima.sb3

- ajskateboarder
-
1000+ posts
Can we run Linux on scratch
BruhThe title of this topic is Rust and C can compile to WASM (which runs in the browser)Can we run Linux on scratchnotCan we run Linux in a browser
If v86 can run in the browser, it can run in Scratch through a block extension.
- Mystery96
-
100+ posts
Can we run Linux on scratch
that would be kinda cheating though, as you wouldn't even have to use the normal scratch blocks, just plop your os of choice into v86 and off you go.BruhThe title of this topic is Rust and C can compile to WASM (which runs in the browser)Can we run Linux on scratchnotCan we run Linux in a browser
If v86 can run in the browser, it can run in Scratch through a block extension.
- rishi272011
-
100 posts
Can we run Linux on scratch
I think you can also run it on turbowarp online here: somewhat, im no linux nerd so i cannot verify if this is in fact “Linux” but such a thing does exist
https://github.com/Its-Jakey/Linux-On-Scratch
Download the project from here - https://raw.githubusercontent.com/Its-Jakey/Linux-On-Scratch/main/rv32ima.sb3
https://experiments.turbowarp.org/next/892602496/fullscreen?size=960x720
- Leon_to_ziomal
-
5 posts
Can we run Linux on scratch
(#5)That's JavaScript, not Scratch.I think you need to take a look at this With how limited Scratch is, probably not (and I mean a real Linux distro, not a fan-made operating system claiming to be a Linux distro even though Linux uses 0 Scratch code)
https://bellard.org/jslinux/vm.html?cpu=riscv64&url=fedora33-riscv-xwin.cfg&graphic=1&mem=256
Scratch IS JavaScript. (Well, not exactly…)
Scratch isn't a programming language, but a graphical interface for JavaScript.
You could inject JavaScript code on Turbowarp or PenguinMod, but not stock Scratch. You need to use prebuilt JavaScript blocks.
I would like to see a lot of things from here (https://scratch-mit-edu.ezproxyberklee.flo.org/projects/827943393/) on Scratch 4.0, but also a Custom JavaScript Block.
Maybe we will get that…
- BigNate469
-
1000+ posts
Can we run Linux on scratch
Incorrect- Scratch is a programming language interpreted in JavaScript, but it isn't a graphical interface for JS itself (otherwise we would probably have things like DOM API access and objects, among other things). Scratch isn't a programming language, but a graphical interface for JavaScript.
Anyways, Scratch is Turing-complete. Just make a C compiler that compiles to Scratch instead of bytecode- and then create a minimal Linux distribution.
- BigNate469
-
1000+ posts
Can we run Linux on scratch
Would it though? Technically you could also create a way to emulate a x86 or ARM CPU plugged into a monitor, and compile Linux and just import the code into Scratch, likely into a list.(#29)It's not that simple. That would probably be even more complicated than an emulator.
Anyways, Scratch is Turing-complete. Just make a C compiler that compiles to Scratch instead of bytecode- and then create a minimal Linux distribution.
- Jonathan50
-
1000+ posts
Can we run Linux on scratch
You could compile a straightforward portable C program that way (providing the needed standard library routines) – which is what bobbybee was doing with scratch-llvm as a Clang backend. The Linux kernel isn't that; it has machine-dependent parts (and parts written in assembly, not just C), since after all its job is to multiplex the CPU/RAM/hardware to processes, which access hardware in a limited/abstracted way thanks to system calls. Would it though?
Technically you could also create a way to emulate a x86 or ARM CPU plugged into a monitor, and compile Linux and just import the code into Scratch, likely into a list.Yes, and that's what @bilman66 did do, except with RISC-V. (Here's a link to the project on bilman66's GitHub account, in case you never saw it, though of course it's already been discussed on this thread)
Last edited by Jonathan50 (Feb. 8, 2025 21:01:03)
- scratchcode1_2_3
-
1000+ posts
Can we run Linux on scratch
people've emulated computers before here (but very simple nes-like ones)
it's possible in a pdf we can't lose hope
it's possible in a pdf we can't lose hope
- CST1229
-
1000+ posts
Can we run Linux on scratch
(#33)someone has emulated a whole linux computer before https://scratch-mit-edu.ezproxyberklee.flo.org/discuss/topic/710568/ (but the project was apparently unshared. not sure what's on about that)
people've emulated computers before here (but very simple nes-like ones)