Announcing the first release of Fwrap

Fwrap v0.1.0

I am pleased to announce the first release of Fwrap v0.1.0, a utility for
wrapping Fortran code in C, Cython and Python. Fwrap focuses on supporting the
features of Fortran 90/95, but will work with most well-behaved Fortran 77
code, too.

Fwrap is BSD licensed.

Fwrap is beta-level software; all public APIs and commandline options are
subject to change.

Features in the v0.1.0 release:

  • Fortran source parsing and automatic wrapper generation;
  • Top-level (non-module) Fortran subroutines and functions;
  • Supports all intrinsic types (integer, real, complex, logical &
  • Default and non-default intrinsic types properly wrapped;
  • Scalar and array arguments supported;
  • Supports assumed-shape, assumed-size, and explicit-shape array arguments;
  • Intent ‘in’, ‘inout’, ‘out’ and no intent arguments supported;
  • Automatic docstring generation for extension module and functions;
  • Wrappers are portable w.r.t. both Fortran and C compilers.

Upcoming features:

  • “Use” statement support;
  • Python & Cython callback support;
  • Kind-parameters in type specification;
  • Module-level data and parameters;
  • User-derived types.

See the README and documentation for requirements, compiler support, etc.


You can get fwrap from pypi or from its sourceforge download page:

More Info

Project homepage, including links to wiki & bug tracker:

Mailing list:

Development blog:


5 Responses to “Announcing the first release of Fwrap”

  1. zbeekman Says:

    When do you anticipate support for:

    * “Use” statement support;
    * Kind-parameters in type specification;
    * Module-level data and parameters;
    * User-derived types.

    • Kurt Smith Says:

      (1) “Use” statements are next on the list; certainly by v0.2.

      (2) Kind-type-params depend on use statements, and will work once use statements work, so v0.2.

      (3) Module-level parameters and variables will be soon after that; module-level common blocks are more uncertain.

      User-derived types: likely v0.3. It’s mapped out but depends on (1) and (2) first, I anticipate a few dark corners.

  2. David Ketcheson Says:

    Hi Kurt,

    I’m planning to use fwrap for a project I’m starting now, so glad to have a release! Looking forward to support for modules. Thanks for fwrap.

    -David Ketcheson

  3. Dmitrey Says:

    How does it refers to f2py? What are pros and cons of Fwrap vs f2py?

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s

%d bloggers like this: