File mysql-connector-cpp.spec of Package mysql-connector-cpp
#
# spec file for package mysql-connector-cpp (Version 1.0.5)
#
# Copyright (c) 2009 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via http://bugs.opensuse.org/
#
# norootforbuild
Name: mysql-connector-cpp
Summary: MySQL Connector/C++: Standardized database driver for C++ development
Version: 1.0.5
Release: 2
Group: Development/Libraries
License: GPL
Url: http://dev.mysql.com/downloads/connector/
# http://dev.mysql.com/get/Downloads/Connector-C%2B%2B/mysql-connector-c%2B%2B-%{version}.tar.gz
Source: mysql-connector-c++-%{version}.tar.bz2
# PATCH-SUSE-INTEGRATION - mysql-connector-cpp-1.0.4-beta-cmake-paths-fix.patch [] mhrusecky@suse.cz -- adjust some default paths
Patch0: mysql-connector-cpp-1.0.4-beta-cmake-paths-fix.patch
# PATCH-UPSTREAM-FIX - mysql-connector-cpp-1.0.4-beta-gcc44.patch [ upstream#44931 ] mhrusecky@suse.cz -- adding missing includes
# http://bugs.mysql.com/44931
Patch1: mysql-connector-cpp-1.0.5-gcc44.patch
BuildRoot: %{_tmppath}/%{name}-%{version}-build
BuildRequires: cmake gcc-c++ libmysqlclient-devel
%description
MySQL Connector/C++ is a MySQL database connector for C++ development. The
MySQL driver for C++ can be used to connect to MySQL from C++ applications. The
driver mimics the JDBC 4.0 API. It implements a significant subset of JDBC 4.0.
The Driver for C++ is designed to work best with MySQL 5.1 or later. Note - its
full functionality is not available when connecting to MySQL 5.0. You cannot
connect to MySQL 4.1 or earlier.
Using MySQL Connector/C++ instead of the MySQL C API (MySQL Client Library)
offers the following advantages for C++ users:
* Convenience of pure C++ - no C function calls
* Support of a well designed API - JDBC 4.0
* Support of a commonly known and well documented API - JDBC 4.0
* Support of the object oriented programming paradigma
* Shorter development times
%package -n libmysqlcppconn-devel
License: GPL
Requires: libmysqlcppconn1 = %{version}
Group: Development/Libraries/C and C++
Summary: Development files for MySQL Connector/C++
%description -n libmysqlcppconn-devel
MySQL Connector/C++ is a MySQL database connector for C++ development. The
MySQL driver for C++ can be used to connect to MySQL from C++ applications. The
driver mimics the JDBC 4.0 API. It implements a significant subset of JDBC 4.0.
The Driver for C++ is designed to work best with MySQL 5.1 or later. Note - its
full functionality is not available when connecting to MySQL 5.0. You cannot
connect to MySQL 4.1 or earlier.
Using MySQL Connector/C++ instead of the MySQL C API (MySQL Client Library)
offers the following advantages for C++ users:
* Convenience of pure C++ - no C function calls
* Support of a well designed API - JDBC 4.0
* Support of a commonly known and well documented API - JDBC 4.0
* Support of the object oriented programming paradigma
* Shorter development times
%package -n libmysqlcppconn1
License: GPL
Group: Development/Libraries/C and C++
Summary: MySQL Connector/C++: Standardized database driver for C++ development
%description -n libmysqlcppconn1
MySQL Connector/C++ is a MySQL database connector for C++ development. The
MySQL driver for C++ can be used to connect to MySQL from C++ applications. The
driver mimics the JDBC 4.0 API. It implements a significant subset of JDBC 4.0.
The Driver for C++ is designed to work best with MySQL 5.1 or later. Note - its
full functionality is not available when connecting to MySQL 5.0. You cannot
connect to MySQL 4.1 or earlier.
Using MySQL Connector/C++ instead of the MySQL C API (MySQL Client Library)
offers the following advantages for C++ users:
* Convenience of pure C++ - no C function calls
* Support of a well designed API - JDBC 4.0
* Support of a commonly known and well documented API - JDBC 4.0
* Support of the object oriented programming paradigma
* Shorter development times
%prep
%setup -n mysql-connector-c++-%{version}
%patch0 -p1
%patch1
%build
cmake . -DCMAKE_INSTALL_PREFIX=/usr -DCMAKE_INSTALL_LIB_DIR=`basename %{_libdir}`
make %{?jobs:-j%jobs} LIBDIR=%{_libdir}
%install
%makeinstall
rm -f %{buildroot}%{_libdir}/libmysqlcppconn-static.a
rm -f %{buildroot}/usr/[A-Z]*
%clean
rm -rf %{buildroot}
%post -n libmysqlcppconn1 -p /sbin/ldconfig
%postun -n libmysqlcppconn1 -p /sbin/ldconfig
%files -n libmysqlcppconn-devel
%defattr(-,root,root)
%doc README ANNOUNCEMENT COPYING CHANGES
/usr/include/mysql-connector
%{_libdir}/*.so
%files -n libmysqlcppconn1
%defattr(-,root,root)
%{_libdir}/*.so.*
%changelog