3 %bcond_without guile # disable guile support
4 %bcond_without ocaml # disable ocaml support
5 %bcond_without perl # disable perl support
6 %bcond_without php # disable php support
7 %bcond_without ruby # disable ruby support
8 %bcond_without tcl # disable tcl support
10 Summary: Interface generator for Perl, Tcl, Guile and Python
11 Summary(pl): Generator interfejsów do Perla, Tcl-a, Guile'a i Pythona
12 Summary(pt_BR): Gerador de Interfaces e "Wrappers" Simplificado (SWIG)
16 License: distributable
17 Group: Development/Languages
18 Source0: http://dl.sourceforge.net/swig/%{name}-%{version}.tar.gz
19 # Source0-md5: 88ff5b99be3eafebb8a6e20f4f986c04
20 Patch0: %{name}-format.patch
21 Patch1: %{name}-php.patch
22 Patch2: %{name}-php-tsrm.patch
23 Patch3: %{name}-php-freearg.patch
24 Patch4: %{name}-php-vdecl.patch
25 Patch5: %{name}-python-lib64.patch
26 URL: http://www.swig.org/
28 BuildRequires: autoconf
29 BuildRequires: automake
30 %{?with_guile:BuildRequires: guile-devel}
31 BuildRequires: libstdc++-devel
32 BuildRequires: libtool
33 %{?with_ocaml:BuildRequires: ocaml}
34 %{?with_perl:BuildRequires: perl-devel >= 1:5.6.1}
35 %{?with_php:BuildRequires: php-devel >= 4.1.0}
36 %{?with_php:BuildRequires: php-cgi}
37 BuildRequires: python-devel >= 1:2.3.2
38 %{?with_ruby:BuildRequires: ruby >= 1:1.6.3}
39 %{?with_tcl:BuildRequires: tcl-devel >= 8.3.3}
41 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
44 SWIG is a compiler that attempts to make it easy to integrate C, C++,
45 or Objective-C code with scripting languages including Perl, Tcl, and
46 Python. In a nutshell, you give it a bunch of ANSI C/C++ declarations
47 and it generates an interface between C and your favorite scripting
48 language. However, this is only scratching the surface of what SWIG
49 can do--some of its more advanced features include automatic
50 documentation generation, module and library management, extensive
51 customization options, and more.
53 SWIG is entirely the product of users who have used the system and
54 suggested new idea. There are far too many people to thank
55 individually, but without this support, SWIG would be not be nearly as
56 powerful or fun to use as it is now. Many thanks!
59 SWIG jesk kompilatorem, który próbuje u³atwiæ integrowanie kodu
60 napisanego w C, C++ lub Objective-C z jêzykami skryptowymi, takimi jak
61 Perl, Tcl i Python. Mówi±c najpro¶ciej, je¶li dostarczysz mu zestaw
62 zadeklarowanych w ANSI C/C++ funkcji, SWIG wygeneruje Ci interfejs
63 pomiêdzy C a Twoim ulubionym jêzykiem skryptowym. To tylko drobna
64 czê¶æ tego co SWIG potrafi robiæ, bardziej zaawansowane zastosowania
65 to automatyczne generowanie dokumentacji, zarz±dzanie bibliotekami i
66 modu³ami i wiele innych.
68 SWIG jest w ca³o¶ci dzie³em ludzi, którzy go u¿ywali i wprowadzali
69 nowe pomys³y. Zbyt wielu ich jest, aby dziêkowaæ ka¿demu z nich
70 osobno, ale bez ich wsparcia SWIG nie by³by ani tak potê¿nym
71 narzêdziem, ani tak fajnym w u¿yciu jak jest teraz. Wiekie dziêki!
74 O SWIG gera interfaces para perl, python e Tcl a partir de uma arquivo
75 com uma interface de descrição que consiste de uma combinação de C/C++
76 e diretivas especiais. Permite que linguagens tipo script usem C/C++
77 com um mínimo de esforço.
80 Summary: SWIG library: guile
81 Summary(pl): Biblioteka SWIG: guile
87 %description guile -l pl
88 Biblioteka SWIG: guile.
91 Summary: SWIG library: Perl
92 Summary(pl): Biblioteka SWIG: Perl
98 %description perl -l pl
99 Biblioteka SWIG: perl.
102 Summary: SWIG library: php
103 Summary(pl): Biblioteka SWIG: php
109 %description php -l pl
110 Biblioteka SWIG: php.
113 Summary: SWIG library: python
114 Summary(pl): Biblioteka SWIG: python
118 SWIG library: python.
120 %description python -l pl
121 Biblioteka SWIG: python.
124 Summary: SWIG library: ruby
125 Summary(pl): Biblioteka SWIG: ruby
131 %description ruby -l pl
132 Biblioteka SWIG: ruby.
135 Summary: SWIG library: tcl
136 Summary(pl): Biblioteka SWIG: tcl
142 %description tcl -l pl
143 Biblioteka SWIG: tcl.
146 %setup -q -n SWIG-%{version}
152 %if "%{_lib}" == "lib64"
158 %{__aclocal} -I Tools/config
162 %{__make} source runtime \
166 rm -rf $RPM_BUILD_ROOT
167 install -d $RPM_BUILD_ROOT{%{_mandir}/man1,%{_examplesdir}/%{name}-%{version}}
169 %{__make} install install-runtime \
170 DESTDIR=$RPM_BUILD_ROOT \
171 M4_INSTALL_DIR=$RPM_BUILD_ROOT%{_aclocaldir}
173 cp -a Examples/* $RPM_BUILD_ROOT%{_examplesdir}/%{name}-%{version}
176 rm -rf $RPM_BUILD_ROOT
178 %post -p /sbin/ldconfig
179 %postun -p /sbin/ldconfig
181 %post guile -p /sbin/ldconfig
182 %postun guile -p /sbin/ldconfig
184 %post perl -p /sbin/ldconfig
185 %postun perl -p /sbin/ldconfig
187 %post php -p /sbin/ldconfig
188 %postun php -p /sbin/ldconfig
190 %post python -p /sbin/ldconfig
191 %postun python -p /sbin/ldconfig
193 %post ruby -p /sbin/ldconfig
194 %postun ruby -p /sbin/ldconfig
196 %post tcl -p /sbin/ldconfig
197 %postun tcl -p /sbin/ldconfig
200 %defattr(644,root,root,755)
201 %doc Doc CHANGES NEW README ANNOUNCE TODO LICENSE
203 %attr(755,root,root) %{_bindir}/swig
204 %{_aclocaldir}/swig.m4
205 %{_examplesdir}/%{name}-%{version}
209 %defattr(644,root,root,755)
210 %attr(755,root,root) %{_libdir}/libswigguile*.so.*.*.*
211 %attr(755,root,root) %{_libdir}/libswigguile*.so
212 %{_libdir}/libswigguile*.la
217 %defattr(644,root,root,755)
218 %attr(755,root,root) %{_libdir}/libswigpl.so.*.*.*
219 %attr(755,root,root) %{_libdir}/libswigpl.so
220 %{_libdir}/libswigpl.la
225 %defattr(644,root,root,755)
226 %attr(755,root,root) %{_libdir}/libswigphp4.so.*.*.*
227 %attr(755,root,root) %{_libdir}/libswigphp4.so
228 %{_libdir}/libswigphp4.la
232 %defattr(644,root,root,755)
233 %attr(755,root,root) %{_libdir}/libswigpy.so.*.*.*
234 %attr(755,root,root) %{_libdir}/libswigpy.so
235 %{_libdir}/libswigpy.la
239 %defattr(644,root,root,755)
240 %attr(755,root,root) %{_libdir}/libswigrb.so.*.*.*
241 %attr(755,root,root) %{_libdir}/libswigrb.so
242 %{_libdir}/libswigrb.la
247 %defattr(644,root,root,755)
248 %attr(755,root,root) %{_libdir}/libswigtcl*.so.*.*.*
249 %attr(755,root,root) %{_libdir}/libswigtcl*.so
250 %{_libdir}/libswigtcl*.la