blob: 50ddd8ae568a7e5b1d3425da3116283c42161dfd [file] [log] [blame]
Neil Schemenauer85515ad2001-01-24 17:11:43 +00001# Top-level Makefile for Python
Guido van Rossum7cb32ae2001-08-17 15:32:31 +00002#
Neil Schemenauer85515ad2001-01-24 17:11:43 +00003# As distributed, this file is called Makefile.pre.in; it is processed
4# into the real Makefile by running the script ./configure, which
5# replaces things like @spam@ with values appropriate for your system.
6# This means that if you edit Makefile, your changes get lost the next
7# time you run the configure script. Ideally, you can do:
Guido van Rossum7cb32ae2001-08-17 15:32:31 +00008#
Neil Schemenauer85515ad2001-01-24 17:11:43 +00009# ./configure
10# make
11# make test
12# make install
Guido van Rossum7cb32ae2001-08-17 15:32:31 +000013#
Neil Schemenauer85515ad2001-01-24 17:11:43 +000014# If you have a previous version of Python installed that you don't
15# want to overwrite, you can use "make altinstall" instead of "make
Neil Schemenauer2b2681a2001-02-16 04:16:34 +000016# install". Refer to the "Installing" section in the README file for
17# additional details.
Guido van Rossum7cb32ae2001-08-17 15:32:31 +000018#
Neil Schemenauer85515ad2001-01-24 17:11:43 +000019# See also the section "Build instructions" in the README file.
20
21# === Variables set by makesetup ===
22
23MODOBJS= _MODOBJS_
24MODLIBS= _MODLIBS_
25
26# === Variables set by configure
27VERSION= @VERSION@
28srcdir= @srcdir@
29VPATH= @srcdir@
Trent Nelson739fc542012-10-17 04:45:30 -040030abs_srcdir= @abs_srcdir@
31abs_builddir= @abs_builddir@
Trent Nelson9effe692012-10-16 08:41:32 -040032
Neil Schemenauer85515ad2001-01-24 17:11:43 +000033
34CC= @CC@
35CXX= @CXX@
Thomas Wouters49fd7fa2006-04-21 10:40:58 +000036MAINCC= @MAINCC@
Neil Schemenauer85515ad2001-01-24 17:11:43 +000037LINKCC= @LINKCC@
38AR= @AR@
39RANLIB= @RANLIB@
doko@ubuntu.com58844492012-06-30 18:25:32 +020040READELF= @READELF@
Georg Brandl0d169ea2010-09-03 22:14:52 +000041SOABI= @SOABI@
Barry Warsaw8cf4eae2010-10-16 01:04:07 +000042LDVERSION= @LDVERSION@
Georg Brandl1ca2e792011-03-05 20:51:24 +010043HGVERSION= @HGVERSION@
44HGTAG= @HGTAG@
45HGBRANCH= @HGBRANCH@
Neil Schemenauer85515ad2001-01-24 17:11:43 +000046
Georg Brandl0d169ea2010-09-03 22:14:52 +000047GNULD= @GNULD@
Tarek Ziadébe720e02009-05-09 11:55:12 +000048
Neil Schemenauer85515ad2001-01-24 17:11:43 +000049# Shell used by make (some versions default to the login shell, which is bad)
50SHELL= /bin/sh
51
52# Use this to make a link between python$(VERSION) and python in $(BINDIR)
53LN= @LN@
54
55# Portable install script (configure doesn't always guess right)
56INSTALL= @INSTALL@
57INSTALL_PROGRAM=@INSTALL_PROGRAM@
Neil Schemenauer3f5cc202001-04-10 23:03:35 +000058INSTALL_SCRIPT= @INSTALL_SCRIPT@
Neil Schemenauer85515ad2001-01-24 17:11:43 +000059INSTALL_DATA= @INSTALL_DATA@
60# Shared libraries must be installed with executable mode on some systems;
61# rather than figuring out exactly which, we always give them executable mode.
62# Also, making them read-only seems to be a good idea...
63INSTALL_SHARED= ${INSTALL} -m 555
64
Matthias Klose93a0ef12012-03-15 18:08:34 +010065MKDIR_P= @MKDIR_P@
66
Neil Schemenauer85515ad2001-01-24 17:11:43 +000067MAKESETUP= $(srcdir)/Modules/makesetup
68
69# Compiler options
70OPT= @OPT@
Skip Montanarodecc6a42003-01-01 20:07:49 +000071BASECFLAGS= @BASECFLAGS@
Trent Nelson9effe692012-10-16 08:41:32 -040072BASECPPFLAGS= @BASECPPFLAGS@
Jeffrey Yasskind4fcdb12010-07-09 16:30:58 +000073CONFIGURE_CFLAGS= @CFLAGS@
74CONFIGURE_CPPFLAGS= @CPPFLAGS@
75CONFIGURE_LDFLAGS= @LDFLAGS@
76# Avoid assigning CFLAGS, LDFLAGS, etc. so users can use them on the
77# command line to append to these values without stomping the pre-set
78# values.
79PY_CFLAGS= $(BASECFLAGS) $(OPT) $(CONFIGURE_CFLAGS) $(CFLAGS) $(EXTRA_CFLAGS)
Brett Cannon516592f2004-12-07 00:42:59 +000080# Both CPPFLAGS and LDFLAGS need to contain the shell's value for setup.py to
81# be able to build extension modules using the directories specified in the
82# environment variables
Trent Nelson9effe692012-10-16 08:41:32 -040083PY_CPPFLAGS= $(BASECPPFLAGS) -I. -IInclude -I$(srcdir)/Include $(CONFIGURE_CPPFLAGS) $(CPPFLAGS)
Jeffrey Yasskind4fcdb12010-07-09 16:30:58 +000084PY_LDFLAGS= $(CONFIGURE_LDFLAGS) $(LDFLAGS)
Martin v. Löwis48e14d32011-05-09 07:37:45 +020085NO_AS_NEEDED= @NO_AS_NEEDED@
Neil Schemenauer85515ad2001-01-24 17:11:43 +000086LDLAST= @LDLAST@
87SGI_ABI= @SGI_ABI@
Neil Schemenauer7ac954b2001-01-26 16:14:41 +000088CCSHARED= @CCSHARED@
89LINKFORSHARED= @LINKFORSHARED@
Tarek Ziadé5662d3e2009-05-07 21:24:43 +000090ARFLAGS= @ARFLAGS@
Neil Schemenauer7ac954b2001-01-26 16:14:41 +000091# Extra C flags added for building the interpreter object files.
92CFLAGSFORSHARED=@CFLAGSFORSHARED@
93# C flags used for building the interpreter object files
Jeffrey Yasskind4fcdb12010-07-09 16:30:58 +000094PY_CORE_CFLAGS= $(PY_CFLAGS) $(PY_CPPFLAGS) $(CFLAGSFORSHARED) -DPy_BUILD_CORE
Neil Schemenauer7ac954b2001-01-26 16:14:41 +000095
Neil Schemenauer85515ad2001-01-24 17:11:43 +000096
97# Machine-dependent subdirectories
98MACHDEP= @MACHDEP@
99
doko@python.org3e6e2ac2013-01-25 13:12:29 +0100100# Multiarch directory (may be empty)
101MULTIARCH= @MULTIARCH@
102
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000103# Install prefix for architecture-independent files
104prefix= @prefix@
105
106# Install prefix for architecture-dependent files
107exec_prefix= @exec_prefix@
108
Thomas Woutersbca54802007-09-10 19:32:14 +0000109# Install prefix for data files
110datarootdir= @datarootdir@
111
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000112# Expanded directories
Antoine Pitrou7a61ba92010-03-21 19:25:26 +0000113BINDIR= @bindir@
114LIBDIR= @libdir@
Martin v. Löwisd429ab62001-08-02 06:20:20 +0000115MANDIR= @mandir@
116INCLUDEDIR= @includedir@
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000117CONFINCLUDEDIR= $(exec_prefix)/include
118SCRIPTDIR= $(prefix)/lib
Barry Warsaw8cf4eae2010-10-16 01:04:07 +0000119ABIFLAGS= @ABIFLAGS@
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000120
121# Detailed destination directories
122BINLIBDEST= $(LIBDIR)/python$(VERSION)
123LIBDEST= $(SCRIPTDIR)/python$(VERSION)
Barry Warsaw14d98ac2010-11-24 19:43:47 +0000124INCLUDEPY= $(INCLUDEDIR)/python$(LDVERSION)
125CONFINCLUDEPY= $(CONFINCLUDEDIR)/python$(LDVERSION)
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000126
127# Symbols used for using shared libraries
128SO= @SO@
Antoine Pitroudbec7802010-10-10 09:37:12 +0000129LDSHARED= @LDSHARED@ $(PY_LDFLAGS)
130BLDSHARED= @BLDSHARED@ $(PY_LDFLAGS)
Tarek Ziadé03d788d2010-04-03 08:46:49 +0000131LDCXXSHARED= @LDCXXSHARED@
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000132DESTSHARED= $(BINLIBDEST)/lib-dynload
133
134# Executable suffix (.exe on Windows and Mac OS X)
Neil Schemenauercf9926c2001-02-27 18:50:56 +0000135EXE= @EXEEXT@
Jack Jansen1999ef42001-12-06 21:47:20 +0000136BUILDEXE= @BUILDEXEEXT@
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000137
Jack Jansenb6e9cad2001-08-15 01:26:28 +0000138# Short name and location for Mac OS X Python framework
Thomas Wouters477c8d52006-05-27 19:21:47 +0000139UNIVERSALSDK=@UNIVERSALSDK@
Jack Jansenb6e9cad2001-08-15 01:26:28 +0000140PYTHONFRAMEWORK= @PYTHONFRAMEWORK@
141PYTHONFRAMEWORKDIR= @PYTHONFRAMEWORKDIR@
142PYTHONFRAMEWORKPREFIX= @PYTHONFRAMEWORKPREFIX@
143PYTHONFRAMEWORKINSTALLDIR= @PYTHONFRAMEWORKINSTALLDIR@
Jack Jansen6b08a402004-06-03 12:41:45 +0000144# Deployment target selected during configure, to be checked
Thomas Wouters477c8d52006-05-27 19:21:47 +0000145# by distutils. The export statement is needed to ensure that the
146# deployment target is active during build.
147MACOSX_DEPLOYMENT_TARGET=@CONFIGURE_MACOSX_DEPLOYMENT_TARGET@
148@EXPORT_MACOSX_DEPLOYMENT_TARGET@export MACOSX_DEPLOYMENT_TARGET
149
Bob Ippolito7026a0a2005-03-28 23:23:47 +0000150# Options to enable prebinding (for fast startup prior to Mac OS X 10.3)
151OTHER_LIBTOOL_OPT=@OTHER_LIBTOOL_OPT@
Jack Jansenb6e9cad2001-08-15 01:26:28 +0000152
Martin v. Löwis1142de32002-03-29 16:28:31 +0000153# Environment to run shared python without installed libraries
154RUNSHARED= @RUNSHARED@
155
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000156# Modes for directories, executables and data files created by the
157# install process. Default to user-only-writable for all file types.
158DIRMODE= 755
159EXEMODE= 755
160FILEMODE= 644
161
Neil Schemenauer64b1b682001-03-22 00:32:32 +0000162# configure script arguments
163CONFIG_ARGS= @CONFIG_ARGS@
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000164
165
166# Subdirectories with code
167SRCDIRS= @SRCDIRS@
168
169# Other subdirectories
Georg Brandl59b44722010-12-30 22:12:40 +0000170SUBDIRSTOO= Include Lib Misc
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000171
172# Files and directories to be distributed
Matthias Klose0f4c16e2012-03-14 23:10:15 +0100173CONFIGFILES= configure configure.ac acconfig.h pyconfig.h.in Makefile.pre.in
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000174DISTFILES= README ChangeLog $(CONFIGFILES)
175DISTDIRS= $(SUBDIRS) $(SUBDIRSTOO) Ext-dummy
176DIST= $(DISTFILES) $(DISTDIRS)
177
178
Neil Schemenauer7ac954b2001-01-26 16:14:41 +0000179LIBRARY= @LIBRARY@
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000180LDLIBRARY= @LDLIBRARY@
Jack Jansenb6e9cad2001-08-15 01:26:28 +0000181BLDLIBRARY= @BLDLIBRARY@
Martin v. Löwisd1fc34d2010-12-30 14:55:47 +0000182PY3LIBRARY= @PY3LIBRARY@
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000183DLLLIBRARY= @DLLLIBRARY@
Jack Jansenb6e9cad2001-08-15 01:26:28 +0000184LDLIBRARYDIR= @LDLIBRARYDIR@
Martin v. Löwis1142de32002-03-29 16:28:31 +0000185INSTSONAME= @INSTSONAME@
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000186
187
188LIBS= @LIBS@
189LIBM= @LIBM@
190LIBC= @LIBC@
191SYSLIBS= $(LIBM) $(LIBC)
Martin v. Löwisf90ae202002-06-11 06:22:31 +0000192SHLIBS= @SHLIBS@
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000193
Martin v. Löwis2d7e2642002-04-05 16:50:53 +0000194THREADOBJ= @THREADOBJ@
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000195DLINCLDIR= @DLINCLDIR@
196DYNLOADFILE= @DYNLOADFILE@
Jack Jansenc49e5b72001-06-19 15:00:23 +0000197MACHDEP_OBJS= @MACHDEP_OBJS@
Christian Heimes32fbe592007-11-12 15:01:33 +0000198LIBOBJDIR= Python/
199LIBOBJS= @LIBOBJS@
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000200
Neil Schemenauercf9926c2001-02-27 18:50:56 +0000201PYTHON= python$(EXE)
Jack Jansen1999ef42001-12-06 21:47:20 +0000202BUILDPYTHON= python$(BUILDEXE)
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000203
doko@ubuntu.com1abe1c52012-06-30 20:42:45 +0200204PYTHON_FOR_BUILD=@PYTHON_FOR_BUILD@
205_PYTHON_HOST_PLATFORM=@_PYTHON_HOST_PLATFORM@
doko@python.orga10e4a92013-01-25 18:45:12 +0100206BUILD_GNU_TYPE= @build@
207HOST_GNU_TYPE= @host@
doko@ubuntu.com1abe1c52012-06-30 20:42:45 +0200208
Christian Heimes33fe8092008-04-13 13:53:33 +0000209# The task to run while instrument when building the profile-opt target
Benjamin Petersonf10a79a2008-10-11 00:49:57 +0000210PROFILE_TASK= $(srcdir)/Tools/pybench/pybench.py -n 2 --with-gc --with-syscheck
211#PROFILE_TASK= $(srcdir)/Lib/test/regrtest.py
Christian Heimes33fe8092008-04-13 13:53:33 +0000212
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000213# === Definitions added by makesetup ===
214
215
216##########################################################################
217# Modules
218MODULE_OBJS= \
219 Modules/config.o \
220 Modules/getpath.o \
Neil Schemenauer9c63e6d2001-08-29 23:44:38 +0000221 Modules/main.o \
222 Modules/gcmodule.o
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000223
224# Used of signalmodule.o is not available
225SIGNAL_OBJS= @SIGNAL_OBJS@
226
Alexandre Vassalotti8d8d6302009-04-04 19:58:40 +0000227IO_H= Modules/_io/_iomodule.h
Benjamin Peterson4fa88fa2009-03-04 00:14:51 +0000228
229IO_OBJS= \
Alexandre Vassalotti8d8d6302009-04-04 19:58:40 +0000230 Modules/_io/_iomodule.o \
231 Modules/_io/iobase.o \
232 Modules/_io/fileio.o \
233 Modules/_io/bufferedio.o \
234 Modules/_io/textio.o \
235 Modules/_io/bytesio.o \
236 Modules/_io/stringio.o
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000237
238##########################################################################
239# Grammar
Trent Nelsone60ee292012-08-30 14:52:38 +0000240GRAMMAR_H= Include/graminit.h
241GRAMMAR_C= Python/graminit.c
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000242GRAMMAR_INPUT= $(srcdir)/Grammar/Grammar
243
244
Benjamin Petersond78735d2010-01-01 16:04:23 +0000245LIBFFI_INCLUDEDIR= @LIBFFI_INCLUDEDIR@
246
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000247##########################################################################
248# Parser
Neil Schemenauercf9926c2001-02-27 18:50:56 +0000249PGEN= Parser/pgen$(EXE)
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000250
Matthias Klose93a0ef12012-03-15 18:08:34 +0100251PSRCS= \
252 Parser/acceler.c \
253 Parser/grammar1.c \
254 Parser/listnode.c \
255 Parser/node.c \
256 Parser/parser.c \
257 Parser/bitset.c \
258 Parser/metagrammar.c \
259 Parser/firstsets.c \
260 Parser/grammar.c \
261 Parser/pgen.c
262
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000263POBJS= \
264 Parser/acceler.o \
265 Parser/grammar1.o \
266 Parser/listnode.o \
267 Parser/node.o \
268 Parser/parser.o \
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000269 Parser/bitset.o \
Guido van Rossumd3ab37f2003-04-17 14:55:42 +0000270 Parser/metagrammar.o \
271 Parser/firstsets.o \
272 Parser/grammar.o \
273 Parser/pgen.o
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000274
Victor Stinner7f2fee32011-04-05 00:39:01 +0200275PARSER_OBJS= $(POBJS) Parser/myreadline.o Parser/parsetok.o Parser/tokenizer.o
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000276
Matthias Klose93a0ef12012-03-15 18:08:34 +0100277PGSRCS= \
278 Objects/obmalloc.c \
279 Python/dynamic_annotations.c \
280 Python/mysnprintf.c \
281 Python/pyctype.c \
282 Parser/tokenizer_pgen.c \
283 Parser/printgrammar.c \
284 Parser/parsetok_pgen.c \
285 Parser/pgenmain.c
286
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000287PGOBJS= \
Neil Schemenauerfd1030e2002-04-22 03:05:25 +0000288 Objects/obmalloc.o \
Jeffrey Yasskin39370832010-05-03 19:29:34 +0000289 Python/dynamic_annotations.o \
Guido van Rossumf2272522001-12-04 03:54:08 +0000290 Python/mysnprintf.o \
Benjamin Petersonbf92b7f2010-04-04 23:03:35 +0000291 Python/pyctype.o \
Martin v. Löwis00f1e3f2002-08-04 17:29:52 +0000292 Parser/tokenizer_pgen.o \
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000293 Parser/printgrammar.o \
Victor Stinner7f2fee32011-04-05 00:39:01 +0200294 Parser/parsetok_pgen.o \
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000295 Parser/pgenmain.o
296
Georg Brandl86def6c2008-01-21 20:36:10 +0000297PARSER_HEADERS= \
Victor Stinner69f55cc2011-10-12 22:09:40 +0200298 $(srcdir)/Parser/parser.h \
299 $(srcdir)/Include/parsetok.h \
300 $(srcdir)/Parser/tokenizer.h
Georg Brandl86def6c2008-01-21 20:36:10 +0000301
Matthias Klose93a0ef12012-03-15 18:08:34 +0100302PGENSRCS= $(PSRCS) $(PGSRCS)
303PGENOBJS= $(POBJS) $(PGOBJS)
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000304
Jeremy Hylton3e0055f2005-10-20 19:59:25 +0000305##########################################################################
306# AST
Trent Nelsone60ee292012-08-30 14:52:38 +0000307AST_H_DIR= Include
Thomas Wouters49fd7fa2006-04-21 10:40:58 +0000308AST_H= $(AST_H_DIR)/Python-ast.h
Trent Nelsone60ee292012-08-30 14:52:38 +0000309AST_C_DIR= Python
Thomas Wouters49fd7fa2006-04-21 10:40:58 +0000310AST_C= $(AST_C_DIR)/Python-ast.c
Jeremy Hylton3e0055f2005-10-20 19:59:25 +0000311AST_ASDL= $(srcdir)/Parser/Python.asdl
312
313ASDLGEN_FILES= $(srcdir)/Parser/asdl.py $(srcdir)/Parser/asdl_c.py
314# XXX Note that a build now requires Python exist before the build starts
Matthias Klosec4c48422012-10-21 23:05:35 +0200315ASDLGEN= @ASDLGEN@ $(srcdir)/Parser/asdl_c.py
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000316
317##########################################################################
318# Python
Antoine Pitroub52ec782009-01-25 16:34:23 +0000319
320OPCODETARGETS_H= \
Trent Nelson9effe692012-10-16 08:41:32 -0400321 Python/opcode_targets.h
Antoine Pitroub52ec782009-01-25 16:34:23 +0000322
323OPCODETARGETGEN= \
324 $(srcdir)/Python/makeopcodetargets.py
325
326OPCODETARGETGEN_FILES= \
327 $(OPCODETARGETGEN) $(srcdir)/Lib/opcode.py
328
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000329PYTHON_OBJS= \
Christian Heimes33fe8092008-04-13 13:53:33 +0000330 Python/_warnings.o \
Jeremy Hylton3e0055f2005-10-20 19:59:25 +0000331 Python/Python-ast.o \
332 Python/asdl.o \
333 Python/ast.o \
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000334 Python/bltinmodule.o \
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000335 Python/ceval.o \
336 Python/compile.o \
337 Python/codecs.o \
Jeffrey Yasskin39370832010-05-03 19:29:34 +0000338 Python/dynamic_annotations.o \
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000339 Python/errors.o \
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000340 Python/frozenmain.o \
Jeremy Hylton4db62b12001-02-27 19:07:02 +0000341 Python/future.o \
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000342 Python/getargs.o \
343 Python/getcompiler.o \
344 Python/getcopyright.o \
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000345 Python/getplatform.o \
346 Python/getversion.o \
347 Python/graminit.o \
348 Python/import.o \
349 Python/importdl.o \
350 Python/marshal.o \
351 Python/modsupport.o \
352 Python/mystrtoul.o \
Marc-André Lemburge5006eb2001-07-31 13:24:44 +0000353 Python/mysnprintf.o \
Thomas Wouters00ee7ba2006-08-21 19:07:27 +0000354 Python/peephole.o \
Neal Norwitzadb69fc2005-12-17 20:54:49 +0000355 Python/pyarena.o \
Eric Smith6dc46f52009-04-27 20:39:49 +0000356 Python/pyctype.o \
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000357 Python/pyfpe.o \
Christian Heimes53876d92008-04-19 00:31:39 +0000358 Python/pymath.o \
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000359 Python/pystate.o \
360 Python/pythonrun.o \
Alexander Belopolsky6fc4ade2010-08-05 17:34:27 +0000361 Python/pytime.o \
Georg Brandl2daf6ae2012-02-20 19:54:16 +0100362 Python/random.o \
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000363 Python/structmember.o \
Jeremy Hyltoncb17ae82001-02-09 22:22:18 +0000364 Python/symtable.o \
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000365 Python/sysmodule.o \
366 Python/traceback.o \
367 Python/getopt.o \
Christian Heimes99170a52007-12-19 02:07:34 +0000368 Python/pystrcmp.o \
Martin v. Löwis737ea822004-06-08 18:52:54 +0000369 Python/pystrtod.o \
Mark Dickinsonb08a53a2009-04-16 19:52:09 +0000370 Python/dtoa.o \
Eric Smith8c663262007-08-25 02:26:07 +0000371 Python/formatter_unicode.o \
Victor Stinner4e314432010-10-07 21:45:39 +0000372 Python/fileutils.o \
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000373 Python/$(DYNLOADFILE) \
Christian Heimes32fbe592007-11-12 15:01:33 +0000374 $(LIBOBJS) \
Jack Jansenc49e5b72001-06-19 15:00:23 +0000375 $(MACHDEP_OBJS) \
Martin v. Löwis2d7e2642002-04-05 16:50:53 +0000376 $(THREADOBJ)
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000377
378
379##########################################################################
380# Objects
381OBJECT_OBJS= \
382 Objects/abstract.o \
Antoine Pitroueeb7eea2011-10-06 18:57:27 +0200383 Objects/accu.o \
Guido van Rossum77f6a652002-04-03 22:41:51 +0000384 Objects/boolobject.o \
Gregory P. Smith60d241f2007-10-16 06:31:30 +0000385 Objects/bytes_methods.o \
Christian Heimes2c9c7a52008-05-26 13:42:13 +0000386 Objects/bytearrayobject.o \
Guido van Rossum4dfe8a12006-04-22 23:28:04 +0000387 Objects/bytesobject.o \
Jeremy Hyltonfbd849f2001-01-25 20:04:14 +0000388 Objects/cellobject.o \
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000389 Objects/classobject.o \
Jeremy Hylton3e0055f2005-10-20 19:59:25 +0000390 Objects/codeobject.o \
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000391 Objects/complexobject.o \
Tim Peters6d6c1a32001-08-02 04:15:00 +0000392 Objects/descrobject.o \
Guido van Rossum7dab2422002-04-26 19:40:56 +0000393 Objects/enumobject.o \
Thomas Wouters477c8d52006-05-27 19:21:47 +0000394 Objects/exceptions.o \
Martin v. Löwise440e472004-06-01 15:22:42 +0000395 Objects/genobject.o \
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000396 Objects/fileobject.o \
397 Objects/floatobject.o \
398 Objects/frameobject.o \
399 Objects/funcobject.o \
Guido van Rossum59d1d2b2001-04-20 19:13:02 +0000400 Objects/iterobject.o \
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000401 Objects/listobject.o \
402 Objects/longobject.o \
403 Objects/dictobject.o \
Travis E. Oliphantb99f7622007-08-18 11:21:56 +0000404 Objects/memoryobject.o \
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000405 Objects/methodobject.o \
406 Objects/moduleobject.o \
Barry Warsaw409da152012-06-03 16:18:47 -0400407 Objects/namespaceobject.o \
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000408 Objects/object.o \
Tim Peters1221c0a2002-03-23 00:20:15 +0000409 Objects/obmalloc.o \
Benjamin Petersonb173f782009-05-05 22:31:58 +0000410 Objects/capsule.o \
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000411 Objects/rangeobject.o \
Victor Stinner69f55cc2011-10-12 22:09:40 +0200412 Objects/setobject.o \
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000413 Objects/sliceobject.o \
Guido van Rossum98bf58f2001-10-18 20:34:25 +0000414 Objects/structseq.o \
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000415 Objects/tupleobject.o \
416 Objects/typeobject.o \
Georg Brandl52d168a2008-01-07 18:10:24 +0000417 Objects/unicodeobject.o \
418 Objects/unicodectype.o \
419 Objects/weakrefobject.o
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000420
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000421##########################################################################
422# objects that get linked into the Python library
Antoine Pitroue67f48c2012-06-19 22:29:35 +0200423LIBRARY_OBJS_OMIT_FROZEN= \
Neil Schemenauer18821822001-01-27 21:42:38 +0000424 Modules/getbuildinfo.o \
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000425 $(PARSER_OBJS) \
426 $(OBJECT_OBJS) \
427 $(PYTHON_OBJS) \
428 $(MODULE_OBJS) \
429 $(SIGNAL_OBJS) \
430 $(MODOBJS)
431
Antoine Pitroue67f48c2012-06-19 22:29:35 +0200432LIBRARY_OBJS= \
433 $(LIBRARY_OBJS_OMIT_FROZEN) \
434 Python/frozen.o
435
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000436#########################################################################
437# Rules
438
439# Default target
Guido van Rossum8ce8a782007-11-01 19:42:39 +0000440all: build_all
Trent Nelsonc101bf32012-10-16 08:13:12 -0400441build_all: $(BUILDPYTHON) oldsharedmods sharedmods gdbhooks Modules/_testembed
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000442
Christian Heimes33fe8092008-04-13 13:53:33 +0000443# Compile a binary with gcc profile guided optimization.
444profile-opt:
445 @echo "Building with support for profile generation:"
446 $(MAKE) clean
447 $(MAKE) build_all_generate_profile
448 @echo "Running benchmark to generate profile data:"
449 $(MAKE) profile-removal
450 $(MAKE) run_profile_task
451 @echo "Rebuilding with profile guided optimizations:"
452 $(MAKE) clean
453 $(MAKE) build_all_use_profile
454
455build_all_generate_profile:
456 $(MAKE) all CFLAGS="$(CFLAGS) -fprofile-generate" LIBS="$(LIBS) -lgcov"
457
458run_profile_task:
doko@ubuntu.com1abe1c52012-06-30 20:42:45 +0200459 : # FIXME: can't run for a cross build
Antoine Pitrou2d9db1d2012-06-17 00:27:30 +0200460 $(RUNSHARED) ./$(BUILDPYTHON) $(PROFILE_TASK)
Christian Heimes33fe8092008-04-13 13:53:33 +0000461
462build_all_use_profile:
Matthias Klose39b1e5d2012-06-27 14:13:33 +0200463 $(MAKE) all CFLAGS="$(CFLAGS) -fprofile-use -fprofile-correction"
Christian Heimes33fe8092008-04-13 13:53:33 +0000464
Georg Brandlb533e262008-05-25 18:19:30 +0000465coverage:
466 @echo "Building with support for coverage checking:"
467 $(MAKE) clean
468 $(MAKE) all CFLAGS="$(CFLAGS) -O0 -pg -fprofile-arcs -ftest-coverage" LIBS="$(LIBS) -lgcov"
469
470
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000471# Build the interpreter
Martin v. Löwisd1fc34d2010-12-30 14:55:47 +0000472$(BUILDPYTHON): Modules/python.o $(LIBRARY) $(LDLIBRARY) $(PY3LIBRARY)
Georg Brandl9411eeb2010-08-01 08:46:24 +0000473 $(LINKCC) $(PY_LDFLAGS) $(LINKFORSHARED) -o $@ Modules/python.o $(BLDLIBRARY) $(LIBS) $(MODLIBS) $(SYSLIBS) $(LDLAST)
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000474
Trent Nelsonc101bf32012-10-16 08:13:12 -0400475platform: $(BUILDPYTHON) pybuilddir.txt
doko@ubuntu.com1abe1c52012-06-30 20:42:45 +0200476 $(RUNSHARED) $(PYTHON_FOR_BUILD) -c 'import sys ; from sysconfig import get_platform ; print(get_platform()+"-"+sys.version[0:3])' >platform
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000477
Trent Nelsonc101bf32012-10-16 08:13:12 -0400478# Create build directory and generate the sysconfig build-time data there.
479# pybuilddir.txt contains the name of the build dir and is used for
480# sys.path fixup -- see Modules/getpath.c.
481pybuilddir.txt: $(BUILDPYTHON)
doko@ubuntu.com1abe1c52012-06-30 20:42:45 +0200482 $(RUNSHARED) $(PYTHON_FOR_BUILD) -S -m sysconfig --generate-posix-vars
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000483
484# Build the shared modules
Christian Heimes8ca1d5f2012-12-02 08:14:50 +0100485# Under GNU make, MAKEFLAGS are sorted and normalized; the 's' for
Christian Heimes5f381212012-09-07 02:24:58 +0200486# -s, --silent or --quiet is always the first char.
Christian Heimes8ca1d5f2012-12-02 08:14:50 +0100487# Under BSD make, MAKEFLAGS might be " -s -v x=y".
Trent Nelsonc101bf32012-10-16 08:13:12 -0400488sharedmods: $(BUILDPYTHON) pybuilddir.txt
Christian Heimes5f381212012-09-07 02:24:58 +0200489 @case "$$MAKEFLAGS" in \
Christian Heimes8ca1d5f2012-12-02 08:14:50 +0100490 *\ -s*|s*) quiet="-q";; \
Christian Heimes5f381212012-09-07 02:24:58 +0200491 *) quiet="";; \
492 esac; \
doko@ubuntu.com1abe1c52012-06-30 20:42:45 +0200493 $(RUNSHARED) CC='$(CC)' LDSHARED='$(BLDSHARED)' OPT='$(OPT)' \
Christian Heimes4e251402012-09-07 02:26:26 +0200494 $(PYTHON_FOR_BUILD) $(srcdir)/setup.py $$quiet build
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000495
496# Build static library
Guido van Rossum4e6a7a62001-04-09 22:23:22 +0000497# avoid long command lines, same as LIBRARY_OBJS
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000498$(LIBRARY): $(LIBRARY_OBJS)
499 -rm -f $@
Tarek Ziadé5662d3e2009-05-07 21:24:43 +0000500 $(AR) $(ARFLAGS) $@ Modules/getbuildinfo.o
501 $(AR) $(ARFLAGS) $@ $(PARSER_OBJS)
502 $(AR) $(ARFLAGS) $@ $(OBJECT_OBJS)
Antoine Pitroue67f48c2012-06-19 22:29:35 +0200503 $(AR) $(ARFLAGS) $@ $(PYTHON_OBJS) Python/frozen.o
Tarek Ziadé5662d3e2009-05-07 21:24:43 +0000504 $(AR) $(ARFLAGS) $@ $(MODULE_OBJS) $(SIGNAL_OBJS)
505 $(AR) $(ARFLAGS) $@ $(MODOBJS)
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000506 $(RANLIB) $@
507
Barry Warsaw8cf4eae2010-10-16 01:04:07 +0000508libpython$(LDVERSION).so: $(LIBRARY_OBJS)
Martin v. Löwisbc122622003-06-14 13:11:24 +0000509 if test $(INSTSONAME) != $(LDLIBRARY); then \
Antoine Pitroudbec7802010-10-10 09:37:12 +0000510 $(BLDSHARED) -Wl,-h$(INSTSONAME) -o $(INSTSONAME) $(LIBRARY_OBJS) $(MODLIBS) $(SHLIBS) $(LIBC) $(LIBM) $(LDLAST); \
Martin v. Löwis45ec95d2003-03-30 15:37:33 +0000511 $(LN) -f $(INSTSONAME) $@; \
Georg Brandlb1441c72009-01-03 22:33:39 +0000512 else \
Antoine Pitroudbec7802010-10-10 09:37:12 +0000513 $(BLDSHARED) -o $@ $(LIBRARY_OBJS) $(MODLIBS) $(SHLIBS) $(LIBC) $(LIBM) $(LDLAST); \
Martin v. Löwis45ec95d2003-03-30 15:37:33 +0000514 fi
Martin v. Löwis1142de32002-03-29 16:28:31 +0000515
Martin v. Löwisd1fc34d2010-12-30 14:55:47 +0000516libpython3.so: libpython$(LDVERSION).so
Martin v. Löwis48e14d32011-05-09 07:37:45 +0200517 $(BLDSHARED) $(NO_AS_NEEDED) -o $@ -Wl,-h$@ $^
Martin v. Löwisd1fc34d2010-12-30 14:55:47 +0000518
Georg Brandl6e8d17c2011-02-19 08:47:14 +0000519libpython$(LDVERSION).dylib: $(LIBRARY_OBJS)
520 $(CC) -dynamiclib -Wl,-single_module $(PY_LDFLAGS) -undefined dynamic_lookup -Wl,-install_name,$(prefix)/lib/libpython$(LDVERSION).dylib -Wl,-compatibility_version,$(VERSION) -Wl,-current_version,$(VERSION) -o $@ $(LIBRARY_OBJS) $(SHLIBS) $(LIBC) $(LIBM) $(LDLAST); \
Victor Stinner4e314432010-10-07 21:45:39 +0000521
Georg Brandlb1441c72009-01-03 22:33:39 +0000522
Martin v. Löwis1142de32002-03-29 16:28:31 +0000523libpython$(VERSION).sl: $(LIBRARY_OBJS)
Antoine Pitroudbec7802010-10-10 09:37:12 +0000524 $(LDSHARED) -o $@ $(LIBRARY_OBJS) $(MODLIBS) $(SHLIBS) $(LIBC) $(LIBM) $(LDLAST)
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000525
Benjamin Peterson6a6666a2010-04-11 21:49:28 +0000526# Copy up the gdb python hooks into a position where they can be automatically
527# loaded by gdb during Lib/test/test_gdb.py
528#
529# Distributors are likely to want to install this somewhere else e.g. relative
530# to the stripped DWARF data for the shared library.
531gdbhooks: $(BUILDPYTHON)-gdb.py
532
533SRC_GDB_HOOKS=$(srcdir)/Tools/gdb/libpython.py
534$(BUILDPYTHON)-gdb.py: $(SRC_GDB_HOOKS)
535 $(INSTALL_DATA) $(SRC_GDB_HOOKS) $(BUILDPYTHON)-gdb.py
536
Jack Jansenea0c3822002-08-01 21:57:49 +0000537# This rule is here for OPENSTEP/Rhapsody/MacOSX. It builds a temporary
538# minimal framework (not including the Lib directory and such) in the current
539# directory.
Christian Heimes81ee3ef2008-05-04 22:42:01 +0000540RESSRCDIR=Mac/Resources/framework
Jack Jansenea0c3822002-08-01 21:57:49 +0000541$(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK): \
542 $(LIBRARY) \
Christian Heimes81ee3ef2008-05-04 22:42:01 +0000543 $(RESSRCDIR)/Info.plist
Jack Jansen246debb2002-02-12 21:30:53 +0000544 $(INSTALL) -d -m $(DIRMODE) $(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)
Ronald Oussoren42d0f682011-03-14 11:04:34 -0400545 $(CC) -o $(LDLIBRARY) $(PY_LDFLAGS) -dynamiclib \
Ronald Oussoren25032492011-03-14 10:11:59 -0400546 -all_load $(LIBRARY) -Wl,-single_module \
547 -install_name $(DESTDIR)$(PYTHONFRAMEWORKINSTALLDIR)/Versions/$(VERSION)/$(PYTHONFRAMEWORK) \
548 -compatibility_version $(VERSION) \
549 -current_version $(VERSION) \
Victor Stinnerdfb866d2011-09-29 01:12:24 +0200550 -framework CoreFoundation $(LIBS);
Jack Jansenea0c3822002-08-01 21:57:49 +0000551 $(INSTALL) -d -m $(DIRMODE) \
552 $(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/Resources/English.lproj
553 $(INSTALL_DATA) $(RESSRCDIR)/Info.plist \
554 $(PYTHONFRAMEWORKDIR)/Versions/$(VERSION)/Resources/Info.plist
Jack Jansenc736b8d2002-08-04 21:17:20 +0000555 $(LN) -fsn $(VERSION) $(PYTHONFRAMEWORKDIR)/Versions/Current
Jack Jansenb36687a2004-07-16 08:43:47 +0000556 $(LN) -fsn Versions/Current/$(PYTHONFRAMEWORK) $(PYTHONFRAMEWORKDIR)/$(PYTHONFRAMEWORK)
Jack Jansenc736b8d2002-08-04 21:17:20 +0000557 $(LN) -fsn Versions/Current/Resources $(PYTHONFRAMEWORKDIR)/Resources
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000558
Jason Tishler30765592003-09-04 11:04:06 +0000559# This rule builds the Cygwin Python DLL and import library if configured
560# for a shared core library; otherwise, this rule is a noop.
561$(DLLLIBRARY) libpython$(VERSION).dll.a: $(LIBRARY_OBJS)
562 if test -n "$(DLLLIBRARY)"; then \
Antoine Pitroudbec7802010-10-10 09:37:12 +0000563 $(LDSHARED) -Wl,--out-implib=$@ -o $(DLLLIBRARY) $^ \
Benjamin Petersonae5360b2008-09-08 23:05:23 +0000564 $(LIBS) $(MODLIBS) $(SYSLIBS) $(LDLAST); \
Jason Tishler30765592003-09-04 11:04:06 +0000565 else true; \
566 fi
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000567
568
569oldsharedmods: $(SHAREDMODS)
570
571
572Makefile Modules/config.c: Makefile.pre \
573 $(srcdir)/Modules/config.c.in \
574 $(MAKESETUP) \
575 Modules/Setup.config \
576 Modules/Setup \
577 Modules/Setup.local
578 $(SHELL) $(MAKESETUP) -c $(srcdir)/Modules/config.c.in \
579 -s Modules \
580 Modules/Setup.config \
581 Modules/Setup.local \
582 Modules/Setup
583 @mv config.c Modules
584 @echo "The Makefile was updated, you may need to re-run make."
585
586
587Modules/Setup: $(srcdir)/Modules/Setup.dist
588 @if test -f Modules/Setup; then \
589 echo "-----------------------------------------------"; \
590 echo "Modules/Setup.dist is newer than Modules/Setup;"; \
591 echo "check to make sure you have all the updates you"; \
592 echo "need in your Modules/Setup file."; \
Alexandre Vassalottieca20b62008-05-16 02:54:33 +0000593 echo "Usually, copying Modules/Setup.dist to Modules/Setup will work."; \
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000594 echo "-----------------------------------------------"; \
Neil Schemenauer7ac954b2001-01-26 16:14:41 +0000595 fi
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000596
Antoine Pitrou8e605772011-04-25 21:21:07 +0200597Modules/_testembed: Modules/_testembed.o $(LIBRARY) $(LDLIBRARY) $(PY3LIBRARY)
598 $(LINKCC) $(PY_LDFLAGS) $(LINKFORSHARED) -o $@ Modules/_testembed.o $(BLDLIBRARY) $(LIBS) $(MODLIBS) $(SYSLIBS) $(LDLAST)
Marc-Andre Lemburgaed97732012-04-25 19:45:11 +0200599
Brett Cannonfd074152012-04-14 14:10:13 -0400600############################################################################
601# Importlib
Antoine Pitrou8e605772011-04-25 21:21:07 +0200602
Antoine Pitroue67f48c2012-06-19 22:29:35 +0200603Modules/_freeze_importlib: Modules/_freeze_importlib.o $(LIBRARY_OBJS_OMIT_FROZEN)
604 $(LINKCC) $(PY_LDFLAGS) -o $@ Modules/_freeze_importlib.o $(LIBRARY_OBJS_OMIT_FROZEN) $(LIBS) $(MODLIBS) $(SYSLIBS) $(LDLAST)
605
606Python/importlib.h: $(srcdir)/Lib/importlib/_bootstrap.py Modules/_freeze_importlib.c
607 $(MAKE) Modules/_freeze_importlib
608 ./Modules/_freeze_importlib \
609 $(srcdir)/Lib/importlib/_bootstrap.py Python/importlib.h
610
Marc-Andre Lemburgaed97732012-04-25 19:45:11 +0200611
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000612############################################################################
613# Special rules for object files
614
Martin v. Löwisdea59e52006-01-05 10:00:36 +0000615Modules/getbuildinfo.o: $(PARSER_OBJS) \
616 $(OBJECT_OBJS) \
617 $(PYTHON_OBJS) \
618 $(MODULE_OBJS) \
619 $(SIGNAL_OBJS) \
620 $(MODOBJS) \
621 $(srcdir)/Modules/getbuildinfo.c
Georg Brandl13039c82011-03-06 10:13:00 +0100622 $(CC) -c $(PY_CORE_CFLAGS) \
Georg Brandl1ca2e792011-03-05 20:51:24 +0100623 -DHGVERSION="\"`LC_ALL=C $(HGVERSION)`\"" \
624 -DHGTAG="\"`LC_ALL=C $(HGTAG)`\"" \
625 -DHGBRANCH="\"`LC_ALL=C $(HGBRANCH)`\"" \
626 -o $@ $(srcdir)/Modules/getbuildinfo.c
Andrew M. Kuchling03184e22001-01-26 22:52:45 +0000627
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000628Modules/getpath.o: $(srcdir)/Modules/getpath.c Makefile
Jeffrey Yasskind4fcdb12010-07-09 16:30:58 +0000629 $(CC) -c $(PY_CORE_CFLAGS) -DPYTHONPATH='"$(PYTHONPATH)"' \
Neil Schemenauer7ac954b2001-01-26 16:14:41 +0000630 -DPREFIX='"$(prefix)"' \
631 -DEXEC_PREFIX='"$(exec_prefix)"' \
632 -DVERSION='"$(VERSION)"' \
633 -DVPATH='"$(VPATH)"' \
Sjoerd Mullender30be8702001-01-29 09:39:14 +0000634 -o $@ $(srcdir)/Modules/getpath.c
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000635
Thomas Wouters49fd7fa2006-04-21 10:40:58 +0000636Modules/python.o: $(srcdir)/Modules/python.c
Jeffrey Yasskind4fcdb12010-07-09 16:30:58 +0000637 $(MAINCC) -c $(PY_CORE_CFLAGS) -o $@ $(srcdir)/Modules/python.c
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000638
Victor Stinner69f55cc2011-10-12 22:09:40 +0200639Modules/_testembed.o: $(srcdir)/Modules/_testembed.c
640 $(MAINCC) -c $(PY_CORE_CFLAGS) -o $@ $(srcdir)/Modules/_testembed.c
641
Serhiy Storchaka7cf55992013-02-10 21:56:49 +0200642Modules/posixmodule.o: $(srcdir)/Modules/posixmodule.c $(srcdir)/Modules/posixmodule.h
643
644Modules/grpmodule.o: $(srcdir)/Modules/grpmodule.c $(srcdir)/Modules/posixmodule.h
645
646Modules/pwdmodule.o: $(srcdir)/Modules/pwdmodule.c $(srcdir)/Modules/posixmodule.h
647
648Modules/signalmodule.o: $(srcdir)/Modules/signalmodule.c $(srcdir)/Modules/posixmodule.h
649
Barry Warsaw35f3a2c2010-09-03 18:30:30 +0000650Python/dynload_shlib.o: $(srcdir)/Python/dynload_shlib.c Makefile
651 $(CC) -c $(PY_CORE_CFLAGS) \
652 -DSOABI='"$(SOABI)"' \
653 -o $@ $(srcdir)/Python/dynload_shlib.c
654
Barry Warsaw8cf4eae2010-10-16 01:04:07 +0000655Python/sysmodule.o: $(srcdir)/Python/sysmodule.c Makefile
656 $(CC) -c $(PY_CORE_CFLAGS) \
657 -DABIFLAGS='"$(ABIFLAGS)"' \
658 -o $@ $(srcdir)/Python/sysmodule.c
659
Benjamin Peterson4fa88fa2009-03-04 00:14:51 +0000660$(IO_OBJS): $(IO_H)
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000661
Matthias Klose93a0ef12012-03-15 18:08:34 +0100662$(GRAMMAR_H): $(GRAMMAR_INPUT) $(PGENSRCS)
663 @$(MKDIR_P) Include
664 $(MAKE) $(PGEN)
Victor Stinnere1c0c7c2010-12-28 23:14:17 +0000665 $(PGEN) $(GRAMMAR_INPUT) $(GRAMMAR_H) $(GRAMMAR_C)
Matthias Klose93a0ef12012-03-15 18:08:34 +0100666$(GRAMMAR_C): $(GRAMMAR_H) $(GRAMMAR_INPUT) $(PGENSRCS)
667 $(MAKE) $(GRAMMAR_H)
668 touch $(GRAMMAR_C)
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000669
670$(PGEN): $(PGENOBJS)
Jeffrey Yasskind4fcdb12010-07-09 16:30:58 +0000671 $(CC) $(OPT) $(PY_LDFLAGS) $(PGENOBJS) $(LIBS) -o $(PGEN)
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000672
673Parser/grammar.o: $(srcdir)/Parser/grammar.c \
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000674 $(srcdir)/Include/token.h \
675 $(srcdir)/Include/grammar.h
676Parser/metagrammar.o: $(srcdir)/Parser/metagrammar.c
677
Martin v. Löwis00f1e3f2002-08-04 17:29:52 +0000678Parser/tokenizer_pgen.o: $(srcdir)/Parser/tokenizer.c
Victor Stinner7f2fee32011-04-05 00:39:01 +0200679Parser/parsetok_pgen.o: $(srcdir)/Parser/parsetok.c
Victor Stinner69f55cc2011-10-12 22:09:40 +0200680Parser/printgrammar.o: $(srcdir)/Parser/printgrammar.c
Martin v. Löwis00f1e3f2002-08-04 17:29:52 +0000681
Thomas Woutersfc7bb8c2007-01-15 15:49:28 +0000682Parser/pgenmain.o: $(srcdir)/Include/parsetok.h
683
Thomas Wouters49fd7fa2006-04-21 10:40:58 +0000684$(AST_H): $(AST_ASDL) $(ASDLGEN_FILES)
Trent Nelsone60ee292012-08-30 14:52:38 +0000685 $(MKDIR_P) $(AST_H_DIR)
Thomas Wouters49fd7fa2006-04-21 10:40:58 +0000686 $(ASDLGEN) -h $(AST_H_DIR) $(AST_ASDL)
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000687
Benjamin Peterson1f918c12012-01-13 08:45:55 -0500688$(AST_C): $(AST_H) $(AST_ASDL) $(ASDLGEN_FILES)
Trent Nelsone60ee292012-08-30 14:52:38 +0000689 $(MKDIR_P) $(AST_C_DIR)
Thomas Wouters49fd7fa2006-04-21 10:40:58 +0000690 $(ASDLGEN) -c $(AST_C_DIR) $(AST_ASDL)
Thomas Wouters0e3f5912006-08-11 14:57:12 +0000691
Benjamin Peterson87c8d872009-06-11 22:54:11 +0000692Python/compile.o Python/symtable.o Python/ast.o: $(GRAMMAR_H) $(AST_H)
Neil Schemenauer40417742001-02-27 02:45:36 +0000693
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000694Python/getplatform.o: $(srcdir)/Python/getplatform.c
Jeffrey Yasskind4fcdb12010-07-09 16:30:58 +0000695 $(CC) -c $(PY_CORE_CFLAGS) -DPLATFORM='"$(MACHDEP)"' -o $@ $(srcdir)/Python/getplatform.c
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000696
697Python/importdl.o: $(srcdir)/Python/importdl.c
Jeffrey Yasskind4fcdb12010-07-09 16:30:58 +0000698 $(CC) -c $(PY_CORE_CFLAGS) -I$(DLINCLDIR) -o $@ $(srcdir)/Python/importdl.c
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000699
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000700Objects/unicodectype.o: $(srcdir)/Objects/unicodectype.c \
701 $(srcdir)/Objects/unicodetype_db.h
702
Christian Heimesda996832008-03-22 18:37:22 +0000703BYTESTR_DEPS = \
Neal Norwitz22c65422008-03-24 05:03:36 +0000704 $(srcdir)/Include/bytes_methods.h \
Christian Heimesda996832008-03-22 18:37:22 +0000705 $(srcdir)/Objects/stringlib/count.h \
706 $(srcdir)/Objects/stringlib/ctype.h \
707 $(srcdir)/Objects/stringlib/eq.h \
708 $(srcdir)/Objects/stringlib/fastsearch.h \
709 $(srcdir)/Objects/stringlib/find.h \
Antoine Pitroudd4e2f02011-10-13 00:02:27 +0200710 $(srcdir)/Objects/stringlib/find_max_char.h \
Christian Heimesda996832008-03-22 18:37:22 +0000711 $(srcdir)/Objects/stringlib/partition.h \
Antoine Pitrouf2c54842010-01-13 08:07:53 +0000712 $(srcdir)/Objects/stringlib/split.h \
Christian Heimesda996832008-03-22 18:37:22 +0000713 $(srcdir)/Objects/stringlib/stringdefs.h \
Christian Heimesda996832008-03-22 18:37:22 +0000714 $(srcdir)/Objects/stringlib/transmogrify.h \
715 $(srcdir)/Objects/stringlib/unicodedefs.h \
Antoine Pitrou3e623242011-11-13 19:37:58 +0100716 $(srcdir)/Objects/stringlib/localeutil.h \
717 $(srcdir)/Objects/stringlib/undef.h
718
719UNICODE_DEPS = $(BYTESTR_DEPS) \
720 $(srcdir)/Objects/stringlib/asciilib.h \
Antoine Pitrou0a3229d2011-11-21 20:39:13 +0100721 $(srcdir)/Objects/stringlib/codecs.h \
Antoine Pitrou3e623242011-11-13 19:37:58 +0100722 $(srcdir)/Objects/stringlib/ucs1lib.h \
723 $(srcdir)/Objects/stringlib/ucs2lib.h \
724 $(srcdir)/Objects/stringlib/ucs4lib.h \
725 $(srcdir)/Objects/stringlib/unicode_format.h \
726 $(srcdir)/Objects/stringlib/unicodedefs.h
Gregory P. Smith60d241f2007-10-16 06:31:30 +0000727
Benjamin Peterson9ae32202009-01-13 21:53:28 +0000728Objects/bytesobject.o: $(srcdir)/Objects/bytesobject.c $(BYTESTR_DEPS)
Gregory P. Smith60d241f2007-10-16 06:31:30 +0000729
Victor Stinner4e314432010-10-07 21:45:39 +0000730Objects/bytearrayobject.o: $(srcdir)/Objects/bytearrayobject.c $(BYTESTR_DEPS)
Gregory P. Smith60d241f2007-10-16 06:31:30 +0000731
Antoine Pitrou3e623242011-11-13 19:37:58 +0100732Objects/unicodeobject.o: $(srcdir)/Objects/unicodeobject.c $(UNICODE_DEPS)
Eric Smith8c663262007-08-25 02:26:07 +0000733
Martin v. Löwis6fb44722011-09-25 17:36:11 +0200734Objects/dictobject.o: $(srcdir)/Objects/stringlib/eq.h
735Objects/setobject.o: $(srcdir)/Objects/stringlib/eq.h
736
Antoine Pitroub52ec782009-01-25 16:34:23 +0000737$(OPCODETARGETS_H): $(OPCODETARGETGEN_FILES)
738 $(OPCODETARGETGEN) $(OPCODETARGETS_H)
739
Victor Stinner69f55cc2011-10-12 22:09:40 +0200740Python/ceval.o: $(OPCODETARGETS_H) $(srcdir)/Python/ceval_gil.h
Antoine Pitroub52ec782009-01-25 16:34:23 +0000741
Eric Smith8c663262007-08-25 02:26:07 +0000742Python/formatter_unicode.o: $(srcdir)/Python/formatter_unicode.c \
Martin v. Löwisd63a3b82011-09-28 07:41:54 +0200743 $(BYTESTR_DEPS)
Eric Smith8c663262007-08-25 02:26:07 +0000744
Trent Nelson4d4ec652012-10-16 08:51:24 -0400745Python/frozen.o: Python/importlib.h
Antoine Pitroua4932352012-04-16 18:29:28 +0200746
Trent Nelson9effe692012-10-16 08:41:32 -0400747Objects/typeobject.o: Objects/typeslots.inc
748Objects/typeslots.inc: $(srcdir)/Include/typeslots.h $(srcdir)/Objects/typeslots.py
749 $(PYTHON) $(srcdir)/Objects/typeslots.py < $(srcdir)/Include/typeslots.h > Objects/typeslots.inc
Eric Smith8c663262007-08-25 02:26:07 +0000750
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000751############################################################################
752# Header files
753
Neil Schemenauerf65e5002001-01-25 20:07:50 +0000754PYTHON_HEADERS= \
Victor Stinner69f55cc2011-10-12 22:09:40 +0200755 $(srcdir)/Include/Python.h \
756 $(srcdir)/Include/abstract.h \
757 $(srcdir)/Include/accu.h \
758 $(srcdir)/Include/asdl.h \
759 $(srcdir)/Include/ast.h \
760 $(srcdir)/Include/bltinmodule.h \
761 $(srcdir)/Include/bitset.h \
762 $(srcdir)/Include/boolobject.h \
763 $(srcdir)/Include/bytes_methods.h \
764 $(srcdir)/Include/bytearrayobject.h \
765 $(srcdir)/Include/bytesobject.h \
766 $(srcdir)/Include/cellobject.h \
767 $(srcdir)/Include/ceval.h \
768 $(srcdir)/Include/classobject.h \
769 $(srcdir)/Include/code.h \
770 $(srcdir)/Include/codecs.h \
771 $(srcdir)/Include/compile.h \
772 $(srcdir)/Include/complexobject.h \
773 $(srcdir)/Include/descrobject.h \
774 $(srcdir)/Include/dictobject.h \
775 $(srcdir)/Include/dtoa.h \
776 $(srcdir)/Include/dynamic_annotations.h \
777 $(srcdir)/Include/enumobject.h \
778 $(srcdir)/Include/errcode.h \
779 $(srcdir)/Include/eval.h \
780 $(srcdir)/Include/fileobject.h \
781 $(srcdir)/Include/fileutils.h \
782 $(srcdir)/Include/floatobject.h \
783 $(srcdir)/Include/frameobject.h \
784 $(srcdir)/Include/funcobject.h \
785 $(srcdir)/Include/genobject.h \
786 $(srcdir)/Include/import.h \
787 $(srcdir)/Include/intrcheck.h \
788 $(srcdir)/Include/iterobject.h \
789 $(srcdir)/Include/listobject.h \
790 $(srcdir)/Include/longintrepr.h \
791 $(srcdir)/Include/longobject.h \
792 $(srcdir)/Include/marshal.h \
793 $(srcdir)/Include/memoryobject.h \
794 $(srcdir)/Include/metagrammar.h \
795 $(srcdir)/Include/methodobject.h \
796 $(srcdir)/Include/modsupport.h \
797 $(srcdir)/Include/moduleobject.h \
Barry Warsaw409da152012-06-03 16:18:47 -0400798 $(srcdir)/Include/namespaceobject.h \
Victor Stinner69f55cc2011-10-12 22:09:40 +0200799 $(srcdir)/Include/node.h \
800 $(srcdir)/Include/object.h \
801 $(srcdir)/Include/objimpl.h \
802 $(srcdir)/Include/opcode.h \
803 $(srcdir)/Include/osdefs.h \
804 $(srcdir)/Include/patchlevel.h \
805 $(srcdir)/Include/pgen.h \
806 $(srcdir)/Include/pgenheaders.h \
807 $(srcdir)/Include/pyarena.h \
808 $(srcdir)/Include/pyatomic.h \
809 $(srcdir)/Include/pycapsule.h \
810 $(srcdir)/Include/pyctype.h \
811 $(srcdir)/Include/pydebug.h \
812 $(srcdir)/Include/pyerrors.h \
813 $(srcdir)/Include/pyfpe.h \
814 $(srcdir)/Include/pymath.h \
815 $(srcdir)/Include/pygetopt.h \
816 $(srcdir)/Include/pymacro.h \
817 $(srcdir)/Include/pymem.h \
818 $(srcdir)/Include/pyport.h \
819 $(srcdir)/Include/pystate.h \
820 $(srcdir)/Include/pystrcmp.h \
821 $(srcdir)/Include/pystrtod.h \
822 $(srcdir)/Include/pythonrun.h \
823 $(srcdir)/Include/pythread.h \
824 $(srcdir)/Include/pytime.h \
825 $(srcdir)/Include/rangeobject.h \
826 $(srcdir)/Include/setobject.h \
827 $(srcdir)/Include/sliceobject.h \
828 $(srcdir)/Include/structmember.h \
829 $(srcdir)/Include/structseq.h \
830 $(srcdir)/Include/symtable.h \
831 $(srcdir)/Include/sysmodule.h \
832 $(srcdir)/Include/traceback.h \
833 $(srcdir)/Include/tupleobject.h \
834 $(srcdir)/Include/ucnhash.h \
835 $(srcdir)/Include/unicodeobject.h \
836 $(srcdir)/Include/warnings.h \
837 $(srcdir)/Include/weakrefobject.h \
Georg Brandl86def6c2008-01-21 20:36:10 +0000838 pyconfig.h \
839 $(PARSER_HEADERS)
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000840
Thomas Wouters49fd7fa2006-04-21 10:40:58 +0000841$(LIBRARY_OBJS) $(MODOBJS) Modules/python.o: $(PYTHON_HEADERS)
Neil Schemenauerf65e5002001-01-25 20:07:50 +0000842
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000843
844######################################################################
845
Nadeem Vawda3c01d162011-08-01 23:48:26 +0200846TESTOPTS= $(EXTRATESTOPTS)
847TESTPYTHON= $(RUNSHARED) ./$(BUILDPYTHON) $(TESTPYTHONOPTS)
848TESTRUNNER= $(TESTPYTHON) $(srcdir)/Tools/scripts/run_tests.py
849TESTTIMEOUT= 3600
850
Nadeem Vawdaecd3e382011-07-31 01:09:04 +0200851# Run a basic set of regression tests.
852# This excludes some tests that are particularly resource-intensive.
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000853test: all platform
Nadeem Vawda3c01d162011-08-01 23:48:26 +0200854 $(TESTRUNNER) $(TESTOPTS)
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000855
Nadeem Vawdaecd3e382011-07-31 01:09:04 +0200856# Run the full test suite twice - once without .pyc files, and once with.
857# In the past, we've had problems where bugs in the marshalling or
858# elsewhere caused bytecode read from .pyc files to behave differently
859# than bytecode generated directly from a .py source file. Sometimes
860# the bytecode read from a .pyc file had the bug, sometimes the directly
861# generated bytecode. This is sometimes a very shy bug needing a lot of
862# sample data.
Skip Montanaro446ad712003-05-06 15:30:20 +0000863testall: all platform
864 -find $(srcdir)/Lib -name '*.py[co]' -print | xargs rm -f
Nadeem Vawda3c01d162011-08-01 23:48:26 +0200865 $(TESTPYTHON) -E $(srcdir)/Lib/compileall.py
Christian Heimes905a9042007-11-21 02:51:50 +0000866 -find $(srcdir)/Lib -name '*.py[co]' -print | xargs rm -f
Nadeem Vawda3c01d162011-08-01 23:48:26 +0200867 -$(TESTRUNNER) -u all $(TESTOPTS)
868 $(TESTRUNNER) -u all $(TESTOPTS)
Skip Montanaro446ad712003-05-06 15:30:20 +0000869
Nadeem Vawdaecd3e382011-07-31 01:09:04 +0200870# Run the test suite for both architectures in a Universal build on OSX.
871# Must be run on an Intel box.
Thomas Wouters477c8d52006-05-27 19:21:47 +0000872testuniversal: all platform
873 if [ `arch` != 'i386' ];then \
874 echo "This can only be used on OSX/i386" ;\
875 exit 1 ;\
876 fi
Nadeem Vawda3c01d162011-08-01 23:48:26 +0200877 $(TESTRUNNER) -u all $(TESTOPTS)
878 $(RUNSHARED) /usr/libexec/oah/translate \
879 ./$(BUILDPYTHON) -E -m test -j 0 -u all $(TESTOPTS)
Thomas Wouters477c8d52006-05-27 19:21:47 +0000880
Nadeem Vawda3c01d162011-08-01 23:48:26 +0200881# Like testall, but with only one pass and without multiple processes.
Nadeem Vawdaecd3e382011-07-31 01:09:04 +0200882# Run an optional script to include information about the build environment.
Martin v. Löwisbfa8bd72006-03-13 10:59:32 +0000883buildbottest: all platform
Thomas Wouters89d996e2007-09-08 17:39:28 +0000884 -@if which pybuildbot.identify >/dev/null 2>&1; then \
885 pybuildbot.identify "CC='$(CC)'" "CXX='$(CXX)'"; \
886 fi
Nadeem Vawda3c01d162011-08-01 23:48:26 +0200887 $(TESTRUNNER) -j 1 -u all -W --timeout=$(TESTTIMEOUT) $(TESTOPTS)
Martin v. Löwisbfa8bd72006-03-13 10:59:32 +0000888
Jeremy Hyltonfdd6dee2009-03-27 21:24:45 +0000889QUICKTESTOPTS= $(TESTOPTS) -x test_subprocess test_io test_lib2to3 \
890 test_multibytecodec test_urllib2_localnet test_itertools \
891 test_multiprocessing test_mailbox test_socket test_poll \
Nadeem Vawda3c01d162011-08-01 23:48:26 +0200892 test_select test_zipfile test_concurrent_futures
Jeremy Hylton2a850d92001-02-01 19:51:28 +0000893quicktest: all platform
Nadeem Vawda3c01d162011-08-01 23:48:26 +0200894 $(TESTRUNNER) $(QUICKTESTOPTS)
Jeremy Hylton2a850d92001-02-01 19:51:28 +0000895
Barry Warsaw42119252001-03-03 04:14:21 +0000896
Ned Deilya48b61f2013-02-08 22:53:51 -0800897install: altinstall bininstall maninstall
Guido van Rossumdc21db32008-04-07 18:37:41 +0000898
Thomas Wouters73e5a5b2006-06-08 15:35:45 +0000899altinstall: @FRAMEWORKALTINSTALLFIRST@ altbininstall libinstall inclinstall libainstall \
Ned Deilya48b61f2013-02-08 22:53:51 -0800900 sharedinstall oldsharedinstall altmaninstall @FRAMEWORKALTINSTALLLAST@
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000901
902# Install shared libraries enabled by Setup
903DESTDIRS= $(exec_prefix) $(LIBDIR) $(BINLIBDEST) $(DESTSHARED)
904
905oldsharedinstall: $(DESTSHARED) $(SHAREDMODS)
906 @for i in X $(SHAREDMODS); do \
Neil Schemenauerac959772001-02-06 14:50:27 +0000907 if test $$i != X; then \
908 echo $(INSTALL_SHARED) $$i $(DESTSHARED)/`basename $$i`; \
Martin v. Löwis3b8ee082003-05-11 20:25:35 +0000909 $(INSTALL_SHARED) $$i $(DESTDIR)$(DESTSHARED)/`basename $$i`; \
Neil Schemenauerac959772001-02-06 14:50:27 +0000910 fi; \
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000911 done
912
Guido van Rossum7cb32ae2001-08-17 15:32:31 +0000913$(DESTSHARED):
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000914 @for i in $(DESTDIRS); \
915 do \
Martin v. Löwis3b8ee082003-05-11 20:25:35 +0000916 if test ! -d $(DESTDIR)$$i; then \
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000917 echo "Creating directory $$i"; \
Martin v. Löwis3b8ee082003-05-11 20:25:35 +0000918 $(INSTALL) -d -m $(DIRMODE) $(DESTDIR)$$i; \
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000919 else true; \
920 fi; \
921 done
922
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000923# Install the interpreter with $(VERSION) affixed
924# This goes into $(exec_prefix)
Benjamin Peterson932073a2009-05-23 16:14:33 +0000925altbininstall: $(BUILDPYTHON)
Martin v. Löwisd8a20d22002-05-08 08:59:59 +0000926 @for i in $(BINDIR) $(LIBDIR); \
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000927 do \
Martin v. Löwis3b8ee082003-05-11 20:25:35 +0000928 if test ! -d $(DESTDIR)$$i; then \
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000929 echo "Creating directory $$i"; \
Martin v. Löwis3b8ee082003-05-11 20:25:35 +0000930 $(INSTALL) -d -m $(DIRMODE) $(DESTDIR)$$i; \
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000931 else true; \
932 fi; \
933 done
Barry Warsaw14d98ac2010-11-24 19:43:47 +0000934 $(INSTALL_PROGRAM) $(BUILDPYTHON) $(DESTDIR)$(BINDIR)/python$(LDVERSION)$(EXE)
Barry Warsaw771d33e2010-12-13 18:04:23 +0000935 -if test "$(VERSION)" != "$(LDVERSION)"; then \
Nick Coghlan4fcad3c2012-02-17 23:17:34 +1000936 if test -f $(DESTDIR)$(BINDIR)/python$(VERSION)$(EXE) -o -h $(DESTDIR)$(BINDIR)/python$(VERSION)$(EXE); \
Barry Warsaw771d33e2010-12-13 18:04:23 +0000937 then rm -f $(DESTDIR)$(BINDIR)/python$(VERSION)$(EXE); \
938 fi; \
939 (cd $(DESTDIR)$(BINDIR); $(LN) python$(LDVERSION)$(EXE) python$(VERSION)$(EXE)); \
Barry Warsawad6f8772010-12-11 21:32:01 +0000940 fi
Georg Brandlb1441c72009-01-03 22:33:39 +0000941 if test -f $(LDLIBRARY); then \
Georg Brandl1f01deb2009-01-03 22:47:39 +0000942 if test -n "$(DLLLIBRARY)" ; then \
943 $(INSTALL_SHARED) $(DLLLIBRARY) $(DESTDIR)$(BINDIR); \
Jason Tishlerc0f1e772002-07-29 16:18:23 +0000944 else \
Georg Brandlb1441c72009-01-03 22:33:39 +0000945 $(INSTALL_SHARED) $(LDLIBRARY) $(DESTDIR)$(LIBDIR)/$(INSTSONAME); \
946 if test $(LDLIBRARY) != $(INSTSONAME); then \
947 (cd $(DESTDIR)$(LIBDIR); $(LN) -sf $(INSTSONAME) $(LDLIBRARY)) \
Martin v. Löwise3be8602003-11-18 19:54:20 +0000948 fi \
Jason Tishlerc0f1e772002-07-29 16:18:23 +0000949 fi; \
Martin v. Löwisd1fc34d2010-12-30 14:55:47 +0000950 if test -n "$(PY3LIBRARY)"; then \
951 $(INSTALL_SHARED) $(PY3LIBRARY) $(DESTDIR)$(LIBDIR)/$(PY3LIBRARY); \
952 fi; \
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000953 else true; \
954 fi
Benjamin Peterson932073a2009-05-23 16:14:33 +0000955
956bininstall: altbininstall
Nick Coghlan4fcad3c2012-02-17 23:17:34 +1000957 -if test -f $(DESTDIR)$(BINDIR)/python3$(EXE) -o -h $(DESTDIR)$(BINDIR)/python3$(EXE); \
958 then rm -f $(DESTDIR)$(BINDIR)/python3$(EXE); \
Benjamin Petersonf4841e22009-04-25 21:04:19 +0000959 else true; \
960 fi
Nick Coghlan4fcad3c2012-02-17 23:17:34 +1000961 (cd $(DESTDIR)$(BINDIR); $(LN) -s python$(VERSION)$(EXE) python3$(EXE))
Barry Warsaw771d33e2010-12-13 18:04:23 +0000962 -if test "$(VERSION)" != "$(LDVERSION)"; then \
963 rm -f $(DESTDIR)$(BINDIR)/python$(VERSION)-config; \
964 (cd $(DESTDIR)$(BINDIR); $(LN) -s python$(LDVERSION)-config python$(VERSION)-config); \
965 rm -f $(DESTDIR)$(LIBPC)/python-$(LDVERSION).pc; \
966 (cd $(DESTDIR)$(LIBPC); $(LN) -s python-$(VERSION).pc python-$(LDVERSION).pc); \
967 fi
Benjamin Petersonf4841e22009-04-25 21:04:19 +0000968 -rm -f $(DESTDIR)$(BINDIR)/python3-config
969 (cd $(DESTDIR)$(BINDIR); $(LN) -s python$(VERSION)-config python3-config)
Antoine Pitrou20327222009-05-24 20:39:11 +0000970 -rm -f $(DESTDIR)$(LIBPC)/python3.pc
971 (cd $(DESTDIR)$(LIBPC); $(LN) -s python-$(VERSION).pc python3.pc)
Georg Brandlff52f762010-12-28 09:51:43 +0000972 -rm -f $(DESTDIR)$(BINDIR)/idle3
973 (cd $(DESTDIR)$(BINDIR); $(LN) -s idle$(VERSION) idle3)
974 -rm -f $(DESTDIR)$(BINDIR)/pydoc3
975 (cd $(DESTDIR)$(BINDIR); $(LN) -s pydoc$(VERSION) pydoc3)
976 -rm -f $(DESTDIR)$(BINDIR)/2to3
977 (cd $(DESTDIR)$(BINDIR); $(LN) -s 2to3-$(VERSION) 2to3)
Vinay Sajip7ded1f02012-05-26 03:45:29 +0100978 -rm -f $(DESTDIR)$(BINDIR)/pyvenv
979 (cd $(DESTDIR)$(BINDIR); $(LN) -s pyvenv-$(VERSION) pyvenv)
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000980
Ned Deilya48b61f2013-02-08 22:53:51 -0800981# Install the versioned manual page
982altmaninstall:
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000983 @for i in $(MANDIR) $(MANDIR)/man1; \
984 do \
Martin v. Löwis3b8ee082003-05-11 20:25:35 +0000985 if test ! -d $(DESTDIR)$$i; then \
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000986 echo "Creating directory $$i"; \
Martin v. Löwis3b8ee082003-05-11 20:25:35 +0000987 $(INSTALL) -d -m $(DIRMODE) $(DESTDIR)$$i; \
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000988 else true; \
989 fi; \
990 done
991 $(INSTALL_DATA) $(srcdir)/Misc/python.man \
Benjamin Peterson1a6e0d02008-10-25 15:49:17 +0000992 $(DESTDIR)$(MANDIR)/man1/python$(VERSION).1
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000993
Ned Deilya48b61f2013-02-08 22:53:51 -0800994# Install the unversioned manual page
995maninstall: altmaninstall
996 -rm -f $(DESTDIR)$(MANDIR)/man1/python3.1
997 (cd $(DESTDIR)$(MANDIR)/man1; $(LN) -s python$(VERSION).1 python3.1)
998
Neil Schemenauer85515ad2001-01-24 17:11:43 +0000999# Install the library
1000PLATDIR= plat-$(MACHDEP)
Jack Jansen83f898c2002-12-30 22:23:40 +00001001EXTRAPLATDIR= @EXTRAPLATDIR@
1002MACHDEPS= $(PLATDIR) $(EXTRAPLATDIR)
Thomas Wouters0e3f5912006-08-11 14:57:12 +00001003XMLLIBSUBDIRS= xml xml/dom xml/etree xml/parsers xml/sax
Benjamin Petersoncb6dbe52010-03-18 21:36:06 +00001004LIBSUBDIRS= tkinter tkinter/test tkinter/test/test_tkinter \
Victor Stinner5b326592011-05-25 01:15:59 +02001005 tkinter/test/test_ttk site-packages test \
Ned Deilye2d51902011-07-04 19:06:20 -07001006 test/capath test/data \
Barry Warsaw04fe64b2011-06-14 16:51:58 -04001007 test/cjkencodings test/decimaltestdata test/xmltestdata \
Vinay Sajip935b6292012-04-10 18:41:48 +01001008 test/subprocessdata test/sndhdrdata \
Alexander Belopolskye8f58322010-10-15 16:28:20 +00001009 test/tracedmodules test/encoded_modules \
Ned Deily7e18f432012-05-27 22:34:33 -07001010 test/namespace_pkgs \
1011 test/namespace_pkgs/both_portions \
1012 test/namespace_pkgs/both_portions/foo \
1013 test/namespace_pkgs/not_a_namespace_pkg \
1014 test/namespace_pkgs/not_a_namespace_pkg/foo \
1015 test/namespace_pkgs/portion1 \
1016 test/namespace_pkgs/portion1/foo \
1017 test/namespace_pkgs/portion2 \
1018 test/namespace_pkgs/portion2/foo \
1019 test/namespace_pkgs/project1 \
1020 test/namespace_pkgs/project1/parent \
1021 test/namespace_pkgs/project1/parent/child \
1022 test/namespace_pkgs/project2 \
1023 test/namespace_pkgs/project2/parent \
1024 test/namespace_pkgs/project2/parent/child \
1025 test/namespace_pkgs/project3 \
1026 test/namespace_pkgs/project3/parent \
1027 test/namespace_pkgs/project3/parent/child \
Eric V. Smith714370f2012-06-24 19:55:18 -04001028 test/namespace_pkgs/module_and_namespace_package \
1029 test/namespace_pkgs/module_and_namespace_package/a_test \
Georg Brandl53291232011-02-23 07:30:12 +00001030 collections concurrent concurrent/futures encodings \
R David Murray92cafb82011-06-17 11:41:49 -04001031 email email/mime test/test_email test/test_email/data \
Alexander Belopolskyff27ee02010-11-30 03:03:30 +00001032 html json test/json_tests http dbm xmlrpc \
Thomas Wouters49fd7fa2006-04-21 10:40:58 +00001033 sqlite3 sqlite3/test \
Georg Brandl1158a332009-06-04 09:30:30 +00001034 logging csv wsgiref urllib \
Alexandre Vassalottie9f305f2008-05-16 04:39:54 +00001035 lib2to3 lib2to3/fixes lib2to3/pgen2 lib2to3/tests \
Barry Warsaw04fe64b2011-06-14 16:51:58 -04001036 lib2to3/tests/data lib2to3/tests/data/fixers \
1037 lib2to3/tests/data/fixers/myfixes \
Thomas Wouters49fd7fa2006-04-21 10:40:58 +00001038 ctypes ctypes/test ctypes/macholib idlelib idlelib/Icons \
Fred Drakee612c8e2005-01-19 06:24:58 +00001039 distutils distutils/command distutils/tests $(XMLLIBSUBDIRS) \
Ned Deilycc409f42012-07-20 13:24:58 -07001040 importlib test/test_importlib test/test_importlib/builtin \
1041 test/test_importlib/extension test/test_importlib/frozen \
1042 test/test_importlib/import_ test/test_importlib/source \
Alexander Belopolskyea13d9d2010-11-01 17:39:37 +00001043 turtledemo \
Benjamin Peterson6bf2d6b2008-06-20 02:54:41 +00001044 multiprocessing multiprocessing/dummy \
Ned Deilye8b416e2012-03-22 13:34:11 -07001045 unittest unittest/test unittest/test/testmock \
Vinay Sajip7ded1f02012-05-26 03:45:29 +01001046 venv venv/scripts venv/scripts/posix \
Ronald Oussoren69026bb2009-05-19 19:07:43 +00001047 curses pydoc_data $(MACHDEPS)
Ned Deily58f27b22011-06-28 00:42:50 -07001048libinstall: build_all $(srcdir)/Lib/$(PLATDIR) $(srcdir)/Modules/xxmodule.c
Neil Schemenauer85515ad2001-01-24 17:11:43 +00001049 @for i in $(SCRIPTDIR) $(LIBDEST); \
1050 do \
Martin v. Löwis3b8ee082003-05-11 20:25:35 +00001051 if test ! -d $(DESTDIR)$$i; then \
Neil Schemenauer85515ad2001-01-24 17:11:43 +00001052 echo "Creating directory $$i"; \
Martin v. Löwis3b8ee082003-05-11 20:25:35 +00001053 $(INSTALL) -d -m $(DIRMODE) $(DESTDIR)$$i; \
Neil Schemenauer85515ad2001-01-24 17:11:43 +00001054 else true; \
1055 fi; \
1056 done
1057 @for d in $(LIBSUBDIRS); \
1058 do \
1059 a=$(srcdir)/Lib/$$d; \
1060 if test ! -d $$a; then continue; else true; fi; \
1061 b=$(LIBDEST)/$$d; \
Martin v. Löwis3b8ee082003-05-11 20:25:35 +00001062 if test ! -d $(DESTDIR)$$b; then \
Neil Schemenauer85515ad2001-01-24 17:11:43 +00001063 echo "Creating directory $$b"; \
Martin v. Löwis3b8ee082003-05-11 20:25:35 +00001064 $(INSTALL) -d -m $(DIRMODE) $(DESTDIR)$$b; \
Neil Schemenauer85515ad2001-01-24 17:11:43 +00001065 else true; \
1066 fi; \
1067 done
Trent Nelsonc101bf32012-10-16 08:13:12 -04001068 @for i in $(srcdir)/Lib/*.py `cat pybuilddir.txt`/_sysconfigdata.py; \
Neil Schemenauer85515ad2001-01-24 17:11:43 +00001069 do \
1070 if test -x $$i; then \
Martin v. Löwis3b8ee082003-05-11 20:25:35 +00001071 $(INSTALL_SCRIPT) $$i $(DESTDIR)$(LIBDEST); \
Neil Schemenauer3f5cc202001-04-10 23:03:35 +00001072 echo $(INSTALL_SCRIPT) $$i $(LIBDEST); \
Neil Schemenauer85515ad2001-01-24 17:11:43 +00001073 else \
Martin v. Löwis3b8ee082003-05-11 20:25:35 +00001074 $(INSTALL_DATA) $$i $(DESTDIR)$(LIBDEST); \
Neil Schemenauer85515ad2001-01-24 17:11:43 +00001075 echo $(INSTALL_DATA) $$i $(LIBDEST); \
1076 fi; \
1077 done
1078 @for d in $(LIBSUBDIRS); \
1079 do \
1080 a=$(srcdir)/Lib/$$d; \
1081 if test ! -d $$a; then continue; else true; fi; \
Thomas Wouters49fd7fa2006-04-21 10:40:58 +00001082 if test `ls $$a | wc -l` -lt 1; then continue; fi; \
Neil Schemenauer85515ad2001-01-24 17:11:43 +00001083 b=$(LIBDEST)/$$d; \
1084 for i in $$a/*; \
1085 do \
1086 case $$i in \
1087 *CVS) ;; \
1088 *.py[co]) ;; \
1089 *.orig) ;; \
1090 *~) ;; \
1091 *) \
1092 if test -d $$i; then continue; fi; \
1093 if test -x $$i; then \
Neil Schemenauer3f5cc202001-04-10 23:03:35 +00001094 echo $(INSTALL_SCRIPT) $$i $$b; \
Martin v. Löwis3b8ee082003-05-11 20:25:35 +00001095 $(INSTALL_SCRIPT) $$i $(DESTDIR)$$b; \
Neil Schemenauer85515ad2001-01-24 17:11:43 +00001096 else \
1097 echo $(INSTALL_DATA) $$i $$b; \
Martin v. Löwis3b8ee082003-05-11 20:25:35 +00001098 $(INSTALL_DATA) $$i $(DESTDIR)$$b; \
Neil Schemenauer85515ad2001-01-24 17:11:43 +00001099 fi;; \
1100 esac; \
1101 done; \
1102 done
Martin v. Löwis3b8ee082003-05-11 20:25:35 +00001103 $(INSTALL_DATA) $(srcdir)/LICENSE $(DESTDIR)$(LIBDEST)/LICENSE.txt
Ned Deily58f27b22011-06-28 00:42:50 -07001104 if test -d $(DESTDIR)$(LIBDEST)/distutils/tests; then \
1105 $(INSTALL_DATA) $(srcdir)/Modules/xxmodule.c \
1106 $(DESTDIR)$(LIBDEST)/distutils/tests ; \
1107 fi
Guido van Rossum827bfd02007-07-15 13:12:42 +00001108 -PYTHONPATH=$(DESTDIR)$(LIBDEST) $(RUNSHARED) \
doko@ubuntu.com1abe1c52012-06-30 20:42:45 +02001109 $(PYTHON_FOR_BUILD) -Wi $(DESTDIR)$(LIBDEST)/compileall.py \
Martin v. Löwis975302d2003-06-21 13:26:28 +00001110 -d $(LIBDEST) -f \
Benjamin Peterson89a545f2010-03-18 22:58:19 +00001111 -x 'bad_coding|badsyntax|site-packages|lib2to3/tests/data' \
Benjamin Petersonf47ed4a2009-04-11 20:45:40 +00001112 $(DESTDIR)$(LIBDEST)
Guido van Rossum827bfd02007-07-15 13:12:42 +00001113 -PYTHONPATH=$(DESTDIR)$(LIBDEST) $(RUNSHARED) \
doko@ubuntu.com1abe1c52012-06-30 20:42:45 +02001114 $(PYTHON_FOR_BUILD) -Wi -O $(DESTDIR)$(LIBDEST)/compileall.py \
Martin v. Löwis975302d2003-06-21 13:26:28 +00001115 -d $(LIBDEST) -f \
Benjamin Peterson89a545f2010-03-18 22:58:19 +00001116 -x 'bad_coding|badsyntax|site-packages|lib2to3/tests/data' \
Benjamin Petersonf47ed4a2009-04-11 20:45:40 +00001117 $(DESTDIR)$(LIBDEST)
Hye-Shik Chang0e5e6c72004-03-18 07:51:27 +00001118 -PYTHONPATH=$(DESTDIR)$(LIBDEST) $(RUNSHARED) \
doko@ubuntu.com1abe1c52012-06-30 20:42:45 +02001119 $(PYTHON_FOR_BUILD) -Wi $(DESTDIR)$(LIBDEST)/compileall.py \
Martin v. Löwis975302d2003-06-21 13:26:28 +00001120 -d $(LIBDEST)/site-packages -f \
Martin v. Löwis3b8ee082003-05-11 20:25:35 +00001121 -x badsyntax $(DESTDIR)$(LIBDEST)/site-packages
Hye-Shik Chang0e5e6c72004-03-18 07:51:27 +00001122 -PYTHONPATH=$(DESTDIR)$(LIBDEST) $(RUNSHARED) \
doko@ubuntu.com1abe1c52012-06-30 20:42:45 +02001123 $(PYTHON_FOR_BUILD) -Wi -O $(DESTDIR)$(LIBDEST)/compileall.py \
Martin v. Löwis975302d2003-06-21 13:26:28 +00001124 -d $(LIBDEST)/site-packages -f \
Martin v. Löwis3b8ee082003-05-11 20:25:35 +00001125 -x badsyntax $(DESTDIR)$(LIBDEST)/site-packages
Ned Deily4725b132012-09-08 19:04:47 -07001126 -PYTHONPATH=$(DESTDIR)$(LIBDEST) $(RUNSHARED) \
1127 $(PYTHON_FOR_BUILD) -m lib2to3.pgen2.driver $(DESTDIR)$(LIBDEST)/lib2to3/Grammar.txt
1128 -PYTHONPATH=$(DESTDIR)$(LIBDEST) $(RUNSHARED) \
1129 $(PYTHON_FOR_BUILD) -m lib2to3.pgen2.driver $(DESTDIR)$(LIBDEST)/lib2to3/PatternGrammar.txt
Neil Schemenauer85515ad2001-01-24 17:11:43 +00001130
1131# Create the PLATDIR source directory, if one wasn't distributed..
1132$(srcdir)/Lib/$(PLATDIR):
1133 mkdir $(srcdir)/Lib/$(PLATDIR)
1134 cp $(srcdir)/Lib/plat-generic/regen $(srcdir)/Lib/$(PLATDIR)/regen
1135 export PATH; PATH="`pwd`:$$PATH"; \
1136 export PYTHONPATH; PYTHONPATH="`pwd`/Lib"; \
Jack Jansenb6e9cad2001-08-15 01:26:28 +00001137 export DYLD_FRAMEWORK_PATH; DYLD_FRAMEWORK_PATH="`pwd`"; \
Jack Jansen0d153662001-12-19 09:24:40 +00001138 export EXE; EXE="$(BUILDEXE)"; \
doko@python.org3e6e2ac2013-01-25 13:12:29 +01001139 if [ -n "$(MULTIARCH)" ]; then export MULTIARCH; MULTIARCH=$(MULTIARCH); fi; \
doko@python.orga10e4a92013-01-25 18:45:12 +01001140 export PYTHON_FOR_BUILD; \
1141 if [ "$(BUILD_GNU_TYPE)" = "$(HOST_GNU_TYPE)" ]; then \
1142 PYTHON_FOR_BUILD="$(BUILDPYTHON)"; \
1143 else \
1144 PYTHON_FOR_BUILD="$(PYTHON_FOR_BUILD)"; \
1145 fi; \
Benjamin Petersonfce25a72008-12-30 18:05:46 +00001146 cd $(srcdir)/Lib/$(PLATDIR); $(RUNSHARED) ./regen
Neil Schemenauer85515ad2001-01-24 17:11:43 +00001147
Collin Winterbf199072010-03-19 21:17:17 +00001148python-config: $(srcdir)/Misc/python-config.in
1149 # Substitution happens here, as the completely-expanded BINDIR
1150 # is not available in configure
Barry Warsaw14d98ac2010-11-24 19:43:47 +00001151 sed -e "s,@EXENAME@,$(BINDIR)/python$(LDVERSION)$(EXE)," < $(srcdir)/Misc/python-config.in >python-config
Collin Winterbf199072010-03-19 21:17:17 +00001152
Neil Schemenauer85515ad2001-01-24 17:11:43 +00001153# Install the include files
1154INCLDIRSTOMAKE=$(INCLUDEDIR) $(CONFINCLUDEDIR) $(INCLUDEPY) $(CONFINCLUDEPY)
1155inclinstall:
1156 @for i in $(INCLDIRSTOMAKE); \
1157 do \
Martin v. Löwis3b8ee082003-05-11 20:25:35 +00001158 if test ! -d $(DESTDIR)$$i; then \
Neil Schemenauer85515ad2001-01-24 17:11:43 +00001159 echo "Creating directory $$i"; \
Martin v. Löwis3b8ee082003-05-11 20:25:35 +00001160 $(INSTALL) -d -m $(DIRMODE) $(DESTDIR)$$i; \
Neil Schemenauer85515ad2001-01-24 17:11:43 +00001161 else true; \
1162 fi; \
1163 done
1164 @for i in $(srcdir)/Include/*.h; \
1165 do \
1166 echo $(INSTALL_DATA) $$i $(INCLUDEPY); \
Martin v. Löwis3b8ee082003-05-11 20:25:35 +00001167 $(INSTALL_DATA) $$i $(DESTDIR)$(INCLUDEPY); \
Neil Schemenauer85515ad2001-01-24 17:11:43 +00001168 done
Martin v. Löwis3b8ee082003-05-11 20:25:35 +00001169 $(INSTALL_DATA) pyconfig.h $(DESTDIR)$(CONFINCLUDEPY)/pyconfig.h
Neil Schemenauer85515ad2001-01-24 17:11:43 +00001170
1171# Install the library and miscellaneous stuff needed for extending/embedding
1172# This goes into $(exec_prefix)
Barry Warsaw14d98ac2010-11-24 19:43:47 +00001173LIBPL= $(LIBDEST)/config-$(LDVERSION)
Antoine Pitrou20327222009-05-24 20:39:11 +00001174
1175# pkgconfig directory
1176LIBPC= $(LIBDIR)/pkgconfig
1177
Collin Winterbf199072010-03-19 21:17:17 +00001178libainstall: all python-config
Barry Warsaw14d98ac2010-11-24 19:43:47 +00001179 @for i in $(LIBDIR) $(LIBPL) $(LIBPC); \
Neil Schemenauer85515ad2001-01-24 17:11:43 +00001180 do \
Martin v. Löwis3b8ee082003-05-11 20:25:35 +00001181 if test ! -d $(DESTDIR)$$i; then \
Neil Schemenauer85515ad2001-01-24 17:11:43 +00001182 echo "Creating directory $$i"; \
Martin v. Löwis3b8ee082003-05-11 20:25:35 +00001183 $(INSTALL) -d -m $(DIRMODE) $(DESTDIR)$$i; \
Neil Schemenauer85515ad2001-01-24 17:11:43 +00001184 else true; \
1185 fi; \
1186 done
Martin v. Löwis1142de32002-03-29 16:28:31 +00001187 @if test -d $(LIBRARY); then :; else \
Jack Jansen127e56e2001-09-11 14:41:54 +00001188 if test "$(PYTHONFRAMEWORKDIR)" = no-framework; then \
Jason Tishlerc0f1e772002-07-29 16:18:23 +00001189 if test "$(SO)" = .dll; then \
Martin v. Löwis3b8ee082003-05-11 20:25:35 +00001190 $(INSTALL_DATA) $(LDLIBRARY) $(DESTDIR)$(LIBPL) ; \
Jason Tishlerc0f1e772002-07-29 16:18:23 +00001191 else \
Martin v. Löwis3b8ee082003-05-11 20:25:35 +00001192 $(INSTALL_DATA) $(LIBRARY) $(DESTDIR)$(LIBPL)/$(LIBRARY) ; \
1193 $(RANLIB) $(DESTDIR)$(LIBPL)/$(LIBRARY) ; \
Jason Tishlerc0f1e772002-07-29 16:18:23 +00001194 fi; \
Jack Jansenb6e9cad2001-08-15 01:26:28 +00001195 else \
Martin v. Löwis1142de32002-03-29 16:28:31 +00001196 echo Skip install of $(LIBRARY) - use make frameworkinstall; \
Jack Jansenb6e9cad2001-08-15 01:26:28 +00001197 fi; \
Neil Schemenauer85515ad2001-01-24 17:11:43 +00001198 fi
Martin v. Löwis3b8ee082003-05-11 20:25:35 +00001199 $(INSTALL_DATA) Modules/config.c $(DESTDIR)$(LIBPL)/config.c
Thomas Wouters49fd7fa2006-04-21 10:40:58 +00001200 $(INSTALL_DATA) Modules/python.o $(DESTDIR)$(LIBPL)/python.o
Martin v. Löwis3b8ee082003-05-11 20:25:35 +00001201 $(INSTALL_DATA) $(srcdir)/Modules/config.c.in $(DESTDIR)$(LIBPL)/config.c.in
1202 $(INSTALL_DATA) Makefile $(DESTDIR)$(LIBPL)/Makefile
1203 $(INSTALL_DATA) Modules/Setup $(DESTDIR)$(LIBPL)/Setup
1204 $(INSTALL_DATA) Modules/Setup.local $(DESTDIR)$(LIBPL)/Setup.local
1205 $(INSTALL_DATA) Modules/Setup.config $(DESTDIR)$(LIBPL)/Setup.config
Antoine Pitrou20327222009-05-24 20:39:11 +00001206 $(INSTALL_DATA) Misc/python.pc $(DESTDIR)$(LIBPC)/python-$(VERSION).pc
Martin v. Löwis3b8ee082003-05-11 20:25:35 +00001207 $(INSTALL_SCRIPT) $(srcdir)/Modules/makesetup $(DESTDIR)$(LIBPL)/makesetup
1208 $(INSTALL_SCRIPT) $(srcdir)/install-sh $(DESTDIR)$(LIBPL)/install-sh
Barry Warsaw14d98ac2010-11-24 19:43:47 +00001209 $(INSTALL_SCRIPT) python-config $(DESTDIR)$(BINDIR)/python$(LDVERSION)-config
Thomas Wouters49fd7fa2006-04-21 10:40:58 +00001210 rm python-config
Neil Schemenauer85515ad2001-01-24 17:11:43 +00001211 @if [ -s Modules/python.exp -a \
1212 "`echo $(MACHDEP) | sed 's/^\(...\).*/\1/'`" = "aix" ]; then \
1213 echo; echo "Installing support files for building shared extension modules on AIX:"; \
1214 $(INSTALL_DATA) Modules/python.exp \
Martin v. Löwis3b8ee082003-05-11 20:25:35 +00001215 $(DESTDIR)$(LIBPL)/python.exp; \
Neil Schemenauer85515ad2001-01-24 17:11:43 +00001216 echo; echo "$(LIBPL)/python.exp"; \
Neil Schemenauer3f5cc202001-04-10 23:03:35 +00001217 $(INSTALL_SCRIPT) $(srcdir)/Modules/makexp_aix \
Martin v. Löwis3b8ee082003-05-11 20:25:35 +00001218 $(DESTDIR)$(LIBPL)/makexp_aix; \
Neil Schemenauer85515ad2001-01-24 17:11:43 +00001219 echo "$(LIBPL)/makexp_aix"; \
Neil Schemenauer3f5cc202001-04-10 23:03:35 +00001220 $(INSTALL_SCRIPT) $(srcdir)/Modules/ld_so_aix \
Martin v. Löwis3b8ee082003-05-11 20:25:35 +00001221 $(DESTDIR)$(LIBPL)/ld_so_aix; \
Neil Schemenauer85515ad2001-01-24 17:11:43 +00001222 echo "$(LIBPL)/ld_so_aix"; \
1223 echo; echo "See Misc/AIX-NOTES for details."; \
1224 else true; \
1225 fi
Neil Schemenauer85515ad2001-01-24 17:11:43 +00001226
1227# Install the dynamically loadable modules
1228# This goes into $(exec_prefix)
Benjamin Petersonbbda0c52010-07-17 20:39:23 +00001229sharedinstall: sharedmods
doko@ubuntu.com1abe1c52012-06-30 20:42:45 +02001230 $(RUNSHARED) $(PYTHON_FOR_BUILD) $(srcdir)/setup.py install \
Martin v. Löwis1142de32002-03-29 16:28:31 +00001231 --prefix=$(prefix) \
Guido van Rossumb33e7892001-10-17 06:26:53 +00001232 --install-scripts=$(BINDIR) \
Martin v. Löwis3b8ee082003-05-11 20:25:35 +00001233 --install-platlib=$(DESTSHARED) \
Thomas Wouters81638f12011-03-06 11:49:15 -08001234 --root=$(DESTDIR)/
Trent Nelsonc101bf32012-10-16 08:13:12 -04001235 -rm $(DESTDIR)$(DESTSHARED)/_sysconfigdata.py
1236 -rm -r $(DESTDIR)$(DESTSHARED)/__pycache__
Neil Schemenauer85515ad2001-01-24 17:11:43 +00001237
Jack Jansencb4321e2002-08-09 00:18:21 +00001238# Here are a couple of targets for MacOSX again, to install a full
1239# framework-based Python. frameworkinstall installs everything, the
1240# subtargets install specific parts. Much of the actual work is offloaded to
Thomas Wouters73e5a5b2006-06-08 15:35:45 +00001241# the Makefile in Mac
Jack Jansencb4321e2002-08-09 00:18:21 +00001242#
Thomas Wouters477c8d52006-05-27 19:21:47 +00001243#
1244# This target is here for backward compatiblity, previous versions of Python
1245# hadn't integrated framework installation in the normal install process.
1246frameworkinstall: install
Guido van Rossumed2f7252002-08-09 19:18:25 +00001247
Jack Jansenb6e9cad2001-08-15 01:26:28 +00001248# On install, we re-make the framework
1249# structure in the install location, /Library/Frameworks/ or the argument to
1250# --enable-framework. If --enable-framework has been specified then we have
1251# automatically set prefix to the location deep down in the framework, so we
1252# only have to cater for the structural bits of the framework.
1253
Jack Jansencb4321e2002-08-09 00:18:21 +00001254frameworkinstallframework: frameworkinstallstructure install frameworkinstallmaclib
1255
1256frameworkinstallstructure: $(LDLIBRARY)
Jack Jansen127e56e2001-09-11 14:41:54 +00001257 @if test "$(PYTHONFRAMEWORKDIR)" = no-framework; then \
Jack Jansenb6e9cad2001-08-15 01:26:28 +00001258 echo Not configured with --enable-framework; \
Jack Jansen127e56e2001-09-11 14:41:54 +00001259 exit 1; \
Jack Jansenb6e9cad2001-08-15 01:26:28 +00001260 else true; \
1261 fi
Jack Jansencb4321e2002-08-09 00:18:21 +00001262 @for i in $(prefix)/Resources/English.lproj $(prefix)/lib; do\
Martin v. Löwis3b8ee082003-05-11 20:25:35 +00001263 if test ! -d $(DESTDIR)$$i; then \
Jack Jansen9592fe92003-05-25 22:01:32 +00001264 echo "Creating directory $(DESTDIR)$$i"; \
1265 $(INSTALL) -d -m $(DIRMODE) $(DESTDIR)$$i; \
Jack Jansenb6e9cad2001-08-15 01:26:28 +00001266 else true; \
1267 fi; \
1268 done
Ronald Oussoren0499d0b2010-12-07 14:41:05 +00001269 $(LN) -fsn include/python$(LDVERSION) $(DESTDIR)$(prefix)/Headers
Benjamin Peterson4c29b472008-07-01 14:42:51 +00001270 sed 's/%VERSION%/'"`$(RUNSHARED) ./$(BUILDPYTHON) -c 'import platform; print(platform.python_version())'`"'/g' < $(RESSRCDIR)/Info.plist > $(DESTDIR)$(prefix)/Resources/Info.plist
Jack Jansen9592fe92003-05-25 22:01:32 +00001271 $(LN) -fsn $(VERSION) $(DESTDIR)$(PYTHONFRAMEWORKINSTALLDIR)/Versions/Current
Christian Heimes81ee3ef2008-05-04 22:42:01 +00001272 $(LN) -fsn Versions/Current/$(PYTHONFRAMEWORK) $(DESTDIR)$(PYTHONFRAMEWORKINSTALLDIR)/$(PYTHONFRAMEWORK)
Jack Jansen9592fe92003-05-25 22:01:32 +00001273 $(LN) -fsn Versions/Current/Headers $(DESTDIR)$(PYTHONFRAMEWORKINSTALLDIR)/Headers
1274 $(LN) -fsn Versions/Current/Resources $(DESTDIR)$(PYTHONFRAMEWORKINSTALLDIR)/Resources
Jack Jansen4735b232003-06-20 20:36:53 +00001275 $(INSTALL_SHARED) $(LDLIBRARY) $(DESTDIR)$(PYTHONFRAMEWORKPREFIX)/$(LDLIBRARY)
Guido van Rossum7cb32ae2001-08-17 15:32:31 +00001276
Jack Jansencb4321e2002-08-09 00:18:21 +00001277# This installs Mac/Lib into the framework
Thomas Wouters0e3f5912006-08-11 14:57:12 +00001278# Install a number of symlinks to keep software that expects a normal unix
1279# install (which includes python-config) happy.
Jack Jansencb4321e2002-08-09 00:18:21 +00001280frameworkinstallmaclib:
Ned Deilyecd4e9d2012-07-24 03:31:48 -07001281 ln -fs "../../../$(PYTHONFRAMEWORK)" "$(DESTDIR)$(prefix)/lib/python$(VERSION)/config-$(LDVERSION)/libpython$(LDVERSION).a"
1282 ln -fs "../../../$(PYTHONFRAMEWORK)" "$(DESTDIR)$(prefix)/lib/python$(VERSION)/config-$(LDVERSION)/libpython$(LDVERSION).dylib"
Ronald Oussoren0499d0b2010-12-07 14:41:05 +00001283 ln -fs "../../../$(PYTHONFRAMEWORK)" "$(DESTDIR)$(prefix)/lib/python$(VERSION)/config-$(LDVERSION)/libpython$(VERSION).a"
1284 ln -fs "../../../$(PYTHONFRAMEWORK)" "$(DESTDIR)$(prefix)/lib/python$(VERSION)/config-$(LDVERSION)/libpython$(VERSION).dylib"
Ned Deilyecd4e9d2012-07-24 03:31:48 -07001285 ln -fs "../$(PYTHONFRAMEWORK)" "$(DESTDIR)$(prefix)/lib/libpython$(LDVERSION).dylib"
Ronald Oussoren0d2cceb2009-06-08 21:04:41 +00001286 ln -fs "../$(PYTHONFRAMEWORK)" "$(DESTDIR)$(prefix)/lib/libpython$(VERSION).dylib"
Jack Jansencb4321e2002-08-09 00:18:21 +00001287
1288# This installs the IDE, the Launcher and other apps into /Applications
1289frameworkinstallapps:
Thomas Wouters73e5a5b2006-06-08 15:35:45 +00001290 cd Mac && $(MAKE) installapps DESTDIR="$(DESTDIR)"
Jack Jansencb4321e2002-08-09 00:18:21 +00001291
1292# This install the unix python and pythonw tools in /usr/local/bin
1293frameworkinstallunixtools:
Thomas Wouters73e5a5b2006-06-08 15:35:45 +00001294 cd Mac && $(MAKE) installunixtools DESTDIR="$(DESTDIR)"
1295
1296frameworkaltinstallunixtools:
1297 cd Mac && $(MAKE) altinstallunixtools DESTDIR="$(DESTDIR)"
Jack Jansen0b06be72002-06-21 14:48:38 +00001298
Georg Brandl59b44722010-12-30 22:12:40 +00001299# This installs the Tools into the applications directory.
Jack Jansena1b77582003-06-19 22:35:20 +00001300# It is not part of a normal frameworkinstall
1301frameworkinstallextras:
Mark Dickinson09027aa2008-12-18 19:49:35 +00001302 cd Mac && $(MAKE) installextras DESTDIR="$(DESTDIR)"
Jack Jansena1b77582003-06-19 22:35:20 +00001303
Skip Montanarodecc6a42003-01-01 20:07:49 +00001304# This installs a few of the useful scripts in Tools/scripts
1305scriptsinstall:
Martin v. Löwis01f43112003-01-03 20:39:29 +00001306 SRCDIR=$(srcdir) $(RUNSHARED) \
doko@ubuntu.com1abe1c52012-06-30 20:42:45 +02001307 $(PYTHON_FOR_BUILD) $(srcdir)/Tools/scripts/setup.py install \
Skip Montanarodecc6a42003-01-01 20:07:49 +00001308 --prefix=$(prefix) \
Martin v. Löwis3b8ee082003-05-11 20:25:35 +00001309 --install-scripts=$(BINDIR) \
Thomas Wouters81638f12011-03-06 11:49:15 -08001310 --root=$(DESTDIR)/
Skip Montanarodecc6a42003-01-01 20:07:49 +00001311
Neil Schemenauer85515ad2001-01-24 17:11:43 +00001312# Build the toplevel Makefile
Victor Stinner69f55cc2011-10-12 22:09:40 +02001313Makefile.pre: $(srcdir)/Makefile.pre.in config.status
Neil Schemenauer85515ad2001-01-24 17:11:43 +00001314 CONFIG_FILES=Makefile.pre CONFIG_HEADERS= $(SHELL) config.status
1315 $(MAKE) -f Makefile.pre Makefile
1316
Neil Schemenauer64b1b682001-03-22 00:32:32 +00001317# Run the configure script.
Neil Schemenauer85515ad2001-01-24 17:11:43 +00001318config.status: $(srcdir)/configure
Neil Schemenauer64b1b682001-03-22 00:32:32 +00001319 $(SHELL) $(srcdir)/configure $(CONFIG_ARGS)
Neil Schemenauer85515ad2001-01-24 17:11:43 +00001320
Jack Jansen1999ef42001-12-06 21:47:20 +00001321.PRECIOUS: config.status $(BUILDPYTHON) Makefile Makefile.pre
Neil Schemenauer85515ad2001-01-24 17:11:43 +00001322
1323# Some make's put the object file in the current directory
1324.c.o:
Jeffrey Yasskind4fcdb12010-07-09 16:30:58 +00001325 $(CC) -c $(PY_CORE_CFLAGS) -o $@ $<
Neil Schemenauer85515ad2001-01-24 17:11:43 +00001326
Thomas Wouters49fd7fa2006-04-21 10:40:58 +00001327# Run reindent on the library
1328reindent:
Christian Heimesfd66e512008-01-29 12:18:50 +00001329 ./$(BUILDPYTHON) $(srcdir)/Tools/scripts/reindent.py -r $(srcdir)/Lib
Thomas Wouters49fd7fa2006-04-21 10:40:58 +00001330
Neil Schemenauer85515ad2001-01-24 17:11:43 +00001331# Rerun configure with the same options as it was run last time,
1332# provided the config.status script exists
1333recheck:
1334 $(SHELL) config.status --recheck
1335 $(SHELL) config.status
1336
Matthias Klose0f4c16e2012-03-14 23:10:15 +01001337# Rebuild the configure script from configure.ac; also rebuild pyconfig.h.in
Neil Schemenauer85515ad2001-01-24 17:11:43 +00001338autoconf:
Matthias Klose80b09d42010-04-25 21:23:32 +00001339 (cd $(srcdir); autoconf -Wall)
1340 (cd $(srcdir); autoheader -Wall)
Neil Schemenauer85515ad2001-01-24 17:11:43 +00001341
1342# Create a tags file for vi
1343tags::
1344 cd $(srcdir); \
1345 ctags -w -t Include/*.h; \
1346 for i in $(SRCDIRS); do ctags -w -t -a $$i/*.[ch]; \
1347 done; \
Guido van Rossumc9489662002-02-28 19:26:08 +00001348 sort -o tags tags
Neil Schemenauer85515ad2001-01-24 17:11:43 +00001349
1350# Create a tags file for GNU Emacs
1351TAGS::
1352 cd $(srcdir); \
1353 etags Include/*.h; \
1354 for i in $(SRCDIRS); do etags -a $$i/*.[ch]; done
1355
Martin v. Loewiscfc1cc22012-04-27 16:10:21 +02001356# Touch generated files
1357touch:
1358 hg --config extensions.touch=Tools/hg/hgtouch.py touch -v
1359
Neil Schemenauer85515ad2001-01-24 17:11:43 +00001360# Sanitation targets -- clean leaves libraries, executables and tags
Mark Dickinson067b38e2009-09-24 19:24:44 +00001361# files, which clobber removes as well
Thomas Wouters49fd7fa2006-04-21 10:40:58 +00001362pycremoval:
Petri Lehtinenbc74ee02011-11-05 21:04:24 +02001363 -find $(srcdir) -depth -name '__pycache__' -exec rm -rf {} ';'
Barry Warsaw5f2347d2010-04-26 16:02:14 +00001364 -find $(srcdir) -name '*.py[co]' -exec rm -f {} ';'
Neil Schemenauer85515ad2001-01-24 17:11:43 +00001365
Guido van Rossum77b5e332007-08-29 23:24:02 +00001366rmtestturds:
1367 -rm -f *BAD *GOOD *SKIPPED
1368 -rm -rf OUT
1369 -rm -f *.TXT
1370 -rm -f *.txt
1371 -rm -f gb-18030-2000.xml
1372
Guido van Rossum8188e632007-08-29 23:48:29 +00001373docclean:
1374 -rm -rf Doc/build
1375 -rm -rf Doc/tools/sphinx Doc/tools/pygments Doc/tools/docutils
1376
Guido van Rossum5420bc32007-08-29 23:35:30 +00001377clean: pycremoval
Georg Brandl241bdab2010-07-31 22:05:54 +00001378 find . -name '*.[oa]' -exec rm -f {} ';'
Guido van Rossumcd0ed972001-04-14 17:57:07 +00001379 find . -name '*.s[ol]' -exec rm -f {} ';'
Georg Brandl241bdab2010-07-31 22:05:54 +00001380 find . -name '*.so.[0-9]*.[0-9]*' -exec rm -f {} ';'
Thomas Heller6ab91482009-04-24 18:27:10 +00001381 find build -name 'fficonfig.h' -exec rm -f {} ';' || true
Trent Nelsonc101bf32012-10-16 08:13:12 -04001382 find build -name '*.py' -exec rm -f {} ';' || true
1383 find build -name '*.py[co]' -exec rm -f {} ';' || true
1384 -rm -f pybuilddir.txt
Ned Deily4725b132012-09-08 19:04:47 -07001385 -rm -f Lib/lib2to3/*Grammar*.pickle
Antoine Pitroue67f48c2012-06-19 22:29:35 +02001386 -rm -f Modules/_testembed Modules/_freeze_importlib
Neil Schemenauer85515ad2001-01-24 17:11:43 +00001387
Christian Heimes33fe8092008-04-13 13:53:33 +00001388profile-removal:
1389 find . -name '*.gc??' -exec rm -f {} ';'
1390
1391clobber: clean profile-removal
Jack Jansen1999ef42001-12-06 21:47:20 +00001392 -rm -f $(BUILDPYTHON) $(PGEN) $(LIBRARY) $(LDLIBRARY) $(DLLLIBRARY) \
Matthias Klose597e6b42012-04-04 13:20:55 +02001393 tags TAGS \
Guido van Rossum7cb32ae2001-08-17 15:32:31 +00001394 config.cache config.log pyconfig.h Modules/config.c
Guido van Rossum1d88c592001-06-06 17:51:57 +00001395 -rm -rf build platform
Jack Jansenc6096892003-02-27 23:19:46 +00001396 -rm -rf $(PYTHONFRAMEWORKDIR)
Neil Schemenauer85515ad2001-01-24 17:11:43 +00001397
1398# Make things extra clean, before making a distribution:
1399# remove all generated files, even Makefile[.pre]
Neal Norwitz1a196b52006-01-03 01:38:53 +00001400# Keep configure and Python-ast.[ch], it's possible they can't be generated
Neil Schemenauer85515ad2001-01-24 17:11:43 +00001401distclean: clobber
Mark Dickinsonde802be2010-08-01 21:33:01 +00001402 for file in Lib/test/data/* ; do \
1403 if test "$$file" != "Lib/test/data/README"; then rm "$$file"; fi; \
1404 done
Martin v. Löwisdea59e52006-01-05 10:00:36 +00001405 -rm -f core Makefile Makefile.pre config.status \
Mark Dickinson9b3d5572009-08-31 14:52:10 +00001406 Modules/Setup Modules/Setup.local Modules/Setup.config \
Georg Brandl9a829be2011-02-15 15:44:51 +00001407 Modules/ld_so_aix Modules/python.exp Misc/python.pc
Benjamin Peterson6a6666a2010-04-11 21:49:28 +00001408 -rm -f python*-gdb.py
Neil Schemenauere0d43572001-02-03 17:16:29 +00001409 find $(srcdir) '(' -name '*.fdc' -o -name '*~' \
1410 -o -name '[@,#]*' -o -name '*.old' \
1411 -o -name '*.orig' -o -name '*.rej' \
1412 -o -name '*.bak' ')' \
1413 -exec rm -f {} ';'
Neil Schemenauer85515ad2001-01-24 17:11:43 +00001414
1415# Check for smelly exported symbols (not starting with Py/_Py)
1416smelly: all
1417 nm -p $(LIBRARY) | \
1418 sed -n "/ [TDB] /s/.* //p" | grep -v "^_*Py" | sort -u; \
1419
1420# Find files with funny names
1421funny:
Éric Araujo1c608e32011-08-10 02:01:32 +02001422 find $(SUBDIRS) $(SUBDIRSTOO) \
Éric Araujoe9715b92011-08-10 21:42:23 +02001423 -type d \
Neil Schemenauer85515ad2001-01-24 17:11:43 +00001424 -o -name '*.[chs]' \
1425 -o -name '*.py' \
Georg Brandl4c9aa452010-08-14 13:43:37 +00001426 -o -name '*.pyw' \
Neil Schemenauer85515ad2001-01-24 17:11:43 +00001427 -o -name '*.dat' \
1428 -o -name '*.el' \
1429 -o -name '*.fd' \
1430 -o -name '*.in' \
Guido van Rossum77b5e332007-08-29 23:24:02 +00001431 -o -name '*.gif' \
1432 -o -name '*.txt' \
1433 -o -name '*.xml' \
1434 -o -name '*.xbm' \
1435 -o -name '*.xpm' \
1436 -o -name '*.uue' \
1437 -o -name '*.decTest' \
Georg Brandl4c9aa452010-08-14 13:43:37 +00001438 -o -name '*.tmCommand' \
1439 -o -name '*.tmSnippet' \
Neil Schemenauer85515ad2001-01-24 17:11:43 +00001440 -o -name 'Setup' \
1441 -o -name 'Setup.*' \
Guido van Rossum77b5e332007-08-29 23:24:02 +00001442 -o -name regen \
Neil Schemenauer85515ad2001-01-24 17:11:43 +00001443 -o -name README \
Georg Brandl4c9aa452010-08-14 13:43:37 +00001444 -o -name NEWS \
1445 -o -name HISTORY \
Neil Schemenauer85515ad2001-01-24 17:11:43 +00001446 -o -name Makefile \
1447 -o -name ChangeLog \
Georg Brandl4c9aa452010-08-14 13:43:37 +00001448 -o -name .hgignore \
1449 -o -name .bzrignore \
Neil Schemenauer85515ad2001-01-24 17:11:43 +00001450 -o -name MANIFEST \
Éric Araujob5da6e92011-08-16 19:05:56 +02001451 -o -print
Neil Schemenauer85515ad2001-01-24 17:11:43 +00001452
Christian Heimesada8c3b2008-03-18 18:26:33 +00001453# Perform some verification checks on any modified files.
Brett Cannona741ebf2008-09-05 23:01:27 +00001454patchcheck:
Georg Brandlfcaf9102008-07-16 02:17:56 +00001455 $(RUNSHARED) ./$(BUILDPYTHON) $(srcdir)/Tools/scripts/patchcheck.py
Christian Heimesada8c3b2008-03-18 18:26:33 +00001456
Guido van Rossum9454ad72001-08-18 21:08:22 +00001457# Dependencies
1458
Martin v. Löwis06f15bb2001-12-02 13:02:32 +00001459Python/thread.o: @THREADHEADERS@
Guido van Rossum9454ad72001-08-18 21:08:22 +00001460
Guido van Rossumd4f7da32002-10-10 15:04:04 +00001461# Declare targets that aren't real files
Victor Stinnere0a669e2011-12-15 21:48:39 +01001462.PHONY: all build_all sharedmods oldsharedmods test quicktest
Guido van Rossumd4f7da32002-10-10 15:04:04 +00001463.PHONY: install altinstall oldsharedinstall bininstall altbininstall
1464.PHONY: maninstall libinstall inclinstall libainstall sharedinstall
1465.PHONY: frameworkinstall frameworkinstallframework frameworkinstallstructure
1466.PHONY: frameworkinstallmaclib frameworkinstallapps frameworkinstallunixtools
Victor Stinner4e314432010-10-07 21:45:39 +00001467.PHONY: frameworkaltinstallunixtools recheck autoconf clean clobber distclean
Ned Deilyaa20b002013-02-08 23:02:09 -08001468.PHONY: smelly funny patchcheck touch altmaninstall
Benjamin Peterson6a6666a2010-04-11 21:49:28 +00001469.PHONY: gdbhooks
Guido van Rossumd4f7da32002-10-10 15:04:04 +00001470
Neil Schemenauer85515ad2001-01-24 17:11:43 +00001471# IF YOU PUT ANYTHING HERE IT WILL GO AWAY
Barry Warsaw771d33e2010-12-13 18:04:23 +00001472# Local Variables:
1473# mode: makefile
1474# End: