From 88e5c3126b2c3d5357b6343ac56d19b339c25a9b Mon Sep 17 00:00:00 2001 From: Larry Hajali Date: Sat, 28 Jan 2017 15:56:53 -0800 Subject: libraries/podofo: fix building against cppunit on x86 Signed-off-by: Larry Hajali --- libraries/podofo/podofo-0.9.4_build.patch | 12 ++++++++++++ libraries/podofo/podofo.SlackBuild | 14 +++++++------- 2 files changed, 19 insertions(+), 7 deletions(-) create mode 100644 libraries/podofo/podofo-0.9.4_build.patch (limited to 'libraries/podofo') diff --git a/libraries/podofo/podofo-0.9.4_build.patch b/libraries/podofo/podofo-0.9.4_build.patch new file mode 100644 index 0000000000..3c4b72a751 --- /dev/null +++ b/libraries/podofo/podofo-0.9.4_build.patch @@ -0,0 +1,12 @@ +diff -rupN podofo-0.9.4/test/unit/EncryptTest.h podofo-0.9.4-new/test/unit/EncryptTest.h +--- podofo-0.9.4/test/unit/EncryptTest.h 2012-12-12 23:55:46.000000000 +0100 ++++ podofo-0.9.4-new/test/unit/EncryptTest.h 2016-09-18 10:41:30.476635230 +0200 +@@ -83,7 +83,7 @@ class EncryptTest : public CppUnit::Test + + private: + char* m_pEncBuffer; +- long m_lLen; ++ PoDoFo::pdf_long m_lLen; + int m_protection; + + }; diff --git a/libraries/podofo/podofo.SlackBuild b/libraries/podofo/podofo.SlackBuild index fbc03df177..00c65076c7 100644 --- a/libraries/podofo/podofo.SlackBuild +++ b/libraries/podofo/podofo.SlackBuild @@ -2,7 +2,7 @@ # Slackware build script for podofo -# Copyright 2009-2016 Larry Hajali +# Copyright 2009-2017 Larry Hajali # All rights reserved. # # Redistribution and use of this script, with or without modification, is @@ -24,7 +24,7 @@ PRGNAM=podofo VERSION=${VERSION:-0.9.4} -BUILD=${BUILD:-1} +BUILD=${BUILD:-2} TAG=${TAG:-_SBo} CWD=$(pwd) @@ -34,14 +34,14 @@ OUTPUT=${OUTPUT:-/tmp} if [ -z "$ARCH" ]; then case "$( uname -m )" in - i?86) ARCH=i486 ;; + i?86) ARCH=i586 ;; arm*) ARCH=arm ;; *) ARCH=$( uname -m ) ;; esac fi -if [ "$ARCH" = "i486" ]; then - SLKCFLAGS="-O2 -march=i486 -mtune=i686" +if [ "$ARCH" = "i586" ]; then + SLKCFLAGS="-O2 -march=i586 -mtune=i686" LIBDIRSUFFIX="FALSE" elif [ "$ARCH" = "i686" ]; then SLKCFLAGS="-O2 -march=i686 -mtune=i686" @@ -71,8 +71,8 @@ find -L . \ # Fix mandir directory. sed -i 's|share/man|man|' CMakeLists.txt -# Don't compile unit tests on x86 with cppunit. -sed -i 's|PODOFO_HAVE_CPPUNIT.*|PODOFO_HAVE_CPPUNIT OFF)|' CMakeLists.txt +# Fix building podofo on x86 with cppunit. +patch -p1 < $CWD/podofo-0.9.4_build.patch mkdir build cd build -- cgit v1.2.3