editors/kakoune: fix build on armv6/armv7

https://github.com/mawww/kakoune/issues/4385

PR:		259434
(cherry picked from commit 13c431b0bf)
This commit is contained in:
Robert Clausecker 2021-10-25 13:49:33 +02:00 committed by Tobias Kortkamp
parent 7c6c750a79
commit 3f89e8c6ed
No known key found for this signature in database
GPG Key ID: A4F09FB73CC51F61
1 changed files with 17 additions and 0 deletions

View File

@ -0,0 +1,17 @@
--- src/main.cc.orig 2021-10-25 11:31:24 UTC
+++ src/main.cc
@@ -1249,8 +1249,12 @@ int main(int argc, char* argv[])
}
#if defined(__ELF__)
-asm(R"(
-.pushsection ".debug_gdb_scripts", "MS",@progbits,1
+#ifdef __arm__
+# define PROGBITS "%progbits"
+#else
+# define PROGBITS "@progbits"
+#endif
+asm(".pushsection \".debug_gdb_scripts\", \"MS\"," PROGBITS ",1" R"(
.byte 4
.ascii "kakoune-inline-gdb.py\n"
.ascii "import os.path\n"