From 3a0f3a3d742807ad43845310cf01d3dae976447d Mon Sep 17 00:00:00 2001 From: Kacper Kasper Date: Sat, 26 Apr 2014 05:51:59 +0200 Subject: [PATCH 1/4] Fix tiff-4.0.2 recipe --- media-libs/tiff/tiff-4.0.2.recipe | 83 +++++++++++++++++-------------- 1 file changed, 46 insertions(+), 37 deletions(-) diff --git a/media-libs/tiff/tiff-4.0.2.recipe b/media-libs/tiff/tiff-4.0.2.recipe index 0c8433cf5..699820927 100644 --- a/media-libs/tiff/tiff-4.0.2.recipe +++ b/media-libs/tiff/tiff-4.0.2.recipe @@ -4,7 +4,7 @@ TIFF the Tag Image File Format, is a widely used format for storing image \ data. Included in this software is a library, libtiff, for reading and writing \ TIFF. " -HOMEPAGE="http://www.libtiff.org" +HOMEPAGE="http://www.libtiff.org" SRC_URI="ftp://ftp.remotesensing.org/pub/libtiff/tiff-4.0.2.tar.gz" CHECKSUM_SHA256="aa29f1f5bfe3f443c3eb4dac472ebde15adc8ff0464b83376f35e3b2fef935da" REVISION="1" @@ -12,21 +12,28 @@ LICENSE="MIT" COPYRIGHT="1988-1997 Sam Leffler 1991-1997 Silicon Graphics, Inc." -REVISION="1" -ARCHITECTURES="!x86_gcc2 ?x86 ?x86_64" -SECONDARY_ARCHITECTURES="!x86_gcc2 ?x86" +REVISION="2" +ARCHITECTURES="x86 ?x86_64" +if [ $effectiveTargetArchitecture != x86_gcc2 ]; then + ARCHITECTURES="$ARCHITECTURES x86_gcc2" +fi +SECONDARY_ARCHITECTURES="x86" PROVIDES=" - tiff$secondaryArchSuffix = $portVersion compat >= 4 - lib:libtiff$secondaryArchSuffix = $portVersion compat >= 4 + tiff$secondaryArchSuffix = $portVersion + lib:libtiff$secondaryArchSuffix = 5.1.0 compat >= 5 + lib:libtiffxx$secondaryArchSuffix = 5.1.0 compat >= 5 " REQUIRES=" haiku$secondaryArchSuffix >= $haikuVersion - lib:libGL - lib:libjpeg - lib:libz + lib:libGL$secondaryArchSuffix + lib:libjpeg$secondaryArchSuffix + lib:libz$secondaryArchSuffix " BUILD_REQUIRES=" + devel:libGL$secondaryArchSuffix + devel:libjpeg$secondaryArchSuffix + devel:libz$secondaryArchSuffix " BUILD_PREREQUIRES=" haiku${secondaryArchSuffix}_devel >= $haikuVersion @@ -46,7 +53,7 @@ BUILD() automake --add-missing autoconf autoheader - runConfigure ./configure + runConfigure ./configure --with-docdir=$documentationDir/$portName # --enable-shared make $jobArgs } @@ -55,7 +62,8 @@ INSTALL() { make install - prepareInstalledDevelLibs libtiff + prepareInstalledDevelLibs libtiff libtiffxx + fixPkgconfig # devel package packageEntries devel \ @@ -78,8 +86,9 @@ INSTALL() # ----- devel package ------------------------------------------------------- PROVIDES_devel=" - tiff${secondaryArchSuffix}_devel = $portVersion compat >= 4 - devel:libtiff$secondaryArchSuffix = $portVersion compat >= 4 + tiff${secondaryArchSuffix}_devel = $portVersion + devel:libtiff$secondaryArchSuffix = 5.1.0 compat >= 5 + devel:libtiffxx$secondaryArchSuffix = 5.1.0 compat >= 5 " REQUIRES_devel=" tiff$secondaryArchSuffix == $portVersion base @@ -90,30 +99,30 @@ REQUIRES_devel=" if [ -z "$secondaryArchSuffix" ]; then SUMMARY_tools="The TIFF tools" PROVIDES_tools=" - tiff_tools = $portVersion compat >= 4 - cmd:bmp2tiff = $portVersion compat >= 4 - cmd:fax2ps = $portVersion compat >= 4 - cmd:fax2tiff = $portVersion compat >= 4 - cmd:gif2tiff = $portVersion compat >= 4 - cmd:pal2rgb = $portVersion compat >= 4 - cmd:ppm2tiff = $portVersion compat >= 4 - cmd:ras2tiff = $portVersion compat >= 4 - cmd:raw2tiff = $portVersion compat >= 4 - cmd:rgb2ycbcr = $portVersion compat >= 4 - cmd:thumbnail = $portVersion compat >= 4 - cmd:tiff2bw = $portVersion compat >= 4 - cmd:tiff2pdf = $portVersion compat >= 4 - cmd:tiff2ps = $portVersion compat >= 4 - cmd:tiff2rgba = $portVersion compat >= 4 - cmd:tiffcmp = $portVersion compat >= 4 - cmd:tiffcp = $portVersion compat >= 4 - cmd:tiffcrop = $portVersion compat >= 4 - cmd:tiffdither = $portVersion compat >= 4 - cmd:tiffdump = $portVersion compat >= 4 - cmd:tiffinfo = $portVersion compat >= 4 - cmd:tiffmedian = $portVersion compat >= 4 - cmd:tiffset = $portVersion compat >= 4 - cmd:tiffsplit = $portVersion compat >= 4 + tiff_tools = $portVersion + cmd:bmp2tiff + cmd:fax2ps + cmd:fax2tiff + cmd:gif2tiff + cmd:pal2rgb + cmd:ppm2tiff + cmd:ras2tiff + cmd:raw2tiff + cmd:rgb2ycbcr + cmd:thumbnail + cmd:tiff2bw + cmd:tiff2pdf + cmd:tiff2ps + cmd:tiff2rgba + cmd:tiffcmp + cmd:tiffcp + cmd:tiffcrop + cmd:tiffdither + cmd:tiffdump + cmd:tiffinfo + cmd:tiffmedian + cmd:tiffset + cmd:tiffsplit " REQUIRES_tools=" haiku >= $haikuVersion From b3dc608babca3c07b76d0d9de3f5347a8c171031 Mon Sep 17 00:00:00 2001 From: Kacper Kasper Date: Sat, 26 Apr 2014 06:14:56 +0200 Subject: [PATCH 2/4] Fix fftw-3.3.4 recipe --- sci-libs/fftw/fftw-3.3.4.recipe | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/sci-libs/fftw/fftw-3.3.4.recipe b/sci-libs/fftw/fftw-3.3.4.recipe index 465634abd..b204e5d57 100644 --- a/sci-libs/fftw/fftw-3.3.4.recipe +++ b/sci-libs/fftw/fftw-3.3.4.recipe @@ -21,7 +21,7 @@ COPYRIGHT=" 2003, 2007-2011 Matteo Frigo 2003, 2007-2011 Massachusetts Institute of Technology " -REVISION="1" +REVISION="2" ARCHITECTURES="x86 x86_gcc2 x86_64" SECONDARY_ARCHITECTURES="x86_gcc2 x86" @@ -58,6 +58,7 @@ INSTALL() { make install prepareInstalledDevelLib libfftw3 + fixPkgconfig packageEntries devel $developDir } From 92edcf4217990eda0d5082640b21fb77cdc4d608 Mon Sep 17 00:00:00 2001 From: Kacper Kasper Date: Sat, 26 Apr 2014 23:53:44 +0200 Subject: [PATCH 3/4] vigra: turn bep into recipe and update version --- media-libs/vigra/vigra-1.10.0.recipe | 102 +++++++++++++++++++++++++++ media-libs/vigra/vigra-1.8.0.recipe | 23 ------ 2 files changed, 102 insertions(+), 23 deletions(-) create mode 100644 media-libs/vigra/vigra-1.10.0.recipe delete mode 100644 media-libs/vigra/vigra-1.8.0.recipe diff --git a/media-libs/vigra/vigra-1.10.0.recipe b/media-libs/vigra/vigra-1.10.0.recipe new file mode 100644 index 000000000..cece4c3cc --- /dev/null +++ b/media-libs/vigra/vigra-1.10.0.recipe @@ -0,0 +1,102 @@ +SUMMARY="Vision with Generic Algorithms" +DESCRIPTION=" + C++ computer vision library with emphasize on customizable \ + algorithms and data structures. + " +LICENSE="MIT" +COPYRIGHT="1998-2013 by Ullrich Koethe" +HOMEPAGE="http://ukoethe.github.io/vigra/" +SRC_URI="https://github.com/ukoethe/vigra/archive/Version-1-10-0.tar.gz" +CHECKSUM_SHA256="406f6fcbcea2e92f681a7b844487c29049d338f5b2b25f8145e67bcb518c7ef8" +REVISION="1" + +ARCHITECTURES="x86 ?x86_gcc2 ?x86_64" +SECONDARY_ARCHITECTURES="?x86 ?x86_gcc2" + +SOURCE_DIR="vigra-Version-1-10-0" + +PROVIDES=" + vigra$secondaryArchSuffix = $portVersion + cmd:vigra_config$secondaryArchSuffix + lib:libvigraimpex$secondaryArchSuffix = 5.1.10.0 compat >= 5 +" +REQUIRES=" + haiku$secondaryArchSuffix >= $haikuVersion + lib:libjpeg$secondaryArchSuffix + lib:libpng$secondaryArchSuffix + lib:libtiff$secondaryArchSuffix + lib:libHalf$secondaryArchSuffix + lib:libIex_2_1$secondaryArchSuffix + lib:libImath_2_1$secondaryArchSuffix + lib:libIlmImf_Imf_2_1$secondaryArchSuffix + lib:libIlmThread_2_1$secondaryArchSuffix + lib:libfftw$secondaryArchSuffix + lib:libz$secondaryArchSuffix +" +BUILD_REQUIRES=" + devel:libjpeg$secondaryArchSuffix + devel:libpng$secondaryArchSuffix + devel:libtiff$secondaryArchSuffix + devel:libHalf$secondaryArchSuffix + devel:libIex$secondaryArchSuffix + devel:libImath$secondaryArchSuffix + devel:libIlmImf$secondaryArchSuffix + devel:libfftw$secondaryArchSuffix + devel:libz$secondaryArchSuffix +" +BUILD_PREREQUIRES=" + haiku${secondaryArchSuffix}_devel >= $haikuVersion + cmd:cmake + cmd:g++$secondaryArchSuffix + cmd:ld$secondaryArchSuffix + cmd:make +" + +BUILD() +{ + mkdir -p build + cd build + cmake -DCMAKE_INSTALL_PREFIX=$prefix -DWITH_HDF5=0 -DWITH_VIGRANUMPY=0 \ + -DWITH_OPENEXR=1 ../ + make $jobArgs +} + +INSTALL() +{ + cd build + make install + + # we did not generate documentation + rm -rf $prefix/doc + + # move headers + mkdir -p $includeDir + mv $prefix/include/* $includeDir + + rm -rf $prefix/include + + prepareInstalledDevelLib libvigraimpex + + # move CMake scripts... + # FIXME: ...which probably won't work + mv $libDir/$portName $developLibDir + sed -i "s#/include/#/$relativeIncludeDir/#g" \ + $developLibDir/$portName/VigraConfig.cmake + + packageEntries devel $developDir +} + +TEST() +{ + # FIXME: these tests fail, probably due to wrong paths + cd build + make test +} + +PROVIDES_devel=" + vigra${secondaryArchSuffix}_devel = $portVersion + devel:libvigraimpex$secondaryArchSuffix = 5.1.10.0 compat >= 5 + " +REQUIRES_devel=" + vigra$secondaryArchSuffix == $portVersion base + " diff --git a/media-libs/vigra/vigra-1.8.0.recipe b/media-libs/vigra/vigra-1.8.0.recipe deleted file mode 100644 index e05e7b3c5..000000000 --- a/media-libs/vigra/vigra-1.8.0.recipe +++ /dev/null @@ -1,23 +0,0 @@ -DESCRIPTION="C++ computer vision library with emphasize on customizable algorithms and data structures. " -HOMEPAGE="http://hci.iwr.uni-heidelberg.de/vigra/" -SRC_URI="http://hci.iwr.uni-heidelberg.de/vigra/vigra-1.8.0-src.tar.gz" -CHECKSUM_MD5="15c5544448e529ee60020758ab6be264" -REVISION="1" -STATUS_HAIKU="stable" -MESSAGE="The port only builds with gcc4. Use 'setgcc gcc4' before building." -DEPEND="cmake" -BUILD() -{ - cd vigra-1.8.0 - cmake CMakelists.txt - make -} - -INSTALL() -{ - cd vigra-1.8.0 - make install -} - -LICENSE="MIT" -COPYRIGHT="1998-2010 by Ullrich Koethe" From dea6d55cdc37d46c6ea7a2cd18d1153d05ff6eef Mon Sep 17 00:00:00 2001 From: Kacper Kasper Date: Wed, 30 Apr 2014 01:38:16 +0200 Subject: [PATCH 4/4] Fixes for fftw, tiff and vigra. * tiff can build on gcc2 now. * Move vigra-config script to devel package. * Fix policy violations. --- media-libs/tiff/tiff-4.0.2.recipe | 23 +++++++++++++++-------- media-libs/vigra/vigra-1.10.0.recipe | 10 ++++++---- sci-libs/fftw/fftw-3.3.4.recipe | 9 +++++---- 3 files changed, 26 insertions(+), 16 deletions(-) diff --git a/media-libs/tiff/tiff-4.0.2.recipe b/media-libs/tiff/tiff-4.0.2.recipe index 699820927..215787964 100644 --- a/media-libs/tiff/tiff-4.0.2.recipe +++ b/media-libs/tiff/tiff-4.0.2.recipe @@ -12,15 +12,12 @@ LICENSE="MIT" COPYRIGHT="1988-1997 Sam Leffler 1991-1997 Silicon Graphics, Inc." -REVISION="2" -ARCHITECTURES="x86 ?x86_64" -if [ $effectiveTargetArchitecture != x86_gcc2 ]; then - ARCHITECTURES="$ARCHITECTURES x86_gcc2" -fi -SECONDARY_ARCHITECTURES="x86" +REVISION="3" +ARCHITECTURES="x86_gcc2 x86 ?x86_64" +SECONDARY_ARCHITECTURES="x86_gcc2 x86" PROVIDES=" - tiff$secondaryArchSuffix = $portVersion + tiff$secondaryArchSuffix = $portVersion compat >= 4 lib:libtiff$secondaryArchSuffix = 5.1.0 compat >= 5 lib:libtiffxx$secondaryArchSuffix = 5.1.0 compat >= 5 " @@ -46,6 +43,14 @@ BUILD_PREREQUIRES=" cmd:make " +PATCH() +{ + if [ $effectiveTargetArchitecture == x86_gcc2 ]; then + sed -i 's/ios::pos_type/streampos/g' libtiff/tif_stream.cxx + sed -i 's/ios::off_type/streamoff/g' libtiff/tif_stream.cxx + fi +} + BUILD() { aclocal @@ -86,7 +91,7 @@ INSTALL() # ----- devel package ------------------------------------------------------- PROVIDES_devel=" - tiff${secondaryArchSuffix}_devel = $portVersion + tiff${secondaryArchSuffix}_devel = $portVersion compat >= 4 devel:libtiff$secondaryArchSuffix = 5.1.0 compat >= 5 devel:libtiffxx$secondaryArchSuffix = 5.1.0 compat >= 5 " @@ -127,5 +132,7 @@ if [ -z "$secondaryArchSuffix" ]; then REQUIRES_tools=" haiku >= $haikuVersion tiff == $portVersion base + lib:libjpeg + lib:libz " fi diff --git a/media-libs/vigra/vigra-1.10.0.recipe b/media-libs/vigra/vigra-1.10.0.recipe index cece4c3cc..78ec8b860 100644 --- a/media-libs/vigra/vigra-1.10.0.recipe +++ b/media-libs/vigra/vigra-1.10.0.recipe @@ -7,17 +7,17 @@ LICENSE="MIT" COPYRIGHT="1998-2013 by Ullrich Koethe" HOMEPAGE="http://ukoethe.github.io/vigra/" SRC_URI="https://github.com/ukoethe/vigra/archive/Version-1-10-0.tar.gz" +SRC_FILENAME="$portVersionedName.tar.gz" CHECKSUM_SHA256="406f6fcbcea2e92f681a7b844487c29049d338f5b2b25f8145e67bcb518c7ef8" -REVISION="1" +REVISION="2" ARCHITECTURES="x86 ?x86_gcc2 ?x86_64" -SECONDARY_ARCHITECTURES="?x86 ?x86_gcc2" +SECONDARY_ARCHITECTURES="x86 ?x86_gcc2" SOURCE_DIR="vigra-Version-1-10-0" PROVIDES=" vigra$secondaryArchSuffix = $portVersion - cmd:vigra_config$secondaryArchSuffix lib:libvigraimpex$secondaryArchSuffix = 5.1.10.0 compat >= 5 " REQUIRES=" @@ -83,7 +83,7 @@ INSTALL() sed -i "s#/include/#/$relativeIncludeDir/#g" \ $developLibDir/$portName/VigraConfig.cmake - packageEntries devel $developDir + packageEntries devel $developDir bin/vigra-config } TEST() @@ -95,6 +95,8 @@ TEST() PROVIDES_devel=" vigra${secondaryArchSuffix}_devel = $portVersion + cmd:vigra_config$secondaryArchSuffix + cmd:python # vigra-config is python script devel:libvigraimpex$secondaryArchSuffix = 5.1.10.0 compat >= 5 " REQUIRES_devel=" diff --git a/sci-libs/fftw/fftw-3.3.4.recipe b/sci-libs/fftw/fftw-3.3.4.recipe index b204e5d57..dcefbe609 100644 --- a/sci-libs/fftw/fftw-3.3.4.recipe +++ b/sci-libs/fftw/fftw-3.3.4.recipe @@ -21,15 +21,15 @@ COPYRIGHT=" 2003, 2007-2011 Matteo Frigo 2003, 2007-2011 Massachusetts Institute of Technology " -REVISION="2" +REVISION="3" ARCHITECTURES="x86 x86_gcc2 x86_64" SECONDARY_ARCHITECTURES="x86_gcc2 x86" PROVIDES=" libfftw$secondaryArchSuffix = $portVersion compat >= 3 lib:libfftw$secondaryArchSuffix = $portVersion compat >= 3 - cmd:fftw_wisdom - cmd:fftw_wisdom_to_conf + cmd:fftw_wisdom$secondaryArchSuffix + cmd:fftw_wisdom_to_conf$secondaryArchSuffix " REQUIRES=" @@ -64,7 +64,8 @@ INSTALL() PROVIDES_devel=" libfftw${secondaryArchSuffix}_devel = $portVersion compat >= 3 - devel:libfftw${secondaryArchSuffix} = $portVersion compat >= 3 + devel:libfftw$secondaryArchSuffix = $portVersion compat >= 3 + devel:libfftw3$secondaryArchSuffix = $portVersion compat >= 3 " REQUIRES_devel=" libfftw$secondaryArchSuffix == $portVersion base