void-packages/srcpkgs/maturin/patches/target-lexicon-ppcle.patch
Đoàn Trần Công Danh 765e304c4b srcpkgs/m*: convert patches to -Np1
```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

42 lines
1.3 KiB
Diff

--- a/target-lexicon/src/targets.rs
+++ b/target-lexicon/src/targets.rs
@@ -26,6 +26,7 @@
Msp430,
Nvptx64,
Powerpc,
+ PowerpcLe,
Powerpc64,
Powerpc64le,
Riscv32(Riscv32Architecture),
@@ -517,6 +518,7 @@
| Mips64(Mips64Architecture::Mipsisa64r6el)
| Msp430
| Nvptx64
+ | PowerpcLe
| Powerpc64le
| Riscv32(_)
| Riscv64(_)
@@ -553,6 +555,7 @@
| Sparc
| Wasm32
| Mips32(_)
+ | PowerpcLe
| Powerpc => Ok(PointerWidth::U32),
AmdGcn
| Powerpc64le
@@ -737,6 +740,7 @@
Msp430 => f.write_str("msp430"),
Nvptx64 => f.write_str("nvptx64"),
Powerpc => f.write_str("powerpc"),
+ PowerpcLe => f.write_str("powerpcle"),
Powerpc64 => f.write_str("powerpc64"),
Powerpc64le => f.write_str("powerpc64le"),
Riscv32(riscv32) => riscv32.fmt(f),
@@ -913,6 +917,7 @@
"msp430" => Msp430,
"nvptx64" => Nvptx64,
"powerpc" => Powerpc,
+ "powerpcle" => PowerpcLe,
"powerpc64" => Powerpc64,
"powerpc64le" => Powerpc64le,
"s390x" => S390x,