aboutsummaryrefslogtreecommitdiff
path: root/gnu
diff options
context:
space:
mode:
authorMarius Bakke <mbakke@fastmail.com>2019-07-18 16:31:14 +0200
committerMarius Bakke <mbakke@fastmail.com>2019-07-18 16:31:14 +0200
commit995c30d0d65c1ad8c98897a7b0ff08740dbed38f (patch)
tree8b38de27f738e90f1d35d2d94a38d5443436c612 /gnu
parent0de9a1be04a2f93bcdf81bdb0f6c2dca12225974 (diff)
downloadguix-995c30d0d65c1ad8c98897a7b0ff08740dbed38f.tar.gz
guix-995c30d0d65c1ad8c98897a7b0ff08740dbed38f.zip
gnu: libmp4v2: Fix build with C++11.
* gnu/packages/patches/libmp4v2-c++11.patch: New file. * gnu/local.mk (dist_patch_DATA): Adjust accordingly. * gnu/packages/video.scm (libmp4v2)[source](patches): New field.
Diffstat (limited to 'gnu')
-rw-r--r--gnu/local.mk1
-rw-r--r--gnu/packages/patches/libmp4v2-c++11.patch14
-rw-r--r--gnu/packages/video.scm1
3 files changed, 16 insertions, 0 deletions
diff --git a/gnu/local.mk b/gnu/local.mk
index 49c3826685..e97ff507e9 100644
--- a/gnu/local.mk
+++ b/gnu/local.mk
@@ -1023,6 +1023,7 @@ dist_patch_DATA = \
%D%/packages/patches/libmad-armv7-thumb-pt2.patch \
%D%/packages/patches/libmad-frame-length.patch \
%D%/packages/patches/libmad-mips-newgcc.patch \
+ %D%/packages/patches/libmp4v2-c++11.patch \
%D%/packages/patches/libmygpo-qt-fix-qt-5.11.patch \
%D%/packages/patches/libmygpo-qt-missing-qt5-modules.patch \
%D%/packages/patches/libreoffice-boost.patch \
diff --git a/gnu/packages/patches/libmp4v2-c++11.patch b/gnu/packages/patches/libmp4v2-c++11.patch
new file mode 100644
index 0000000000..e12f89bd84
--- /dev/null
+++ b/gnu/packages/patches/libmp4v2-c++11.patch
@@ -0,0 +1,14 @@
+Avoid a type mismatch that shows up in C++11.
+Taken from <https://bugs.debian.org/853560>.
+
+--- a/src/rtphint.cpp 2012-05-20 16:11:53.000000000 -0600
++++ b/src/rtphint.cpp 2017-05-16 10:25:26.930705191 -0600
+@@ -339,7 +339,7 @@
+ pSlash = strchr(pSlash, '/');
+ if (pSlash != NULL) {
+ pSlash++;
+- if (pSlash != '\0') {
++ if (*pSlash != '\0') {
+ length = (uint32_t)strlen(pRtpMap) - (pSlash - pRtpMap);
+ *ppEncodingParams = (char *)MP4Calloc(length + 1);
+ strncpy(*ppEncodingParams, pSlash, length);
diff --git a/gnu/packages/video.scm b/gnu/packages/video.scm
index 995f7fab15..5fa9070ba7 100644
--- a/gnu/packages/video.scm
+++ b/gnu/packages/video.scm
@@ -2746,6 +2746,7 @@ of modern, widely supported codecs.")
"code-archive-downloads/v2/"
"code.google.com/mp4v2/mp4v2-" version ".tar.bz2"))
(file-name (string-append name "-" version ".tar.bz2"))
+ (patches (search-patches "libmp4v2-c++11.patch"))
(sha256
(base32
"0f438bimimsvxjbdp4vsr8hjw2nwggmhaxgcw07g2z361fkbj683"))))
nv "HOME"))))) ((@ (guix build utils) mkdir-p) log-dir) (system* #$(file-append shepherd "/bin/shepherd") "--logfile" (string-append log-dir "/shepherd.log") "--config" #$(home-shepherd-configuration-file services shepherd)))) #~""))) (define (reload-configuration-gexp config) (let* ((shepherd (home-shepherd-configuration-shepherd config)) (services (home-shepherd-configuration-services config))) #~(system* #$(file-append shepherd "/bin/herd") "load" "root" #$(home-shepherd-configuration-file services shepherd)))) (define (ensure-shepherd-gexp config) #~(if (file-exists? (string-append (or (getenv "XDG_RUNTIME_DIR") (format #f "/run/user/~a" (getuid))) "/shepherd/socket")) #$(reload-configuration-gexp config) #$(launch-shepherd-gexp config))) (define-public home-shepherd-service-type (service-type (name 'home-shepherd) (extensions (list (service-extension home-run-on-first-login-service-type launch-shepherd-gexp) (service-extension home-activation-service-type ensure-shepherd-gexp) (service-extension home-profile-service-type (lambda (config) `(,(home-shepherd-configuration-shepherd config)))))) (compose concatenate) (extend (lambda (config extra-services) (home-shepherd-configuration (inherit config) (services (append (home-shepherd-configuration-services config) extra-services))))) (default-value (home-shepherd-configuration)) (description "Configure and install userland Shepherd.")))