]> git.pld-linux.org Git - packages/perl-DBIx-BLOB-Handle.git/blob - perl-DBIx-BLOB-Handle.spec
81b374719980b6bb5c2136c88e4fa546eedc1e17
[packages/perl-DBIx-BLOB-Handle.git] / perl-DBIx-BLOB-Handle.spec
1 #
2 # Conditional build:
3 %bcond_without  tests   # Do not perform "make test"
4 #
5 %include        /usr/lib/rpm/macros.perl
6 %define         pdir    DBIx
7 %define         pnam    BLOB-Handle
8 Summary:        DBIx::BLOB::Handle - read database large object binaries from file handles
9 Summary(pl.UTF-8):      DBIx::BLOB::Handle - czytanie obiektów BLOB z uchwytów plików
10 Name:           perl-DBIx-BLOB-Handle
11 Version:        0.2
12 Release:        6
13 License:        Artistic
14 Group:          Development/Languages/Perl
15 Source0:        http://www.cpan.org/modules/by-module/%{pdir}/%{pdir}-%{pnam}-%{version}.tar.gz
16 # Source0-md5:  e23fbc1e9ca23295847cb94780262757
17 BuildRequires:  perl-devel >= 1:5.8.0
18 BuildRequires:  perl-DBI
19 BuildRequires:  rpm-perlprov >= 4.1-13
20 BuildArch:      noarch
21 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
22
23 %description
24 DBI has a blob_copy_to_file method which takes a file handle argument
25 and copies a database large object binary (LOB) to this file handle.
26 However, the method is undocumented and faulty. Constructing a similar
27 method yourself is pretty simple but what if you wished to read the
28 data and perform operations on it? You could use the DBI's blob_read
29 method yourself to process chunks of data from the LOB or even dump
30 its contents into a scalar, but maybe it would be nice to read the
31 data line by line or piece by piece from a familiar old filehandle?!
32
33 %description -l pl.UTF-8
34 DBI ma metodę blob_copy_to_file, która przyjmuje parametr będący
35 uchwytem pliku i kopiuje duże obiekty bazodanowe (LOB) do tego
36 uchwytu. Mimo to, ta metoda jest nieudokumentowana i zawiera błędy.
37 Stworzenie podobnej metody jest proste, ale co jeśli trzeba czytać
38 dane i przeprowadzać na nich operacje? Można użyć metody blob_read z
39 DBI do przetwarzania fragmentów danych z obiektu LOB albo nawet
40 zrzucać zawartość do zmiennej, ale może przyjemniej jest czytać dane
41 linia po linii lub kawałek po kawałku z normalnego uchwytu pliku?
42
43 %prep
44 %setup -q -n %{pdir}-%{pnam}-%{version}
45
46 %build
47 %{__perl} Makefile.PL \
48         INSTALLDIRS=vendor
49 %{__make}
50
51 %{?with_tests:%{__make} test}
52
53 %install
54 rm -rf $RPM_BUILD_ROOT
55
56 %{__make} install \
57         DESTDIR=$RPM_BUILD_ROOT
58
59 %clean
60 rm -rf $RPM_BUILD_ROOT
61
62 %files
63 %defattr(644,root,root,755)
64 %dir %{perl_vendorlib}/DBIx/BLOB
65 %{perl_vendorlib}/DBIx/BLOB/*.pm
66 %{_mandir}/man3/*
This page took 0.032465 seconds and 2 git commands to generate.