Hello people. I have some questions

Bruce Sass bsass at freenet.edmonton.ab.ca
Wed Aug 29 14:39:51 EDT 2001


On Wed, 29 Aug 2001, Alex Martelli wrote:
<...>
> I see other posters have mentioned and are debating "OS modules".
> It's again just a question of runtime support -- no more, no
> less: if an OS had runtime support for VB, or for Python, you
> could use VB, or Python, to write modules for that OS, period.
> There's no "conceptual" block -- just that, in practice, I know
> of no such OS (for either language).

You do now...

Kernel Support for miscellaneous (your favourite) Binary Formats v1.1
=====================================================================

This Kernel feature allows you to invoke almost (for restrictions see
below) every program by simply typing its name in the shell. This
includes for example compiled Java(TM), Python or Emacs programs.

To achieve this you must tell binfmt_misc which interpreter has to be
invoked with which binary. Binfmt_misc recognises the binary-type by
matching some bytes at the beginning of the file with a magic byte
sequence (masking out specified bits) you have supplied. Binfmt_misc
can also recognise a filename extension aka '.com' or '.exe'.
<...snip...>
There are some restrictions:
 - the whole register string may not exceed 255 characters
 - the magic must reside in the first 128 bytes of the file, i.e.
   offset+size(magic) has to be less than 128
 - the interpreter string may not exceed 127 characters
<...snip...>
- enable support for Windows executables using wine:
  echo ':DOSWin:M::MZ::/usr/local/bin/wine:' > register
<...snip...>
There is a web page about binfmt_misc at
http://www.tat.physik.uni-tuebingen.de/~rguenth/linux/binfmt_misc.html
<...snip...>


- Bruce





More information about the Python-list mailing list