Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 1 | # This file can be invoked from the various frameworkinstall... targets in the |
| 2 | # main Makefile. The next couple of variables are overridden on the |
| 3 | # commandline in that case. |
| 4 | |
| 5 | VERSION=@VERSION@ |
Thomas Wouters | 73e5a5b | 2006-06-08 15:35:45 +0000 | [diff] [blame] | 6 | builddir = .. |
| 7 | srcdir=@srcdir@ |
Thomas Wouters | 0e3f591 | 2006-08-11 14:57:12 +0000 | [diff] [blame] | 8 | prefix=@prefix@ |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 9 | LIBDEST=$(prefix)/lib/python$(VERSION) |
Thomas Wouters | 73e5a5b | 2006-06-08 15:35:45 +0000 | [diff] [blame] | 10 | RUNSHARED=@RUNSHARED@ |
| 11 | BUILDEXE=@BUILDEXEEXT@ |
| 12 | BUILDPYTHON=$(builddir)/python$(BUILDEXE) |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 13 | DESTDIR= |
Thomas Wouters | 73e5a5b | 2006-06-08 15:35:45 +0000 | [diff] [blame] | 14 | LDFLAGS=@LDFLAGS@ |
| 15 | FRAMEWORKUNIXTOOLSPREFIX=@FRAMEWORKUNIXTOOLSPREFIX@ |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 16 | PYTHONFRAMEWORK=@PYTHONFRAMEWORK@ |
Ronald Oussoren | f29b6b4 | 2009-03-30 20:00:00 +0000 | [diff] [blame^] | 17 | PYTHONFRAMEWORKIDENTIFIER=@PYTHONFRAMEWORKIDENTIFIER@ |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 18 | |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 19 | |
| 20 | # These are normally glimpsed from the previous set |
Thomas Wouters | 73e5a5b | 2006-06-08 15:35:45 +0000 | [diff] [blame] | 21 | bindir=$(prefix)/bin |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 22 | PYTHONAPPSDIR=/Applications/$(PYTHONFRAMEWORK) $(VERSION) |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 23 | APPINSTALLDIR=$(prefix)/Resources/Python.app |
| 24 | |
| 25 | # Variables for installing the "normal" unix binaries |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 26 | INSTALLED_PYTHONAPP=$(APPINSTALLDIR)/Contents/MacOS/$(PYTHONFRAMEWORK) |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 27 | |
| 28 | # Items more-or-less copied from the main Makefile |
| 29 | DIRMODE=755 |
| 30 | FILEMODE=644 |
| 31 | INSTALL=@INSTALL@ |
| 32 | INSTALL_SYMLINK=ln -fsn |
| 33 | INSTALL_PROGRAM=@INSTALL_PROGRAM@ |
| 34 | INSTALL_SCRIPT= @INSTALL_SCRIPT@ |
| 35 | INSTALL_DATA=@INSTALL_DATA@ |
| 36 | LN=@LN@ |
| 37 | STRIPFLAG=-s |
| 38 | CPMAC=/Developer/Tools/CpMac |
| 39 | |
Thomas Wouters | 73e5a5b | 2006-06-08 15:35:45 +0000 | [diff] [blame] | 40 | APPTEMPLATE=$(srcdir)/Resources/app |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 41 | APPSUBDIRS=MacOS Resources Resources/English.lproj \ |
| 42 | Resources/English.lproj/Documentation \ |
| 43 | Resources/English.lproj/Documentation/doc \ |
| 44 | Resources/English.lproj/Documentation/ide |
Thomas Wouters | 73e5a5b | 2006-06-08 15:35:45 +0000 | [diff] [blame] | 45 | DOCDIR=$(srcdir)/Resources/app/Resources/English.lproj/Documentation |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 46 | DOCINDEX=$(DOCDIR)/"Documentation idx" |
Thomas Wouters | 73e5a5b | 2006-06-08 15:35:45 +0000 | [diff] [blame] | 47 | compileall=$(srcdir)/../Lib/compileall.py |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 48 | |
Georg Brandl | 59f8d83 | 2008-07-19 09:58:13 +0000 | [diff] [blame] | 49 | installapps: install_Python install_PythonLauncher install_IDLE \ |
| 50 | checkapplepython install_pythonw install_versionedtools |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 51 | |
Georg Brandl | 59f8d83 | 2008-07-19 09:58:13 +0000 | [diff] [blame] | 52 | installapps4way: install_Python4way install_PythonLauncher \ |
Ronald Oussoren | 672f62a | 2009-02-12 15:18:15 +0000 | [diff] [blame] | 53 | install_IDLE4way install_pythonw4way install_versionedtools |
Georg Brandl | fcaf910 | 2008-07-16 02:17:56 +0000 | [diff] [blame] | 54 | |
| 55 | |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 56 | install_pythonw: pythonw |
| 57 | $(INSTALL_PROGRAM) $(STRIPFLAG) pythonw "$(DESTDIR)$(prefix)/bin/pythonw$(VERSION)" |
| 58 | $(INSTALL_PROGRAM) $(STRIPFLAG) pythonw "$(DESTDIR)$(prefix)/bin/python$(VERSION)" |
| 59 | ln -sf python$(VERSION) "$(DESTDIR)$(prefix)/bin/python" |
| 60 | ln -sf pythonw$(VERSION) "$(DESTDIR)$(prefix)/bin/pythonw" |
| 61 | |
Georg Brandl | fcaf910 | 2008-07-16 02:17:56 +0000 | [diff] [blame] | 62 | |
| 63 | # Install 3 variants of python/pythonw: |
| 64 | # - 32-bit (i386 and ppc) |
| 65 | # - 64-bit (x86_64 and ppc64) |
| 66 | # - all (all four architectures) |
| 67 | # - Make 'python' and 'pythonw' aliases for the 32-bit variant |
| 68 | install_pythonw4way: pythonw-32 pythonw-64 pythonw |
| 69 | $(INSTALL_PROGRAM) $(STRIPFLAG) pythonw-64 "$(DESTDIR)$(prefix)/bin/pythonw$(VERSION)-64" |
| 70 | $(INSTALL_PROGRAM) $(STRIPFLAG) pythonw-64 "$(DESTDIR)$(prefix)/bin/python$(VERSION)-64" |
| 71 | ln -sf python$(VERSION)-64 "$(DESTDIR)$(prefix)/bin/python-64" |
| 72 | ln -sf pythonw$(VERSION)-64 "$(DESTDIR)$(prefix)/bin/pythonw-64" |
| 73 | |
| 74 | $(INSTALL_PROGRAM) $(STRIPFLAG) pythonw-32 "$(DESTDIR)$(prefix)/bin/pythonw$(VERSION)-32" |
| 75 | $(INSTALL_PROGRAM) $(STRIPFLAG) pythonw-32 "$(DESTDIR)$(prefix)/bin/python$(VERSION)-32" |
| 76 | ln -sf python$(VERSION)-32 "$(DESTDIR)$(prefix)/bin/python-32" |
| 77 | ln -sf pythonw$(VERSION)-32 "$(DESTDIR)$(prefix)/bin/pythonw-32" |
| 78 | |
| 79 | $(INSTALL_PROGRAM) $(STRIPFLAG) pythonw "$(DESTDIR)$(prefix)/bin/pythonw$(VERSION)-all" |
| 80 | $(INSTALL_PROGRAM) $(STRIPFLAG) pythonw "$(DESTDIR)$(prefix)/bin/python$(VERSION)-all" |
| 81 | ln -sf python$(VERSION)-all "$(DESTDIR)$(prefix)/bin/python-all" |
| 82 | ln -sf pythonw$(VERSION)-all "$(DESTDIR)$(prefix)/bin/pythonw-all" |
| 83 | |
| 84 | ln -sf pythonw$(VERSION)-32 "$(DESTDIR)$(prefix)/bin/pythonw$(VERSION)" |
| 85 | ln -sf python$(VERSION)-32 "$(DESTDIR)$(prefix)/bin/python$(VERSION)" |
| 86 | ln -sf pythonw$(VERSION)-32 "$(DESTDIR)$(prefix)/bin/pythonw" |
| 87 | ln -sf python$(VERSION)-32 "$(DESTDIR)$(prefix)/bin/python" |
| 88 | |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 89 | # |
| 90 | # Install unix tools in /usr/local/bin. These are just aliases for the |
| 91 | # actual installation inside the framework. |
| 92 | # |
| 93 | installunixtools: |
Thomas Wouters | 73e5a5b | 2006-06-08 15:35:45 +0000 | [diff] [blame] | 94 | if [ ! -d "$(DESTDIR)$(FRAMEWORKUNIXTOOLSPREFIX)/bin" ]; then \ |
| 95 | $(INSTALL) -d -m $(DIRMODE) "$(DESTDIR)$(FRAMEWORKUNIXTOOLSPREFIX)/bin" ;\ |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 96 | fi |
Thomas Wouters | 73e5a5b | 2006-06-08 15:35:45 +0000 | [diff] [blame] | 97 | for fn in python pythonw idle pydoc python-config smtpd.py \ |
| 98 | python$(VERSION) pythonw$(VERSION) idle$(VERSION) \ |
Georg Brandl | fcaf910 | 2008-07-16 02:17:56 +0000 | [diff] [blame] | 99 | pydoc$(VERSION) python$(VERSION)-config smtpd$(VERSION).py ;\ |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 100 | do \ |
Thomas Wouters | 73e5a5b | 2006-06-08 15:35:45 +0000 | [diff] [blame] | 101 | ln -fs "$(prefix)/bin/$${fn}" "$(DESTDIR)$(FRAMEWORKUNIXTOOLSPREFIX)/bin/$${fn}" ;\ |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 102 | done |
| 103 | |
Georg Brandl | fcaf910 | 2008-07-16 02:17:56 +0000 | [diff] [blame] | 104 | |
| 105 | # TODO: install symlinks for -32, -64 and -all as well |
| 106 | installunixtools4way: installunixtools |
| 107 | |
| 108 | |
Thomas Wouters | 73e5a5b | 2006-06-08 15:35:45 +0000 | [diff] [blame] | 109 | # |
| 110 | # Like installunixtools, but only install links to the versioned binaries. |
| 111 | # |
| 112 | altinstallunixtools: |
| 113 | if [ ! -d "$(DESTDIR)$(FRAMEWORKUNIXTOOLSPREFIX)/bin" ]; then \ |
| 114 | $(INSTALL) -d -m $(DIRMODE) "$(DESTDIR)$(FRAMEWORKUNIXTOOLSPREFIX)/bin" ;\ |
| 115 | fi |
| 116 | for fn in python$(VERSION) pythonw$(VERSION) idle$(VERSION) \ |
Georg Brandl | 3ccb787 | 2008-07-16 03:00:45 +0000 | [diff] [blame] | 117 | pydoc$(VERSION) python$(VERSION)-config smtpd$(VERSION).py ;\ |
Thomas Wouters | 73e5a5b | 2006-06-08 15:35:45 +0000 | [diff] [blame] | 118 | do \ |
| 119 | ln -fs "$(prefix)/bin/$${fn}" "$(DESTDIR)$(FRAMEWORKUNIXTOOLSPREFIX)/bin/$${fn}" ;\ |
| 120 | done |
| 121 | |
Georg Brandl | fcaf910 | 2008-07-16 02:17:56 +0000 | [diff] [blame] | 122 | # TODO: -32, -64 and -all variants |
| 123 | altinstallunixtools4way: altinstallunixtools |
Thomas Wouters | 73e5a5b | 2006-06-08 15:35:45 +0000 | [diff] [blame] | 124 | |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 125 | # By default most tools are installed without a version in their basename, to |
| 126 | # make it easier to install (and use) several python versions side-by-side move |
| 127 | # the tools to a version-specific name and add the non-versioned name as an |
| 128 | # alias. |
| 129 | install_versionedtools: |
Georg Brandl | fcaf910 | 2008-07-16 02:17:56 +0000 | [diff] [blame] | 130 | for fn in idle pydoc ;\ |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 131 | do \ |
| 132 | if [ -h "$(DESTDIR)$(prefix)/bin/$${fn}" ]; then \ |
| 133 | continue ;\ |
| 134 | fi ;\ |
| 135 | mv "$(DESTDIR)$(prefix)/bin/$${fn}" "$(DESTDIR)$(prefix)/bin/$${fn}$(VERSION)" ;\ |
| 136 | ln -sf "$${fn}$(VERSION)" "$(DESTDIR)$(prefix)/bin/$${fn}" ;\ |
| 137 | done |
Georg Brandl | fcaf910 | 2008-07-16 02:17:56 +0000 | [diff] [blame] | 138 | if [ ! -h "$(DESTDIR)$(prefix)/bin/python-config" ]; then \ |
| 139 | mv "$(DESTDIR)$(prefix)/bin/python-config" "$(DESTDIR)$(prefix)/bin/python$(VERSION)-config" ;\ |
| 140 | ln -sf "python$(VERSION)-config" "$(DESTDIR)$(prefix)/bin/python-config" ; \ |
| 141 | fi |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 142 | if [ ! -h "$(DESTDIR)$(prefix)/bin/smtpd.py" ]; then \ |
| 143 | mv "$(DESTDIR)$(prefix)/bin/smtpd.py" "$(DESTDIR)$(prefix)/bin/smtpd$(VERSION).py" ;\ |
| 144 | ln -sf "smtpd$(VERSION).py" "$(DESTDIR)$(prefix)/bin/smtpd.py" ;\ |
| 145 | fi |
| 146 | |
| 147 | |
Thomas Wouters | 89f507f | 2006-12-13 04:49:30 +0000 | [diff] [blame] | 148 | pythonw: $(srcdir)/Tools/pythonw.c Makefile |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 149 | $(CC) $(LDFLAGS) -o $@ $(srcdir)/Tools/pythonw.c \ |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 150 | -DPYTHONWEXECUTABLE='"$(APPINSTALLDIR)/Contents/MacOS/$(PYTHONFRAMEWORK)"' |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 151 | |
Georg Brandl | fcaf910 | 2008-07-16 02:17:56 +0000 | [diff] [blame] | 152 | pythonw-32: $(srcdir)/Tools/pythonw.c Makefile |
| 153 | $(CC) $(LDFLAGS) -o $@ -arch i386 -arch ppc $(srcdir)/Tools/pythonw.c \ |
| 154 | -DPYTHONWEXECUTABLE='"$(APPINSTALLDIR)/Contents/MacOS/$(PYTHONFRAMEWORK)-32"' |
| 155 | |
| 156 | pythonw-64: $(srcdir)/Tools/pythonw.c Makefile |
| 157 | $(CC) $(LDFLAGS) -o $@ -arch x86_64 -arch ppc64 $(srcdir)/Tools/pythonw.c \ |
| 158 | -DPYTHONWEXECUTABLE='"$(APPINSTALLDIR)/Contents/MacOS/$(PYTHONFRAMEWORK)-64"' |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 159 | |
| 160 | install_PythonLauncher: |
| 161 | cd PythonLauncher && make install DESTDIR=$(DESTDIR) |
| 162 | |
| 163 | install_Python: |
| 164 | @if test ! -f $(DOCINDEX); then \ |
| 165 | echo WARNING: you should run Apple Help Indexing Tool on $(DOCDIR); \ |
| 166 | fi |
| 167 | @for i in "$(PYTHONAPPSDIR)" "$(APPINSTALLDIR)" "$(APPINSTALLDIR)/Contents"; do \ |
| 168 | if test ! -d "$(DESTDIR)$$i"; then \ |
| 169 | echo "Creating directory $(DESTDIR)$$i"; \ |
| 170 | $(INSTALL) -d -m $(DIRMODE) "$(DESTDIR)$$i"; \ |
| 171 | fi;\ |
| 172 | done |
| 173 | @for i in $(APPSUBDIRS); do \ |
| 174 | if test ! -d "$(DESTDIR)$(APPINSTALLDIR)/Contents/$$i"; then \ |
| 175 | echo "Creating directory $(DESTDIR)$(APPINSTALLDIR)/Contents/$$i"; \ |
| 176 | $(INSTALL) -d -m $(DIRMODE) "$(DESTDIR)$(APPINSTALLDIR)/Contents/$$i"; \ |
| 177 | else true; \ |
| 178 | fi; \ |
| 179 | done |
| 180 | @for d in . $(APPSUBDIRS); \ |
| 181 | do \ |
| 182 | a=$(APPTEMPLATE)/$$d; \ |
| 183 | if test ! -d $$a; then continue; else true; fi; \ |
| 184 | b="$(DESTDIR)$(APPINSTALLDIR)/Contents/$$d"; \ |
| 185 | for i in $$a/*; \ |
| 186 | do \ |
| 187 | case $$i in \ |
| 188 | *CVS) ;; \ |
| 189 | *.svn) ;; \ |
| 190 | *.py[co]) ;; \ |
| 191 | *.orig) ;; \ |
| 192 | *~) ;; \ |
| 193 | *idx) \ |
| 194 | echo $(CPMAC) "$$i" $$b; \ |
| 195 | $(CPMAC) "$$i" "$$b"; \ |
| 196 | ;; \ |
| 197 | *) \ |
| 198 | if test -d $$i; then continue; fi; \ |
| 199 | if test -x $$i; then \ |
| 200 | echo $(INSTALL_SCRIPT) "$$i" "$$b"; \ |
| 201 | $(INSTALL_SCRIPT) "$$i" "$$b"; \ |
| 202 | else \ |
| 203 | echo $(INSTALL_DATA) "$$i" "$$b"; \ |
| 204 | $(INSTALL_DATA) "$$i" "$$b"; \ |
| 205 | fi;; \ |
| 206 | esac; \ |
| 207 | done; \ |
| 208 | done |
Christian Heimes | 81ee3ef | 2008-05-04 22:42:01 +0000 | [diff] [blame] | 209 | $(INSTALL_PROGRAM) $(STRIPFLAG) $(BUILDPYTHON) "$(DESTDIR)$(APPINSTALLDIR)/Contents/MacOS/$(PYTHONFRAMEWORK)" |
Ronald Oussoren | f29b6b4 | 2009-03-30 20:00:00 +0000 | [diff] [blame^] | 210 | sed -e "s!%bundleid%!$(PYTHONFRAMEWORKIDENTIFIER)!g" \ |
| 211 | -e "s!%version%!`$(RUNSHARED) $(BUILDPYTHON) \ |
| 212 | -c 'import platform; print(platform.python_version())'`!g" \ |
| 213 | < "$(DESTDIR)$(APPINSTALLDIR)/Contents/Info.plist.in" \ |
| 214 | > "$(DESTDIR)$(APPINSTALLDIR)/Contents/Info.plist" |
| 215 | rm "$(DESTDIR)$(APPINSTALLDIR)/Contents/Info.plist.in" |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 216 | |
Georg Brandl | fcaf910 | 2008-07-16 02:17:56 +0000 | [diff] [blame] | 217 | install_Python4way: install_Python |
| 218 | lipo -extract i386 -extract ppc7400 -output "$(DESTDIR)$(APPINSTALLDIR)/Contents/MacOS/$(PYTHONFRAMEWORK)-32" "$(DESTDIR)$(APPINSTALLDIR)/Contents/MacOS/$(PYTHONFRAMEWORK)" |
| 219 | lipo -extract x86_64 -extract ppc64 -output "$(DESTDIR)$(APPINSTALLDIR)/Contents/MacOS/$(PYTHONFRAMEWORK)-64" "$(DESTDIR)$(APPINSTALLDIR)/Contents/MacOS/$(PYTHONFRAMEWORK)" |
| 220 | |
| 221 | |
| 222 | |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 223 | install_IDLE: |
Benjamin Peterson | de9c869 | 2008-07-01 18:23:09 +0000 | [diff] [blame] | 224 | test -d "$(DESTDIR)$(PYTHONAPPSDIR)" || mkdir -p "$(DESTDIR)$(PYTHONAPPSDIR)" |
Ronald Oussoren | 827822e | 2009-02-12 15:01:44 +0000 | [diff] [blame] | 225 | -test -d "$(DESTDIR)$(PYTHONAPPSDIR)/IDLE.app" && rm -rf "$(DESTDIR)$(PYTHONAPPSDIR)/IDLE.app" |
Ronald Oussoren | af11860 | 2009-01-02 11:48:29 +0000 | [diff] [blame] | 226 | /bin/cp -PR "$(srcdir)/IDLE/IDLE.app" "$(DESTDIR)$(PYTHONAPPSDIR)" |
Ronald Oussoren | 672f62a | 2009-02-12 15:18:15 +0000 | [diff] [blame] | 227 | ln -sf "$(INSTALLED_PYTHONAPP)" "$(DESTDIR)$(PYTHONAPPSDIR)/IDLE.app/Contents/MacOS/Python" |
Ronald Oussoren | af11860 | 2009-01-02 11:48:29 +0000 | [diff] [blame] | 228 | sed -e "s!%prefix%!$(prefix)!g" -e 's!%exe%!$(PYTHONFRAMEWORK)!g' < "$(srcdir)/IDLE/IDLE.app/Contents/MacOS/IDLE" > "$(DESTDIR)$(PYTHONAPPSDIR)/IDLE.app/Contents/MacOS/IDLE" |
Ronald Oussoren | 2160015 | 2008-12-30 12:59:02 +0000 | [diff] [blame] | 229 | sed "s!%version%!`$(RUNSHARED) $(BUILDPYTHON) -c 'import platform; print(platform.python_version())'`!g" < "$(srcdir)/IDLE/IDLE.app/Contents/Info.plist" > "$(DESTDIR)$(PYTHONAPPSDIR)/IDLE.app/Contents/Info.plist" |
Ronald Oussoren | 711b578 | 2009-02-12 15:12:03 +0000 | [diff] [blame] | 230 | if [ -f "$(DESTDIR)$(LIBDEST)/idlelib/config-main.def" ]; then \ |
| 231 | /bin/cp -p "$(DESTDIR)$(LIBDEST)/idlelib/config-main.def" \ |
| 232 | "$(DESTDIR)$(LIBDEST)/idlelib/config-main.def~" ; \ |
| 233 | sed -e 's!name= IDLE Classic Windows!name= IDLE Classic OSX!g' \ |
| 234 | < "$(DESTDIR)$(LIBDEST)/idlelib/config-main.def~" \ |
| 235 | > "$(DESTDIR)$(LIBDEST)/idlelib/config-main.def" ; \ |
| 236 | rm "$(DESTDIR)$(LIBDEST)/idlelib/config-main.def~" ; \ |
| 237 | fi |
| 238 | if [ -f "$(DESTDIR)$(LIBDEST)/idlelib/config-extensions.def" ]; then \ |
| 239 | /bin/cp -p "$(DESTDIR)$(LIBDEST)/idlelib/config-extensions.def" \ |
| 240 | "$(DESTDIR)$(LIBDEST)/idlelib/config-extensions.def~" ; \ |
| 241 | sed -e 's!zoom-height=<Alt-Key-2>!zoom-height=<Option-Key-0>!g' \ |
| 242 | -e 's!<Alt-Key-!<Option-Key-!g' \ |
| 243 | < "$(DESTDIR)$(LIBDEST)/idlelib/config-extensions.def~" \ |
| 244 | > "$(DESTDIR)$(LIBDEST)/idlelib/config-extensions.def" ; \ |
| 245 | rm "$(DESTDIR)$(LIBDEST)/idlelib/config-extensions.def~" ; \ |
| 246 | fi |
Benjamin Peterson | de9c869 | 2008-07-01 18:23:09 +0000 | [diff] [blame] | 247 | touch "$(DESTDIR)$(PYTHONAPPSDIR)/IDLE.app" |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 248 | |
Ronald Oussoren | 672f62a | 2009-02-12 15:18:15 +0000 | [diff] [blame] | 249 | install_IDLE4way: install_IDLE |
| 250 | ln -sf "$(INSTALLED_PYTHONAPP)-32" "$(DESTDIR)$(PYTHONAPPSDIR)/IDLE.app/Contents/MacOS/Python" |
| 251 | sed -e "s!%prefix%!$(prefix)!g" -e 's!%exe%!$(PYTHONFRAMEWORK)-32!g' < "$(srcdir)/IDLE/IDLE.app/Contents/MacOS/IDLE" > "$(DESTDIR)$(PYTHONAPPSDIR)/IDLE.app/Contents/MacOS/IDLE" |
| 252 | touch "$(DESTDIR)$(PYTHONAPPSDIR)/IDLE.app" |
| 253 | |
Thomas Wouters | 73e5a5b | 2006-06-08 15:35:45 +0000 | [diff] [blame] | 254 | $(INSTALLED_PYTHONAPP): install_Python |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 255 | |
Thomas Wouters | 73e5a5b | 2006-06-08 15:35:45 +0000 | [diff] [blame] | 256 | installextras: $(srcdir)/Extras.ReadMe.txt $(srcdir)/Extras.install.py |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 257 | $(INSTALL) -d "$(DESTDIR)$(PYTHONAPPSDIR)/Extras" |
Thomas Wouters | 73e5a5b | 2006-06-08 15:35:45 +0000 | [diff] [blame] | 258 | $(INSTALL) $(srcdir)/Extras.ReadMe.txt "$(DESTDIR)$(PYTHONAPPSDIR)/Extras/ReadMe.txt" |
| 259 | $(RUNSHARED) $(BUILDPYTHON) $(srcdir)/Extras.install.py $(srcdir)/../Demo \ |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 260 | "$(DESTDIR)$(PYTHONAPPSDIR)/Extras/Demo" |
Thomas Wouters | 73e5a5b | 2006-06-08 15:35:45 +0000 | [diff] [blame] | 261 | $(RUNSHARED) $(BUILDPYTHON) $(srcdir)/Extras.install.py $(srcdir)/Demo \ |
| 262 | "$(DESTDIR)$(PYTHONAPPSDIR)/Extras/Demo.Mac" |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 263 | |
| 264 | |
Thomas Wouters | 73e5a5b | 2006-06-08 15:35:45 +0000 | [diff] [blame] | 265 | checkapplepython: $(srcdir)/Tools/fixapplepython23.py |
| 266 | @if ! $(RUNSHARED) $(BUILDPYTHON) $(srcdir)/Tools/fixapplepython23.py -n; then \ |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 267 | echo "* WARNING: Apple-installed Python 2.3 will have trouble building extensions from now on."; \ |
Thomas Wouters | 73e5a5b | 2006-06-08 15:35:45 +0000 | [diff] [blame] | 268 | echo "* WARNING: Run $(srcdir)/Tools/fixapplepython23.py with \"sudo\" to fix this."; \ |
Thomas Wouters | 477c8d5 | 2006-05-27 19:21:47 +0000 | [diff] [blame] | 269 | fi |
| 270 | |
| 271 | |
| 272 | clean: |
| 273 | rm pythonw |
| 274 | cd PythonLauncher && make clean |
Thomas Wouters | 89f507f | 2006-12-13 04:49:30 +0000 | [diff] [blame] | 275 | |
| 276 | Makefile: $(srcdir)/Makefile.in ../config.status |
| 277 | cd .. && CONFIG_FILES=Mac/Makefile CONFIG_HEADERS= $(SHELL) ./config.status |