--- lyx-2.2.3.ebuild 2017-07-12 21:45:47.051703387 +0200 +++ lyx-2.2.3-r1.ebuild 2017-07-19 22:58:13.842790253 +0200 @@ -1,10 +1,10 @@ # Copyright 1999-2017 Gentoo Foundation # Distributed under the terms of the GNU General Public License v2 -EAPI=5 +EAPI=6 PYTHON_COMPAT=( python2_7 ) -inherit gnome2-utils eutils fdo-mime flag-o-matic font python-single-r1 toolchain-funcs +inherit gnome2-utils eutils fdo-mime flag-o-matic font python-single-r1 qmake-utils toolchain-funcs MY_P="${P/_}" @@ -12,14 +12,14 @@ FONT_S="${S}/lib/fonts" FONT_SUFFIX="ttf" DESCRIPTION="WYSIWYM frontend for LaTeX, DocBook, etc." -HOMEPAGE="http://www.lyx.org/" +HOMEPAGE="https://www.lyx.org/" SRC_URI="ftp://ftp.lyx.org/pub/lyx/stable/2.2.x/${MY_P}.tar.xz ftp://ftp.lyx.org/pub/lyx/devel/lyx-2.2/${MY_P}/${MY_P}.tar.xz" LICENSE="GPL-2" SLOT="0" KEYWORDS="~alpha ~amd64 ~hppa ~ia64 ~ppc ~ppc64 ~sparc ~x86 ~x64-macos ~x86-macos" -IUSE="cups debug nls +latex monolithic-build html rtf dot docbook dia subversion rcs svg gnumeric +hunspell aspell enchant +qt4 qt5" +IUSE="aspell cups debug docbook dia dot enchant gnumeric html +hunspell +latex monolithic-build nls +qt5 rcs rtf subversion svg" LANGS="ar ca cs da de el en es eu fi fr gl he hu ia id it ja nb nn pl pt_BR pt_PT ro ru sk sr sv tr uk zh_CN zh_TW" @@ -27,62 +27,76 @@ IUSE="${IUSE} linguas_${X}" done -REQUIRED_USE="${PYTHON_REQUIRED_USE} - qt4? ( !qt5 ) - qt5? ( !qt4 )" +REQUIRED_USE="${PYTHON_REQUIRED_USE}" -DOCS=( ANNOUNCE NEWS README RELEASE-NOTES UPGRADING ) - -COMMONDEPEND=">=dev-libs/boost-1.34:= - ${PYTHON_DEPS} - qt4? ( dev-qt/qtgui:4 dev-qt/qtcore:4 dev-qt/qtsvg:4 ) - qt5? ( dev-qt/qtgui:5 dev-qt/qtcore:5 dev-qt/qtwidgets:5 dev-qt/qtx11extras:5 dev-qt/qtsvg:5 dev-qt/qtconcurrent:5 )" - -RDEPEND="${COMMONDEPEND} +RDEPEND="${PYTHON_DEPS} + dev-libs/boost:= dev-texlive/texlive-fontsextra + sys-apps/file + sys-libs/zlib virtual/imagemagick-tools[png,svg?] + aspell? ( app-text/aspell ) cups? ( net-print/cups ) + dia? ( app-office/dia ) + docbook? ( app-text/sgmltools-lite ) + dot? ( media-gfx/graphviz ) + enchant? ( app-text/enchant ) + gnumeric? ( app-office/gnumeric ) + html? ( dev-tex/html2latex ) + hunspell? ( app-text/hunspell ) latex? ( - app-text/texlive + app-text/dvipng app-text/ghostscript-gpl app-text/noweb - app-text/dvipng - dev-tex/dvipost - dev-tex/chktex app-text/ps2eps + app-text/texlive + dev-tex/chktex + dev-tex/dvipost + dev-texlive/texlive-fontsrecommended dev-texlive/texlive-latexextra dev-texlive/texlive-pictures || ( dev-texlive/texlive-mathscience dev-texlive/texlive-science ) || ( dev-texlive/texlive-plaingeneric dev-texlive/texlive-genericextra ) - dev-texlive/texlive-fontsrecommended || ( - dev-tex/latex2html - dev-tex/tth dev-tex/hevea + dev-tex/latex2html dev-tex/tex4ht[java] + dev-tex/tth ) ) - html? ( dev-tex/html2latex ) - rtf? ( - dev-tex/latex2rtf - app-text/unrtf - dev-tex/html2latex - ) linguas_he? ( dev-tex/culmus-latex ) - docbook? ( app-text/sgmltools-lite ) - dot? ( media-gfx/graphviz ) - dia? ( app-office/dia ) - subversion? ( dev-vcs/subversion ) + !qt5? ( + dev-qt/qtcore:4 + dev-qt/qtgui:4 + ) + qt5? ( + dev-qt/qtcore:5 + dev-qt/qtgui:5 + dev-qt/qtsvg:5 + dev-qt/qtwidgets:5 + ) rcs? ( dev-vcs/rcs ) + rtf? ( + app-text/unrtf + dev-tex/html2latex + dev-tex/latex2rtf + ) + subversion? ( dev-vcs/subversion ) svg? ( || ( gnome-base/librsvg media-gfx/inkscape ) ) - gnumeric? ( app-office/gnumeric ) - hunspell? ( app-text/hunspell ) - aspell? ( app-text/aspell ) - enchant? ( app-text/enchant )" - -DEPEND="${COMMONDEPEND} +" +DEPEND="${RDEPEND} virtual/pkgconfig - nls? ( sys-devel/gettext )" + nls? ( sys-devel/gettext ) + !qt5? ( dev-qt/qtsvg:4 ) + qt5? ( + dev-qt/qtconcurrent:5 + dev-qt/qtx11extras:5 + ) +" + +DOCS=( ANNOUNCE NEWS README RELEASE-NOTES UPGRADING ) + +PATCHES=( "${FILESDIR}"/2.1-python.patch ) pkg_setup() { python-single-r1_pkg_setup @@ -90,36 +104,26 @@ } src_prepare() { - epatch "${FILESDIR}"/2.1-python.patch + default sed "s:python -tt:${EPYTHON} -tt:g" -i lib/configure.py || die - if use qt4; then - export QT_SELECT=qt4 - elif use qt5; then - export QT_SELECT=qt5 - fi } src_configure() { tc-export CXX #bug 221921 export VARTEXFONTS=${T}/fonts - local qt_flag="" - if use qt4; then - qt_flag="" - elif use qt5; then - qt_flag="--enable-qt5" - fi econf \ - $(use_enable nls) \ - $(use_enable debug) \ - $(use_enable monolithic-build) \ - $(use_with hunspell) \ $(use_with aspell) \ + $(use_enable debug) \ $(use_with enchant) \ - ${qt_flag} \ - --without-included-boost \ + $(use_with hunspell) \ + $(use_enable monolithic-build) \ + $(use_enable nls) \ + $(use_enable qt5) \ + --with-qt-dir=$(usex qt5 $(qt5_get_libdir)/qt5 $(qt4_get_libdir)) \ --disable-stdlib-debug \ + --without-included-boost \ --with-packaging=posix }