Gentoo Archives: gentoo-commits

From: "Samuli Suominen (ssuominen)" <ssuominen@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in www-misc/zoneminder/files/1.24.2: zm_jpeg.patch
Date: Mon, 22 Feb 2010 15:39:20
Message-Id: E1NjaNR-0008VF-UT@stork.gentoo.org
1 ssuominen 10/02/22 15:39:17
2
3 Added: zm_jpeg.patch
4 Log:
5 Fix building with jpeg-8 (previous declaration of jpeg_mem_src and jpeg_mem_dest) wrt #305201, thanks to Alex. P. Burlutsky for patch.
6 (Portage version: 2.2_rc63/cvs/Linux x86_64)
7
8 Revision Changes Path
9 1.1 www-misc/zoneminder/files/1.24.2/zm_jpeg.patch
10
11 file : http://sources.gentoo.org/viewcvs.py/gentoo-x86/www-misc/zoneminder/files/1.24.2/zm_jpeg.patch?rev=1.1&view=markup
12 plain: http://sources.gentoo.org/viewcvs.py/gentoo-x86/www-misc/zoneminder/files/1.24.2/zm_jpeg.patch?rev=1.1&content-type=text/plain
13
14 Index: zm_jpeg.patch
15 ===================================================================
16 diff -ur ZoneMinder-1.24.2.orig/src/zm_image.cpp ZoneMinder-1.24.2/src/zm_image.cpp
17 --- ZoneMinder-1.24.2.orig/src/zm_image.cpp 2009-05-25 21:04:00.000000000 +0300
18 +++ ZoneMinder-1.24.2/src/zm_image.cpp 2010-02-22 17:43:14.000000000 +0200
19 @@ -461,7 +461,7 @@
20 return( false );
21 }
22
23 - jpeg_mem_src( cinfo, inbuffer, inbuffer_size );
24 + zm_jpeg_mem_src( cinfo, inbuffer, inbuffer_size );
25
26 jpeg_read_header( cinfo, TRUE );
27
28 @@ -523,7 +523,7 @@
29 jpeg_create_compress( cinfo );
30 }
31
32 - jpeg_mem_dest( cinfo, outbuffer, outbuffer_size );
33 + zm_jpeg_mem_dest( cinfo, outbuffer, outbuffer_size );
34
35 cinfo->image_width = width; /* image width and height, in pixels */
36 cinfo->image_height = height;
37 diff -ur ZoneMinder-1.24.2.orig/src/zm_jpeg.c ZoneMinder-1.24.2/src/zm_jpeg.c
38 --- ZoneMinder-1.24.2.orig/src/zm_jpeg.c 2009-03-20 14:07:00.000000000 +0200
39 +++ ZoneMinder-1.24.2/src/zm_jpeg.c 2010-02-22 17:43:14.000000000 +0200
40 @@ -173,7 +173,7 @@
41 * for closing it after finishing compression.
42 */
43
44 -void jpeg_mem_dest (j_compress_ptr cinfo, JOCTET *outbuffer, int *outbuffer_size )
45 +void zm_jpeg_mem_dest (j_compress_ptr cinfo, JOCTET *outbuffer, int *outbuffer_size )
46 {
47 mem_dest_ptr dest;
48
49 @@ -350,12 +350,12 @@
50 * for closing it after finishing decompression.
51 */
52
53 -void jpeg_mem_src( j_decompress_ptr cinfo, const JOCTET *inbuffer, int inbuffer_size )
54 +void zm_jpeg_mem_src( j_decompress_ptr cinfo, const JOCTET *inbuffer, int inbuffer_size )
55 {
56 mem_src_ptr src;
57
58 /* The source object and input buffer are made permanent so that a series
59 - * of JPEG images can be read from the same file by calling jpeg_mem_src
60 + * of JPEG images can be read from the same file by calling zm_jpeg_mem_src
61 * only before the first one. (If we discarded the buffer at the end of
62 * one image, we'd likely lose the start of the next one.)
63 * This makes it unsafe to use this manager and a different source
64 diff -ur ZoneMinder-1.24.2.orig/src/zm_jpeg.h ZoneMinder-1.24.2/src/zm_jpeg.h
65 --- ZoneMinder-1.24.2.orig/src/zm_jpeg.h 2009-03-20 14:07:00.000000000 +0200
66 +++ ZoneMinder-1.24.2/src/zm_jpeg.h 2010-02-22 17:43:14.000000000 +0200
67 @@ -36,5 +36,5 @@
68 void zm_jpeg_emit_message( j_common_ptr cinfo, int msg_level );
69
70 // Prototypes for memory compress/decompression object */
71 -void jpeg_mem_src(j_decompress_ptr cinfo, const JOCTET *inbuffer, int inbuffer_size );
72 -void jpeg_mem_dest(j_compress_ptr cinfo, JOCTET *outbuffer, int *outbuffer_size );
73 +void zm_jpeg_mem_src(j_decompress_ptr cinfo, const JOCTET *inbuffer, int inbuffer_size );
74 +void zm_jpeg_mem_dest(j_compress_ptr cinfo, JOCTET *outbuffer, int *outbuffer_size );