libiodbc-3.52.8-r2.ebuild 1.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768
  1. # Copyright 1999-2015 Gentoo Foundation
  2. # Distributed under the terms of the GNU General Public License v2
  3. EAPI="5"
  4. inherit autotools eutils multilib-minimal
  5. MY_PN="iODBC"
  6. DESCRIPTION="ODBC Interface for Linux"
  7. HOMEPAGE="http://www.iodbc.org/"
  8. SRC_URI="https://github.com/openlink/${MY_PN}/archive/v${PV}.zip -> ${P}.zip"
  9. KEYWORDS="alpha amd64 arm hppa ia64 ~mips ppc ppc64 s390 sh sparc x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~ppc-macos"
  10. LICENSE="|| ( LGPL-2 BSD )"
  11. SLOT="0"
  12. IUSE="gtk"
  13. RDEPEND="gtk? ( x11-libs/gtk+:2[${MULTILIB_USEDEP}] )"
  14. DEPEND="${RDEPEND}"
  15. DOCS="AUTHORS ChangeLog NEWS README"
  16. S="${WORKDIR}/${MY_PN}-${PV}"
  17. MULTILIB_CHOST_TOOLS=(
  18. /usr/bin/iodbc-config
  19. )
  20. src_prepare() {
  21. sed -i.orig \
  22. -e '/^cd "$PREFIX"/,/^esac/d' \
  23. iodbc/install_libodbc.sh || die "sed failed"
  24. epatch \
  25. "${FILESDIR}"/libiodbc-3.52.7-debian_bug501100.patch \
  26. "${FILESDIR}"/libiodbc-3.52.7-debian_bug508480.patch \
  27. "${FILESDIR}"/libiodbc-3.52.7-gtk.patch \
  28. "${FILESDIR}"/libiodbc-3.52.7-multilib.patch \
  29. "${FILESDIR}"/libiodbc-3.52.7-unicode_includes.patch \
  30. "${FILESDIR}"/libiodbc-3.52.8-gtk-parallel-make.patch \
  31. "${FILESDIR}"/libiodbc-3.52.8-runtime-failures.patch \
  32. "${FILESDIR}"/fix-runpaths.patch
  33. chmod -x include/*.h || die
  34. eautoreconf
  35. }
  36. multilib_src_configure() {
  37. ECONF_SOURCE=${S} \
  38. econf \
  39. --disable-static \
  40. --enable-odbc3 \
  41. --enable-pthreads \
  42. --with-layout=gentoo \
  43. --with-iodbc-inidir=yes \
  44. $(use_enable gtk gui)
  45. }
  46. multilib_src_install_all() {
  47. einstalldocs
  48. prune_libtool_files
  49. # Install lintian overrides
  50. insinto /usr/share/lintian/overrides
  51. newins debian/iodbc.lintian-overrides iodbc
  52. newins debian/libiodbc2.lintian-overrides libiodbc2
  53. }