diff options
Diffstat (limited to 'dev-lang/yasm')
-rw-r--r-- | dev-lang/yasm/Manifest | 3 | ||||
-rw-r--r-- | dev-lang/yasm/files/yasm-1.3.0-fix-modern-c.patch | 87 | ||||
-rw-r--r-- | dev-lang/yasm/yasm-1.3.0-r2.ebuild (renamed from dev-lang/yasm/yasm-1.3.0-r1.ebuild) | 8 |
3 files changed, 95 insertions, 3 deletions
diff --git a/dev-lang/yasm/Manifest b/dev-lang/yasm/Manifest index 0556de791556..b56b512364a6 100644 --- a/dev-lang/yasm/Manifest +++ b/dev-lang/yasm/Manifest @@ -1,3 +1,4 @@ +AUX yasm-1.3.0-fix-modern-c.patch 2584 BLAKE2B 5c967ff7bfdd250f78650c1d5b5b92edb573c77ab457441101da1a903359baa761a9fc83a789dc072dc1dcb2e4f7a214df38a7bf5f365eb9d3085d65eed70c93 SHA512 e78d9032e05f9241755af49d0e08a2f6d5eb3843582040f68dc63364c1d90743d8247304d46fee3455daf7a252919f231b3d43f234190bc5175d4e4ee44fefea DIST yasm-1.3.0.tar.gz 1492156 BLAKE2B e419a4f9912eb244e9503462dbf0c5e5c95bdfa49583ee205dc4708b42710df8dd2056b2e36e04de04474f4af900916cb64c14a623db1346c3e1cb46a8cc34a5 SHA512 572d3b45568b10f58e48f1188c2d6bcbdd16429c8afaccc8c6d37859b45635e106885d679e41d0bee78c23822108c7ae75aa7475eed5ba58057e0a6fe1b68645 -EBUILD yasm-1.3.0-r1.ebuild 1232 BLAKE2B b9768cb8232d4800331c857232254b57fe12d14342193500540389601c15aeb93742174c972eb507fa024b018ac3fbe059fe75c204d5c59bbfa030f3eb326ff8 SHA512 9fa76f7529ac4df147450bbb75a7c255abf96c8a19c4735f6e81faefc9653b05c6c873f269b7214a51d6ca1187d590883a2550b158545c87367a535034efe694 +EBUILD yasm-1.3.0-r2.ebuild 1284 BLAKE2B 69db204feb150494b7de1873114fd9013ec98f8391fe5bf11ff70449f8c29433d8bac0fbd49738619f62cad30bc47b2e241d40f47224ad74dcd229902644d18a SHA512 6cdf3db9d83e383c4c84b4c52ca89ae0abf1d86652244b94b8ce7ab43cf5610078a5112615794e181147166a5d87dd29784a3ad762bbd26328cca7ad431e9844 MISC metadata.xml 393 BLAKE2B c1a2f5a55132dd63f7ba78e4b78600d87f462995e6d692ed3500fbab47b8a95fb16b292956e07279e1a9183e6abd44b38e1448bd6b48a9652d2e8660a02ea136 SHA512 d486d9fa65b102b36665e84436f23c6b1897aca20c1451eaa5e36ad5d00b8020da73583de3948a73af3d860bee243caea15da9904187b3dbf1700ba9ed39136c diff --git a/dev-lang/yasm/files/yasm-1.3.0-fix-modern-c.patch b/dev-lang/yasm/files/yasm-1.3.0-fix-modern-c.patch new file mode 100644 index 000000000000..61f1e88634f0 --- /dev/null +++ b/dev-lang/yasm/files/yasm-1.3.0-fix-modern-c.patch @@ -0,0 +1,87 @@ +https://github.com/yasm/yasm/commit/f79f5e37f0e4b06d5dc303cc219929d7359dd7df +From: Biswapriyo Nath <nathbappai@gmail.com> +Date: Thu, 18 May 2023 03:53:32 +0530 +Subject: [PATCH] Fix function declaration warnings with clang (#226) + +This fixes the following compiler warnings with clang + +tools/genperf/perfect.c:65:6: warning: a function definition without a prototype +is deprecated in all versions of C and is not supported in C2x [-Wdeprecated-non-prototype] + +frontends/yasm/yasm.c:1379:23: warning: a function declaration without a prototype +is deprecated in all versions of C [-Wstrict-prototypes] + +modules/objfmts/elf/elf.c:225:18: warning: a function declaration without a prototype +is deprecated in all versions of C [-Wstrict-prototypes] +--- a/frontends/tasm/tasm.c ++++ b/frontends/tasm/tasm.c +@@ -817,7 +817,7 @@ opt_exe_handler(char *cmd, /*@unused@*/ char *param, int extra) + } + + static void +-apply_preproc_builtins() ++apply_preproc_builtins(void) + { + char *predef; + +@@ -853,7 +853,7 @@ apply_preproc_standard_macros(const yasm_stdmac *stdmacs) + } + + static void +-apply_preproc_saved_options() ++apply_preproc_saved_options(void) + { + constcharparam *cp, *cpnext; + +--- a/frontends/yasm/yasm.c ++++ b/frontends/yasm/yasm.c +@@ -1376,7 +1376,7 @@ opt_plugin_handler(/*@unused@*/ char *cmd, char *param, + #endif + + static void +-apply_preproc_builtins() ++apply_preproc_builtins(void) + { + char *predef; + +@@ -1409,7 +1409,7 @@ apply_preproc_standard_macros(const yasm_stdmac *stdmacs) + } + + static void +-apply_preproc_saved_options() ++apply_preproc_saved_options(void) + { + constcharparam *cp, *cpnext; + +--- a/modules/objfmts/elf/elf.c ++++ b/modules/objfmts/elf/elf.c +@@ -222,7 +222,7 @@ elf_strtab_entry_set_str(elf_strtab_entry *entry, const char *str) + } + + elf_strtab_head * +-elf_strtab_create() ++elf_strtab_create(void) + { + elf_strtab_head *strtab = yasm_xmalloc(sizeof(elf_strtab_head)); + elf_strtab_entry *entry = yasm_xmalloc(sizeof(elf_strtab_entry)); +@@ -373,7 +373,7 @@ elf_ssym_symtab_entry_print(void *data, FILE *f, int indent_level) + } + + elf_symtab_head * +-elf_symtab_create() ++elf_symtab_create(void) + { + elf_symtab_head *symtab = yasm_xmalloc(sizeof(elf_symtab_head)); + elf_symtab_entry *entry = yasm_xmalloc(sizeof(elf_symtab_entry)); +--- a/tools/genperf/perfect.c ++++ b/tools/genperf/perfect.c +@@ -62,8 +62,7 @@ Find the mapping that will produce a perfect hash + */ + + /* return the ceiling of the log (base 2) of val */ +-ub4 phash_log2(val) +-ub4 val; ++ub4 phash_log2(ub4 val) + { + ub4 i; + for (i=0; ((ub4)1<<i) < val; ++i) diff --git a/dev-lang/yasm/yasm-1.3.0-r1.ebuild b/dev-lang/yasm/yasm-1.3.0-r2.ebuild index 4d76cccfeeb9..7bbb5163d765 100644 --- a/dev-lang/yasm/yasm-1.3.0-r1.ebuild +++ b/dev-lang/yasm/yasm-1.3.0-r2.ebuild @@ -1,7 +1,7 @@ -# Copyright 1999-2021 Gentoo Authors +# Copyright 1999-2024 Gentoo Authors # Distributed under the terms of the GNU General Public License v2 -EAPI=7 +EAPI=8 inherit toolchain-funcs @@ -37,6 +37,10 @@ if [[ ${PV} == 9999* ]]; then " fi +PATCHES=( + "${FILESDIR}"/${P}-fix-modern-c.patch +) + src_prepare() { default |