README 5.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139
  1. SWIG (Simplified Wrapper and Interface Generator)
  2. Tagline: SWIG is a compiler that integrates C and C++ with languages
  3. including Perl, Python, Tcl, Ruby, PHP, Java, C#, D, Go, Lua,
  4. Octave, R, Scheme (Guile, MzScheme/Racket), Scilab, Ocaml.
  5. SWIG can also export its parse tree into XML.
  6. SWIG reads annotated C/C++ header files and creates wrapper code (glue
  7. code) in order to make the corresponding C/C++ libraries available to
  8. the listed languages, or to extend C/C++ programs with a scripting
  9. language.
  10. Up-to-date SWIG related information can be found at
  11. https://www.swig.org
  12. A SWIG FAQ and other hints can be found on the SWIG Wiki:
  13. https://github.com/swig/swig/wiki
  14. License
  15. =======
  16. Please see the LICENSE file for details of the SWIG license. For
  17. further insight into the license including the license of SWIG's
  18. output code, please visit
  19. https://www.swig.org/legal.html
  20. Release Notes
  21. =============
  22. Please see the CHANGES.current file for a detailed list of bug fixes and
  23. new features for the current release. The CHANGES file contains bug fixes
  24. and new features for older versions. A summary of changes in each release
  25. can be found in the RELEASENOTES file.
  26. Documentation
  27. =============
  28. The Doc/Manual directory contains the most recent set of updated
  29. documentation for this release. The documentation is available in
  30. three different formats, each of which contains identical content.
  31. These format are, pdf (Doc/Manual/SWIGDocumentation.pdf), single
  32. page html (Doc/Manual/SWIGDocumentation.html) or multiple page html
  33. (other files in Doc/Manual). Please select your chosen format and
  34. copy/install to wherever takes your fancy.
  35. There is some technical developer documentation available in the
  36. Doc/Devel subdirectory. This is not necessarily up-to-date, but it
  37. has some information on SWIG internals.
  38. Documentation is also online at https://www.swig.org/doc.html.
  39. Backwards Compatibility
  40. =======================
  41. The developers strive their best to preserve backwards compatibility
  42. between releases, but this is not always possible as the overriding
  43. aim is to provide the best wrapping experience. Where backwards
  44. compatibility is known to be broken, it is clearly marked as an
  45. incompatibility in the CHANGES and CHANGES.current files.
  46. See the documentation for details of the SWIG_VERSION preprocessor
  47. symbol if you have backward compatibility issues and need to use more
  48. than one version of SWIG.
  49. Installation
  50. ============
  51. Please read the Doc/Manual/Preface.html#Preface_installation for
  52. full installation instructions for Windows, Unix and Mac OS X
  53. using the release tarball/zip file. The INSTALL file has generic
  54. build and installation instructions for Unix users.
  55. Users wishing to build and install code from Github should
  56. visit https://swig.org/svn.html to obtain the more detailed
  57. instructions required for building code obtained from Github - extra
  58. steps are required compared to building from the release tarball.
  59. Testing
  60. =======
  61. The typical 'make -k check' can be performed on Unix operating systems.
  62. Please read Doc/Manual/Preface.html#Preface_testing for details.
  63. Examples
  64. ========
  65. The Examples directory contains a variety of examples of using SWIG
  66. and it has some browsable documentation. Simply point your browser to
  67. the file "Example/index.html".
  68. The Examples directory also includes Visual C++ project 6 (.dsp) files for
  69. building some of the examples on Windows. Later versions of Visual Studio
  70. will convert these old style project files into a current solution file.
  71. Known Issues
  72. ============
  73. There are minor known bugs, details of which are in the bug tracker, see
  74. https://www.swig.org/bugs.html.
  75. Troubleshooting
  76. ===============
  77. In order to operate correctly, SWIG relies upon a set of library
  78. files. If after building SWIG, you get error messages like this,
  79. $ swig foo.i
  80. :1. Unable to find 'swig.swg'
  81. :3. Unable to find 'tcl8.swg'
  82. it means that SWIG has either been incorrectly configured or
  83. installed. To fix this:
  84. 1. Make sure you remembered to do a 'make install' and that
  85. the installation actually worked. Make sure you have
  86. write permission on the install directory.
  87. 2. If that doesn't work, type 'swig -swiglib' to find out
  88. where SWIG thinks its library is located.
  89. 3. If the location is not where you expect, perhaps
  90. you supplied a bad option to configure. Use
  91. ./configure --prefix=pathname to set the SWIG install
  92. location. Also, make sure you don't include a shell
  93. escape character such as ~ when you specify the path.
  94. 4. The SWIG library can be changed by setting the SWIG_LIB
  95. environment variable. However, you really shouldn't
  96. have to do this.
  97. If you are having other troubles, you might look at the SWIG Wiki at
  98. https://github.com/swig/swig/wiki.
  99. Participate!
  100. ============
  101. Please report any errors and submit patches (if possible)! We only
  102. have access to a limited variety of hardware (Linux, Solaris, OS-X,
  103. and Windows). All contributions help.
  104. If you would like to join the SWIG development team or contribute a
  105. language module to the distribution, please contact the swig-devel
  106. mailing list, details at https://www.swig.org/mail.html.
  107. -- The SWIG Maintainers