Don't reference removed files in Makefile
[python/dscho.git] / Modules / Makefile.pre.in
blob3424a87098e16b6d4e289cd1a26b3b87190e1178
1 # META-NOTE: this note is different from the note in the other Makefiles!
2 # NOTE: Makefile.pre.in is converted into Makefile.pre by the configure
3 # script in the toplevel directory or by ../config.status.
4 # Makefile.pre is converted into Makefile by running the makesetup
5 # script in the source directory.  Once Makefile exists, it can be
6 # brought up to date by running "make Makefile".  (The makesetup also
7 # creates config.c from config.c.in in the source directory.)
9 LINKCC = $(CC)
10 # === Variables set by makesetup ===
12 MODOBJS=        _MODOBJS_
13 MODLIBS=        _MODLIBS_
15 # === Definitions added by makesetup ===
17 # === Variables set by configure ===
19 srcdir=         @srcdir@
20 VPATH=          @srcdir@
22 CC=             @CC@
23 RANLIB=         @RANLIB@
24 AR=             @AR@
26 DEFS=           @DEFS@
27 LIBS=           @LIBS@
28 LIBM=           @LIBM@
29 LIBC=           @LIBC@
31 # Machine-dependent subdirectories
32 MACHDEP=        @MACHDEP@
34 # Install prefix for architecture-independent files
35 prefix=         @prefix@
37 # Install prefix for architecture-dependent files
38 exec_prefix=    @exec_prefix@
40 # Symbols used for using shared libraries
41 SO=             @SO@
42 LDSHARED=       @LDSHARED@
43 CCSHARED=       @CCSHARED@
44 LINKFORSHARED=  @LINKFORSHARED@
45 DESTSHARED=     $(exec_prefix)/lib/python/$(MACHDEP)
48 # === Variables that are customizable by hand ===
50 INCLDIR=        $(srcdir)/../Include
51 OPT=            @OPT@
52 CFLAGS=         $(OPT) -I$(INCLDIR) -I.. $(DEFS)
54 MKDEP=          mkdep
55 SHELL=          /bin/sh
57 MAKESETUP=      $(srcdir)/makesetup
59 # === Fixed definitions ===
61 OBJS=           $(MODOBJS)
63 LIB=            libModules.a
65 MYLIBS=         $(LIB) \
66                 ../Python/libPython.a \
67                 ../Objects/libObjects.a \
68                 ../Parser/libParser.a
70 SYSLIBS=        $(LIBM) $(LIBC)
73 # === Rules ===
75 all:            $(LIB) ../python sharedmods
77 $(LIB):         $& $(OBJS) Makefile
78                 -rm -f $(LIB)
79                 $(AR) cr $(LIB) $(OBJS)
80                 $(RANLIB) $(LIB)
82 ../python:      config.o $(MYLIBS) Makefile
83                 $(LINKCC) $(OPT) config.o $(LINKFORSHARED) \
84                       $(MYLIBS) $(MODLIBS) $(LIBS) $(SYSLIBS) -o python
85                 mv python ../python
87 config.o:       config.c Makefile $(MYLIBS)
88                 $(LINKCC) $(CFLAGS) -DPYTHONPATH=\"$(PYTHONPATH)\" -c config.c
90 clean:
91                 -rm -f *.o python core *~ [@,#]* *.old *.orig *.rej
93 clobber:        clean
94                 -rm -f *.a tags TAGS config.c glmodule.c Makefile.pre
95                 -rm -f *.so so_locations
97 config.c Makefile: Makefile.pre config.c.in $(MAKESETUP) Setup
98                 $(SHELL) $(MAKESETUP) Setup
100 Setup:
101                 cp $(srcdir)/Setup.in Setup
103 Makefile.pre:   Makefile.pre.in ../config.status
104                 (cd ..; CONFIG_FILES=Modules/Makefile.pre CONFIG_HEADERS= \
105                 $(SHELL) config.status)
107 depend:
108                 $(MKDEP) $(CFLAGS) `echo $(OBJS) | tr ' ' '\012' | \
109                                         sed 's|\(.*\)\.o|$(srcdir)/\1.c|'`
111 .PRECIOUS:      ../python
113 glmodule.c:     $(srcdir)/cgen.py $(srcdir)/cstubs
114                 python $(srcdir)/cgen.py <$(srcdir)/cstubs >glmodule.c
116 almodule.o: almodule.c
117 arraymodule.o: arraymodule.c
118 audioop.o: audioop.c
119 cdmodule.o: cdmodule.c
120 clmodule.o: clmodule.c
121 dbmmodule.o: dbmmodule.c
122 fcntlmodule.o: fcntlmodule.c
123 flmodule.o: flmodule.c
124 fmmodule.o: fmmodule.c
125 glmodule.o: glmodule.c
126 imageop.o: imageop.c
127 imgfile.o: imgfile.c
128 mathmodule.o: mathmodule.c
129 md5c.o: md5c.c
130 md5module.o: md5module.c
131 mpzmodule.o: mpzmodule.c
132 nismodule.o: nismodule.c
133 parsermodule.o: parsermodule.c
134 posixmodule.o: posixmodule.c
135 pwdmodule.o: pwdmodule.c
136 regexmodule.o: regexmodule.c
137 regexpr.o: regexpr.c
138 rgbimgmodule.o: rgbimgmodule.c
139 rotormodule.o: rotormodule.c
140 selectmodule.o: selectmodule.c
141 sgimodule.o: sgimodule.c
142 socketmodule.o: socketmodule.c
143 stdwinmodule.o: stdwinmodule.c
144 stropmodule.o: stropmodule.c
145 structmodule.o: structmodule.c
146 sunaudiodev.o: sunaudiodev.c
147 svmodule.o: svmodule.c
148 threadmodule.o: threadmodule.c
149 timemodule.o: timemodule.c
150 timingmodule.o: timingmodule.c
151 xxmodule.o: xxmodule.c
152 yuvconvert.o: yuvconvert.c
154 # Rules to build and install all shared modules
155 sharedmods:     $(SHAREDMODS)
156 sharedinstall:  $(DESTSHARED) $(SHAREDMODS)
157                 -for i in dummy $(SHAREDMODS); do \
158                     if test -f $$i; then mv $$i $(DESTSHARED)/$$i; fi; done
160 $(DESTSHARED):
161                 mkdir $(DESTSHARED)
163 # Stuff is appended here by makesetup and make depend