Date:2011-01-29 14:48:54 (13 years 2 months ago)
Author:David Kühling
Commit:8b59d50ab755a21f3c1183f246174b467d249f35
Message:svgalib: fix (?) gl_fillbox & friends when used in 32-bit video modes

Files: svgalib/Makefile (1 diff)
svgalib/patches/120-fix-memsetx.patch (1 diff)

Change Details

svgalib/Makefile
136136
137137# The following comments configure the Emacs editor. Just ignore them.
138138# Local Variables:
139# compile-command: "make -C ~/h/src/qi/openwrt-xburst package/svgalib/compile -j2 V=99"
139# compile-command: "cd ~/src/nanonote/svgalib-1.4.3 && ~/bin/quilt-export target && make -C ~/h/src/qi/openwrt-xburst package/svgalib/compile -j2 V=99"
140140# End:
svgalib/patches/120-fix-memsetx.patch
1Index: svgalib-1.4.3/gl/inlstring.h
2===================================================================
3--- svgalib-1.4.3.orig/gl/inlstring.h 2011-01-29 14:33:47.000000000 +0100
4@@ -8,9 +8,22 @@
5 #define __memcpy_conventional(dst,src,n) memcpy((dst),(src),(n))
6 #define __memcpyb(dst,src,n) memcpy((dst),(src),(n))
7 #define __memsetb(dst,c,n) memset((dst),(c),(n))
8-#define __memsetlong(dst,c,n) memset((dst),(c),(n))
9 #define __memset(dst,c,n) memset((dst),(c),(n))
10-#define __memset2(dst,c,n) memset((dst),(c),2*(n))
11+static void __memsetlong(void *ptr, int c, int n)
12+{
13+ unsigned *dst = (unsigned*)ptr;
14+ int i;
15+ for (i = 0; i < n; i++)
16+ dst[i] = c;
17+}
18+static void __memset2(void *ptr, int c, int n)
19+{
20+ unsigned short *dst = (unsigned short*)ptr;
21+ int i;
22+ for (i = 0; i < n; i++)
23+ dst[i] = c;
24+}
25+/* todo: */
26 #define __memset3(dst,c,n) memset((dst),(c),3*(n))
27
28 #else

Archive Download the corresponding diff file



interactive