hwloc-1.9.ebuild 1.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273
  1. # Copyright 1999-2017 Gentoo Foundation
  2. # Distributed under the terms of the GNU General Public License v2
  3. EAPI=5
  4. inherit flag-o-matic cuda autotools-utils multilib versionator
  5. MY_PV=v$(get_version_component_range 1-2)
  6. DESCRIPTION="displays the hardware topology in convenient formats"
  7. HOMEPAGE="http://www.open-mpi.org/projects/hwloc/"
  8. SRC_URI="http://www.open-mpi.org/software/${PN}/${MY_PV}/downloads/${P}.tar.bz2"
  9. LICENSE="BSD"
  10. SLOT="0/5"
  11. KEYWORDS="~alpha ~amd64 ~hppa ~ia64 ~ppc ~ppc64 ~sparc ~x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux"
  12. IUSE="cairo cuda debug gl +numa opencl +pci plugins svg static-libs xml X"
  13. # TODO opencl only works with AMD so no virtual
  14. RDEPEND="sys-libs/ncurses
  15. cairo? ( x11-libs/cairo[X?,svg?] )
  16. cuda? ( dev-util/nvidia-cuda-toolkit )
  17. gl? ( || ( x11-drivers/nvidia-drivers[static-libs,tools] media-video/nvidia-settings ) )
  18. opencl? ( x11-drivers/ati-drivers )
  19. pci? (
  20. sys-apps/pciutils
  21. x11-libs/libpciaccess
  22. )
  23. plugins? ( sys-devel/libtool )
  24. numa? ( sys-process/numactl )
  25. xml? ( dev-libs/libxml2 )"
  26. DEPEND="${RDEPEND}
  27. virtual/pkgconfig"
  28. DOCS=( AUTHORS NEWS README VERSION )
  29. PATCHES=( "${FILESDIR}/${PN}-1.8.1-gl.patch" )
  30. AUTOTOOLS_AUTORECONF=1
  31. src_prepare() {
  32. if use cuda ; then
  33. append-cflags -I/opt/cuda/include
  34. append-cppflags -I/opt/cuda/include
  35. append-ldflags -L/opt/cuda/$(get_libdir)
  36. fi
  37. autotools-utils_src_prepare
  38. }
  39. src_configure() {
  40. export HWLOC_PKG_CONFIG=$(tc-getPKG_CONFIG) #393467
  41. local myeconfargs=(
  42. --disable-silent-rules
  43. --docdir="${EPREFIX}"/usr/share/doc/${PF}
  44. $(use_enable cairo)
  45. $(use_enable cuda)
  46. $(use_enable debug)
  47. $(use_enable gl)
  48. $(use_enable opencl)
  49. $(use_enable pci)
  50. $(use_enable pci libpci)
  51. $(use_enable plugins)
  52. $(use_enable numa libnuma)
  53. $(use_enable xml libxml2)
  54. $(use_with X x)
  55. )
  56. autotools-utils_src_configure
  57. }
  58. src_install() {
  59. autotools-utils_src_install
  60. }