SWIG image
Minidx |  翻译博客 |  主页 |  开发 |  邮件列表 |  错误报告和补丁
Information
SWIG是什么
兼容性
特征
使用教程
文档
风险
历史
版本
参与者
项目
版权申明
友情链接
下载
SwigWiki
Exits
AllegroCL
C# - Mono
C# - MS .NET
CFFI
CHICKEN
CLISP
Guile
Java
Lua
MzScheme
Ocaml
Perl
PHP
Python
R
Ruby
Tcl/Tk
Our Generous Host
SourceForge logo

Compatibility

SWIG is known to work on the following platforms :

  • Unix
    SWIG is configured and built using an autoconf script so it is relatively easy to install on almost any flavor of Unix. However, most of SWIG's development has taken place under Linux and Solaris. While the configuration script tries to determine the proper settings for your machine, some tweaking may be required to compile the examples included in the distribution (especially if you are using a version of Unix such as AIX or HPUX).
  • Microsoft Windows
    SWIG works on 32 bit versions of Windows such as Windows 95/98/NT/2000/XP. Currently the Windows version of SWIG 1.3 is compiled and tested under Visual Studio compilers, Cygwin and Mingw using gcc, but should be compilable by any other Windows C++ compiler. SWIG 1.1 can be compiled with Visual C++ 4.x/5.x/6.x or with the Borland C++ 5.x compiler. However, SWIG 1.1 has only been officially tested using the Visual C++ compiler. You may also need to determine which compiler has been used to compile the various scripting languages that you will be using. In general, using SWIG with a different C++ compiler than the one that was used to compile the target scripting language may not work (for example, trying to create a Tcl/Tk module using the Borland compiler when Tcl/Tk has been compiled with Visual C++).
  • Macintosh
    A highly experimental version of SWIG has been compiled using Metrowerks Code Warrior 10. Given the limited availability and experience with the Macintosh, this version of SWIG should only be used by exceptionally brave users. SWIG has not been fully tested with Python or Perl on the Macintosh although some users have reported success.

    Note:SWIG-1.3.12 does support OS-X/Darwin. Simply download the Unix sources, configure, and build from the command terminal.

Supported Languages

The following scripting languages were supported in the final SWIG 1.1 release.
  • Tcl 8.0 and newer versions.
  • Python 1.5 and newer.
  • Perl 5.003 or newer.
  • Guile 1.3.4 and newer.
The following languages are also supported in SWIG 1.3.6 onwards.
  • Java JDK 1.1 and newer.
  • Ruby.
  • Mzscheme.
PHP support was added in SWIG 1.3.11.
Objective Caml (Ocaml) and Pike support was added in SWIG 1.3.14.
Support for C# and the Chicken scheme compiler was added in SWIG 1.3.18.
Support for Allegro CL and Modula-3 was added in SWIG-1.3.22.
Support for Lua, CLISP and Common Lisp with UFFI was added in SWIG-1.3.26.
Support for Common Lisp with CFFI was added in SWIG-1.3.28.
Support for R was added in SWIG-1.3.30.

Any newer versions of these languages should be assumed to be supported unless otherwise indicated. There is also SwigJS, a JavaScript module for SWIG, swig4d for the D programming language and SWIGEiffel for Eiffel.

Compilation Requirements

SWIG is implemented in C and C++ and is distributed in source form. You will need a working C++ compiler (e.g. g++) to build SWIG and at least one of the supported scripting languages to use it (or else it isn't going to be very useful). SWIG does not depend upon any of the supported scripting languages for its own compilation. Finally, although SWIG is partly written in C++, a C++ compiler is not required to use SWIG--it works just fine with both ANSI C and C++.
Feedback and questions concerning this site should be posted to the swig-devel mailing list.

Last modified : Thu Sep 27 21:25:53 2007