Click here to Skip to main content
15,885,757 members
Please Sign up or sign in to vote.
1.00/5 (3 votes)
I want to rewrite the Linux kernel written in C and Assembly and Ruby and Python programming languages ​​and integrate it completely with Python. I need some help because I only know Python. I'm looking for a C, Assembly, Ruby, Shell programming language converter (if any), Make file (if any)

What I have tried:

None
...........................................
Posted
Updated 13-Feb-22 3:33am

This is impossible. When machine first powers up, there are no Python interpretes on a BIOS level. There fore this cannot be written in Python. Maybe only after boot code was executed. But why would anyone want to write an OS in a slow interpreted language.
 
Share this answer
 
v2
Quote:
I want to rewrite the Linux kernel

Bad idea. If there is not millions of Linux written in everyone's favorite language, it is because it is huge and hard, and not every programming language is usable to build an OS.
An OS talks to bare metal, it rely only on services it create itself.
Python is interpreted, and interpreter rely on existing OS.
Quote:
I'm looking for a C, Assembly, Ruby, Shell programming language converter (if any)

Beyond the most simple programs, consider converters as bad, because different languages have different ways to do the same thing, and OS source code is extremely technical.

Most OS are written in Assembly and C because those languages can talk to bare metal without any service, and they are fast.
 
Share this answer
 
Forget it.
Python needs an OS to work: it's an interpreted scripting language which needs the interpreter (which provides the framework for your app to run) to be executing before your app does. And that needs the OS beneath it to provide hardware services before it can run.

Writing an OS in Python would be a "chicken and egg" situation in that the Python interpreter would need your app (the Linux OS) running before it could start, and your app (the Linux OS) would need the Python interpreter running before it could run! :laugh:
 
Share this answer
 
You probably need to start by looking at the existing source code at GitHub - torvalds/linux: Linux kernel source tree[^].
 
Share this answer
 
Comments
آرین عباسی 67 12-Feb-22 8:07am    
Hello mr.richard maccutchan
I've seen the Linux project before at Github
Please message us in WhatsApp:
[REMOVED]
Dave Kreskowiak 12-Feb-22 16:33pm    
Nobody is going to message you in WhatsApp. The discussion either happens in this forum or it doesn't happen at all.

Oh, and rewriting the Linux Kernel in Ruby or Python is not going to happen. Attempting to do so shows how little you know of both languages and how they execute.
Richard MacCutchan 13-Feb-22 3:05am    
I guess my solution should have read, "Dream on.". :)
Dave Kreskowiak 13-Feb-22 10:41am    
:laugh:

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900