commit:     ff5d95a9972275e1c45b676e4dd4f8fd425077ea
Author:     Jeroen Roovers <jer <AT> gentoo <DOT> org>
AuthorDate: Mon Apr  8 19:22:28 2019 +0000
Commit:     Jeroen Roovers <jer <AT> gentoo <DOT> org>
CommitDate: Mon Apr  8 19:23:05 2019 +0000
URL:        https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=ff5d95a9

x11-libs/fltk: Version 1.3.5

Package-Manager: Portage-2.3.62, Repoman-2.3.12
Signed-off-by: Jeroen Roovers <jer <AT> gentoo.org>

 x11-libs/fltk/Manifest          |   1 +
 x11-libs/fltk/fltk-1.3.5.ebuild | 190 ++++++++++++++++++++++++++++++++++++++++
 2 files changed, 191 insertions(+)

diff --git a/x11-libs/fltk/Manifest b/x11-libs/fltk/Manifest
index e99aaaf51d5..b00e46dfe50 100644
--- a/x11-libs/fltk/Manifest
+++ b/x11-libs/fltk/Manifest
@@ -1,2 +1,3 @@
 DIST fltk-1.3.3-source.tar.gz 4986376 BLAKE2B 
866d26cd8d7d1e985010f7601598ec87b44674f55d019239ebc0cbf8d70e04d9d1bce7a7c8463740bcd4c4a8ffcc8ef5e44b3f0cb591358d53d513844605c868
 SHA512 
277ba27e35c20e2d4fc5296bf418c5ab78c821870476e21d49f723765b99b3a559eed4ecd5215ac26d53a1091ada003e17f1553194cebaa97dd854809dd2885d
 DIST fltk-1.3.4-source.tar.gz 5284217 BLAKE2B 
87da82cd04abe81cf095b92b997d4ca0fb7d77fbbb5602848f88ad79e5e41c9bff64b7c948b408b83833fcb658c07b3fe487f55c30357484fab444faca7e990f
 SHA512 
92c236e426ad9b2a2954a6fc401bc9bf4c4c46d47b08f8c9b879da6031ac158ef9b944f28a8bea64d18072d1af8ceaa09c00abebd745fb76dd628636424446c2
+DIST fltk-1.3.5-source.tar.gz 5261324 BLAKE2B 
df05989d6581b570c689e29e9f31e5fc85fa91dee1296d70b5f5c3b4aab527749850ea78bec3ef5947151b21598c3bb04e52f78b5e6db179e7fd922627862b5e
 SHA512 
db7ea7c5f3489195a48216037b9371a50f1119ae7692d66f71b6711e5ccf78814670581bae015e408dee15c4bba921728309372c1cffc90113cdc092e8540821

diff --git a/x11-libs/fltk/fltk-1.3.5.ebuild b/x11-libs/fltk/fltk-1.3.5.ebuild
new file mode 100644
index 00000000000..008a5a20c95
--- /dev/null
+++ b/x11-libs/fltk/fltk-1.3.5.ebuild
@@ -0,0 +1,190 @@
+# Copyright 1999-2019 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+inherit autotools fdo-mime flag-o-matic multilib-minimal
+
+DESCRIPTION="C++ user interface toolkit for X and OpenGL"
+HOMEPAGE="http://www.fltk.org/";
+SRC_URI="http://fltk.org/pub/${PN}/${PV}/${P}-source.tar.gz";
+
+SLOT="1"
+LICENSE="FLTK LGPL-2"
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sparc ~x86 
~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux ~x86-macos"
+IUSE="cairo debug doc examples games +opengl static-libs +threads +xft 
+xinerama"
+
+RDEPEND="
+       >=media-libs/libpng-1.2:0=[${MULTILIB_USEDEP}]
+       sys-libs/zlib[${MULTILIB_USEDEP}]
+       virtual/jpeg:0=[${MULTILIB_USEDEP}]
+       x11-libs/libICE[${MULTILIB_USEDEP}]
+       x11-libs/libSM[${MULTILIB_USEDEP}]
+       x11-libs/libXcursor[${MULTILIB_USEDEP}]
+       x11-libs/libXext[${MULTILIB_USEDEP}]
+       x11-libs/libXfixes[${MULTILIB_USEDEP}]
+       x11-libs/libXt[${MULTILIB_USEDEP}]
+       cairo? ( x11-libs/cairo[${MULTILIB_USEDEP},X] )
+       opengl? (
+               virtual/glu[${MULTILIB_USEDEP}]
+               virtual/opengl[${MULTILIB_USEDEP}]
+       )
+       xft? ( x11-libs/libXft[${MULTILIB_USEDEP}] )
+       xinerama? ( x11-libs/libXinerama[${MULTILIB_USEDEP}] )
+"
+DEPEND="
+       ${RDEPEND}
+       virtual/pkgconfig
+       x11-base/xorg-proto
+       doc? ( app-doc/doxygen )
+"
+DOCS=(
+       ANNOUNCEMENT
+       CHANGES
+       CHANGES_1.0
+       CHANGES_1.1
+       CREDITS
+       README
+       README.abi-version.txt
+       README.Cairo.txt
+       README.CMake.txt
+       README.MSWindows.txt
+       README.OSX.txt
+       README.Unix.txt
+)
+FLTK_GAMES="
+       blocks
+       checkers
+       sudoku
+"
+PATCHES=(
+       "${FILESDIR}"/${PN}-1.3.0-share.patch
+       "${FILESDIR}"/${PN}-1.3.3-fltk-config.patch
+       "${FILESDIR}"/${PN}-1.3.3-makefile-dirs.patch
+       "${FILESDIR}"/${PN}-1.3.3-visibility.patch
+       "${FILESDIR}"/${PN}-1.3.4-conf-tests.patch
+)
+
+src_prepare() {
+       default
+
+       rm -rf zlib jpeg png || die
+
+       sed -i \
+               -e 's:@HLINKS@::g' FL/Makefile.in || die
+       # docs in proper docdir
+       sed -i \
+               -e "/^docdir/s:fltk:${PF}/html:" \
+               -e "/SILENT:/d" \
+               makeinclude.in || die
+       sed -e "s/7/${PV}/" \
+               < "${FILESDIR}"/FLTKConfig.cmake \
+               > CMake/FLTKConfig.cmake || die
+       sed -e 's:-Os::g' -i configure.ac || die
+
+       # also in Makefile:config.guess config.sub:
+       cp misc/config.{guess,sub} . || die
+
+       cp fluid/{,x-}fluid.desktop || die
+
+       eaclocal
+       eautoconf
+       multilib_copy_sources
+}
+
+multilib_src_configure() {
+       unset FLTK_LIBDIRS
+
+       local FLTK_INCDIR=${EPREFIX}/usr/include/fltk
+       local FLTK_LIBDIR=${EPREFIX}/usr/$(get_libdir)/fltk
+       FLTK_LIBDIRS+=${FLTK_LIBDIRS+:}${FLTK_LIBDIR}
+
+       multilib_is_native_abi && use prefix &&
+               append-ldflags -Wl,-rpath -Wl,"${FLTK_LIBDIR}"
+
+       econf \
+               $(use_enable cairo) \
+               $(use_enable debug) \
+               $(use_enable opengl gl) \
+               $(use_enable threads) \
+               $(use_enable xft) \
+               $(use_enable xinerama) \
+               --disable-localjpeg \
+               --disable-localpng \
+               --disable-localzlib \
+               --docdir="${EPREFIX}/usr/share/doc/${PF}/html" \
+               --enable-largefile \
+               --enable-shared \
+               --enable-xcursor \
+               --enable-xdbe \
+               --enable-xfixes \
+               --includedir=${FLTK_INCDIR} \
+               --libdir=${FLTK_LIBDIR}
+}
+
+multilib_src_compile() {
+       # Prevent reconfigure on non-native ABIs.
+       touch -r makeinclude config.{guess,sub} || die
+
+       default
+
+       if multilib_is_native_abi; then
+               emake -C fluid
+               use doc && emake -C documentation html
+               use games && emake -C test ${FLTK_GAMES}
+       fi
+}
+
+multilib_src_test() {
+       emake -C fluid
+       emake -C test
+}
+
+multilib_src_install() {
+       default
+
+       if multilib_is_native_abi; then
+               emake -C fluid DESTDIR="${D}" install-linux install
+
+               use doc && \
+                       emake -C documentation DESTDIR="${D}" install
+
+               use games && \
+                       emake -C test DESTDIR="${D}" install-linux
+       fi
+}
+
+multilib_src_install_all() {
+       for app in fluid $(usex games "${FLTK_GAMES}" ''); do
+               dosym \
+                       /usr/share/icons/hicolor/32x32/apps/${app}.png \
+                       /usr/share/pixmaps/${app}.png
+       done
+
+       if use examples; then
+               insinto /usr/share/doc/${PF}/examples
+               doins test/*.{h,cxx,fl} test/demo.menu
+       fi
+
+       insinto /usr/share/cmake/Modules
+       doins CMake/FLTK*.cmake
+
+       echo "LDPATH=${FLTK_LIBDIRS}" > 99fltk || die
+       echo "FLTK_DOCDIR=${EPREFIX}/usr/share/doc/${PF}/html" >> 99fltk || die
+       doenvd 99fltk
+
+       # FIXME: This is bad, but building only shared libraries is hardly 
supported
+       # FIXME: The executables in test/ are linking statically against libfltk
+       if ! use static-libs; then
+               rm "${ED}"/usr/lib*/fltk/*.a || die
+       fi
+
+       find "${D}" -name '*.la' -delete || die
+}
+
+pkg_postinst() {
+       fdo-mime_desktop_database_update
+}
+
+pkg_postrm() {
+       fdo-mime_desktop_database_update
+}

Reply via email to