Commit ad37ddd8 authored by Daniel Bovensiepen's avatar Daniel Bovensiepen

Improve documentation for Gem and add limitations

parent 96afe4ba
......@@ -25,7 +25,7 @@ The folder *mrblib* contains pure Ruby files to extend mruby. The folder *src*
contains C files to extend mruby. The folder *test* contains pure Ruby files
for testing purposes which will be used by mrbtest. The *Makefile* contains
rules to build all C files and integrates them into the normal mruby
build process. +README.md+ is a short description for the Gem.
build process. *README.md* is a short description of your Gem.
## C Extension
......@@ -36,12 +36,12 @@ files to libmruby.a
### Pre-Conditions
mrbgems will automatically call the +gem-all+ make target of your Gem. Make
sure that you build all files in this target and that you add you object
mrbgems will automatically call the *gem-all* make target of your Gem. Make
sure that you build all files in this target and that you add your object
files to libmruby.a
mrbgems expects that you have implemented a C method called
*mrb_YOURGEMNAME_gem_init(mrb_state* mrb)*. YOURGEMNAME will be replaced
*mrb_YOURGEMNAME_gem_init(mrb_state)*. YOURGEMNAME will be replaced
by the name of you Gem. The directory name of your Gem is considered also
as the name! If you call your Gem directory *c_extension_example*, your
initialisation method could look like this:
......@@ -104,3 +104,16 @@ process of your Ruby extension you can use the *Makefile* too.
|
+- README.md
```
## Current Limitations
The following limitations are currently existing:
* Gem _MUST NOT_ have a *src* folder in case it doesn't have a
C extension
* Gem _MUST NOT_ have a *mrblib* folder in case it doesn't have a
Ruby extension
* Only Ruby files in the root directory of *mrblib* will be integrated
If you have ideas how to fix these issues without implementing to much
complexity into the code please provide your code or idea.
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment