diff --git a/media-libs/djvulibre/djvulibre-3.5.25.recipe b/media-libs/djvulibre/djvulibre-3.5.25.recipe index d70ea50b0..97fea4dea 100644 --- a/media-libs/djvulibre/djvulibre-3.5.25.recipe +++ b/media-libs/djvulibre/djvulibre-3.5.25.recipe @@ -1,24 +1,17 @@ SUMMARY="Web-centric format for distributing documents and images" DESCRIPTION=" DjVu is a web-centric format and software platform for distributing documents \ -and images. -" +and images." HOMEPAGE="http://djvulibre.sourceforge.net/" LICENSE="GNU GPL v2" -COPYRIGHT="2002 Leon Bottou and Yann Le Cun. - 2001 AT&T +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_SHA256="619becf24cf2b9289d5102a19bb81424f68008f90ded841085f07c32e5d48158" -REVISION="1" -ARCHITECTURES="x86 x86_64" -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 +REVISION="2" +ARCHITECTURES="x86_gcc2 x86 x86_64" + SECONDARY_ARCHITECTURES="x86" PROVIDES=" @@ -48,18 +41,22 @@ PROVIDES=" REQUIRES=" haiku$secondaryArchSuffix lib:libjpeg$secondaryArchSuffix - lib:libstdc++$secondaryArchSuffix - lib:libgcc_s$secondaryArchSuffix + lib:libtiff$secondaryArchSuffix + lib:libz$secondaryArchSuffix + " + +if [ $effectiveTargetArchitecture != x86_gcc2 ]; then + REQUIRES+=" + lib:libgcc_s$secondaryArchSuffix + lib:libsupc++$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 + devel:libtiff$secondaryArchSuffix + devel:libz$secondaryArchSuffix " -#needs devel:libtiff too but that isn't provided by anything BUILD_PREREQUIRES=" haiku${secondaryArchSuffix}_devel @@ -82,7 +79,7 @@ REQUIRES_devel=" SOURCE_DIR="djvulibre-3.5.25" -PATCHES="djvulibre-3.5.25.patch" +PATCHES="djvulibre-3.5.25.patchset" BUILD() { diff --git a/media-libs/djvulibre/patches/djvulibre-3.5.25.patch b/media-libs/djvulibre/patches/djvulibre-3.5.25.patch deleted file mode 100644 index 1d12ad8fd..000000000 --- a/media-libs/djvulibre/patches/djvulibre-3.5.25.patch +++ /dev/null @@ -1,12 +0,0 @@ -diff -Naur djvulibre-3.5.25/libdjvu/miniexp.cpp djvulibre-3.5.25-haiku/libdjvu/miniexp.cpp ---- djvulibre-3.5.25/libdjvu/miniexp.cpp 2012-03-17 23:49:02.048758784 +0100 -+++ djvulibre-3.5.25-haiku/libdjvu/miniexp.cpp 2012-03-25 14:42:11.949223424 +0200 -@@ -1010,7 +1010,7 @@ - if (io == &miniexp_io && !CompatCounter::count) - return (*minilisp_getc)(); /* compatibility hack */ - FILE *f = (io->data[0]) ? (FILE*)(io->data[0]) : stdin; -- return ::getc(f); -+ return getc(f); - } - - static int diff --git a/media-libs/djvulibre/patches/djvulibre-3.5.25.patchset b/media-libs/djvulibre/patches/djvulibre-3.5.25.patchset new file mode 100644 index 000000000..ec2a05778 --- /dev/null +++ b/media-libs/djvulibre/patches/djvulibre-3.5.25.patchset @@ -0,0 +1,44 @@ +From 41b3ce02fa610b55445cc25fc31ca8ee763adfad Mon Sep 17 00:00:00 2001 +From: Sergei Reznikov +Date: Wed, 25 Mar 2015 10:35:25 +0300 +Subject: Fix build + + +diff --git a/libdjvu/miniexp.cpp b/libdjvu/miniexp.cpp +index b0d9814..7483ade 100644 +--- a/libdjvu/miniexp.cpp ++++ b/libdjvu/miniexp.cpp +@@ -1010,7 +1010,7 @@ stdio_fgetc(miniexp_io_t *io) + if (io == &miniexp_io && !CompatCounter::count) + return (*minilisp_getc)(); /* compatibility hack */ + FILE *f = (io->data[0]) ? (FILE*)(io->data[0]) : stdin; +- return ::getc(f); ++ return getc(f); + } + + static int +-- +2.2.2 + + +From f035c1e3c46ce966902cb634c82455d8859127c4 Mon Sep 17 00:00:00 2001 +From: Sergei Reznikov +Date: Wed, 25 Mar 2015 10:45:06 +0300 +Subject: Haiku: gcc2 fix + + +diff --git a/libdjvu/JB2Image.h b/libdjvu/JB2Image.h +index a87a83b..86a8bfa 100644 +--- a/libdjvu/JB2Image.h ++++ b/libdjvu/JB2Image.h +@@ -329,6 +329,7 @@ private: + int top,left,right,bottom; + void compute_bounding_box(const GBitmap &cbm); + }; ++public: + GTArray boxes; + void get_bounding_box(int shapeno, LibRect &dest); + }; +-- +2.2.2 +