diff options
author | Daniel Peebles <copumpkin@users.noreply.github.com> | 2017-03-28 21:54:32 -0400 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-03-28 21:54:32 -0400 |
commit | da79d1f01f6bd70833543cab5308d2439c429f9e (patch) | |
tree | b6abaa6e6e67df2bfa50541f945ac98e3f890510 | |
parent | f33e19aa2ccf781de01ddd94ba087db6231d35bc (diff) | |
parent | ab0ea847333b122da2927afefd7448b07f8f9093 (diff) |
Merge pull request #24428 from acowley/libdc1394-darwin
libdc1394: patch bugs on darwin
-rw-r--r-- | pkgs/development/libraries/libdc1394/darwin-fixes.patch | 24 | ||||
-rw-r--r-- | pkgs/development/libraries/libdc1394/default.nix | 2 |
2 files changed, 26 insertions, 0 deletions
diff --git a/pkgs/development/libraries/libdc1394/darwin-fixes.patch b/pkgs/development/libraries/libdc1394/darwin-fixes.patch new file mode 100644 index 0000000000000..5356a11111295 --- /dev/null +++ b/pkgs/development/libraries/libdc1394/darwin-fixes.patch @@ -0,0 +1,24 @@ +diff -Naur libdc1394-2.2.5-old/dc1394/bayer.c libdc1394-2.2.5-new/dc1394/bayer.c +--- libdc1394-2.2.5-old/dc1394/bayer.c 2016-10-11 02:19:10.000000000 -0400 ++++ libdc1394-2.2.5-new/dc1394/bayer.c 2017-03-28 17:59:02.000000000 -0400 +@@ -775,7 +775,7 @@ + { + uint8_t *outR, *outG, *outB; + register int i, j; +- uint tmp; ++ uint32_t tmp; + int st=sx*sy; + int p; + int sx2=sx<<1; +diff -Naur libdc1394-2.2.5-old/dc1394/macosx/capture.c libdc1394-2.2.5-new/dc1394/macosx/capture.c +--- libdc1394-2.2.5-old/dc1394/macosx/capture.c 2016-12-20 08:10:34.000000000 -0500 ++++ libdc1394-2.2.5-new/dc1394/macosx/capture.c 2017-03-28 17:58:38.000000000 -0400 +@@ -614,7 +614,7 @@ + dc1394video_frame_t * frame_tmp = capture->frames + next; + char ch; + +- if(craw->frames==NULL || craw->capture_is_set==0) { ++ if(craw->capture.frames==NULL || craw->capture_is_set==0) { + *frame=NULL; + return DC1394_CAPTURE_IS_NOT_SET; + } diff --git a/pkgs/development/libraries/libdc1394/default.nix b/pkgs/development/libraries/libdc1394/default.nix index c1d11ce87ee5d..036adcef74cbe 100644 --- a/pkgs/development/libraries/libdc1394/default.nix +++ b/pkgs/development/libraries/libdc1394/default.nix @@ -14,6 +14,8 @@ stdenv.mkDerivation rec { ++ stdenv.lib.optional stdenv.isLinux libraw1394 ++ stdenv.lib.optional stdenv.isDarwin CoreServices; + patches = stdenv.lib.optional stdenv.isDarwin ./darwin-fixes.patch; + meta = with stdenv.lib; { homepage = http://sourceforge.net/projects/libdc1394/; description = "Capture and control API for IIDC compliant cameras"; |