photivo-0_pre20121212.ebuild 1.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869
  1. # Copyright 1999-2013 Gentoo Foundation
  2. # Distributed under the terms of the GNU General Public License v2
  3. EAPI=4
  4. inherit qt4-r2
  5. DESCRIPTION="Photo processor for RAW and Bitmap images"
  6. HOMEPAGE="http://www.photivo.org"
  7. SRC_URI="https://dev.gentoo.org/~hwoarang/distfiles/${P}.tar.gz"
  8. LICENSE="GPL-3"
  9. SLOT="0"
  10. KEYWORDS="~amd64 ~x86"
  11. IUSE="gimp"
  12. RDEPEND="dev-qt/qtcore:4
  13. dev-qt/qtgui:4
  14. virtual/jpeg
  15. media-libs/tiff
  16. media-libs/libpng
  17. media-gfx/exiv2
  18. media-libs/lcms:2
  19. media-libs/lensfun
  20. sci-libs/fftw:3.0
  21. media-libs/liblqr
  22. media-gfx/graphicsmagick[q16,-lcms]
  23. media-gfx/greycstoration[lapack]
  24. virtual/lapack
  25. media-libs/cimg
  26. gimp? ( media-gfx/gimp )"
  27. DEPEND="${RDEPEND}"
  28. S=${WORKDIR}/${PN}-${PV/0_pre/}
  29. src_prepare() {
  30. # remove ccache dependency
  31. local File
  32. for File in $(find "${S}" -type f); do
  33. if grep -sq ccache ${File}; then
  34. sed -e 's/ccache//' -i "${File}"
  35. fi
  36. done
  37. # useless check (no pkgconfig file is provided)
  38. sed -e "/PKGCONFIG += CImg/d" \
  39. -i photivoProject/photivoProject.pro || die
  40. qt4-r2_src_prepare
  41. }
  42. src_configure() {
  43. local config="WithSystemCImg"
  44. if use gimp ; then
  45. config+=" WithGimp"
  46. fi
  47. eqmake4 "CONFIG+=${config}"
  48. }
  49. src_install() {
  50. qt4-r2_src_install
  51. if use gimp; then
  52. exeinto $(gimptool-2.0 --gimpplugindir)/plug-ins
  53. doexe ptGimp
  54. doexe "mm extern photivo.py"
  55. fi
  56. }