* [gentoo-commits] repo/gentoo:master commit in: dev-lang/mmix/, dev-lang/mmix/files/
@ 2015-09-20 1:45 Matthias Maier
0 siblings, 0 replies; 2+ messages in thread
From: Matthias Maier @ 2015-09-20 1:45 UTC (permalink / raw
To: gentoo-commits
commit: c7f7df5434de4a699fd95a346651cfa3f4ce148c
Author: Matthias Maier <tamiko <AT> gentoo <DOT> org>
AuthorDate: Sun Sep 20 01:44:38 2015 +0000
Commit: Matthias Maier <tamiko <AT> gentoo <DOT> org>
CommitDate: Sun Sep 20 01:45:26 2015 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=c7f7df54
dev-lang/mmix: Compilation fix for format-security, bug #533694
Gentoo-Bug: 533694
Package-Manager: portage-2.2.20.1
.../mmix/files/mmix-20131017-format-security.patch | 59 ++++++++++++++++++++++
dev-lang/mmix/mmix-20131017.ebuild | 1 +
2 files changed, 60 insertions(+)
diff --git a/dev-lang/mmix/files/mmix-20131017-format-security.patch b/dev-lang/mmix/files/mmix-20131017-format-security.patch
new file mode 100644
index 0000000..3824765
--- /dev/null
+++ b/dev-lang/mmix/files/mmix-20131017-format-security.patch
@@ -0,0 +1,59 @@
+diff --git a/mmix-pipe.w b/mmix-pipe.w
+index b7f4536..a1a9a48 100644
+--- a/mmix-pipe.w
++++ b/mmix-pipe.w
+@@ -1883,7 +1883,7 @@ static void print_specnode_id(a)
+ octa a;
+ {
+ if (a.h==sign_bit) {
+- if (a.l<32) printf(special_name[a.l]);
++ if (a.l<32) fputs(special_name[a.l], stdout);
+ else if (a.l<256) printf("g[%d]",a.l);
+ else printf("l[%d]",a.l-256);
+ }@+else if (a.h!=(tetra)-1) {
+diff --git a/mmix-sim.w b/mmix-sim.w
+index cb6995c..176f60c 100644
+--- a/mmix-sim.w
++++ b/mmix-sim.w
+@@ -2832,7 +2832,7 @@ void trace_print(o)
+ case hex: fputc('#',stdout);@+print_hex(o);@+return;
+ case zhex: printf("%08x%08x",o.h,o.l);@+return;
+ case floating: print_float(o);@+return;
+- case handle:@+if (o.h==0 && o.l<3) printf(stream_name[o.l]);
++ case handle:@+if (o.h==0 && o.l<3) fputs(stream_name[o.l], stdout);
+ else print_int(o);@+return;
+ }
+ }
+@@ -2843,9 +2843,9 @@ case ')': fputc(right_paren[round_mode],stdout);@+break;
+ case 't':@+if (x.l) printf(" Yes, -> #"),print_hex(inst_ptr);
+ else printf(" No");@+break;
+ case 'g':@+if (!good) printf(" (bad guess)");@+break;
+-case 's': printf(special_name[zz]);@+break;
++case 's': fputs(special_name[zz], stdout);@+break;
+ case '?': p++;@+if (z.l) printf("%c%d",*p,z.l);@+break;
+-case 'l': printf(lhs);@+break;
++case 'l': fputs(lhs, stdout);@+break;
+ case 'r': p=switchable_string;@+break;
+
+ @ @d rhs &switchable_string[1]
+@@ -2984,9 +2984,9 @@ void scan_option(arg,usage)
+ fprintf(stderr,
+ "Usage: %s <options> progfile command line-args...\n",myself);
+ @.Usage: ...@>
+- for (k=0;usage_help[k][0];k++) fprintf(stderr,usage_help[k]);
++ for (k=0;usage_help[k][0];k++) fputs(usage_help[k], stderr);
+ exit(-1);
+- }@+else@+ for (k=0;usage_help[k][1]!='b';k++) printf(usage_help[k]);
++ }@+else@+ for (k=0;usage_help[k][1]!='b';k++) fputs(usage_help[k], stdout);
+ return;
+ }
+ }
+@@ -3090,7 +3090,7 @@ void catchint(n)
+ printf("Eh? Sorry, I don't understand `%s'. (Type h for help)\n",
+ command_buf);
+ goto interact;
+- case 'h':@+ for (k=0;interactive_help[k][0];k++) printf(interactive_help[k]);
++ case 'h':@+ for (k=0;interactive_help[k][0];k++) fputs(interactive_help[k], stdout);
+ goto interact;
+ }
+ check_syntax:@+ if (*p!='\n') {
diff --git a/dev-lang/mmix/mmix-20131017.ebuild b/dev-lang/mmix/mmix-20131017.ebuild
index d9c9c76..b233a67 100644
--- a/dev-lang/mmix/mmix-20131017.ebuild
+++ b/dev-lang/mmix/mmix-20131017.ebuild
@@ -25,6 +25,7 @@ S="${WORKDIR}"
src_prepare() {
epatch "${FILESDIR}"/${PN}-20110420-makefile.patch
+ epatch "${FILESDIR}"/${PN}-20131017-format-security.patch
}
src_compile() {
^ permalink raw reply related [flat|nested] 2+ messages in thread
* [gentoo-commits] repo/gentoo:master commit in: dev-lang/mmix/, dev-lang/mmix/files/
@ 2020-03-12 23:14 Sergei Trofimovich
0 siblings, 0 replies; 2+ messages in thread
From: Sergei Trofimovich @ 2020-03-12 23:14 UTC (permalink / raw
To: gentoo-commits
commit: a976eefad7cd78cf43c28d3d73884473327eea73
Author: Sergei Trofimovich <slyfox <AT> gentoo <DOT> org>
AuthorDate: Thu Mar 12 23:13:57 2020 +0000
Commit: Sergei Trofimovich <slyfox <AT> gentoo <DOT> org>
CommitDate: Thu Mar 12 23:13:57 2020 +0000
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=a976eefa
dev-lang/mmix: tweak for gcc-10
Package-Manager: Portage-2.3.93, Repoman-2.3.20
Signed-off-by: Sergei Trofimovich <slyfox <AT> gentoo.org>
dev-lang/mmix/files/mmix-20160804-gcc-10.patch | 24 ++++++++++++++++++++++++
dev-lang/mmix/mmix-20160804-r1.ebuild | 3 ++-
2 files changed, 26 insertions(+), 1 deletion(-)
diff --git a/dev-lang/mmix/files/mmix-20160804-gcc-10.patch b/dev-lang/mmix/files/mmix-20160804-gcc-10.patch
new file mode 100644
index 00000000000..076d22952a5
--- /dev/null
+++ b/dev-lang/mmix/files/mmix-20160804-gcc-10.patch
@@ -0,0 +1,24 @@
+gcc-10 defaults to -fno-common. Causes linker errors for
+duplicate 'buffer' definition.
+--- a/mmix-config.w
++++ b/mmix-config.w
+@@ -357,7 +357,7 @@ print error messages.
+
+ @<Global variables@>=
+ FILE *config_file; /* input comes from here */
+-char buffer[BUF_SIZE]; /* input lines go here */
++static char buffer[BUF_SIZE]; /* input lines go here */
+ char token[BUF_SIZE]; /* and tokens are copied to here */
+ char *buf_pointer=buffer; /* this is our current position */
+ bool token_prescanned; /* does |token| contain the next token already? */
+--- a/mmmix.w
++++ b/mmmix.w
+@@ -115,7 +115,7 @@ and \Hex{fedcba9876543210} into location \Hex{0123456789b0}.
+ octa cur_loc;
+ octa cur_dat;
+ bool new_chunk;
+-char buffer[BUF_SIZE];
++static char buffer[BUF_SIZE];
+ FILE *prog_file;
+
+ @ @<Input a rudimentary hexadecimal file@>=
diff --git a/dev-lang/mmix/mmix-20160804-r1.ebuild b/dev-lang/mmix/mmix-20160804-r1.ebuild
index 65491269b4a..15e84fef8c3 100644
--- a/dev-lang/mmix/mmix-20160804-r1.ebuild
+++ b/dev-lang/mmix/mmix-20160804-r1.ebuild
@@ -1,4 +1,4 @@
-# Copyright 1999-2019 Gentoo Authors
+# Copyright 1999-2020 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=7
@@ -24,6 +24,7 @@ S="${WORKDIR}"
PATCHES=(
"${FILESDIR}"/${PN}-20110420-makefile.patch
"${FILESDIR}"/${PN}-20131017-format-security.patch
+ "${FILESDIR}"/${PN}-20160804-gcc-10.patch
)
src_compile() {
^ permalink raw reply related [flat|nested] 2+ messages in thread
end of thread, other threads:[~2020-03-12 23:14 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-03-12 23:14 [gentoo-commits] repo/gentoo:master commit in: dev-lang/mmix/, dev-lang/mmix/files/ Sergei Trofimovich
-- strict thread matches above, loose matches on Subject: below --
2015-09-20 1:45 Matthias Maier
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox