Commit b398d96e authored by Guido van Rossum's avatar Guido van Rossum

Updated the Makefile to work with the new build strategy.

parent 23797301
# Makefile for embedded Python use demo # Makefile for embedded Python use demo.
# (This version tailored for CNRI and Solaris; edit lines marked with XXX.)
# Top of the build tree and source tree # XXX The compiler you are using
CC= gcc
# XXX Top of the build tree and source tree
blddir= ../.. blddir= ../..
srcdir= ../.. srcdir= ../..
# Python version
VERSION= 1.5
# Compiler flags # Compiler flags
OPT= -g OPT= -g
INCLUDES= -I$(srcdir)/Include -I$(blddir) INCLUDES= -I$(srcdir)/Include -I$(blddir)
DEFINES= -DHAVE_CONFIG_H CFLAGS= $(OPT) $(INCLUDES)
CFLAGS= $(OPT) $(DEFINES) $(INCLUDES)
# Libraries (must be in this order!) # The Python library
MYLIBS= $(blddir)/Modules/libModules.a \ LIBPYTHON= $(blddir)/libpython$(VERSION).a
$(blddir)/Python/libPython.a \
$(blddir)/Objects/libObjects.a \
$(blddir)/Parser/libParser.a
# XXX edit MODLIBS, LIBS and SYSLIBS to match $(blddir)/Modules/Makefile # XXX edit LIBS (in particular) to match $(blddir)/Modules/Makefile
MODLIBS= LIBS= -lsocket -lnsl -ldl -lreadline -ltermcap
LIBS=
SYSLIBS= -lm SYSLIBS= -lm
ALLLIBS= $(MYLIBS) $(MODLIBS) $(LIBS) $(SYSLIBS) MODLIBS=
ALLLIBS= $(LIBPYTHON) $(MODLIBS) $(LIBS) $(SYSLIBS)
# Build the demo application # Build the demo application
all: demo all: demo
demo: demo.o config.o demo: demo.o
$(CC) demo.o config.o $(ALLLIBS) -o demo $(CC) demo.o $(ALLLIBS) -o demo
# Build config.o, suppressing the main() function
config.o: $(blddir)/Modules/config.c
$(CC) $(CFLAGS) -DNO_MAIN -c $(blddir)/Modules/config.c
# Administrative targets # Administrative targets
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment