]> git.pld-linux.org Git - packages/postgresql.git/blob - postgresql.spec
- template dir is owned by root, not postgres use
[packages/postgresql.git] / postgresql.spec
1
2 %include        /usr/lib/rpm/macros.perl
3 %define pglibdir     %{_libdir}/pgsql
4 %define pgsqldir     %{_datadir}/pgsql/sql
5 %define pgmoduledir  %{pglibdir}/modules
6
7 Summary:        PostgreSQL Data Base Management System
8 Summary(de):    PostgreSQL Datenbankverwaltungssystem
9 Summary(fr):    Sysème de gestion de base de données PostgreSQL
10 Summary(pl):    PostgreSQL system bazodanowy
11 Summary(tr):    Veri Tabaný Yönetim Sistemi
12 Name:           postgresql
13 Version:        7.0.2
14 Release:        7
15 License:        BSD
16 Group:          Applications/Databases
17 Group(pl):      Aplikacje/Bazy danych
18 Source0:        ftp://ftp.postgresql.org/pub/%{name}-%{version}.tar.gz
19 Source1:        %{name}.init
20 Source2:        pgsql-Database-HOWTO-html.tar.gz
21 Source3:        %{name}.sysconfig
22 Patch0:         %{name}-opt.patch
23 Patch1:         %{name}-DESTDIR.patch
24 Patch2:         %{name}-perl.patch
25 Patch3:         %{name}-python.patch
26 Patch4:         %{name}-no_libnsl.patch
27 URL:            http://www.postgresql.org/
28 Prereq:         /sbin/chkconfig
29 Requires:       rc-scripts
30 BuildRequires:  autoconf
31 BuildRequires:  tcl-devel
32 BuildRequires:  tk-devel
33 BuildRequires:  readline-devel
34 BuildRequires:  ncurses-devel >= 5.0
35 BuildRequires:  rpm-perlprov
36 BuildRequires:  XFree86-devel
37 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
38 Requires:       %{name}-libs = %{version}
39 Obsoletes:      postgresql-server
40 Obsoletes:      postgresql-test
41
42 %define         _sysconfdir     /etc
43
44 %description
45 PostgreSQL Data Base Management System (formerly known as Postgres,
46 then as Postgres95).
47
48 PostgreSQL is an enhancement of the POSTGRES database management
49 system, a next-generation DBMS research prototype. While PostgreSQL
50 retains the powerful data model and rich data types of POSTGRES, it
51 replaces the PostQuel query language with an extended subset of SQL.
52 PostgreSQL is free and the complete source is available.
53
54 PostgreSQL development is being performed by a team of Internet
55 developers who all subscribe to the PostgreSQL development mailing
56 list. The current coordinator is Marc G. Fournier
57 (scrappy@postgreSQL.org). This team is now responsible for all current
58 and future development of PostgreSQL.
59
60 The authors of PostgreSQL 1.01 were Andrew Yu and Jolly Chen. Many
61 others have contributed to the porting, testing, debugging and
62 enhancement of the code. The original Postgres code, from which
63 PostgreSQL is derived, was the effort of many graduate students,
64 undergraduate students, and staff programmers working under the
65 direction of Professor Michael Stonebraker at the University of
66 California, Berkeley.
67
68 The original name of the software at Berkeley was Postgres. When SQL
69 functionality was added in 1995, its name was changed to Postgres95.
70 The name was changed at the end of 1996 to PostgreSQL.
71
72 PostgreSQL runs on Solaris, SunOS, HPUX, AIX, Linux, Irix, FreeBSD,
73 and most flavours of Unix.
74
75 %description -l de
76 PostgreSQL Datenbank-Managementsystem (früher als Postgres, dann als
77 Postgres95 bekannt).
78
79 PostgreSQL ist eine Verbesserung des POSTGRES-DB-Managementsystems,
80 ein DBMS-Forschungsprototyp der nächsten Generation. Während es das
81 leistungsfähige Datenmodell und die reichhaltigen Datentypen von
82 POSTGRES beibehält, ersetzt es die PostQuel-Abfragesprache durch ein
83 Subset von SQL. PostgreSQL ist gratis, der gesamte Quellcode ist
84 verfügbar.
85
86 Ein Team von Internet-Entwicklern befaßt sich mit PostgreSQL. Sie alle
87 sind auf der PostgreSQL-Entwickleradreßliste. Koordinator ist Marc G.
88 Fournier (scrappy@postgreSQL.org). Das Team ist verantwortlich für
89 alle aktuellen und künftigen Entwicklungen von PostgreSQL.
90
91 Die Autoren von PostgreSQL 1.01 waren Andrew Yu und Jolly Chen.
92 Zahlreiche andere haben zur Portierung, zum Testen, Debugging und zur
93 Verbesserung des Code beigetragen. Den Original-Postgres-Code, von dem
94 sich PostgreSQL ableitet, verdanken wir der Arbeit vieler Doktoranden,
95 Studenten und Programmierern unter der Leitung von Professor Michael
96 Stonebraker an der University of California, Berkeley.
97
98 Der ursprüngliche Name war Postgres. Als 1995 SQL-Funktionalität
99 hinzukam, wurde der Name in Postgres95 geändert. Ende 1996 schließlich
100 entschied man sich für PostgreSQL.
101
102 PostgreSQL läuft auf Solaris, SunOS, HPUX, AIX, Linux, Irix, FreeBSD
103 und den meisten Unix-Systemen.
104
105 %description -l fr
106 Système de gestion de bases de données PostgreSQL (D'abord nommé
107 Postgres, puis Postgres95).
108
109 PostgreSQL est une amélioration du système de gestion de bases de
110 données POSTGRES, un prototype de recherche de la génération suivant
111 DBMS. Tout en conservant le puissant modèle de donnée de et les types
112 de donée riches de Postgres, il remplace le langage de requêtes de
113 Postgres par un sous ensemble etendu de commandes SQL. PosrgreSQL est
114 libre, et ses sources sont disponibles.
115
116 Le développement de PostgreSQL est actuellement réalisé via internet
117 parune équipe de développeurs inscrits sur la mailing-list de
118 développement de PostgreSQL. Le coordinateur actuel est Marc G
119 Fournier (scrappy@postgreSQL.org). Cette équipe est responsable du
120 développemen actuel et à venir de PostgreSQL.
121
122 Les auteurs de PostgreSQL 1.01 étaient Andrew Yu et Jolly Chen.
123 Beaucoup d'autres ont contribué au portage, au test, au débogage et à
124 l'amélioration du code. Le code original de Postgres, duquel
125 PostgreSQL est dérivé, a été l'oeuvre d'étudiants de haut niveau, de
126 moins haut niveau, et de programmeurs travaillant sous la direction du
127 professeur Michael Stonebraker à l'université de Berkeley Californie.
128
129 Le nom original du logiciel était Postgres. Quand les fonctionnalitées
130 SQL furent ajoutées en 1995, son nom est devenu Postgres95. Il a été
131 rebaptisé PostgreSQL en 1996.
132
133 PostgreSQL tourne sur Solaris, SunOS, HPUX, AIX, Linux, Irix, FreeBSD,
134 et la plupart des Unix.
135
136 %description -l pl
137 PostgreSQL System Zarz±dzania Baz± Danych (dawniej znany jako
138 Postgres, nastêpnie jako Postgres95).
139
140 PostgreSQL mo¿e byæ uruchominy pod nastêpuj±cymi systemami: Solaris,
141 SunOS, HPUX, AIX, Linux, Irix, FreeBSD i innych systemach Unix.
142
143 %description -l tr
144 PostgreSQL, POSTGRES'den türemiþ bir veri tabaný yönetim sistemidir
145 (DBMS). Güçlü veri modeli ve zengin POSTGRES veri tiplerini
146 desteklerken SQL'in geniþletilmiþ bir altkümesi yerine PostQuel
147 sorgulama dilini koyar.
148
149 %package devel
150 Summary:        PostgreSQL development header files and libraries
151 Summary(de):    PostgreSQL-Entwicklungs-Header-Dateien und Libraries 
152 Summary(fr):    En-têtes et bibliothèques de développement PostgreSQL
153 Summary(pl):    PostgreSQL - pliki nag³ówkowe i biblioteki
154 Summary(tr):    PostgreSQL baþlýk dosyalarý ve kitaplýklar
155 Group:          Development/Libraries
156 Group(pl):      Programowanie/Biblioteki
157 Group(fr):      Development/Librairies
158 Requires:       %{name}-libs = %{version}
159
160 %description devel
161 This package contains header files and libraries required to compile
162 applications that are talking directly to the PostgreSQL backend
163 server.
164
165 %description -l de devel
166 Dieses Paket enthält die Header-Dateien und Libraries, die zum
167 Kompilieren von Applikationen notwendig sind, die direkt mit dem
168 PostgreSQL-Backend-Server kommunizieren.
169
170 %description -l fr devel
171 Ce package contient les fichiers d'en-tête et les bibliothéques
172 nécessaires pour compiler des applications ayant des échanges directs
173 avec le serveur du backend PostgreSQL.
174
175 %description -l pl devel
176 Pakiet zawiera nag³ówki oraz biblioteki wymagane do kompilacji
177 aplikacji ³±cz±cych siê bezpo¶rednio z serwerem PostgreSQL.
178
179 %description -l tr devel
180 Bu paket, PostgreSQL sunucusuyla konuþacak yazýlýmlar geliþtirmek için
181 gereken baþlýk dosyalarýný ve kitaplýklarý içerir.
182
183 %package clients
184 Summary:        clients needed to access a PostgreSQL server
185 Summary(pl):    klienci wymagani do dostêpu do serwera PostgreSQL
186 Group:          Applications/Databases
187 Group(pl):      Aplikacje/Bazy danych
188 Requires:       %{name}-libs = %{version}
189
190 %description clients
191 This package includes only the clients and client libraries needed to
192 access an PostgreSQL server. The server is included in the main
193 package. If all you need is to connect to another PostgreSQL server,
194 the this is the only package you need to install.
195
196 In this package there are client libraries available for C and C++, as
197 well as several command-line utilities you can use to manage your
198 databases on a remote PostgreSQL server.
199
200 %description -l pl clients
201 Pakiet zawiera klientów oraz biblioteki niezbêdne dla dostêpu do
202 serwera PostgreSQL. Serwer znajduje siê w g³ównym pakiecie.
203
204 %package perl
205 Summary:        Perl interface to PostgreSQL database
206 Summary(pl):    Interface dla Perl'a umo¿liwiaj±cy dostêp do baz PostgreSQL
207 Group:          Applications/Databases
208 Group(pl):      Aplikacje/Bazy danych
209 Requires:       perl >= 5.004
210 Requires:       %{name}-libs = %{version}
211
212 %description perl
213 This package includes only perl modules needed to access an PostgreSQL
214 server.
215
216 %description -l pl perl
217 Pakiet ten zawiera tylko modu³y Perl'a wymagane dla dostêpu do serwera
218 PostgreSQL.
219
220 %package python
221 Summary:        The python-based client programs needed for accessing a PostgreSQL server
222 Group:          Development/Databases
223 ######          Unknown group!
224 Requires:       python >= 1.5
225 Requires:       %{name}-libs = %{version}
226
227 %description python
228 postgresql-python includes the python-based client programs and client
229 libraries that you'll need to access a PostgreSQL database management
230 system server.
231
232 %package doc
233 Summary:        Documentation for PostgreSQL
234 Summary(pl):    Dodatkowa dokumantacja dla PostgreSQL
235 Group:          Applications/Databases
236 Group(pl):      Aplikacje/Bazy danych
237 #Requires:      %{name} = %{version}
238
239 %description doc
240 This package includes documentation and HOWTO for programmer, admin
241 etc., in HTML format.
242
243 %description -l pl doc
244 Pakiet ten zawiera dokumentacjê oraz HOWTO m.in. dla programistów,
245 administratorów w formacie HTML.
246
247 %package libs
248 Summary:        PostgreSQL libraries
249 Summary(pl):    Biblioteki dzielone programu PostgreSQL
250 Group:          Libraries
251 Group(pl):      Biblioteki
252 Group(fr):      Librairies
253
254 %description libs
255 PostgreSQL libraries.
256
257 %description libs -l pl
258 Biblioteki dzielone programu PostgreSQL.
259
260 %package static
261 Summary:        PostgreSQL static libraries
262 Summary(pl):    Biblioteki statyczne programu PostgreSQL
263 Group:          Development/Libraries
264 Group(pl):      Programowanie/Biblioteki
265 Group(fr):      Development/Librairies
266 Requires:       %{name}-devel = %{version}
267
268 %description static
269 PostgreSQL static libraries.
270
271 %description -l pl static
272 Biblioteki statyczne programu PostgreSQL.
273
274 %package c++
275 Summary:        C++ interface to PostgreSQL
276 Summary(pl):    Interface C++ do PostgreSQL
277 Group:          Applications/Databases
278 Group(pl):      Aplikacje/Bazy danych
279 Requires:       %{name}-libs = %{version}
280
281 %description c++
282 This package includes library for C++ interface to PostgreSQL.
283
284 %description -l pl c++
285 Pakiet ten zawiera biblioteki dla interface'u C++ do PostgreSQL.
286
287 %package c++-devel
288 Summary:        C++ interface to PostgreSQL - development part
289 Summary(pl):    Interface C++ do PostgreSQL - cze¶æ programistyczna
290 Group:          Applications/Databases
291 Group(pl):      Aplikacje/Bazy danych
292 Requires:       %{name}-c++ = %{version}
293 Requires:       %{name}-devel = %{version}
294
295 %description c++-devel
296 This package includes library and header files for C++ interface.
297
298 %description -l pl c++-devel
299 Pakiet ten zawiera biblioteki i pliki nag³ówkowe dla interface'u C++.
300
301 %package c++-static
302 Summary:        C++ interface to PostgreSQL - static libraries
303 Summary(pl):    Interface C++ do PostgreSQL - biblioteki statyczne
304 Group:          Applications/Databases
305 Group(pl):      Aplikacje/Bazy danych
306 Requires:       %{name}-c++-devel = %{version}
307
308 %description c++-static
309 This package includes static library for interface C++.
310
311 %description -l pl c++-static
312 Pakiet ten zawiera biblioteki statyczne dla interface'u C++.
313
314 %package odbc
315 Summary:        ODBC interface to PostgreSQL
316 Summary(pl):    Interface ODBC do PostgreSQL
317 Group:          Applications/Databases
318 Group(pl):      Aplikacje/Bazy danych
319 Requires:       %{name}-libs = %{version}
320
321 %description odbc
322 This package includes library for interface ODBC.
323
324 %description -l pl odbc
325 Pakiet ten zawiera biblioteki dla interface'u ODBC.
326
327 %package odbc-devel
328 Summary:        ODBC interface to PostgreSQL - development part
329 Summary(pl):    Interface ODBC do PostgreSQL - cze¶æ programistyczna
330 Group:          Applications/Databases
331 Group(pl):      Aplikacje/Bazy danych
332 Requires:       %{name}-odbc = %{version}
333 Requires:       %{name}-devel = %{version}
334
335 %description odbc-devel
336 This package includes library and header files for interface ODBC.
337
338 %description -l pl odbc-devel
339 Pakiet ten zawiera biblioteki i pliki nag³ówkowe dla interface'u ODBC.
340
341 %package odbc-static
342 Summary:        ODBC interface to PostgreSQL - static libraries
343 Summary(pl):    Interface ODBC do PostgreSQL - biblioteki statyczne
344 Group:          Applications/Databases
345 Group(pl):      Aplikacje/Bazy danych
346 Requires:       %{name}-odbc-devel = %{version}
347
348 %description odbc-static
349 This package includes static library for interface ODBC.
350
351 %description -l pl odbc-static
352 Pakiet ten zawiera biblioteki statyczne dla interface'u ODBC.
353
354 %package tcl
355 Summary:        tcl interface for PostgreSQL
356 Summary(pl):    tcl interface dla PostgreSQL
357 Group:          Development/Languages/Tcl
358 Group(pl):      Programowanie/Jêzyki/Tcl
359 Requires:       %{name}-libs = %{version}
360
361 %description tcl
362 tcl interface for PostgreSQL.
363
364 %description tcl -l pl
365 tcl interface dla PostgreSQL.
366
367 %package tcl-devel
368 Summary:        Development part of tcl interface for PostgreSQL
369 Summary(pl):    Czê¶æ dla programistów interafece tcl dla PostgreSQL
370 Group:          Development/Languages/Tcl
371 Group(pl):      Programowanie/Jêzyki/Tcl
372 Requires:       %{name}-tcl = %{version}
373 Requires:       %{name}-devel = %{version}
374
375 %description tcl-devel
376 Development part of tcl interface for PostgreSQL.
377
378 %description tcl-devel -l pl
379 Czê¶æ dla programistów interafece tcl dla PostgreSQL.
380
381 %package tcl-static
382 Summary:        Static libraries of tcl interface for PostgreSQL
383 Summary(pl):    Biblioteki statyczne interafece tcl dla PostgreSQL
384 Group:          Development/Languages/Tcl
385 Group(pl):      Programowanie/Jêzyki/Tcl
386 Requires:       %{name}-tcl-devel = %{version}
387
388 %description tcl-static
389 Static libraries of tcl interface for PostgreSQL
390
391 %description tcl-devel -l pl
392 Biblioteki statyczne interafece tcl dla PostgreSQL
393
394 %package module-datetime
395 Summary:        Some useful datetime functions for PostgreSQL
396 Summary(pl):    Kilka u¿ytecznych funkcji operuj±cych na dacie i czasie dla PostgreSQL
397 Group:          Applications/Databases
398 Group(pl):      Aplikacje/Bazy danych
399 Requires:       %{name} = %{version}
400
401 %description module-datetime
402 Some useful datetime function for PostgreSQL such as:
403 - hhmm_in(opaque)
404 - hhmm_out(opaque)
405 - hhmm(time)
406 - time_difference(time,time)
407 - time_hours(time)
408 - time_minutes(time)
409 - time_seconds(time)
410 - as_minutes(time)
411 - as_seconds(time)
412 - date_day(date)
413 - date_month(date)
414 - date_year(date)
415 - currenttime()
416 - currentdate() To enable them you need to execute
417   datetime_function.sql script. You can found it in /usr/share/pgsql/sql
418   directory.
419
420 %description module-datetime -l pl
421 Kilka u¿ytecznych funkcji operuj±cych na dacie i czasie dla
422 PostgreSQL.
423 - hhmm_in(opaque)
424 - hhmm_out(opaque)
425 - hhmm(time)
426 - time_difference(time,time)
427 - time_hours(time)
428 - time_minutes(time)
429 - time_seconds(time)
430 - as_minutes(time)
431 - as_seconds(time)
432 - date_day(date)
433 - date_month(date)
434 - date_year(date)
435 - currenttime()
436 - currentdate() Po wykonaniu skryptu datetime_function.sql mo¿na
437   u¿ywaæ tych funkcji z poziomu zapytañ SQL. Skrypt ten znajduje siê w
438   katalogu /usr/share/pgsql/sql.
439
440 %package module-plpgsql
441 Summary:        PL/pgSQL - PostgreSQL procedural language
442 Summary(pl):    PL/pgSQL jêzyk proceduralny bazy danych PostgreSQL
443 Group:          Applications/Databases
444 Group(pl):      Aplikacje/Bazy danych
445
446 %description module-plpgsql
447 From PostgreSQL documentation.
448
449 Postgres supports the definition of procedural languages. In the case
450 of a function or trigger procedure defined in a procedural language,
451 the database has no built-in knowledge about how to interpret the
452 function's source text. Instead, the task is passed to a handler that
453 knows the details of the language. The handler itself is a special
454 programming language function compiled into a shared object and loaded
455 on demand.
456
457 To enable PL/pgSQL procedural language for your database you have to
458 run createlang command.
459
460 %description module-plpgsql -l pl
461 Z dokumentacji PostgreSQL.
462
463 Postgres ma wsparcie dla jêzyków proceduralnych. W przypadku, kiedy
464 programista zdefiniuje procedurê wyzwalacza lub funkcjê w jêzyku
465 proceduralnym, baza danych nie ma pojêcia jak interpretowaæ tego typu
466 funkcjê. Funkcja lub procedura ta jest przekazywana do interpretera,
467 który wie jak j± wykonaæ. Interpreter jest odpowiedni±, specjaln±
468 funkcj±, która jest skompilowana w obiekt dzielony i ³adowany w razie
469 potrzeby.
470
471 Za pomoc± komendy createlang mo¿na dodaæ wsparcie dla jêzyka
472 proceduralnego PL/pgSQL dla swojej bazy danych.
473
474 %package module-pltcl
475 Summary:        PL/TCL - PostgreSQL procedural language
476 Summary(pl):    PL/TCL jêzyk proceduralny bazy danych PostgreSQL
477 Group:          Applications/Databases
478 Group(pl):      Aplikacje/Bazy danych
479
480 %description module-pltcl
481 From PostgreSQL documentation.
482
483 Postgres supports the definition of procedural languages. In the case
484 of a function or trigger procedure defined in a procedural language,
485 the database has no built-in knowledge about how to interpret the
486 function's source text. Instead, the task is passed to a handler that
487 knows the details of the language. The handler itself is a special
488 programming language function compiled into a shared object and loaded
489 on demand.
490
491 To enable PL/TCL procedural language for your database you have to run
492 createlang command.
493
494 %description module-pltcl -l pl
495 Z dokumentacji PostgreSQL.
496
497 Postgres ma wsparcie dla jêzyków proceduralnych. W przypadku, kiedy
498 programista zdefiniuje procedurê wyzwalacza lub funkcjê w jêzyku
499 proceduralnym, baza danych nie ma pojêcia jak interpretowaæ tego typu
500 funkcjê. Funkcja lub procedura ta jest przekazywana do interpretera,
501 który wie jak j± wykonaæ. Interpreter jest odpowiedni±, specjaln±
502 funkcj±, która jest skompilowana w obiekt dzielony i ³adowany w razie
503 potrzeby.
504
505 Za pomoc± komendy createlang mo¿na dodaæ wsparcie dla jêzyka
506 proceduralnego PL/TCL dla swojej bazy danych.
507
508 %prep
509 %setup  -q
510 %patch0 -p1
511 %patch1 -p1
512 %patch2 -p1
513 %patch3 -p1
514 %patch4 -p1
515
516 # Erase all CVS dir
517 rm -fR `find contrib/ -type d -name CVS`
518
519 %build
520 PATH=$PATH:. ; export PATH
521 cd src
522
523 aclocal
524 autoconf
525 LDFLAGS="-s"; export LDFLAGS
526 %configure \
527 %ifarch %{ix86}
528         --with-template=linux_i386 \
529 %else
530         --with-template=linux_%{_target_cpu} \
531 %endif
532         --enable-hba \
533         --with-mulitbyte=UNICODE \
534         --enable-locale \
535         --with-odbc \
536         --with-odbcinst=%{_sysconfdir} \
537         --with-tcl \
538         --with-tk \
539         --with-python \
540         --with-x \
541         --with-perl
542
543 %{__make} OPT="$RPM_OPT_FLAGS"
544
545 cd ..
546 %{__make} all PGDOCS=unpacked -C doc
547
548 # for datetime functions
549 make -C contrib/datetime LIBDIR=%{pglibdir}
550
551
552 %install
553 rm -rf $RPM_BUILD_ROOT
554 install -d $RPM_BUILD_ROOT%{_sysconfdir}/{rc.d/init.d,sysconfig} \
555         $RPM_BUILD_ROOT/var/lib/pgsql \
556         $RPM_BUILD_ROOT%{_libdir}/pgsql
557
558 %{__make} -C src install DESTDIR=$RPM_BUILD_ROOT
559 %{__make} -C doc install DESTDIR=$RPM_BUILD_ROOT
560
561 # for datetime functions
562 %{__make} -C contrib/datetime install \
563         LIBDIR=$RPM_BUILD_ROOT%{pglibdir} SQLDIR=$RPM_BUILD_ROOT%{pgsqldir}
564
565 # Move PL/pgSQL procedural language to %{pgmoduledir}
566 ( cd $RPM_BUILD_ROOT%{_libdir}
567   mv plpgsql.so $RPM_BUILD_ROOT%{pgmoduledir}
568 )
569
570 # Move PL/TCL procedural language to %{pgmoduledir}
571 ( cd $RPM_BUILD_ROOT%{_libdir}
572   mv pltcl.so $RPM_BUILD_ROOT%{pgmoduledir}
573 )
574
575 # For Perl interface
576 ( cd $RPM_BUILD_ROOT%{perl_sitearch}/auto/Pg
577   mv .packlist .packlist.old
578   sed -e "s|$RPM_BUILD_ROOT/|/|g" -e "s|./||" < .packlist.old > .packlist
579   rm -f .packlist.old
580 )
581
582 # Move all templates/examples beneath %{_libdir}/pgsql
583 ( cd $RPM_BUILD_ROOT%{_libdir}
584   mv  *description *source *sample pgsql
585 )
586
587 install %{SOURCE1} $RPM_BUILD_ROOT/etc/rc.d/init.d/postgresql
588 install %{SOURCE3} $RPM_BUILD_ROOT/etc/sysconfig/postgresql
589
590 install -d howto
591 ( cd howto
592   tar xzf $RPM_SOURCE_DIR/pgsql-Database-HOWTO-html.tar.gz
593 )
594
595 # Install all header files. They are required
596 # by executor/spi.h and commands/trigger.h
597
598 ( cd src/include
599   cp -rf * $RPM_BUILD_ROOT%{_includedir}/pgsql
600 )
601
602 strip --strip-unneeded $RPM_BUILD_ROOT%{_libdir}/lib*.so* \
603         $RPM_BUILD_ROOT%{perl_sitearch}/auto/Pg/*.so
604
605 gzip -9nf $RPM_BUILD_ROOT%{_mandir}/man*/*
606
607 %pre
608 getgid postgres >/dev/null 2>&1 || /usr/sbin/groupadd -g 88 -r -f postgres
609 id postgres >/dev/null 2>&1 || /usr/sbin/useradd -M -o -r -u 88 \
610         -d /var/lib/pgsql -s /bin/sh -g postgres \
611         -c "PostgreSQL Server" postgres
612
613 %post
614 /sbin/chkconfig --add postgresql
615
616 if [ -r /var/lock/subsys/postmaster ]; then
617         /etc/rc.d/init.d/postgresql restart >&2
618 else
619         echo "Run \"/etc/rc.d/init.d/postgresql start\" to start postgresql server."
620 fi
621
622 %preun
623 if [ "$1" = "0" ]; then
624         if [ -f /var/lock/subsys/postmaster ]; then
625                 /etc/rc.d/init.d/postgresql stop
626         fi
627         /sbin/chkconfig --del postgresql
628 fi
629
630 %post   libs -p /sbin/ldconfig
631 %postun libs -p /sbin/ldconfig
632
633 %post   tcl -p /sbin/ldconfig
634 %postun tcl -p /sbin/ldconfig
635
636 %post   clients -p /sbin/ldconfig
637 %postun clients -p /sbin/ldconfig
638
639 %post   c++ -p /sbin/ldconfig
640 %postun c++ -p /sbin/ldconfig
641
642 %post   odbc -p /sbin/ldconfig
643 %postun odbc -p /sbin/ldconfig
644
645 %clean
646 rm -rf $RPM_BUILD_ROOT
647 rm -f /tmp/tmp_perl_info
648
649 %files doc
650 %defattr(644,root,root,755)
651 %doc doc/unpacked/*
652 %doc howto
653
654 %files
655 %defattr(644,root,root,755)
656 %doc contrib 
657 %doc doc/FAQ doc/FAQ_Linux doc/README* 
658 %doc COPYRIGHT README HISTORY doc/bug.template
659 %doc doc/*.ps.gz
660
661 %attr(754,root,root) /etc/rc.d/init.d/*
662 %attr(644,root,root) /etc/sysconfig/*
663
664 %attr(755,root,root) %{_bindir}/createdb
665 %attr(755,root,root) %{_bindir}/createuser
666 %attr(755,root,root) %{_bindir}/dropdb
667 %attr(755,root,root) %{_bindir}/dropuser
668 %attr(755,root,root) %{_bindir}/initdb
669 %attr(755,root,root) %{_bindir}/initlocation
670 %attr(755,root,root) %{_bindir}/pg_passwd
671 %attr(755,root,root) %{_bindir}/pg_version
672 %attr(755,root,root) %{_bindir}/postgres
673 %attr(755,root,root) %{_bindir}/postmaster
674 %attr(755,root,root) %{_bindir}/ipcclean
675 %attr(755,root,root) %{_bindir}/createlang
676 %attr(755,root,root) %{_bindir}/droplang
677
678 %{_mandir}/man1/createdb.1*
679 %{_mandir}/man1/createlang.1*
680 %{_mandir}/man1/createuser.1*
681 %{_mandir}/man1/dropdb.1*
682 %{_mandir}/man1/droplang.1*
683 %{_mandir}/man1/dropuser.1*
684 %{_mandir}/man1/initdb.1*
685 %{_mandir}/man1/initlocation.1*
686 %{_mandir}/man1/pg_passwd.1*
687 %{_mandir}/man1/postgres.1*
688 %{_mandir}/man1/postmaster.1*
689 %{_mandir}/man1/ipcclean.1*
690
691 %attr(750,postgres,postgres) %dir /var/lib/pgsql
692
693 %files libs
694 %defattr(644,root,root,755)
695 %attr(755,root,root) %{_libdir}/libpq.so.*.*
696 %attr(755,root,root) %{_libdir}/libecpg.so.*.*
697
698 %attr(755,root,root) %{_bindir}/pg_id
699
700 %attr(644,root,root) %{_libdir}/pgsql
701
702 %files devel
703 %defattr(644,root,root,755)
704 %attr(755,root,root) %{_libdir}/libecpg.so
705 %attr(755,root,root) %{_libdir}/libpq.so
706 %dir %{_includedir}/pgsql
707 %{_includedir}/pgsql/c.h
708 %{_includedir}/pgsql/config.h
709 %{_includedir}/pgsql/dynloader.h
710 %{_includedir}/pgsql/ecpgerrno.h
711 %{_includedir}/pgsql/ecpglib.h
712 %{_includedir}/pgsql/ecpgtype.h
713 %{_includedir}/pgsql/fmgr.h
714 %{_includedir}/pgsql/libpgeasy.h
715 %{_includedir}/pgsql/libpgtcl.h
716 %{_includedir}/pgsql/libpq-fe.h
717 %{_includedir}/pgsql/libpq-int.h
718 %{_includedir}/pgsql/miscadmin.h
719 %{_includedir}/pgsql/os.h
720 %{_includedir}/pgsql/postgres.h
721 %{_includedir}/pgsql/postgres_ext.h
722 %{_includedir}/pgsql/pqexpbuffer.h
723 %{_includedir}/pgsql/rusagestub.h
724 %{_includedir}/pgsql/sql3types.h
725 %{_includedir}/pgsql/sqlca.h
726 %{_includedir}/pgsql/strdup.h
727 %{_includedir}/pgsql/version.h
728 %{_includedir}/pgsql/access
729 %{_includedir}/pgsql/bootstrap
730 %{_includedir}/pgsql/catalog
731 %{_includedir}/pgsql/commands
732 %{_includedir}/pgsql/executor
733 %{_includedir}/pgsql/iodbc
734 %{_includedir}/pgsql/lib
735 %{_includedir}/pgsql/libpq
736 %{_includedir}/pgsql/mb
737 %{_includedir}/pgsql/nodes
738 %{_includedir}/pgsql/optimizer
739 %{_includedir}/pgsql/parser
740 %{_includedir}/pgsql/regex
741 %{_includedir}/pgsql/rewrite
742 %{_includedir}/pgsql/storage
743 %{_includedir}/pgsql/tcop
744 %{_includedir}/pgsql/utils
745 %attr(755,root,root) %{_bindir}/ecpg
746 %{_mandir}/man1/ecpg.1*
747
748 %files static
749 %defattr(644,root,root,755)
750 %{_libdir}/libecpg.a
751 %{_libdir}/libpq.a
752
753 %files clients
754 %defattr(644,root,root,755)
755 %attr(755,root,root) %{_libdir}/libec*.so.*.*
756 %attr(755,root,root) %{_libdir}/libpq*.so.*.*
757 %attr(755,root,root) %{_bindir}/pg_dump
758 %attr(755,root,root) %{_bindir}/pg_dumpall
759 %attr(755,root,root) %{_bindir}/pg_upgrade
760 %attr(755,root,root) %{_bindir}/psql
761 %attr(755,root,root) %{_bindir}/vacuumdb
762
763 %{_mandir}/man1/pg_dump.1*
764 %{_mandir}/man1/pg_dumpall.1*
765 %{_mandir}/man1/pg_upgrade.1*
766 %{_mandir}/man1/psql.1*
767 %{_mandir}/manl/*.l*
768
769 %files c++
770 %defattr(644,root,root,755)
771 %attr(755,root,root) %{_libdir}/libpq++.so.*.*
772
773 %files c++-devel
774 %defattr(644,root,root,755)
775 %attr(755,root,root) %{_libdir}/libpq++.so
776 %{_includedir}/pgsql/libpq++.h
777 %{_includedir}/pgsql/libpq++
778
779 %files c++-static
780 %defattr(644,root,root,755)
781 %{_libdir}/libpq++.a
782
783 %files perl
784 %defattr(644,root,root,755)
785 %dir %{perl_sitearch}/auto/Pg
786 %{perl_sitearch}/auto/Pg/Pg.so
787 %attr(755,root,root) %{perl_sitearch}/auto/Pg/Pg.bs
788 %{perl_sitearch}/auto/Pg/autosplit.ix
789 %{perl_sitearch}/auto/Pg/.packlist
790 %{perl_sitearch}/Pg.pm
791 %{_mandir}/man3/*
792
793 %files tcl
794 %defattr(644,root,root,755)
795 %attr(755,root,root) %{_libdir}/libpgtcl.so.*.*
796 %attr(755,root,root) %{_bindir}/pgtclsh
797 %attr(755,root,root) %{_bindir}/pgtksh
798 %attr(755,root,root) %{_bindir}/pgaccess
799
800 %files tcl-devel
801 %defattr(644,root,root,755)
802 %attr(755,root,root) %{_libdir}/libpgtcl.so
803
804 %files tcl-static
805 %defattr(644,root,root,755)
806 %{_libdir}/libpgtcl.a
807
808 %files odbc
809 %defattr(644,root,root,755)
810 %doc src/interfaces/odbc/readme.txt src/interfaces/odbc/notice.txt
811 %config(noreplace) %verify(not size mtime md5) %{_sysconfdir}/odbc*
812 %attr(755,root,root) %{_libdir}/libpsqlodbc.so.*.*
813
814 %files odbc-devel
815 %defattr(644,root,root,755)
816 %{_includedir}/pgsql/iodbc
817 %attr(755,root,root) %{_libdir}/libpsqlodbc.so
818
819 %files odbc-static
820 %defattr(644,root,root,755)
821 %attr(755,root,root) %{_libdir}/libpsqlodbc.a
822
823 %files module-datetime
824 %defattr(644,root,root,755)
825 %attr(755,root,root) %{pgmoduledir}/datetime_functions.so
826 %attr(644,root,root) %{pgsqldir}/datetime_functions.sql
827
828 %files module-plpgsql
829 %defattr(644,root,root,755)
830 %attr(755,root,root) %{pgmoduledir}/plpgsql.so
831
832 %files module-pltcl
833 %defattr(644,root,root,755)
834 %attr(755,root,root) %{pgmoduledir}/pltcl.so
This page took 2.729659 seconds and 3 git commands to generate.