void-packages/srcpkgs/winusb/patches/wxwidget-compatible.patch
Đoàn Trần Công Danh 04b9978a29 srcpkgs/w*: convert patches to -Np1
* wine 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

19 lines
878 B
Diff

--- a/src/findFile.cpp 2013-03-27 22:57:44.000000000 +0100
+++ b/src/findFile.cpp 2014-02-17 17:16:01.256683107 +0100
@@ -37,14 +37,14 @@
}
#if defined(__UNIX__)
- testPath = wxString(wxStandardPaths().GetInstallPrefix() + _T("/share/") + _T(PACKAGE) + _T("/") + str);
+ testPath = wxString(wxStandardPaths::Get().GetInstallPrefix() + _T("/share/") + _T(PACKAGE) + _T("/") + str);
if(wxFileExists(testPath) || wxDirExists(testPath)) // Si c'est dans le dossier /usr/.../share/nomprog
{
return testPath;
}
#endif // defined(__UNIX__)
- testPath = wxString(wxStandardPaths().GetDataDir() + _T("/") + str);
+ testPath = wxString(wxStandardPaths::Get().GetDataDir() + _T("/") + str);
if(wxFileExists(testPath) || wxDirExists(testPath)) // Si c'est dans le dossier /usr/.../share/nomPaquet
{
return testPath;