~drizzle-trunk/drizzle/development

1 by brian
clean slate
1
#
2
# MySQL-shared-compat.spec
3
#
4
# RPM build instructions to create a "meta" package that includes two
5
# versions of the MySQL shared libraries (for compatibility with
6
# distributions that ship older versions of MySQL and do not provide a
7
# separate "MySQL-shared" package. This spec file simply repackages two
8
# already existing MySQL-shared RPMs into a single package.
9
# 
10
# Copyright (C) 2003 MySQL AB
11
# 
12
# This program is free software; you can redistribute it and/or modify it
13
# under the terms of the GNU General Public License as published by the Free
14
# Software Foundation; version 2 of the License.
15
#
16
# This program is distributed in the hope that it will be useful, but
17
# WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
18
# or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
19
# for more details.
20
#
21
# You should have received a copy of the GNU General Public License along
22
# with this program; if not, write to the Free Software Foundation, Inc., 59
23
# Temple Place, Suite 330, Boston, MA  02111-1307  USA
24
25
# For 5.0 and up, this is needed because of "libndbclient".
26
%define _unpackaged_files_terminate_build 0
27
28
#
29
# Change this to match the version of the shared libs you want to include
30
#
31
%define version50 @MYSQL_NO_DASH_VERSION@
32
%define version41 4.1.17
33
%define version40 4.0.26
34
%define version3 3.23.58
35
36
Name:         MySQL-shared-compat
37
Packager:     MySQL Product Engineering team <build@mysql.com>
38
Vendor:       MySQL AB
39
License:      GPL
40
Group:        Applications/Databases
41
URL:          http://www.mysql.com/
42
Autoreqprov:  on
43
Version:      %{version50}
44
Release:      0
45
BuildRoot:    %{_tmppath}/%{name}-%{version}-build
46
Obsoletes:    MySQL-shared, mysql-shared
47
Provides:     MySQL-shared
48
Summary:      MySQL shared client libraries for MySQL %{version}, %{version41}, %{version40} and %{version3}
49
# We simply use the "MySQL-shared" subpackages as input sources instead of
50
# rebuilding all from source
51
Source0:      MySQL-shared-%{version50}-0.%{_arch}.rpm
52
Source1:      MySQL-shared-%{version41}-1.%{_arch}.rpm
53
Source2:      MySQL-shared-%{version40}-0.%{_arch}.rpm
54
Source3:      MySQL-shared-%{version3}-1.%{_arch}.rpm
55
# No need to include the RPMs once more - they can be downloaded seperately
56
# if you want to rebuild this package
57
NoSource:     0
58
NoSource:     1
59
NoSource:     2
60
NoSource:     3
61
BuildRoot:    %{_tmppath}/%{name}-%{version}-build
62
63
%description
64
This package includes the shared libraries for MySQL %{version3},
65
MySQL %{version40}, %{version41} as well as MySQL %{version50}.
66
Install this package instead of "MySQL-shared", if you have applications
67
installed that are dynamically linked against older versions of the MySQL
68
client library but you want to upgrade to MySQL %{version} without breaking the
69
library dependencies.
70
71
%install
72
[ "$RPM_BUILD_ROOT" != "/" ] && [ -d $RPM_BUILD_ROOT ] && rm -rf $RPM_BUILD_ROOT;
73
mkdir -p $RPM_BUILD_ROOT
74
cd $RPM_BUILD_ROOT
75
rpm2cpio %{SOURCE0} | cpio -iv --make-directories
76
rpm2cpio %{SOURCE1} | cpio -iv --make-directories
77
rpm2cpio %{SOURCE2} | cpio -iv --make-directories
78
rpm2cpio %{SOURCE3} | cpio -iv --make-directories
79
/sbin/ldconfig -n $RPM_BUILD_ROOT%{_libdir}
80
81
%clean
82
[ "$RPM_BUILD_ROOT" != "/" ] && [ -d $RPM_BUILD_ROOT ] && rm -rf $RPM_BUILD_ROOT;
83
84
%files
85
%defattr(-, root, root)
86
%{_libdir}/libmysqlclient*