Author |
Topic: Linux? (Read 2149 times) |
|
rtr2
Guest
|
 |
Re: Linux?
« Reply #7 on: Jun 11th, 2015, 11:33pm » |
|
on Jun 11th, 2015, 10:15pm, dfeugey wrote:| Kernel module is a 'no go' for such a project, because it's too dangerous. No one will accept to integrate it inside the standard kernel. |
|
Nobody is suggesting such a crazy approach, any more than BBC BASIC for Windows needs to be integrated with the Windows kernel!
The assembler wrapper idea is perfectly workable: the interface with the existing interpreter would necessarily use the custom ABI that BB4W uses, and the interface to Linux would use the int 0x80 syscall API. The wrapper would simply do the necessary data munging.
I am not proposing anything complicated or dangerous. By keeping the source code identical to BB4W the risk of introducing bugs is substantially eliminated, and by supplying relocatable object modules I can make the interpreter available without jeopardising my IPR.
I will just have to hope that one day somebody with a positive attitude to this proposal will come along.
Richard.
|
|
Logged
|
|
|
|
dfeugey
Guest
|
 |
Re: Linux?
« Reply #8 on: Jun 12th, 2015, 08:26am » |
|
on Jun 11th, 2015, 11:33pm, g4bau wrote:| The assembler wrapper idea is perfectly workable: the interface with the existing interpreter would necessarily use the custom ABI that BB4W uses, and the interface to Linux would use the int 0x80 syscall API. The wrapper would simply do the necessary data munging. |
|
I did not make kernel things for years under Linux, but I don't think it's possible. IMHO, you can't call external ASM code from a wrapper, if this code is not compiled inside a DLL or other ELF content (or run as root). All other type of loads are limited to data only.
The kernel and tools as SELinux will not let you execute data as code. The only way to achieve this goal would be to compile the wrapper as a kernel module (I do not say that BBC Basic should be a kernel module. Just the wrapper).
Of course, I can be wrong on this subject, but I'm pretty sure I'm not. I can't remember of any example of non elf binary blob that will run without a specific kernel module.
|
| « Last Edit: Jun 12th, 2015, 08:29am by dfeugey » |
Logged
|
|
|
|
|