home *** CD-ROM | disk | FTP | other *** search
/ NetNews Usenet Archive 1993 #3 / NN_1993_3.iso / spool / comp / sys / next / programm / 8243 < prev    next >
Encoding:
Text File  |  1993-01-21  |  2.4 KB  |  60 lines

  1. Newsgroups: comp.sys.next.programmer
  2. Path: sparky!uunet!think.com!ames!pasteur!nntp
  3. From: nicolson@strauss.berkeley.edu (Ed Nicolson)
  4. Subject: Re: NXBundles and external libraries
  5. Message-ID: <1993Jan21.184110.19517@pasteur.Berkeley.EDU>
  6. Sender: nntp@pasteur.Berkeley.EDU (NNTP Poster)
  7. Nntp-Posting-Host: strauss.berkeley.edu
  8. Reply-To: nicolson@robotics.berkeley.edu
  9. Organization: University of California, at Berkeley
  10. References: <PFKEB.93Jan20214908@kaon.SLAC.Stanford.EDU>
  11. Date: Thu, 21 Jan 1993 18:41:10 GMT
  12. Lines: 46
  13.  
  14. In article <PFKEB.93Jan20214908@kaon.SLAC.Stanford.EDU>  
  15. pfkeb@kaon.SLAC.Stanford.EDU (Paul F. Kunz) writes:
  16. >    I would appreciate advice on how to best handle the following 
  17. > situation...
  18. >    I have a large body of code with nibs which I've encapsulated in to
  19. > a NXBundle.  The code makes calls to an external library package.  The
  20. > purpose of the bundle is so that a number of other applications can
  21. > load this bundle rather than compiling and linking their own copies of
  22. > the source code.  These other applications also link against the same
  23. > external library, but far fewer members of the library.
  24. I have a similar question.  When distributing a custom Palette I
  25. need to distribute a library of the object code along with the
  26. Palette, which I believe is a bundle.   The Palette contains my
  27. custom subclass of IBPalette (MyIBPalette) along with other classes I have
  28. created.  The palette (bundle) also contains nib and tiff files
  29. that the other classes need.  To get those resources I use 
  30.  
  31. bundle = [NXBundle bundleForClass: [MyIBPalette class]];
  32. [bundle getpath:buf forResource .....]
  33.  
  34. in the code for the other classes.
  35.  
  36. To create the library I took all the object code files from the 
  37.    palette and used ar and ranlib to create a library which I link in 
  38.    with the application using the custom Palette.  This gives the message:
  39.  
  40. /bin/ld: Undefined symbols:
  41. objc_class_name_IBInspector
  42. _IBObjectPboardType
  43. objc_class_name_IBPalette
  44.  
  45. Questions:
  46.  
  47. a) Is there another library other than the standard -lMedia_s -lNeXT_s
  48.    that could be linked to solve this problem (I could not find one.)
  49.  
  50. b) Should I not be using the class MyIBPalette to be the class 
  51.    "holding" the bundle for all the custom palette resources since
  52.     the application will not require the IBInspectors and IBPalette
  53.     classes during execution.  It only needs them when running
  54.     Interface Builder.
  55.  
  56. Ed Nicolson
  57. nicolson@robotics.berkeley.edu
  58.