2005-03-22 05:10:09 -08:00
|
|
|
Embryo @VERSION@
|
2004-03-25 01:52:12 -08:00
|
|
|
|
2004-04-17 17:57:06 -07:00
|
|
|
WARNING: gcc compatibility!!!
|
|
|
|
There seems to be some bug (or disagreement) between embryo and gcc 3.2.x
|
2004-05-14 22:04:07 -07:00
|
|
|
where IEEE floating point format encoding does not "agree" with embryo's own
|
2004-04-17 17:57:06 -07:00
|
|
|
hand-made tests. embryo_cc may not work if you compile using gcc 3.2.x. gcc
|
|
|
|
3.3.x is known to work fine. we are not 100% sure whose fault this is yet, so
|
|
|
|
we won't be jumping up and down, but be warned - gcc 3.2.x does not agree
|
|
|
|
with embryo.
|
|
|
|
|
2004-09-25 07:37:39 -07:00
|
|
|
To view the API docs, run ./gendoc and view doc/html/index.html.
|
2004-04-17 17:57:06 -07:00
|
|
|
|
2004-05-14 22:04:07 -07:00
|
|
|
OK a lot of people ask this. What is Embryo?
|
2004-03-25 01:52:12 -08:00
|
|
|
|
2004-03-25 06:55:26 -08:00
|
|
|
Embryo is primarily a shared library that gives you an API to load and control
|
2004-05-14 22:04:07 -07:00
|
|
|
interpreted programs compiled into an abstract machine bytecode that it
|
|
|
|
understands. This abstract (or virtual) machine is similar to a real machine
|
|
|
|
with a CPU, but it is emulated in software. The architecture is simple and is
|
2004-03-25 06:55:26 -08:00
|
|
|
the same as the abstract machine (AMX) in the
|
|
|
|
<a href=http://www.compuphase.com/small.htm>SMALL</a> language as it is based
|
|
|
|
on exactly the same code. Embryo has modified the code for the AMX extensively
|
2004-05-14 22:04:07 -07:00
|
|
|
and has made it smaller and more portable. It is VERY small. The total size
|
2004-03-25 06:55:26 -08:00
|
|
|
of the virtual machine code AND header files is less than 2500 lines of code.
|
2004-05-14 22:04:07 -07:00
|
|
|
It includes the floating point library support by default as well. This makes
|
|
|
|
it one of the smallest interpreters around, and thus makes is very
|
2004-03-25 06:55:26 -08:00
|
|
|
efficient to use in code.
|
2004-03-25 01:52:12 -08:00
|
|
|
|
2004-05-14 22:04:07 -07:00
|
|
|
Embryo also uses the SMALL compiler from the same code base. This code has
|
|
|
|
barely been touched and so suffers from lots of portability issues. It has
|
2004-03-25 06:55:26 -08:00
|
|
|
been partially fixed and now works on both big and little endian but the code
|
2004-05-14 22:04:07 -07:00
|
|
|
still need to be gone over and really cleaned up . It does work, but it's only
|
|
|
|
just working. It has been called embryo_cc and compiled a subset of SMALL
|
|
|
|
binary outputs. It does not support packed strings, variable alignment, or
|
|
|
|
debugging output. It does not support many features of the full SMALL
|
2004-03-25 06:55:26 -08:00
|
|
|
compiler because the Embryo AMX does not support these either. You will find
|
2004-05-14 22:04:07 -07:00
|
|
|
the Embryo codebase to work much better on Linux (and BSD and MacOS X) and
|
2004-03-25 06:55:26 -08:00
|
|
|
other UNIX operating systems as it has been developed and tested on them. IT
|
|
|
|
is known to work on:
|
|
|
|
gcc Linux (x86-32)
|
|
|
|
gcc Linux (PPC)
|
|
|
|
gcc MacOS X (PPC)
|
|
|
|
|
|
|
|
And will likely work on more combinations. IT currently has problems on 64bit
|
2004-05-14 22:04:07 -07:00
|
|
|
SPARC CPUs. Other 64bit systems are untested. It is the aim to fix the code
|
2004-03-25 06:55:26 -08:00
|
|
|
so it works on all commonly used architectures (32, 64bit, big and little
|
2004-05-14 22:04:07 -07:00
|
|
|
endian, alignment forgiving/unforgiving). So far 64bit support is the major
|
2004-03-25 06:55:26 -08:00
|
|
|
issue.
|
|
|
|
|
|
|
|
For more documentation please see the Language guide here:
|
|
|
|
|
|
|
|
<a href=http://www.compuphase.com/smalldoc.pdf>Small Language Booklet</a>
|
2004-03-25 01:52:12 -08:00
|
|
|
|
2004-03-25 06:55:26 -08:00
|
|
|
This documents the SMALL language and is 100% relevant for Embryo and the
|
|
|
|
syntax of files it can compile (.sma files).
|
|
|
|
|
|
|
|
Any help is appreciated in helping clean and port this code, so feel free to
|
|
|
|
send patches to the Enlightenment development lists.
|
|
|
|
|
2004-05-14 22:04:07 -07:00
|
|
|
The main aim of Embryo is to provide an easy to use library for running
|
2004-03-25 06:55:26 -08:00
|
|
|
compiled SMALL programs and giving them access to the calling program and
|
2004-05-14 22:04:07 -07:00
|
|
|
any API it exports to the SMALL script. SMALL programs/scripts are completely
|
|
|
|
sand-boxed. They cannot access any system or function calls other than the
|
|
|
|
ones provided by the calling application to the Embryo API. This means a
|
2004-03-25 06:55:26 -08:00
|
|
|
SMALL script cannot open or write to, delete or load files. It is fairly
|
|
|
|
harmless and this also keeps Embryo small.
|
|
|
|
|
|
|
|
This is a work in progress, so please be patient if things don't work for you
|
|
|
|
- and patches and help in fixing it is very much appreciated.
|
|
|
|
|
2005-03-22 05:10:09 -08:00
|
|
|
------------------------------------------------------------------------------
|
|
|
|
COMPILING AND INSTALLING:
|
|
|
|
|
|
|
|
./configure
|
|
|
|
make
|
|
|
|
(as root unless youa re installing in your users directories):
|
|
|
|
make install
|
|
|
|
|
|
|
|
------------------------------------------------------------------------------
|
|
|
|
BUILDING PACKAGES:
|
|
|
|
|
|
|
|
RPM: To build rpm packages:
|
|
|
|
|
|
|
|
sudo rpm -ta @PACKAGE@-@VERSION@.tar.gz
|
|
|
|
|
|
|
|
You will find rpm packages in your system /usr/src/redhat/* dirs (note you may
|
|
|
|
not need to use sudo or root if you have your own ~/.rpmrc. see rpm documents
|
|
|
|
for more details)
|
|
|
|
|
|
|
|
DEB: To build deb packages:
|
|
|
|
|
|
|
|
tar zvf @PACKAGE@-@VERSION@.tar.gz
|
|
|
|
cd @PACKAGE@-@VERSION@
|
|
|
|
dpkg-buildpackage -us -uc -rfakeroot
|
|
|
|
cd ..
|
|
|
|
rm -rf @PACKAGE@-@VERSION@
|
|
|
|
|
|
|
|
You will find all the debian source, binary etc. packages put in the directory
|
|
|
|
where you first untarred the source tarball.
|