From 579a9cdec7673d9007ef924bb345f42527aa0a72 Mon Sep 17 00:00:00 2001 From: Eric Bavier Date: Wed, 28 Jun 2017 22:05:24 -0500 Subject: gnu: Add libopenshot. * gnu/packages/video.scm (libopenshot): New variable. * gnu/packages/patches/libopenshot-tests-with-system-libs.patch: New file. * gnu/local.mk (dist_patch_DATA): Add it. --- .../libopenshot-tests-with-system-libs.patch | 95 ++++++++++++++++++++++ 1 file changed, 95 insertions(+) create mode 100644 gnu/packages/patches/libopenshot-tests-with-system-libs.patch (limited to 'gnu/packages/patches') diff --git a/gnu/packages/patches/libopenshot-tests-with-system-libs.patch b/gnu/packages/patches/libopenshot-tests-with-system-libs.patch new file mode 100644 index 0000000000..a18c4b8bba --- /dev/null +++ b/gnu/packages/patches/libopenshot-tests-with-system-libs.patch @@ -0,0 +1,95 @@ +Combination of two patches that fix libopenshot tests when built with +system-provided ffmpeg and jsoncpp. See + + https://github.com/OpenShot/libopenshot/pull/163 + +From 0d7691ab53433e1583f6a66ea96683b0f7af8a57 Mon Sep 17 00:00:00 2001 +From: "FeRD (Frank Dana)" +Date: Mon, 17 Sep 2018 14:04:40 -0400 +Subject: [PATCH] tests/CMakeFiles: Use FFMpeg like src/ + +--- + tests/CMakeLists.txt | 32 +++++++++++++++++++++++++++++++- + 1 file changed, 31 insertions(+), 1 deletion(-) + +diff --git a/tests/CMakeLists.txt b/tests/CMakeLists.txt +index 2c45550..4df8464 100644 +--- a/tests/CMakeLists.txt ++++ b/tests/CMakeLists.txt +@@ -79,7 +79,37 @@ ENDIF (ImageMagick_FOUND) + FIND_PACKAGE(FFmpeg REQUIRED) + + # Include FFmpeg headers (needed for compile) +-include_directories(${FFMPEG_INCLUDE_DIR}) ++message('AVCODEC_FOUND: ${AVCODEC_FOUND}') ++message('AVCODEC_INCLUDE_DIRS: ${AVCODEC_INCLUDE_DIRS}') ++message('AVCODEC_LIBRARIES: ${AVCODEC_LIBRARIES}') ++ ++IF (AVCODEC_FOUND) ++ include_directories(${AVCODEC_INCLUDE_DIRS}) ++ENDIF (AVCODEC_FOUND) ++IF (AVDEVICE_FOUND) ++ include_directories(${AVDEVICE_INCLUDE_DIRS}) ++ENDIF (AVDEVICE_FOUND) ++IF (AVFORMAT_FOUND) ++ include_directories(${AVFORMAT_INCLUDE_DIRS}) ++ENDIF (AVFORMAT_FOUND) ++IF (AVFILTER_FOUND) ++ include_directories(${AVFILTER_INCLUDE_DIRS}) ++ENDIF (AVFILTER_FOUND) ++IF (AVUTIL_FOUND) ++ include_directories(${AVUTIL_INCLUDE_DIRS}) ++ENDIF (AVUTIL_FOUND) ++IF (POSTPROC_FOUND) ++ include_directories(${POSTPROC_INCLUDE_DIRS}) ++ENDIF (POSTPROC_FOUND) ++IF (SWSCALE_FOUND) ++ include_directories(${SWSCALE_INCLUDE_DIRS}) ++ENDIF (SWSCALE_FOUND) ++IF (SWRESAMPLE_FOUND) ++ include_directories(${SWRESAMPLE_INCLUDE_DIRS}) ++ENDIF (SWRESAMPLE_FOUND) ++IF (AVRESAMPLE_FOUND) ++ include_directories(${AVRESAMPLE_INCLUDE_DIRS}) ++ENDIF (AVRESAMPLE_FOUND) + + ################# LIBOPENSHOT-AUDIO ################### + # Find JUCE-based openshot Audio libraries + + +From e9e85cdfd036587adb86341f7f81619dc69f102c Mon Sep 17 00:00:00 2001 +From: "FeRD (Frank Dana)" +Date: Mon, 17 Sep 2018 19:23:25 -0400 +Subject: [PATCH] Use system jsoncpp in tests, too + +The tests/ build needs to use the same jsoncpp as the src/ build, +or tests in Clip_Tests.cpp can fail. +--- + tests/CMakeLists.txt | 10 ++++++++-- + 1 file changed, 8 insertions(+), 2 deletions(-) + +diff --git a/tests/CMakeLists.txt b/tests/CMakeLists.txt +index 4df8464..a1a0356 100644 +--- a/tests/CMakeLists.txt ++++ b/tests/CMakeLists.txt +@@ -180,12 +180,18 @@ endif(OPENMP_FOUND) + # Find ZeroMQ library (used for socket communication & logging) + FIND_PACKAGE(ZMQ REQUIRED) + +-# Include FFmpeg headers (needed for compile) ++# Include ZeroMQ headers (needed for compile) + include_directories(${ZMQ_INCLUDE_DIRS}) + + ################### JSONCPP ##################### + # Include jsoncpp headers (needed for JSON parsing) +-include_directories("../thirdparty/jsoncpp/include") ++if (USE_SYSTEM_JSONCPP) ++ find_package(JsonCpp REQUIRED) ++ include_directories(${JSONCPP_INCLUDE_DIRS}) ++else() ++ message("Using embedded JsonCpp") ++ include_directories("../thirdparty/jsoncpp/include") ++endif(USE_SYSTEM_JSONCPP) + + IF (NOT DISABLE_TESTS) + ############### SET TEST SOURCE FILES ################# -- cgit 1.4.1 From 8e59c5febd2dad171fe90caf04d8b3eb31ca3b31 Mon Sep 17 00:00:00 2001 From: Efraim Flashner Date: Tue, 27 Nov 2018 19:16:24 +0200 Subject: gnu: x265: Fix building on armhf-linux. * gnu/packages/video.scm (x265)[patches]: Add patch. [arguments]: Add a configure-flag to disable assembly. Adjust a custom phase to recognize armv8 as 32-bit arm when masquerading as armhf-linux. --- gnu/local.mk | 1 + gnu/packages/patches/x265-arm-flags.patch | 36 +++++++++++++++++++++++++++++++ gnu/packages/video.scm | 10 ++++++++- 3 files changed, 46 insertions(+), 1 deletion(-) create mode 100644 gnu/packages/patches/x265-arm-flags.patch (limited to 'gnu/packages/patches') diff --git a/gnu/local.mk b/gnu/local.mk index 0cd9fad2e5..29d07f5192 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -1243,6 +1243,7 @@ dist_patch_DATA = \ %D%/packages/patches/wpa-supplicant-fix-zeroed-keys.patch \ %D%/packages/patches/wpa-supplicant-fix-nonce-reuse.patch \ %D%/packages/patches/wpa-supplicant-krack-followups.patch \ + %D%/packages/patches/x265-arm-flags.patch \ %D%/packages/patches/x265-detect512-all-arches.patch \ %D%/packages/patches/xboing-CVE-2004-0149.patch \ %D%/packages/patches/xf86-video-ark-remove-mibstore.patch \ diff --git a/gnu/packages/patches/x265-arm-flags.patch b/gnu/packages/patches/x265-arm-flags.patch new file mode 100644 index 0000000000..f17e26f6f1 --- /dev/null +++ b/gnu/packages/patches/x265-arm-flags.patch @@ -0,0 +1,36 @@ +https://sources.debian.org/src/x265/2.9-3/debian/patches/0001-Fix-arm-flags.patch/ + +From: Sebastian Ramacher +Date: Wed, 26 Apr 2017 22:05:06 +0200 +Subject: Fix arm* flags + +--- + source/CMakeLists.txt | 6 +----- + 1 file changed, 1 insertion(+), 5 deletions(-) + +diff --git a/source/CMakeLists.txt b/source/CMakeLists.txt +index 33b6523..25aecbb 100644 +--- a/source/CMakeLists.txt ++++ b/source/CMakeLists.txt +@@ -72,7 +72,7 @@ elseif(ARMMATCH GREATER "-1") + endif() + message(STATUS "Detected ARM target processor") + set(ARM 1) +- add_definitions(-DX265_ARCH_ARM=1 -DHAVE_ARMV6=1) ++ # add_definitions(-DX265_ARCH_ARM=1 -DHAVE_ARMV6=1) + else() + message(STATUS "CMAKE_SYSTEM_PROCESSOR value `${CMAKE_SYSTEM_PROCESSOR}` is unknown") + message(STATUS "Please add this value near ${CMAKE_CURRENT_LIST_FILE}:${CMAKE_CURRENT_LIST_LINE}") +@@ -230,12 +230,8 @@ if(GCC) + if(ARM AND CROSS_COMPILE_ARM) + set(ARM_ARGS -march=armv6 -mfloat-abi=soft -mfpu=vfp -marm -fPIC) + elseif(ARM) +- find_package(Neon) + if(CPU_HAS_NEON) +- set(ARM_ARGS -mcpu=native -mfloat-abi=hard -mfpu=neon -marm -fPIC) + add_definitions(-DHAVE_NEON) +- else() +- set(ARM_ARGS -mcpu=native -mfloat-abi=hard -mfpu=vfp -marm) + endif() + endif() + add_definitions(${ARM_ARGS}) diff --git a/gnu/packages/video.scm b/gnu/packages/video.scm index 1e1c988c25..fc3ee5c72b 100644 --- a/gnu/packages/video.scm +++ b/gnu/packages/video.scm @@ -405,7 +405,8 @@ and creating Matroska files from other media files (@code{mkvmerge}).") (sha256 (base32 "090hp4216isis8q5gb7bwzia8rfyzni54z21jnwm97x3hiy6ibpb")) - (patches (search-patches "x265-detect512-all-arches.patch")) + (patches (search-patches "x265-arm-flags.patch" + "x265-detect512-all-arches.patch")) (modules '((guix build utils))) (snippet '(begin (delete-file-recursively "source/compat/getopt") @@ -416,6 +417,10 @@ and creating Matroska files from other media files (@code{mkvmerge}).") #:configure-flags ;; Ensure position independent code for everyone. (list "-DENABLE_PIC=TRUE" + ,@(if (string-prefix? "armhf" (or (%current-system) + (%current-target-system))) + '("-DENABLE_ASSEMBLY=OFF") + '()) (string-append "-DCMAKE_INSTALL_PREFIX=" (assoc-ref %outputs "out"))) #:phases @@ -424,6 +429,9 @@ and creating Matroska files from other media files (@code{mkvmerge}).") (lambda _ (delete-file-recursively "build") (chdir "source") + ;; recognize armv8 in 32-bit mode as ARM + (substitute* "CMakeLists.txt" + (("armv6l") "armv8l")) #t)) (add-before 'configure 'build-12-bit (lambda* (#:key (configure-flags '()) #:allow-other-keys) -- cgit 1.4.1 From 4236959de8200bba4eeb2c23519fc736b3c50a23 Mon Sep 17 00:00:00 2001 From: Ricardo Wurmus Date: Tue, 27 Nov 2018 23:22:20 +0100 Subject: gnu: scribus: Fix build with recent Poppler. Suggested by ngz on #guix. * gnu/packages/patches/scribus-poppler.patch: New file. * gnu/local.mk (dist_patch_DATA): Add it. * gnu/packages/scribus.scm (scribus)[source]: Add patch. --- gnu/local.mk | 1 + gnu/packages/patches/scribus-poppler.patch | 72 ++++++++++++++++++++++++++++++ gnu/packages/scribus.scm | 4 +- 3 files changed, 75 insertions(+), 2 deletions(-) create mode 100644 gnu/packages/patches/scribus-poppler.patch (limited to 'gnu/packages/patches') diff --git a/gnu/local.mk b/gnu/local.mk index 29d07f5192..772002c9cf 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -1145,6 +1145,7 @@ dist_patch_DATA = \ %D%/packages/patches/scotch-build-parallelism.patch \ %D%/packages/patches/scotch-graph-diam-64.patch \ %D%/packages/patches/scotch-graph-induce-type-64.patch \ + %D%/packages/patches/scribus-poppler.patch \ %D%/packages/patches/sdl-libx11-1.6.patch \ %D%/packages/patches/seq24-rename-mutex.patch \ %D%/packages/patches/sharutils-CVE-2018-1000097.patch \ diff --git a/gnu/packages/patches/scribus-poppler.patch b/gnu/packages/patches/scribus-poppler.patch new file mode 100644 index 0000000000..9b969e4cb6 --- /dev/null +++ b/gnu/packages/patches/scribus-poppler.patch @@ -0,0 +1,72 @@ +Fix build with recent Poppler. + +From d867ec3c386baaed1b8e076dd70b278863411480 Mon Sep 17 00:00:00 2001 +From: Jean Ghali +Date: Mon, 30 Apr 2018 09:19:33 +0000 +Subject: [PATCH] =?UTF-8?q?#15289:=20FTBFS=201.5.4=20with=20error:=20inval?= + =?UTF-8?q?id=20conversion=20from=20=E2=80=98const=20GooString*=E2=80=99?= + =?UTF-8?q?=20to=20=E2=80=98GooString*=E2=80=99?= +MIME-Version: 1.0 +Content-Type: text/plain; charset=UTF-8 +Content-Transfer-Encoding: 8bit + +git-svn-id: svn://scribus.net/trunk/Scribus@22498 11d20701-8431-0410-a711-e3c959e3b870 +--- + scribus/plugins/import/pdf/importpdf.cpp | 2 +- + scribus/plugins/import/pdf/importpdf.h | 2 +- + scribus/plugins/import/pdf/slaoutput.cpp | 2 +- + scribus/plugins/import/pdf/slaoutput.h | 2 +- + 4 files changed, 4 insertions(+), 4 deletions(-) + +diff --git a/scribus/plugins/import/pdf/importpdf.cpp b/scribus/plugins/import/pdf/importpdf.cpp +index c1802861aa..d4c5a9ba49 100644 +--- a/scribus/plugins/import/pdf/importpdf.cpp ++++ b/scribus/plugins/import/pdf/importpdf.cpp +@@ -1081,7 +1081,7 @@ QRectF PdfPlug::getCBox(int box, int pgNum) + return cRect; + } + +-QString PdfPlug::UnicodeParsedString(GooString *s1) ++QString PdfPlug::UnicodeParsedString(const GooString *s1) + { + if ( !s1 || s1->getLength() == 0 ) + return QString(); +diff --git a/scribus/plugins/import/pdf/importpdf.h b/scribus/plugins/import/pdf/importpdf.h +index c8c5efcd0d..5249562692 100644 +--- a/scribus/plugins/import/pdf/importpdf.h ++++ b/scribus/plugins/import/pdf/importpdf.h +@@ -81,7 +81,7 @@ class PdfPlug : public QObject + private: + bool convert(const QString& fn); + QRectF getCBox(int box, int pgNum); +- QString UnicodeParsedString(GooString *s1); ++ QString UnicodeParsedString(const GooString *s1); + + QList Elements; + double baseX, baseY; +diff --git a/scribus/plugins/import/pdf/slaoutput.cpp b/scribus/plugins/import/pdf/slaoutput.cpp +index be1815dc29..17b6357246 100644 +--- a/scribus/plugins/import/pdf/slaoutput.cpp ++++ b/scribus/plugins/import/pdf/slaoutput.cpp +@@ -4252,7 +4252,7 @@ void SlaOutputDev::pushGroup(QString maskName, GBool forSoftMask, GBool alpha, b + m_groupStack.push(gElements); + } + +-QString SlaOutputDev::UnicodeParsedString(GooString *s1) ++QString SlaOutputDev::UnicodeParsedString(const GooString *s1) + { + if ( !s1 || s1->getLength() == 0 ) + return QString(); +diff --git a/scribus/plugins/import/pdf/slaoutput.h b/scribus/plugins/import/pdf/slaoutput.h +index 20e8b2d311..6698c030e0 100644 +--- a/scribus/plugins/import/pdf/slaoutput.h ++++ b/scribus/plugins/import/pdf/slaoutput.h +@@ -266,7 +266,7 @@ class SlaOutputDev : public OutputDev + int getBlendMode(GfxState *state); + void applyMask(PageItem *ite); + void pushGroup(QString maskName = "", GBool forSoftMask = gFalse, GBool alpha = gFalse, bool inverted = false); +- QString UnicodeParsedString(GooString *s1); ++ QString UnicodeParsedString(const GooString *s1); + bool checkClip(); + bool pathIsClosed; + QString CurrColorFill; diff --git a/gnu/packages/scribus.scm b/gnu/packages/scribus.scm index dca1dc86e1..615d7e23a2 100644 --- a/gnu/packages/scribus.scm +++ b/gnu/packages/scribus.scm @@ -1,5 +1,5 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2015 Ricardo Wurmus +;;; Copyright © 2015, 2018 Ricardo Wurmus ;;; Copyright © 2016 Efraim Flashner ;;; Copyright © 2017, 2018 Nicolas Goaziou ;;; Copyright © 2018 Clément Lassieur @@ -56,7 +56,7 @@ (sha256 (base32 "00ys0p6h3iq77kh72dkl0qrf7qvznq18qdrgiq10gfxja1995034")) - (modules '((guix build utils))))) + (patches (search-patches "scribus-poppler.patch")))) (build-system cmake-build-system) (arguments `(#:tests? #f ;no test target -- cgit 1.4.1