This repository has been archived by the owner. It is now read-only.

ruby-rubber-generate

ruby-rubber-generate packaging for Kali Linux

h1. Rubber Generate

h2. v0.0.11

Template language for generating Ruby bindings for C libraries by Geoff Youngs g@intersect-uk.co.uk

h3. Introduction

A simple ruby-style bindings generator for Ruby. It allows bindings to be laid out in a Ruby style, documentation to be included inline and explicit type casts within C code. It's somewhere between SWIG and pyrex.

It also allows features extconf.rb creation, including checks for headers, pkg-config etc. The modules it creates currently depend on Ruby/GTK, but it is planned to remove this dependency unless they genuinely require Ruby/GTK.

Other features include custom named type-maps, pre/post code inclusion within functions and some rudimentary understanding of C code.

h3. Changes

  • 0.0.11 - 27th Apr 2011

    • Fix parsing of %min-version numbers
  • 0.0.10 - 27th Apr 2011

    • Add --install flag
  • 0.0.9 - 31st May 2010

    • Add support for --build-dir switch to specify output directory
  • 0.0.8 - 10th May 2010

    • Add support for %min-version ..
  • 0.0.7 - 7th May 2010

    • Add support for array constants (including autmatic type detection) - e.g array = [ "Text", NULL, 3 ]
    • Add syntax_error function to parser which reports slightly more helpful syntax error messages for a .cr file
    • Add tracking of code location so that C compiler throws errors which refer to the original line in the .cr file
    • Add support for GSList{type} or GList{type} conversion to arrays as return values for functions
  • 0.0.6 - 6th May 2010

    • Flags class allows wrapping a bit field with slightly more information. Plus automatic conversion to/from ruby and support for integer values.

h3. Dependencies

  • Ruby 1.8 / Ruby 1.9 / Ruby 2.0

h3. Example

Sample file:

  • example/vte.cr

Usage:

  $ rubber-generate --generate --build --install vte.cr

Which should generate [arch]/vte.c <- Source code for extension [arch]/vte.rd <- RD documentation from vte.cr [arch]/extconf.rb <- Config script [arch]/vte.o <- Object file [arch]/vte.so <- Compiled extension

h3. Installation

  $ sudo gem install rubber-generate

h3. Credits

Author: Geoff Youngs

Contributors:

  • Vincent Isambart
Repository

ruby-rubber-generate

Owner
Statistic
  • 0
  • 0
  • 0
  • 0
  • over 5 years ago
  • April 17, 2019
License

Links
Synced at

Sun, 22 Dec 2024 01:25:07 GMT

Languages