]>
Commit | Line | Data |
---|---|---|
ea0af088 ER |
1 | %define status stable |
2 | %define pearname DB_DataObject | |
ea0af088 ER |
3 | Summary: %{pearname} - an SQL builder, object interface to database tables |
4 | Summary(pl.UTF-8): %{pearname} - SQL builder, obiektowy interfejs do tabel bazodanowych | |
5 | Name: php-pear-%{pearname} | |
05a4ce4c | 6 | Version: 1.11.5 |
f39edc3b | 7 | Release: 2 |
9b47d381 | 8 | License: PHP 3.0 |
3e3d8fc2 | 9 | Group: Development/Languages/PHP |
ea0af088 | 10 | Source0: http://pear.php.net/get/%{pearname}-%{version}.tgz |
05a4ce4c | 11 | # Source0-md5: 1a4b3d6114768b835a56a56585e3422b |
895420d5 | 12 | Patch0: DB_DataObject-PLD.patch |
2d1d77a5 | 13 | URL: http://pear.php.net/package/DB_DataObject/ |
17dbfba9 | 14 | BuildRequires: php-pear-PEAR >= 1:1.4.0-0.b1 |
07dcae72 | 15 | BuildRequires: rpm-php-pearprov >= 4.4.2-11 |
ea0af088 | 16 | BuildRequires: rpmbuild(macros) >= 1.580 |
fe1c0541 | 17 | Requires: php(core) >= 4.3 |
e1bca5f8 | 18 | Requires: php-pear >= 4:1.0-8 |
fe29fc0a ER |
19 | Requires: php-pear-DB >= 1.7.0 |
20 | Requires: php-pear-Date >= 1.4.3 | |
17dbfba9 ER |
21 | Suggests: php-pear-MDB2 |
22 | Suggests: php-pear-Validate | |
3e3d8fc2 PG |
23 | BuildArch: noarch |
24 | BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n) | |
25 | ||
a67c26a1 | 26 | # exclude optional dependencies |
ea0af088 | 27 | %define _noautoreq pear(Validate.*) pear(MDB2.*) |
a67c26a1 | 28 | |
3e3d8fc2 PG |
29 | %description |
30 | The core class is designed to be extended for each of your tables so | |
41a3ee94 | 31 | that you put the data logic inside the data classes. Included is a |
3e3d8fc2 PG |
32 | Generator to make your configuration files and your base classes. |
33 | DataObject performs 2 tasks: | |
d7608d65 | 34 | - Builds SQL statements based on the objects vars and the builder |
35 | methods, | |
36 | - acts as a datastore for a table row. | |
41a3ee94 | 37 | |
ea0af088 | 38 | In PEAR status of this package is: %{status}. |
c15165d4 | 39 | |
d8f31f06 JR |
40 | %description -l pl.UTF-8 |
41 | Główna klasa została stworzona tak, by być rozszerzalną dla każdej | |
42 | tabeli, więc można umieścić logikę danych w klasach danych. Dołączony | |
43 | jest generator do tworzenia plików konfiguracyjnych i klas bazowych. | |
44 | DataObject pełni 2 zadania: | |
45 | - tworzy zapytania SQL bazując na zmiennych obiektowych i metodach | |
d7608d65 | 46 | tworzenia |
47 | - przechowuje dane z wiersza tabeli. | |
3e3d8fc2 | 48 | |
ea0af088 | 49 | Ta klasa ma w PEAR status: %{status}. |
c15165d4 | 50 | |
ccff9b7f ER |
51 | %package cli |
52 | Summary: CLI interface for DB_DataObject | |
7a4e496b | 53 | Summary(pl.UTF-8): Interfejs linii poleceń dla DB_DataObject |
ccff9b7f ER |
54 | Group: Development/Languages/PHP |
55 | Requires: %{name} = %{version}-%{release} | |
56 | ||
57 | %description cli | |
58 | CLI interface for DB_DataObject generator. | |
59 | ||
d8f31f06 JR |
60 | %description cli -l pl.UTF-8 |
61 | Interfejs linii poleceń dla generatora DB_DataObject. | |
fefadfa7 | 62 | |
3e3d8fc2 | 63 | %prep |
a67c26a1 | 64 | %pear_package_setup |
895420d5 ER |
65 | mv ./%{php_pear_dir}/DB/DataObject/createTables.php DB_DataObject_createTables |
66 | %patch0 -p1 | |
3e3d8fc2 PG |
67 | |
68 | %install | |
69 | rm -rf $RPM_BUILD_ROOT | |
895420d5 | 70 | install -d $RPM_BUILD_ROOT{%{php_pear_dir},%{_bindir}} |
a67c26a1 | 71 | %pear_package_install |
ea0af088 | 72 | install -p DB_DataObject_createTables $RPM_BUILD_ROOT%{_bindir} |
3e3d8fc2 PG |
73 | |
74 | %clean | |
75 | rm -rf $RPM_BUILD_ROOT | |
76 | ||
a67c26a1 ER |
77 | %post |
78 | if [ -f %{_docdir}/%{name}-%{version}/optional-packages.txt ]; then | |
79 | cat %{_docdir}/%{name}-%{version}/optional-packages.txt | |
80 | fi | |
81 | ||
3e3d8fc2 PG |
82 | %files |
83 | %defattr(644,root,root,755) | |
05a4ce4c | 84 | %doc install.log |
a67c26a1 | 85 | %{php_pear_dir}/.registry/*.reg |
ea0af088 | 86 | %{php_pear_dir}/DB/*.php |
7cfa1dd9 | 87 | %dir %{php_pear_dir}/DB/DataObject |
ea0af088 | 88 | %{php_pear_dir}/DB/DataObject/Cast.php |
ea0af088 | 89 | %{php_pear_dir}/DB/DataObject/Error.php |
7cfa1dd9 ER |
90 | %{php_pear_dir}/DB/DataObject/Generator.php |
91 | %{php_pear_dir}/DB/DataObject/Links.php | |
ccff9b7f ER |
92 | |
93 | %files cli | |
94 | %defattr(644,root,root,755) | |
ea0af088 | 95 | %doc docs/%{pearname}/docs/example.ini |
ccff9b7f | 96 | %attr(755,root,root) %{_bindir}/DB_DataObject_createTables |