1 # TODO: provide configurations for other configurations (e.g. x11)?
4 %bcond_without tests # do not perform "make test"
5 %bcond_without gtk2 # wxGTK2 packages support
6 %bcond_without gtk3 # wxGTK3 packages support
7 %bcond_with ansi # ANSI wx packages support
8 %bcond_without unicode # Unicode wx packages support
10 %define _enable_debug_packages 0
13 %define pnam wxWidgets
14 Summary: Alien::wxWidgets - building, finding and using wxWidgets binaries
15 Summary(pl.UTF-8): Alien::wxWidgets - budowanie, znajdowanie i wykorzystywanie binariów wxWidgets
16 Name: perl-Alien-wxWidgets
20 License: GPL v1+ or Artistic
21 Group: Development/Languages/Perl
22 Source0: http://www.cpan.org/modules/by-module/Alien/%{pdir}-%{pnam}-%{version}.tar.gz
23 # Source0-md5: 4edfec992976b71333699a84d07c8aa6
24 Patch0: %{name}-nobuild.patch
25 Patch1: %{name}-config.patch
26 URL: https://metacpan.org/release/Alien-wxWidgets
27 BuildRequires: perl-ExtUtils-CBuilder >= 0.24
28 BuildRequires: perl-Module-Build >= 0.28
29 BuildRequires: perl-Module-Pluggable >= 3.1-4
30 BuildRequires: perl-devel >= 1:5.8.0
31 BuildRequires: perl(File::Spec) >= 1.50
32 BuildRequires: perl-Test-Pod >= 1.0
33 BuildRequires: perl-Test-Pod-Coverage >= 1.0
34 BuildRequires: rpm-perlprov >= 4.1-13
35 BuildRequires: rpmbuild(macros) >= 1.745
38 BuildRequires: wxGTK2-devel >= 2.6.3
39 BuildRequires: wxGTK2-gl-devel >= 2.6.3
42 BuildRequires: wxGTK2-unicode-devel >= 2.6.3
43 BuildRequires: wxGTK2-unicode-gl-devel >= 2.6.3
48 BuildRequires: wxGTK3-devel >= 2.6.3
49 BuildRequires: wxGTK3-gl-devel >= 2.6.3
52 BuildRequires: wxGTK3-unicode-devel >= 2.6.3
53 BuildRequires: wxGTK3-unicode-gl-devel >= 2.6.3
56 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
60 %define wx_config wx-gtk2-ansi-config
63 %define wx_config wx-gtk2-unicode-config
69 %define wx_config wx-gtk3-ansi-config
72 %define wx_config wx-gtk3-unicode-config
77 %define wx_ver %(%{wx_config} --version)
78 %define wx_ver_tag %(echo %{wx_ver} | tr . _)
81 Alien::wxWidgets allows wxPerl to easily find information about your
82 wxWidgets installation. It can store this information for multiple
83 wxWidgets versions or configurations (debug, Unicode, etc.). It can
84 also build and install a private copy of wxWidgets as part of the
87 %description -l pl.UTF-8
88 Alien::wxWidgets pozwala wxPerlowi łatwo uzyskać informacje na temat
89 instalacji wxWidgets. Może przechowywać informacje o wielu wersjach
90 lub konfiguracjach (debug, Unicode, itp.). Może także zbudować i
91 zainstalować prywatną kopię wxWidgets jako część procesu budowania.
94 %setup -q -n %{pdir}-%{pnam}-%{version}
99 for toolkit in %{?with_gtk2:gtk2} %{?with_gtk3:gtk3} ; do
100 for charset in %{?with_ansi:ansi} %{?with_unicode:unicode} ; do
101 export WX_CONFIG=wx-${toolkit}-${charset}-config
103 destdir=$RPM_BUILD_ROOT \
109 %{?with_tests:./Build test}
114 rm -rf $RPM_BUILD_ROOT
119 rm -rf $RPM_BUILD_ROOT
122 %defattr(644,root,root,755)
123 %{perl_vendorarch}/Alien/wxWidgets.pm
124 %dir %{perl_vendorarch}/Alien/wxWidgets
125 %{perl_vendorarch}/Alien/wxWidgets/Utility.pm
126 %dir %{perl_vendorarch}/Alien/wxWidgets/Config
129 %{perl_vendorarch}/Alien/wxWidgets/Config/gtk2_%{wx_ver_tag}_gcc_3_4.pm
132 %{perl_vendorarch}/Alien/wxWidgets/Config/gtk2_%{wx_ver_tag}_uni_gcc_3_4.pm
136 # should be gtk3_*.pm?
138 %{perl_vendorarch}/Alien/wxWidgets/Config/gtk_%{wx_ver_tag}_gcc_3_4.pm
141 %{perl_vendorarch}/Alien/wxWidgets/Config/gtk_%{wx_ver_tag}_uni_gcc_3_4.pm
144 %{_mandir}/man3/Alien::wxWidgets*.3pm*