From 2620077d4fe9250a804b8f764af383df5beef85c Mon Sep 17 00:00:00 2001 From: Chris Roberts Date: Mon, 18 Nov 2013 01:25:17 -0700 Subject: [PATCH] Convert djvulibre to working recipe --- media-libs/djvulibre/djvulibre-3.5.25.recipe | 102 ++++++++++++++++--- 1 file changed, 87 insertions(+), 15 deletions(-) diff --git a/media-libs/djvulibre/djvulibre-3.5.25.recipe b/media-libs/djvulibre/djvulibre-3.5.25.recipe index 7cf3da398..737e0f67b 100644 --- a/media-libs/djvulibre/djvulibre-3.5.25.recipe +++ b/media-libs/djvulibre/djvulibre-3.5.25.recipe @@ -1,28 +1,100 @@ -DESCRIPTION="DjVu is a web-centric format and software platform for distributing documents and images" +SUMMARY="web-centric format for distributing documents and images" +DESCRIPTION="DjVu is a web-centric format and software platform for distributing documents and images" HOMEPAGE="http://djvulibre.sourceforge.net/" +LICENSE="GNU GPL v2" +COPYRIGHT="2002 Leon Bottou and Yann Le Cun. + 2001 AT&T + 1999-2001 LizardTech, Inc." SRC_URI="http://downloads.sourceforge.net/project/djvu/DjVuLibre/3.5.25/djvulibre-3.5.25.2.tar.gz" CHECKSUM_MD5="994e2ff1d4ae6a763764dfe20509826e" REVISION="1" -STATUS_HAIKU="stable" -DEPEND="" -MESSAGE="This port only builds with gcc4. Use 'setgcc gcc4' before building." +ARCHITECTURES="x86" +if [ $effectiveTargetArchitecture != x86_gcc2 ]; then + # x86_gcc2 is fine as primary target architecture as long as we're building + # for a different secondary architecture. + ARCHITECTURES="$ARCHITECTURES x86_gcc2" +else + ARCHITECTURES="$ARCHITECTURES !x86_gcc2" +fi +SECONDARY_ARCHITECTURES="x86" + +PROVIDES=" + djvulibre$secondaryArchSuffix = $portVersion compat >= 3.5 + cmd:any2djvu$secondaryArchSuffix = $portVersion compat >= 3.5 + cmd:bzz$secondaryArchSuffix = $portVersion compat >= 3.5 + cmd:c44$secondaryArchSuffix = $portVersion compat >= 3.5 + cmd:cjb2$secondaryArchSuffix = $portVersion compat >= 3.5 + cmd:cpaldjvu$secondaryArchSuffix = $portVersion compat >= 3.5 + cmd:csepdjvu$secondaryArchSuffix = $portVersion compat >= 3.5 + cmd:ddjvu$secondaryArchSuffix = $portVersion compat >= 3.5 + cmd:djvm$secondaryArchSuffix = $portVersion compat >= 3.5 + cmd:djvmcvt$secondaryArchSuffix = $portVersion compat >= 3.5 + cmd:djvudigital$secondaryArchSuffix = $portVersion compat >= 3.5 + cmd:djvudump$secondaryArchSuffix = $portVersion compat >= 3.5 + cmd:djvuextract$secondaryArchSuffix = $portVersion compat >= 3.5 + cmd:djvumake$secondaryArchSuffix = $portVersion compat >= 3.5 + cmd:djvups$secondaryArchSuffix = $portVersion compat >= 3.5 + cmd:djvused$secondaryArchSuffix = $portVersion compat >= 3.5 + cmd:djvuserve$secondaryArchSuffix = $portVersion compat >= 3.5 + cmd:djvutoxml$secondaryArchSuffix = $portVersion compat >= 3.5 + cmd:djvutxt$secondaryArchSuffix = $portVersion compat >= 3.5 + cmd:djvuxmlparser$secondaryArchSuffix = $portVersion compat >= 3.5 + lib:libdjvulibre$secondaryArchSuffix = $portVersion compat >= 3.5 + " + +REQUIRES=" + haiku$secondaryArchSuffix >= $haikuVersion + lib:libjpeg$secondaryArchSuffix + " +# haiku_x86 doesn't claim to provide lib:libtiff_x86 on gcc2 builds +if [ "$targetArchitecture" != x86_gcc2 ];then + REQUIRES="$REQUIRES lib:libtiff$secondaryArchSuffix" +fi + +BUILD_REQUIRES=" + devel:libjpeg$secondaryArchSuffix + " +#needs devel:libtiff too but that isn't provided by anything + +BUILD_PREREQUIRES=" + haiku${secondaryArchSuffix}_devel >= $haikuVersion + cmd:make + cmd:gcc$secondaryArchSuffix + cmd:aclocal + cmd:autoconf + cmd:libtoolize + cmd:libtool + " + +PROVIDES_devel=" + djvulibre${secondaryArchSuffix}_devel = $portVersion compat >= 3.5 + devel:libdjvulibre$secondaryArchSuffix = $portVersion compat >= 3.5 + " + +REQUIRES_devel=" + djvulibre$secondaryArchSuffix == $portVersion + " + +SOURCE_DIR="djvulibre-3.5.25" + +PATCHES="djvulibre-3.5.25.patch" + BUILD() { - cd djvulibre-3.5.25 - COMMON_DIR=`finddir B_COMMON_DIRECTORY` - ./configure --prefix=`finddir B_COMMON_DIRECTORY` \ - --mandir=`finddir B_COMMON_DOCUMENTATION_DIRECTORY`/man \ - --datadir=`finddir B_COMMON_DATA_DIRECTORY` + aclocal + libtoolize -fci + autoconf + runConfigure ./configure make } INSTALL() { - cd djvulibre-3.5.25 make install -} -LICENSE="GNU GPL v2" -COPYRIGHT="2002 Leon Bottou and Yann Le Cun. - 2001 AT&T - 1999-2001 LizardTech, Inc." + prepareInstalledDevelLibs libdjvulibre + + fixPkgconfig + + packageEntries devel $developDir +}