Add recipe for my FLTK port git branch

This commit is contained in:
François Revol
2019-03-03 05:22:14 +01:00
parent 0e83e54ed7
commit 92db0c6a56
2 changed files with 178 additions and 0 deletions

View File

@@ -0,0 +1,132 @@
SUMMARY="A cross-platform C++ GUI toolkit for X11, MS Windows, OSX and Haiku"
DESCRIPTION="FLTK (pronounced \"fulltick\") is a cross-platform C++ GUI \
toolkit for UNIX®/Linux® (X11), Microsoft® Windows®, and MacOS® X. \
FLTK provides modern GUI functionality without the bloat and \
supports 3D graphics via OpenGL® and its built-in GLUT emulation.
NOTE: OpenGL is not supported yet.
FLTK is designed to be small and modular enough to be statically linked, \
but works fine as a shared library. \
FLTK also includes an excellent UI builder called FLUID that can be used \
to create applications in minutes."
HOMEPAGE="https://www.fltk.org/"
COPYRIGHT="1998-2019 by Bill Spitzak and others."
LICENSE="FLTK
GNU LGPL v2"
REVISION="1"
#SOURCE_URI="git+https://github.com/mmuman/fltk.git#haiku-1.3-final"
SOURCE_URI="https://github.com/mmuman/fltk/archive/haiku-1.3-final.zip"
#CHECKSUM_SHA256=""
CHECKSUM_SHA256="a57ed6729dcf1d315ca63912f6660ada1c3548289366ff34bdcfa38b8d45eb89"
#SOURCE_DIR="qt-everywhere-src-${portVersion/\~/-}"
SOURCE_DIR="fltk-haiku-1.3-final"
#PATCHES="qt5-$portVersion.patchset"
ARCHITECTURES="!x86_gcc2 ?x86 ?x86_64"
SECONDARY_ARCHITECTURES="?x86"
PROVIDES="
fltk$secondaryArchSuffix = $portVersion compat >= 1.3
lib:libfltk$secondaryArchSuffix = $portVersion compat >= 1.3
lib:libfltk_forms$secondaryArchSuffix = $portVersion compat >= 1.3
lib:libfltk_images$secondaryArchSuffix = $portVersion compat >= 1.3
"
REQUIRES="
haiku$secondaryArchSuffix
#lib:libgl$secondaryArchSuffix
#lib:libglu$secondaryArchSuffix
#lib:libintl$secondaryArchSuffix
lib:libjpeg$secondaryArchSuffix
lib:libpng16$secondaryArchSuffix
lib:libz$secondaryArchSuffix
"
PROVIDES_devel="
fltk${secondaryArchSuffix}_devel = $portVersion compat >= 1.3
devel:libfltk$secondaryArchSuffix = $portVersion compat >= 1.3
devel:libfltk_forms$secondaryArchSuffix = $portVersion compat >= 1.3
devel:libfltk_images$secondaryArchSuffix = $portVersion compat >= 1.3
cmd:fltk_config$secondaryArchSuffix = $portVersion compat >= 1.3
cmd:fluid$secondaryArchSuffix = $portVersion compat >= 1.3
"
REQUIRES_devel="
fltk$secondaryArchSuffix == $portVersion base
haiku$secondaryArchSuffix
#lib:libgl$secondaryArchSuffix
#lib:libglu$secondaryArchSuffix
lib:libjpeg$secondaryArchSuffix
lib:libpng16$secondaryArchSuffix
lib:libz$secondaryArchSuffix
#devel:libgl$secondaryArchSuffix
"
BUILD_REQUIRES="
haiku${secondaryArchSuffix}_devel
#devel:libgl$secondaryArchSuffix
#devel:libglu$secondaryArchSuffix
devel:libjpeg$secondaryArchSuffix
devel:libpng16$secondaryArchSuffix
devel:libz$secondaryArchSuffix
"
BUILD_PREREQUIRES="
cmd:autoconf
cmd:automake
cmd:awk
cmd:doxygen
cmd:g++$secondaryArchSuffix
cmd:grep
cmd:ld$secondaryArchSuffix
cmd:make
cmd:man
cmd:pkg_config$secondaryArchSuffix
cmd:sed
"
BUILD()
{
NOCONFIGURE=1 sh ./autogen.sh
runConfigure ./configure \
--enable-shared \
--disable-gl \
--disable-localjpeg \
--disable-localpng \
--disable-localzlib \
--enable-debug
make $jobArgs
}
INSTALL()
{
mkdir -p $docDir
make install
fixPkgconfig
prepareInstalledDevelLibs \
libfltk
mv -f $libDir/*.a $developLibDir/
# TODO: fix configure.ac
mkdir -p $developDocDir
mv -f $dataDir/doc/fltk/* $developDocDir/
# install does not copy attributes and strips resources!?
copyattr -d fluid/fluid $binDir/fluid
addAppDeskbarSymlink $binDir/fluid "FLUID"
# extract the FLTK license, we already have the GPLv2 text
# XXX: haikuporter does not like it, wants the licence beforehand anyway.
#sed -n '/^------/q;p' < COPYING > $dataDir/licenses/FLTK
packageEntries devel \
$developDir \
$binDir \
$manDir \
${dataDir}/deskbar
}