home *** CD-ROM | disk | FTP | other *** search
/ ftp.uv.es / 2014.11.ftp.uv.es.tar / ftp.uv.es / pub / unix / pine4.10.tar.gz / pine4.10.tar / pine4.10 / pico / makefile.bso < prev    next >
Makefile  |  1999-01-22  |  3KB  |  103 lines

  1. # $Id: makefile.bso,v 1.2 1999/01/22 18:31:01 hubert Exp $
  2. #
  3. #   Michael Seibel
  4. #   Networks and Distributed Computing
  5. #   Computing and Communications
  6. #   University of Washington
  7. #   Administration Builiding, AG-44
  8. #   Seattle, Washington, 98195, USA
  9. #   Internet: mikes@cac.washington.edu
  10. #
  11. #   Please address all bugs and comments to "pine-bugs@cac.washington.edu"
  12. #
  13. #
  14. #   Pine and Pico are registered trademarks of the University of Washington.
  15. #   No commercial use of these trademarks may be made without prior written
  16. #   permission of the University of Washington.
  17. #
  18. #   Pine, Pico, and Pilot software and its included text are Copyright
  19. #   1989-1999 by the University of Washington.
  20. #
  21. #   The full text of our legal notices is contained in the file called
  22. #   CPYRIGHT, included with this distribution.
  23. #
  24.  
  25. #
  26. # Makefile for OpenBSD shared-lib version of the PINE composer library and 
  27. # stand-alone editor pico.
  28. #
  29. # Port Contributor: Marco S Hyman <marc@snafu.org>
  30. #
  31.  
  32. RM=          rm -f
  33. LN=          ln -s
  34. MAKE=        make
  35. OPTIMIZE=    # -O
  36. PROFILE=     # -pg
  37. DEBUG=       -DDEBUG # -g
  38.  
  39. STDCFLAGS=    -DBSDI -DBSDI2 -DPOSIX -DJOB_CONTROL -DMOUSE
  40. CFLAGS+=        $(OPTIMIZE) $(PROFILE) $(DEBUG) $(EXTRACFLAGS) $(STDCFLAGS)
  41.  
  42. # switches for library building
  43. LIBCMD=        ar
  44. LIBARGS=    ru
  45. RANLIB=        ranlib
  46.  
  47. LIBS=        $(EXTRALIBES) -ltermcap
  48.  
  49. OFILES=        attach.o basic.o bind.o browse.o buffer.o \
  50.         composer.o display.o file.o fileio.o line.o pico_os.o \
  51.         pico.o random.o region.o search.o \
  52.         window.o word.o
  53.  
  54. SOFILES=    ${OFILES:.o=.so}
  55.  
  56. HFILES=        headers.h estruct.h edef.h efunc.h pico.h os.h
  57.  
  58. # Need this for the shared library rule to work correctly
  59. .SUFFIXES: .o .so
  60.  
  61. #
  62. # dependencies for the Unix versions of pico and libpico.a
  63. #
  64. all:        pico pilot
  65. pico pilot:    libpico.a
  66.  
  67. pico:        main.o
  68.         $(CC) $(CFLAGS) main.o -L. -lpico $(LIBS) -o pico
  69.  
  70. pilot:        pilot.o
  71.         $(CC) $(CFLAGS) pilot.o -L. -lpico $(LIBS) -o pilot
  72.  
  73. .c.so:        ; $(CC) -fpic -DPIC -c $(CFLAGS) ${@:.so=.c} -o $@
  74.  
  75. .c.o:        ; $(CC) -c $(CFLAGS) $*.c
  76.  
  77. libpico.a:    $(OFILES)
  78.         $(LIBCMD) $(LIBARGS) libpico.a $(OFILES)
  79.         $(RANLIB) libpico.a
  80.  
  81. libpico.so.1.3:    $(SOFILES)
  82.         ld -Bshareable -x -o libpico.so.1.3 $(SOFILES)
  83.  
  84. clean:
  85.         rm -f *.a *.so.1.3 *.o *.so *~ pico_os.c os.h pico pilot
  86.         cd osdep; $(MAKE) clean; cd ..
  87.  
  88. os.h:        osdep/os-bso.h
  89.         $(RM) os.h
  90.         $(LN) osdep/os-bso.h os.h
  91.  
  92. pico_os.c:    osdep/os-bso.c
  93.         $(RM) pico_os.c
  94.         $(LN) osdep/os-bso.c pico_os.c
  95.  
  96. $(SOFILES) $(OFILES) main.o pilot.o:    $(HFILES)
  97. pico.o:                ebind.h
  98.  
  99. osdep/os-bso.c:    osdep/header osdep/unix osdep/read.sel osdep/raw.ios \
  100.         osdep/spell.unx osdep/term.cap \
  101.         osdep/os-bso.ic
  102.         cd osdep; $(MAKE) includer os-bso.c; cd ..
  103.