void-packages/srcpkgs/devil/patches/fix-mips-variable.patch
Đoàn Trần Công Danh b6bcd8cd34 srcpkgs/d*: convert patches to -Np1
* daemontools and dmraid is kept at -Np0

```sh

git grep -l '^patch_args=-Np0' "srcpkgs/$1*/template" |
while read template; do
	for p in ${template%/template}/patches/*; do
		sed -i '
			\,^[+-][+-][+-] /dev/null,b
			/^[*-]\+ [0-9]\+\(,[0-9]\+\)\? [*-]\+$/b
			s,^[*][*][*] ,&a/,
			/^--- /{
				s,\(^--- \)\(./\)*,\1a/,
				s,[.][Oo][Rr][Ii][Gg]\([	/]\),\1,
				s/[.][Oo][Rr][Ii][Gg]$//
				s/[.]patched[.]\([^.]\)/.\1/
				h
			}
			/^+++ -/{
				g
				s/^--- a/+++ b/
				b
			}
			s,\(^+++ \)\(./\)*,\1b/,
		' "$p"
	done
	sed -i '/^patch_args=/d' $template
done
```
2021-06-20 13:17:29 +07:00

29 lines
873 B
Diff

--- a/DevIL/src-IL/src/il_devil.cpp 2017-01-02 01:03:56.000000000 +0100
+++ b/DevIL/src-IL/src/il_devil.cpp 2017-12-08 22:20:16.696024947 +0100
@@ -187,7 +187,7 @@
// Internal version of ilTexImageSurface.
ILboolean ILAPIENTRY ilTexImageSurface_(ILimage *Image, ILuint Width, ILuint Height, ILuint Depth, ILubyte Bpp, ILenum Format, ILenum Type, void *Data)
{
- ILimage* mips;
+ ILimage* mipmaps;
ILimage* next;
ILimage* faces;
ILimage* layers;
@@ -220,7 +220,7 @@
return IL_FALSE;
}*/
- mips = Image->Mipmaps;
+ mipmaps = Image->Mipmaps;
next = Image->Next;
faces = Image->Faces;
layers = Image->Layers;
@@ -230,7 +230,7 @@
retval = ilInitImage(Image, Width, Height, Depth, Bpp, Format, Type, Data);
// reset our chains
- Image->Mipmaps = mips;
+ Image->Mipmaps = mipmaps;
Image->Next = next;
Image->Faces = faces;
Image->Layers = layers;