calamares-3.1.0.ebuild 2.0 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283
  1. # Copyright 1999-2017 Gentoo Foundation
  2. # Distributed under the terms of the GNU General Public License v2
  3. EAPI=6
  4. PYTHON_COMPAT=( python{3_4,3_5} )
  5. inherit kde5 python-r1
  6. DESCRIPTION="Distribution-independent installer framework"
  7. HOMEPAGE="http://calamares.io"
  8. if [[ ${KDE_BUILD_TYPE} == live ]] ; then
  9. EGIT_REPO_URI="git://github.com/${PN}/${PN}"
  10. else
  11. inherit versionator
  12. MAJOR_PV=$(get_version_component_range 1-2)
  13. SRC_URI="https://github.com/${PN}/${PN}/releases/download/v${MAJOR_PV}/${P}.tar.gz"
  14. KEYWORDS="~amd64"
  15. fi
  16. LICENSE="GPL-3"
  17. IUSE="+networkmanager pythonqt +upower"
  18. REQUIRED_USE="${PYTHON_REQUIRED_USE}"
  19. DEPEND="${PYTHON_DEPS}
  20. $(add_frameworks_dep kcoreaddons)
  21. $(add_frameworks_dep kparts)
  22. $(add_frameworks_dep kservice)
  23. $(add_qt_dep qtdbus)
  24. $(add_qt_dep qtdeclarative)
  25. $(add_qt_dep qtgui)
  26. $(add_qt_dep qtnetwork)
  27. $(add_qt_dep qtsvg)
  28. $(add_qt_dep qtwebengine 'widgets')
  29. $(add_qt_dep qtwidgets)
  30. >=dev-cpp/yaml-cpp-0.5.1
  31. >=dev-libs/boost-1.55:=[${PYTHON_USEDEP}]
  32. sys-apps/dbus
  33. sys-apps/dmidecode
  34. sys-auth/polkit-qt[qt5]
  35. >=sys-libs/kpmcore-3.0.2:5=
  36. pythonqt? ( >=dev-python/PythonQt-3.1:=[${PYTHON_USEDEP}] )
  37. "
  38. RDEPEND="${DEPEND}
  39. app-admin/sudo
  40. dev-libs/libatasmart
  41. net-misc/rsync
  42. >=sys-block/parted-3.0
  43. || ( sys-boot/grub:2 sys-boot/systemd-boot )
  44. sys-boot/os-prober
  45. sys-fs/squashfs-tools
  46. virtual/udev
  47. networkmanager? ( net-misc/networkmanager )
  48. upower? ( sys-power/upower )
  49. "
  50. src_prepare() {
  51. python_setup
  52. export PYTHON_INCLUDE_DIRS="$(python_get_includedir)" \
  53. PYTHON_INCLUDE_PATH="$(python_get_library_path)"\
  54. PYTHON_CFLAGS="$(python_get_CFLAGS)"\
  55. PYTHON_LIBS="$(python_get_LIBS)"
  56. eapply_user
  57. }
  58. src_configure() {
  59. local mycmakeargs=(
  60. -DWEBVIEW_FORCE_WEBKIT=OFF
  61. -DWITH_PYTHONQT=$(usex pythonqt)
  62. )
  63. kde5_src_configure
  64. sed -i -e 's:pkexec /usr/bin/calamares:calamares-pkexec:' "${S}"/calamares.desktop
  65. sed -i -e 's:Icon=calamares:Icon=drive-harddisk:' "${S}"/calamares.desktop
  66. }
  67. src_install() {
  68. kde5_src_install
  69. dobin "${FILESDIR}"/calamares-pkexec
  70. }