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