3 %bcond_without tests # do not perform "make test"
7 Summary: Tie::Restore - restores ties to an existing object
8 Summary(pl.UTF-8): Tie::Restore - odtworzenie powiązań do istniejącego obiektu
13 License: GPL v1+ or Artistic
14 Group: Development/Languages/Perl
15 Source0: http://www.cpan.org/modules/by-module/%{pdir}/%{pdir}-%{pnam}-%{version}.tar.gz
16 # Source0-md5: 1300dfc45d0eb7e4cf0634c81c030230
17 Patch0: %{name}-path.patch
18 URL: http://search.cpan.org/dist/Tie-Restore/
19 BuildRequires: perl-devel >= 1:5.8.0
20 BuildRequires: rpm-perlprov >= 4.1-13
22 BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
25 Provides the opposite of the 'tied' function. Say you have %%hash that
26 is tied to $object. Then, it is relatively simple to get $object from
27 %%hash simply by saying
29 $object = tied %%hash;
31 But, how does one go the other way? Simple, with Tie::Restore
33 tie %%hash, 'Tie::Restore', $object;
35 Works for any kind of tie. (scalar, array, hash, filehandle)
37 %description -l pl.UTF-8
38 Ten moduł dostarcza odwrotność funkcji 'tied'. Załóżmy, że mamy %%hash
39 przywiązany do obiektu $object. Wtedy można stosunkowo prosto otrzymać
40 $object z %%hash poprzez
42 $object = tied %%hash;
44 Ale jak teraz zrobić na odwrót? Proste, przy użyciu Tie::Restore:
46 tie %%hash, 'Tie::Restore', $object;
48 Działa z dowolnym rodzajem przywiązania (skalarem, tablicą, tablicą
49 asocjacyjną, uchwytem do pliku).
52 %setup -q -n %{pdir}-%{pnam}-%{version}
56 %{__perl} Makefile.PL \
60 %{?with_tests:%{__make} test}
63 rm -rf $RPM_BUILD_ROOT
66 DESTDIR=$RPM_BUILD_ROOT
69 rm -rf $RPM_BUILD_ROOT
72 %defattr(644,root,root,755)
74 %{perl_vendorlib}/Tie/*.pm