Commit f3d73298 authored by Ghislain MARY's avatar Ghislain MARY
Browse files

Merge branch 'build_soci'

parents ff73b4c6 0ea63d2e
......@@ -21,20 +21,17 @@
############################################################################
cmake_minimum_required(VERSION 3.0)
project(androidsupport LANGUAGES C)
project(androidsupport LANGUAGES CXX)
include(GNUInstallDirs)
set(SUPPORT_SOURCES
"${CMAKE_ANDROID_NDK}/sources/android/support/src/musl-multibyte/wctomb.c"
"${CMAKE_ANDROID_NDK}/sources/android/support/src/iswblank.cpp"
)
add_library(support STATIC ${SUPPORT_SOURCES})
target_include_directories(support PUBLIC "${CMAKE_ANDROID_NDK}/sources/android/support/include")
if(CMAKE_C_COMPILER_ID STREQUAL "GNU")
target_compile_options(support PRIVATE "-std=c99")
endif()
install(TARGETS support
RUNTIME DESTINATION "${CMAKE_INSTALL_BINDIR}"
......@@ -42,11 +39,3 @@ install(TARGETS support
ARCHIVE DESTINATION "${CMAKE_INSTALL_LIBDIR}"
PERMISSIONS OWNER_READ OWNER_WRITE OWNER_EXECUTE GROUP_READ GROUP_EXECUTE WORLD_READ WORLD_EXECUTE
)
if(NOT CMAKE_SYSTEM_PROCESSOR STREQUAL "aarch64")
install(FILES
"${CMAKE_ANDROID_NDK}/sources/android/support/include/ctype.h"
"${CMAKE_ANDROID_NDK}/sources/android/support/include/langinfo.h"
"${CMAKE_ANDROID_NDK}/sources/android/support/include/nl_types.h"
"${CMAKE_ANDROID_NDK}/sources/android/support/include/xlocale.h"
DESTINATION "${CMAKE_INSTALL_INCLUDEDIR}")
endif()
......@@ -44,7 +44,3 @@ lcb_cmake_options(
"-DENABLE_TESTS_COMPONENT=${ENABLE_UNIT_TESTS}"
)
if(EP_bctoolbox_BUILD_METHOD STREQUAL "rpm")
set(EP_bctoolbox_CONFIGURE_COMMAND_SOURCE ${CMAKE_CURRENT_SOURCE_DIR}/builders/bctoolbox/configure.sh.rpm.cmake)
set(EP_bctoolbox_BUILD_COMMAND_SOURCE ${CMAKE_CURRENT_SOURCE_DIR}/builders/bctoolbox/build.sh.rpm.cmake)
endif()
#!/bin/sh
export RPM_TOPDIR="@LINPHONE_BUILDER_WORK_DIR@/rpmbuild"
cd @ep_build@
# create rpmbuild workdir if needed
for dir in BUILDROOT RPMS SOURCES SPECS SRPMS; do
mkdir -p "$RPM_TOPDIR/$dir"
done
if [ ! -f @ep_config_h_file@ ]
then
cmake @ep_source@ -DCMAKE_INSTALL_PREFIX=@RPM_INSTALL_PREFIX@ -DCPACK_PACKAGE_NAME=bc-bctoolbox -DCPACK_GENERATOR=RPM \
`echo "@EP_bctoolbox_CMAKE_OPTIONS@" | sed 's/;/ /g'`
make package
cp -v *.rpm "$RPM_TOPDIR/RPMS/"
fi
......@@ -26,6 +26,7 @@ lcb_git_tag("master")
lcb_external_source_paths("belr")
lcb_groupable(YES)
lcb_package_source(YES)
lcb_spec_file("belr.spec")
lcb_dependencies("bctoolbox")
lcb_cmake_options("-DENABLE_TOOLS=${ENABLE_TOOLS}")
\ No newline at end of file
lcb_cmake_options("-DENABLE_TOOLS=${ENABLE_TOOLS}")
############################################################################
# decaf.cmake
# Copyright (C) 2017 Belledonne Communications, Grenoble France
#
############################################################################
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
#
############################################################################
lcb_git_repository("git://git.linphone.org/decaf.git")
lcb_git_tag_latest("master")
lcb_git_tag("master")
lcb_external_source_paths("externals/decaf")
lcb_groupable(YES)
lcb_package_source(YES)
......@@ -20,39 +20,34 @@
#
############################################################################
set(EP_flexisip_GIT_REPOSITORY "git://git.linphone.org/flexisip" CACHE STRING "flexisip repository URL")
set(EP_flexisip_GIT_TAG_LATEST "master" CACHE STRING "flexisip tag to use when compiling latest version")
set(EP_flexisip_GIT_TAG "cc4e47496600e9b1d3d412ce6e887275c204334b" CACHE STRING "flexisip tag to use")
set(EP_flexisip_EXTERNAL_SOURCE_PATHS "<LINPHONE_BUILDER_TOP_DIR>")
set(EP_flexisip_GROUPABLE YES)
lcb_git_repository("git://git.linphone.org/flexisip")
lcb_git_tag_latest("master")
lcb_git_tag("cc4e47496600e9b1d3d412ce6e887275c204334b")
lcb_external_source_paths("<LINPHONE_BUILDER_TOP_DIR>")
lcb_groupable(YES)
set(EP_flexisip_CMAKE_OPTIONS )
set(EP_flexisip_CROSS_COMPILATION_OPTIONS
"--prefix=${CMAKE_INSTALL_PREFIX}"
"--host=${LINPHONE_BUILDER_HOST}"
)
set(EP_flexisip_CONFIG_H_FILE "flexisip.spec")
set(EP_flexisip_SPEC_FILE "flexisip.spec")
#set(EP_flexisip_CONFIG_H_FILE "flexisip.spec")
lcb_spec_file("flexisip.spec")
lcb_dependencies("sofiasip")
if (ENABLE_CONFERENCE)
if(ENABLE_CONFERENCE)
lcb_dependencies("linphone" "belr")
endif()
if (ENABLE_PRESENCE)
if(ENABLE_PRESENCE)
lcb_dependencies("bellesip")
endif()
if (ENABLE_REDIS)
lcb_dependencies("hiredis")
endif()
if(ENABLE_SOCI_BUILD)
if(ENABLE_SOCI)
lcb_dependencies("soci")
endif()
if (ENABLE_TRANSCODER)
if(ENABLE_TRANSCODER)
lcb_dependencies("ms2")
else()
lcb_dependencies("ortp")
endif()
if(ENABLE_REDIS)
lcb_dependencies("hiredis")
endif()
lcb_builder_cmake_options(flexisip
lcb_cmake_options(
"-DENABLE_TRANSCODER=${ENABLE_TRANSCODER}"
"-DENABLE_ODB=${ENABLE_ODB}"
"-DENABLE_ODBC=${ENABLE_ODBC}"
......@@ -61,7 +56,6 @@ lcb_builder_cmake_options(flexisip
"-DENABLE_PUSHNOTIFICATION=${ENABLE_PUSHNOTIFICATION}"
"-DENABLE_PRESENCE=${ENABLE_PRESENCE}"
"-DENABLE_CONFERENCE=${ENABLE_CONFERENCE}"
"-DXSDCXX_ROOT_PATH=${XSDCXX_ROOT_PATH}"
"-DENABLE_SNMP=${ENABLE_SNMP}"
"-DENABLE_DOC=${ENABLE_DOC}"
"-DENABLE_PROTOBUF=${ENABLE_PROTOBUF}"
......
......@@ -20,21 +20,14 @@
#
############################################################################
#set(hiredis_filename "v0.13.3.tar.gz")
#set(EP_hiredis_URL "https://github.com/redis/hiredis/archive/${hiredis_filename}")
#set(EP_hiredis_URL_HASH "SHA1=be6f1c50fc4d649dd2924f0afecc0a1705dbe0d3")
set(EP_hiredis_GIT_REPOSITORY "https://github.com/redis/hiredis.git" CACHE STRING "hiredis repository URL")
set(EP_hiredis_GIT_TAG "010756025e8cefd1bc66c6d4ed3b1648ef6f1f95" CACHE STRING "hiredis tag to use")
lcb_git_repository("https://github.com/redis/hiredis.git")
lcb_external_source_paths("externals/hiredis")
lcb_patch_command("COMMAND" "${CMAKE_COMMAND}" "-E" "copy" "${CMAKE_CURRENT_SOURCE_DIR}/builders/hiredis/CMakeLists.txt" "<SOURCE_DIR>")
lcb_patch_command("COMMAND" "${CMAKE_COMMAND}" "-E" "make_directory" "<SOURCE_DIR>/build/")
lcb_patch_command("COMMAND" "${CMAKE_COMMAND}" "-E" "copy" "${CMAKE_CURRENT_SOURCE_DIR}/builders/hiredis/build/CMakeLists.txt" "<SOURCE_DIR>/build/")
lcb_package_source(YES)
set(EP_hiredis_BUILD_METHOD "rpm")
lcb_use_autotools_for_rpm(YES)
lcb_dependencies(bctoolbox)
set(EP_hiredis_SPEC_FILE "hiredis.spec" )
set(EP_hiredis_CONFIG_H_FILE "${CMAKE_CURRENT_SOURCE_DIR}/builders/hiredis/${EP_hiredis_SPEC_FILE}" )
# the spec file goes into the build directory
set(EP_hiredis_PATCH_COMMAND "COMMAND" "${CMAKE_COMMAND}" "-E" "copy" ${EP_hiredis_CONFIG_H_FILE} "<BINARY_DIR>")
# Current versions of CMake cannot download over HTTPS.. we have a speficic step that uses wget to get the archive instead of
# using CMake's own downkoad facility.
set(EP_hiredis_CONFIGURE_COMMAND_SOURCE ${CMAKE_CURRENT_SOURCE_DIR}/builders/hiredis/configure.sh.cmake)
lcb_spec_file("hiredis.spec")
lcb_patch_command("COMMAND" "${CMAKE_COMMAND}" "-E" "copy" "${CMAKE_CURRENT_SOURCE_DIR}/builders/hiredis/build/hiredis.spec.cmake" "<SOURCE_DIR>/build/")
############################################################################
# CMakeLists.txt
# Copyright (C) 2017 Belledonne Communications, Grenoble France
#
############################################################################
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
#
############################################################################
cmake_minimum_required(VERSION 3.1 FATAL_ERROR)
project(hiredis LANGUAGES C VERSION 0.13.3)
option(ENABLE_SHARED "Build shared library." YES)
option(ENABLE_STATIC "Build static library." YES)
include(GNUInstallDirs)
find_package(BcToolbox 0.0.3 REQUIRED)
set(HEADER_FILES
async.h
hiredis.h
read.h
sds.h
)
set(SOURCE_FILES
async.c
hiredis.c
net.c
read.c
sds.c
)
if(ENABLE_STATIC)
add_library(hiredis-static STATIC ${SOURCE_FILES})
set_target_properties(hiredis-static PROPERTIES OUTPUT_NAME hiredis)
install(TARGETS hiredis-static
RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}
PERMISSIONS OWNER_READ OWNER_WRITE OWNER_EXECUTE GROUP_READ GROUP_EXECUTE WORLD_READ WORLD_EXECUTE
)
endif()
if(ENABLE_SHARED)
add_library(hiredis SHARED ${SOURCE_FILES})
set_target_properties(hiredis PROPERTIES VERSION "${PROJECT_VERSION_MAJOR}.${PROJECT_VERSION_MINOR}")
install(TARGETS hiredis
RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR}
LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR}
ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR}
PERMISSIONS OWNER_READ OWNER_WRITE OWNER_EXECUTE GROUP_READ GROUP_EXECUTE WORLD_READ WORLD_EXECUTE
)
endif()
install(FILES ${HEADER_FILES}
DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/hiredis
PERMISSIONS OWNER_READ OWNER_WRITE GROUP_READ WORLD_READ
)
install(DIRECTORY adapters DESTINATION ${CMAKE_INSTALL_INCLUDEDIR}/hiredis)
add_subdirectory(build)
############################################################################
# CMakeLists.txt
# Copyright (C) 2017 Belledonne Communications, Grenoble France
#
############################################################################
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
#
############################################################################
if (NOT CPACK_PACKAGE_NAME)
set(CPACK_PACKAGE_NAME "hiredis")
ENDIF()
set(CPACK_RESOURCE_FILE_LICENSE "${CMAKE_CURRENT_SOURCE_DIR}/../COPYING")
set(CPACK_PACKAGE_VERSION_MAJOR ${PROJECT_VERSION_MAJOR})
set(CPACK_PACKAGE_VERSION_MINOR ${PROJECT_VERSION_MINOR})
set(CPACK_PACKAGE_VERSION_PATCH ${PROJECT_VERSION_PATCH})
set(CPACK_PACKAGE_FILE_NAME ${CPACK_PACKAGE_NAME}-${PROJECT_VERSION})
set(CPACK_SOURCE_GENERATOR "TGZ")
set(CPACK_SOURCE_IGNORE_FILES
"${CMAKE_BINARY_DIR}"
"^${PROJECT_SOURCE_DIR}/.git*"
)
bc_project_build_version(${PROJECT_VERSION} PROJECT_VERSION_BUILD)
if(PROJECT_VERSION_BUILD)
set(CPACK_PACKAGE_FILE_NAME "${CPACK_PACKAGE_FILE_NAME}-${PROJECT_VERSION_BUILD}")
endif()
message("-- Package file name is ${CPACK_PACKAGE_FILE_NAME}" )
set(CPACK_SOURCE_PACKAGE_FILE_NAME ${CPACK_PACKAGE_FILE_NAME})
configure_file(${CMAKE_CURRENT_SOURCE_DIR}/hiredis.spec.cmake ${CMAKE_CURRENT_SOURCE_DIR}/../hiredis.spec)
include(CPack)
%define pkg_name hiredis
%define finalpkg_name %{?_with_bc:bc-%{pkg_name}}%{!?_with_bc:%{pkg_name}}
%define pkg_name %{?_with_bc:bc-hiredis}%{!?_with_bc:hiredis}
%{?_with_bc: %define _prefix /opt/belledonne-communications}
# re-define some directories for older RPMBuild versions which don't. This messes up the doc/ dir
# taken from https://fedoraproject.org/wiki/Packaging:RPMMacros?rd=Packaging/RPMMacros
......@@ -9,14 +8,18 @@
%define _datadir %{_datarootdir}
%define _docdir %{_datadir}/doc
%define build_number @PROJECT_VERSION_BUILD@
%if %{build_number}
%define build_number_ext -%{build_number}
%endif
Name: %{finalpkg_name}
Version: 0.13.3
Release: 3%{?dist}
Name: %{pkg_name}
Version: @PROJECT_VERSION@
Release: %{build_number}%{?dist}
Summary: Minimalistic C client library for Redis
License: BSD
URL: https://github.com/redis/hiredis
Source0: v%{version}.tar.gz
Source0: %{name}-%{version}%{?build_number_ext}.tar.gz
%description
Hiredis is a minimalistic C client library for the Redis database.
......@@ -29,19 +32,26 @@ Requires: %{name}%{?_isa} = %{version}-%{release}
This package contains libraries and header files for
developing applications that use %{name}.
%if 0%{?rhel} && 0%{?rhel} <= 7
%global cmake_name cmake3
%define ctest_name ctest3
%else
%global cmake_name cmake
%define ctest_name ctest
%endif
%prep
%setup -q -n hiredis-%{version}
%setup -q -n %{name}-%{version}%{?build_number_ext}
%build
make %{?_smp_mflags} OPTIMIZATION="%{optflags}"
%{expand:%%%cmake_name} . -DCMAKE_INSTALL_LIBDIR:PATH=%{_libdir} -DCMAKE_PREFIX_PATH:PATH=%{_prefix}
make %{?_smp_mflags}
%install
make install PREFIX=%{buildroot}%{_prefix} INSTALL_LIBRARY_PATH=%{buildroot}%{_libdir}
mkdir -p %{buildroot}%{_bindir}
cp hiredis-test %{buildroot}%{_bindir}
make install DESTDIR=%{buildroot}
find %{buildroot} -name '*.a' -delete -print
%clean
rm -rf $RPM_BUILD_ROOT
%post -p /sbin/ldconfig
......@@ -49,13 +59,12 @@ find %{buildroot} -name '*.a' -delete -print
%files
%doc COPYING
%{_bindir}/hiredis-test
%{_libdir}/libhiredis.so.0.13
%{_libdir}/pkgconfig/hiredis.pc
%files devel
%doc README.md
%{_includedir}/%{pkg_name}/
%{_includedir}/hiredis/
%{_libdir}/libhiredis.a
%{_libdir}/libhiredis.so
%changelog
......
#!/bin/sh
export RPM_TOPDIR="@LINPHONE_BUILDER_WORK_DIR@/rpmbuild/SOURCES/"
export HIREDIS_TARBALL_URL="https://github.com/redis/hiredis/archive/v0.13.3.tar.gz"
mkdir -p "$RPM_TOPDIR"
echo "be6f1c50fc4d649dd2924f0afecc0a1705dbe0d3 v0.13.3.tar.gz" > "$RPM_TOPDIR/v0.13.3.tar.gz.sha1"
wget "$HIREDIS_TARBALL_URL" -P "$RPM_TOPDIR"
# check Sha1
cd "$RPM_TOPDIR" && sha1sum -c "$RPM_TOPDIR/v0.13.3.tar.gz.sha1"
############################################################################
# lime.cmake
# Copyright (C) 2017 Belledonne Communications, Grenoble France
#
############################################################################
#
# This program is free software; you can redistribute it and/or
# modify it under the terms of the GNU General Public License
# as published by the Free Software Foundation; either version 2
# of the License, or (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program; if not, write to the Free Software
# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
#
############################################################################
lcb_git_repository("gitosis@git.linphone.org:lime.git")
lcb_git_tag_latest("master")
lcb_git_tag("master")
lcb_external_source_paths("lime")
lcb_groupable(YES)
lcb_package_source(YES)
lcb_dependencies("decaf")
......@@ -26,8 +26,10 @@ lcb_git_tag("3.10.0")
lcb_external_source_paths("linphone")
lcb_groupable(YES)
lcb_package_source(YES)
lcb_spec_file("liblinphone.spec")
lcb_rpmbuild_name("liblinphone")
lcb_dependencies("bctoolbox" "bellesip" "ortp" "ms2" "belr")
lcb_dependencies("bctoolbox" "bellesip" "ortp" "ms2" "belr" "libxsd" "soci")
if(LINPHONE_BUILDER_BUILD_DEPENDENCIES AND NOT APPLE)
# Do not build sqlite3, xml2 and zlib on Apple systems (Mac OS X and iOS), they are provided by the system
lcb_dependencies("sqlite3" "xml2")
......@@ -42,6 +44,9 @@ if(ENABLE_VCARD)
lcb_dependencies("belcard")
endif()
if(ENABLE_LIME_X3DH)
lcb_dependencies("lime")
endif()
lcb_cmake_options(
"-DENABLE_GTK_UI=${ENABLE_GTK_UI}"
"-DENABLE_VIDEO=${ENABLE_VIDEO}"
......
......@@ -22,12 +22,15 @@
lcb_git_repository("git://git.linphone.org/soci.git")
lcb_external_source_paths("externals/soci")
lcb_dependencies("sqlite3")
if(LINPHONE_BUILDER_BUILD_DEPENDENCIES AND NOT APPLE)
# Do not build sqlite3 on Apple systems (Mac OS X and iOS), they are provided by the system
lcb_dependencies("sqlite3")
endif()
lcb_cmake_options(
"-DSOCI_TESTS=NO"
"-DSOCI_EMPTY=NO"
"-DWITH_DB2=NO"
"-DWITH_FIREBIRD=NO"
"-DWITH_MYSQL=YES"
......@@ -36,6 +39,7 @@ lcb_cmake_options(
"-DWITH_POSTGRESQL=NO"
"-DWITH_SQLITE3=YES"
)
lcb_package_source(YES)
lcb_spec_file("soci.spec")
lcb_linking_type("-DSOCI_SHARED=YES" "-DSOCI_STATIC=NO")
lcb_use_autotools_for_rpm(YES)
#
##
# Default values are --with empty --with sqlite3 --with mysql --with postgresql
# --with odbc --without oracle
# Note that, for Oracle, when enabled, the following options should
# also be given:
# --with-oracle-include=/opt/oracle/app/oracle/product/11.1.0/db_1/rdbms/public
# --with-oracle-lib=/opt/oracle/app/oracle/product/11.1.0/db_1/lib
# If the macros are defined, redefine them with the correct compilation flags.
%bcond_without empty
%bcond_without sqlite3
%bcond_without mysql
%bcond_without postgresql
%bcond_without odbc
%bcond_with oracle
%bcond_with firebird
%define _default_oracle_dir /opt/oracle/app/oracle/product/11.1.0/db_1
%{!?_with_oracle_incdir: %define _with_oracle_incdir --with-oracle-include=%{_default_oracle_dir}/rdbms/public}
%{!?_with_oracle_libdir: %define _with_oracle_libdir --with-oracle-lib=%{_default_oracle_dir}/lib}
#
##
#
Name: soci
Version: 3.2.3
Release: 1%{?dist}
Summary: The database access library for C++ programmers
Group: System Environment/Libraries
License: Boost
URL: http://%{name}.sourceforge.net
Source0: http://downloads.sourceforge.net/%{name}/%{name}-%{version}.tar.gz
BuildRoot: %(mktemp -ud %{_tmppath}/%{name}-%{version}-%{release}-XXXXXX)
Patch: %{soci_patch}
BuildRequires: cmake
BuildRequires: boost-devel
%description
%{name} is a C++ database access library that provides the
illusion of embedding SQL in regular C++ code, staying entirely within
the C++ standard.
%{?with_sqlite3:%package sqlite3
Summary: SQLite3 back-end for %{name}
Group: System Environment/Libraries
Requires: %{name}%{?_isa} = %{version}-%{release}
BuildRequires: sqlite-devel
%description sqlite3
This package contains the SQLite3 back-end for %{name}, i.e.,
dynamic library specific to the SQLite3 database. If you would like to
use %{name} in your programs with SQLite3, you will need to
install %{name}-sqlite3.}
%{?with_mysql:%package mysql
Summary: MySQL back-end for %{name}
Group: System Environment/Libraries
Requires: %{name}%{?_isa} = %{version}-%{release}
BuildRequires: mysql-devel
%description mysql
This package contains the MySQL back-end for %{name}, i.e.,
dynamic library specific to the MySQL database. If you would like to
use %{name} in your programs with MySQL, you will need to
install %{name}-mysql.}
%{?with_postgresql:%package postgresql
Summary: PostGreSQL back-end for %{name}
Group: System Environment/Libraries
Requires: %{name}%{?_isa} = %{version}-%{release}
BuildRequires: postgresql-devel
%description postgresql
This package contains the PostGreSQL back-end for %{name}, i.e.,
dynamic library specific to the PostGreSQL database. If you would like
to use %{name} in your programs with PostGreSQL, you will need to
install %{name}-postgresql.}
%{?with_odbc:%package odbc
Summary: ODBC back-end for %{name}
Group: System Environment/Libraries
Requires: %{name}%{?_isa} = %{version}-%{release}
BuildRequires: unixODBC-devel
%description odbc
This package contains the ODBC back-end for %{name}, i.e.,
dynamic library specific to the ODBC connectors. If you would like to
use %{name} in your programs with ODBC, you will need to
install %{name}-odbc.}
%{?with_oracle:%package oracle
Summary: Oracle back-end for %{name}
Group: System Environment/Libraries
Requires: %{name}%{?_isa} = %{version}-%{release}
%description oracle
This package contains the Oracle back-end for %{name}, i.e.,
dynamic library specific to the Oracle database. If you would like to
use %{name} in your programs with Oracle, you will need to install
%{name}-oracle.}
%package devel
Summary: Header files, libraries and development documentation for %{name}
Group: Development/Libraries
Requires: %{name}%{?_isa} = %{version}-%{release}
Requires: pkgconfig