X-Git-Url: http://shamusworld.gotdns.org/cgi-bin/gitweb.cgi?p=rmac;a=blobdiff_plain;f=sect.c;h=781a81bda516c5e5fdbf7f0f06351a8a3e63f69e;hp=0ea53a843f1c4568dec445fcab7c7f3a179ed014;hb=ace0b549a94110b69ec61442f825fb421b79799a;hpb=8f287ee72236774216a11a3062f9a26dc8dc66b6 diff --git a/sect.c b/sect.c index 0ea53a8..781a81b 100644 --- a/sect.c +++ b/sect.c @@ -415,6 +415,15 @@ int ResolveFixups(int sno) // evexpr presumably issues the errors/warnings here if (evexpr(fup->expr, &eval, &eattr, &esym) != OK) continue; + + if (optim_pc) + if (eattr & REFERENCED) + if (eattr & DEFINED) + if (!(eattr & EQUATED)) + { + error("relocation not allowed"); + continue; + } } // Simple symbol else @@ -422,6 +431,15 @@ int ResolveFixups(int sno) SYM * sy = fup->symbol; eattr = sy->sattr; + if (optim_pc) + if (eattr & REFERENCED) + if (eattr & DEFINED) + if (!(eattr & EQUATED)) + { + error("relocation not allowed"); + continue; + } + if (eattr & DEFINED) eval = sy->svalue; else