home *** CD-ROM | disk | FTP | other *** search
/ AmigActive 15 / AACD15.ISO / AACD / Programming / Python2 / Python20_source / Demo / embed / Makefile < prev    next >
Encoding:
Makefile  |  2000-10-25  |  903 b   |  45 lines

  1. # Makefile for embedded Python use demo.
  2. # (This version tailored for my Red Hat Linux 6.1 setup;
  3. # edit lines marked with XXX.)
  4.  
  5. # XXX The compiler you are using
  6. CC=         gcc
  7.  
  8. # XXX Top of the build tree and source tree
  9. blddir=        ../../linux
  10. srcdir=        ../..
  11.  
  12. # Python version
  13. VERSION=    2.0
  14.  
  15. # Compiler flags
  16. OPT=        -g
  17. INCLUDES=    -I$(srcdir)/Include -I$(blddir)
  18. CFLAGS=        $(OPT) $(INCLUDES)
  19.  
  20. # The Python library
  21. LIBPYTHON=    $(blddir)/libpython$(VERSION).a
  22.  
  23. # XXX edit LIBS (in particular) to match $(blddir)/Modules/Makefile
  24. LIBS=        -lnsl -ldl -lreadline -ltermcap -lieee -lpthread -lutil
  25. LDFLAGS=    -Xlinker -export-dynamic
  26. SYSLIBS=    -lm
  27. MODLIBS=    
  28. ALLLIBS=    $(LIBPYTHON) $(MODLIBS) $(LIBS) $(SYSLIBS)
  29.  
  30. # Build the demo application
  31. all:        demo
  32. demo:        demo.o
  33.         $(CC) $(LDFLAGS) demo.o $(ALLLIBS) -o demo
  34.  
  35. # Administrative targets
  36.  
  37. test:        demo
  38.         ./demo
  39.  
  40. clean:
  41.         -rm -f *.o core
  42.  
  43. clobber:    clean
  44.         -rm -f *~ @* '#'* demo
  45.