home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1992 #27 / NN_1992_27.iso / spool / comp / sys / next / programm / 7299 < prev    next >
Encoding:
Internet Message Format  |  1992-11-18  |  2.0 KB

  1. Path: sparky!uunet!ornl!rsg1.er.usgs.gov!darwin.sura.net!zaphod.mps.ohio-state.edu!cs.utexas.edu!ut-emx!ccwf.cc.utexas.edu!jdawson
  2. From: jdawson@ccwf.cc.utexas.edu (John Dawson)
  3. Newsgroups: comp.sys.next.programmer
  4. Subject: Can anyone link with libsys_p.a under 3.0?
  5. Message-ID: <JDAWSON.92Nov18215141@donald.cc.utexas.edu>
  6. Date: 19 Nov 92 03:51:41 GMT
  7. Sender: news@ut-emx.uucp
  8. Organization: The University of Texas at Austin
  9. Lines: 39
  10.  
  11. Since 3.0, I've lost the ability to compile a profiled application and
  12. link it with the library sys_p.  I can find no way to perform linking
  13. using cc that doesn't generate reams of duplicate symbols if I tell
  14. it to link with sys_p; i.e.,
  15.  
  16. % cc -g -pg -O -Wall -DPROFILE -ObjC -sectcreate __ICON
  17. __header g.iconheader -segprot __ICON r r -sectcreate __ICON app
  18. /usr/lib/NextStep/Workspace.app/application.tiff -o g.profile/g
  19. profile_obj/g_main.o -lNeXT_p -lsys_p
  20.  
  21. ... generates ...
  22.  
  23. /bin/ld: multiple definitions of symbol .objc_class_name_MethodSignature
  24. /lib/libsys_p.a(NXProxy.o) definition of absolute .objc_class_name_MethodSignature (value 0x0)
  25. /lib/libsys_s.a(NXProxy.o) definition of absolute .objc_class_name_MethodSignature (value 0x0)
  26.  
  27. ... etc., on and on and on.
  28.  
  29. Further, invoking ld by hand seems to "work" -- it will generate a
  30. runnable binary without complaint -- but programs generated in this
  31. manner seg fault from within objc_msgSend before getting very far.
  32. I.e.,
  33.  
  34. % ld -ObjC -sectcreate __ICON __header g.iconheader -segprot __ICON r
  35. r -sectcreate __ICON app /usr/lib/NextStep/Workspace.app/application.tiff
  36. -o g.profile/g profile_obj/g_main.o /lib/crt0.o -lNeXT_p -lsys_p
  37.  
  38. ... generates a program without error; its exit code is 0.  But if
  39. you run the program, it crashes instantly.  Note that this particular
  40. program doesn't even have any code I wrote; it has no central brain.
  41. It's the complete minimum possible application generated with PB and
  42. IB.
  43.  
  44. Anyone know why it doesn't work?  Or better yet, how to make it
  45. work?
  46.  
  47. ...jkd
  48. --
  49. jdawson@ccwf.cc.utexas.edu (John Dawson)
  50.