Subject: gnu/usr.bin/ld/ns32k problem
To: 532bsd Mailing List <port-pc532@sun-lamp.cs.berkeley.edu>
From: Matthias Pfaller <leo@marco.de>
List: port-pc532
Date: 08/16/1994 10:49:53
Hi,

finally I got burned by the 532's icache :-). A short fix for the problem
follows.

	Matthias

*** gnu/usr.bin/ld/ns32k/md.c.orig	Sun Aug 14 14:46:17 1994
--- gnu/usr.bin/ld/ns32k/md.c	Sun Aug 14 14:45:51 1994
***************
*** 315,321 ****
--- 315,330 ----
  {
  	put_num(sp->code, BR, 2);
  	put_disp(sp->code + 2, addr - offset - 1, 4);
+ #ifdef RTLD
+ /*
+  * Selfmodifing code is a problem on systems with
+  * instruction cache. If sp->reloc_index is not changed
+  * by ld.so, eventually binder will be more then once, but
+  * it will work at least.
+  */
+ #else
  	sp->reloc_index = 0;
+ #endif
  }
  
  /*


------------------------------------------------------------------------------