diff options
author | Ned Deily <nad@acm.org> | 2013-11-22 06:42:25 (GMT) |
---|---|---|
committer | Ned Deily <nad@acm.org> | 2013-11-22 06:42:25 (GMT) |
commit | b8f944f0b76ebfeecb181498868f10b273981668 (patch) | |
tree | a818ddc5a97ce0095936b9aebc1da0559f24afb5 /Makefile.pre.in | |
parent | c06d6fdc37a70c28feaac60b06047b9f6357c05f (diff) | |
download | cpython-b8f944f0b76ebfeecb181498868f10b273981668.zip cpython-b8f944f0b76ebfeecb181498868f10b273981668.tar.gz cpython-b8f944f0b76ebfeecb181498868f10b273981668.tar.bz2 |
Issue #19649: On OS X, the same set of file names are now installed
in bin directories for all configurations: non-framework vs framework,
and single arch vs universal builds. pythonx.y-32 is now always
installed for 64-bit/32-bit universal builds. The obsolete and
undocumented pythonw* symlinks are no longer installed anywhere.
Diffstat (limited to 'Makefile.pre.in')
-rw-r--r-- | Makefile.pre.in | 35 |
1 files changed, 31 insertions, 4 deletions
diff --git a/Makefile.pre.in b/Makefile.pre.in index 33f6f86..0e75bbe 100644 --- a/Makefile.pre.in +++ b/Makefile.pre.in @@ -148,6 +148,12 @@ PYTHONFRAMEWORKINSTALLDIR= @PYTHONFRAMEWORKINSTALLDIR@ MACOSX_DEPLOYMENT_TARGET=@CONFIGURE_MACOSX_DEPLOYMENT_TARGET@ @EXPORT_MACOSX_DEPLOYMENT_TARGET@export MACOSX_DEPLOYMENT_TARGET +# Option to install to strip binaries +STRIPFLAG=-s + +# Flags to lipo to produce a 32-bit-only universal executable +LIPO_32BIT_FLAGS=@LIPO_32BIT_FLAGS@ + # Options to enable prebinding (for fast startup prior to Mac OS X 10.3) OTHER_LIBTOOL_OPT=@OTHER_LIBTOOL_OPT@ @@ -955,7 +961,7 @@ quicktest: all platform $(TESTRUNNER) $(QUICKTESTOPTS) -install: altinstall bininstall maninstall +install: @FRAMEWORKINSTALLFIRST@ altinstall bininstall maninstall @FRAMEWORKINSTALLLAST@ altinstall: @FRAMEWORKALTINSTALLFIRST@ altbininstall libinstall inclinstall libainstall \ sharedinstall oldsharedinstall altmaninstall @FRAMEWORKALTINSTALLLAST@ @@ -983,7 +989,7 @@ $(DESTSHARED): # Install the interpreter with $(VERSION) affixed # This goes into $(exec_prefix) -altbininstall: $(BUILDPYTHON) +altbininstall: $(BUILDPYTHON) @FRAMEWORKPYTHONW@ @for i in $(BINDIR) $(LIBDIR); \ do \ if test ! -d $(DESTDIR)$$i; then \ @@ -992,7 +998,11 @@ altbininstall: $(BUILDPYTHON) else true; \ fi; \ done - $(INSTALL_PROGRAM) $(BUILDPYTHON) $(DESTDIR)$(BINDIR)/python$(LDVERSION)$(EXE) + if test "$(PYTHONFRAMEWORKDIR)" = "no-framework" ; then \ + $(INSTALL_PROGRAM) $(BUILDPYTHON) $(DESTDIR)$(BINDIR)/python$(LDVERSION)$(EXE); \ + else \ + $(INSTALL_PROGRAM) $(STRIPFLAG) Mac/pythonw $(DESTDIR)$(BINDIR)/python$(LDVERSION)$(EXE); \ + fi -if test "$(VERSION)" != "$(LDVERSION)"; then \ if test -f $(DESTDIR)$(BINDIR)/python$(VERSION)$(EXE) -o -h $(DESTDIR)$(BINDIR)/python$(VERSION)$(EXE); \ then rm -f $(DESTDIR)$(BINDIR)/python$(VERSION)$(EXE); \ @@ -1013,6 +1023,12 @@ altbininstall: $(BUILDPYTHON) fi; \ else true; \ fi + if test "x$(LIPO_32BIT_FLAGS)" != "x" ; then \ + rm -f $(DESTDIR)$(BINDIR)python$(VERSION)-32$(EXE); \ + lipo $(LIPO_32BIT_FLAGS) \ + -output $(DESTDIR)$(BINDIR)/python$(VERSION)-32$(EXE) \ + $(DESTDIR)$(BINDIR)/python$(VERSION)$(EXE); \ + fi bininstall: altbininstall -if test -f $(DESTDIR)$(BINDIR)/python3$(EXE) -o -h $(DESTDIR)$(BINDIR)/python3$(EXE); \ @@ -1038,6 +1054,10 @@ bininstall: altbininstall (cd $(DESTDIR)$(BINDIR); $(LN) -s 2to3-$(VERSION) 2to3) -rm -f $(DESTDIR)$(BINDIR)/pyvenv (cd $(DESTDIR)$(BINDIR); $(LN) -s pyvenv-$(VERSION) pyvenv) + if test "x$(LIPO_32BIT_FLAGS)" != "x" ; then \ + rm -f $(DESTDIR)$(BINDIR)/python3-32$(EXE); \ + (cd $(DESTDIR)$(BINDIR); $(LN) -s python$(VERSION)-32$(EXE) python3-32$(EXE)) \ + fi # Install the versioned manual page altmaninstall: @@ -1364,7 +1384,14 @@ frameworkinstallmaclib: frameworkinstallapps: cd Mac && $(MAKE) installapps DESTDIR="$(DESTDIR)" -# This install the unix python and pythonw tools in /usr/local/bin +# Build the bootstrap executable that will spawn the interpreter inside +# an app bundle within the framework. This allows the interpreter to +# run OS X GUI APIs. +frameworkpythonw: + cd Mac && $(MAKE) pythonw + +# This installs the python* and other bin symlinks in $prefix/bin or in +# a bin directory relative to the framework root frameworkinstallunixtools: cd Mac && $(MAKE) installunixtools DESTDIR="$(DESTDIR)" |