]> git.pld-linux.org Git - packages/xtrabackup.git/blob - xtrabackup.spec
- up to 2.4.12
[packages/xtrabackup.git] / xtrabackup.spec
1 # NOTES
2 # - build instructions: http://www.percona.com/doc/percona-xtrabackup/2.2/installation/compiling_xtrabackup.html
3 Summary:        XtraBackup online backup for MySQL / InnoDB
4 Name:           xtrabackup
5 Version:        2.4.12
6 Release:        1
7 License:        GPL v2
8 Group:          Applications/Databases
9 Source0:        https://www.percona.com/downloads/XtraBackup/Percona-XtraBackup-%{version}/source/tarball/percona-%{name}-%{version}.tar.gz
10 # Source0-md5:  c086206421a77f7c1ad28771a75cf396
11 Source1:        http://downloads.sourceforge.net/boost/boost_1_59_0.tar.bz2
12 # Source1-md5:  6aa9a5c6a4ca1016edd0ed1178e3cb87
13 Patch0: jsmn.patch
14 URL:            http://www.percona.com/doc/percona-xtrabackup/
15 BuildRequires:  bash
16 BuildRequires:  cmake >= 2.6
17 BuildRequires:  acl-devel
18 BuildRequires:  curl-devel
19 BuildRequires:  expat-devel
20 BuildRequires:  jsmn-devel
21 BuildRequires:  gnupg
22 BuildRequires:  libaio-devel
23 BuildRequires:  libarchive-devel
24 BuildRequires:  bison
25 BuildRequires:  libev-devel
26 BuildRequires:  libgcrypt-devel
27 BuildRequires:  libstdc++-devel
28 BuildRequires:  libxml2-devel
29 BuildRequires:  zlib-devel
30 BuildRequires:  ncurses-devel >= 4.2
31 BuildRequires:  python-modules
32 BuildRequires:  readline-devel
33 BuildRequires:  xxd
34 BuildRequires:  sphinx-pdg
35 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
36
37 %description
38 Percona XtraBackup is an open-source hot backup utility for
39 MySQL-based servers that doesn't lock your database during the backup.
40
41 It can back up data from InnoDB, XtraDB, and MyISAM tables on MySQL
42 5.1, 5.5 and 5.6 servers, as well as Percona Server with XtraDB.
43
44 Percona XtraBackup is a combination of the xtrabackup C program, and
45 the innobackupex Perl script. The xtrabackup program copies and
46 manipulates InnoDB and XtraDB data files, and the Perl script enables
47 enhanced functionality, such as interacting with a running MySQL
48 server and backing up MyISAM tables.
49
50 %prep
51 %setup -q -n percona-%{name}-%{version} -a1
52 %patch0 -p1
53
54 # use system package
55 mv storage/innobase/xtrabackup/src/jsmn .
56 mv zlib zlib.dist
57
58 %build
59 install -d build
60 cd build
61 %cmake \
62         -DBUILD_CONFIG=xtrabackup_release \
63         -DCMAKE_BUILD_TYPE=%{!?debug:RelWithDebInfo}%{?debug:Debug} \
64         -DCMAKE_C_FLAGS_RELWITHDEBINFO="%{rpmcflags} -DNDEBUG -fno-omit-frame-pointer -fno-strict-aliasing" \
65         -DCMAKE_CXX_FLAGS_RELWITHDEBINFO="%{rpmcxxflags} -DNDEBUG -fno-omit-frame-pointer -fno-strict-aliasing" \
66         -DENABLE_DTRACE=OFF \
67         -DMYSQL_UNIX_ADDR=/var/lib/mysql/mysql.sock \
68         -DWITH_PIC=ON \
69         -DWITH_READLINE=system \
70         -DWITH_ZLIB=system \
71         -DWITH_SSL=system \
72         -DWITH_BOOST="$(pwd)/$(ls -1d ../boost_*)" \
73         ..
74
75 %{__make}
76
77 %install
78 rm -rf $RPM_BUILD_ROOT
79 %{__make} -C build install \
80         DESTDIR=$RPM_BUILD_ROOT
81
82 # TODO: find fix in make or cmake rules
83 install -d $RPM_BUILD_ROOT%{_mandir}
84 b=$(readlink -f %{_builddir})
85 mv $RPM_BUILD_ROOT$b/percona-xtrabackup-%{version}/build/man/man1 $RPM_BUILD_ROOT%{_mandir}
86
87 %{__rm} -r $RPM_BUILD_ROOT%{_prefix}/xtrabackup-test
88
89 %clean
90 rm -rf $RPM_BUILD_ROOT
91
92 %files
93 %defattr(644,root,root,755)
94 %attr(755,root,root) %{_bindir}/innobackupex
95 %attr(755,root,root) %{_bindir}/xbcloud
96 %attr(755,root,root) %{_bindir}/xbcloud_osenv
97 %attr(755,root,root) %{_bindir}/xbcrypt
98 %attr(755,root,root) %{_bindir}/xbstream
99 %attr(755,root,root) %{_bindir}/xtrabackup
100 %{_mandir}/man1/innobackupex.1*
101 %{_mandir}/man1/xbcrypt.1*
102 %{_mandir}/man1/xbstream.1*
103 %{_mandir}/man1/xtrabackup.1*
This page took 0.091648 seconds and 3 git commands to generate.