]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
If we're installing to another partition than the system partition offer to copy...
authorJack Jansen <jack.jansen@cwi.nl>
Fri, 13 Oct 2000 23:33:34 +0000 (23:33 +0000)
committerJack Jansen <jack.jansen@cwi.nl>
Fri, 13 Oct 2000 23:33:34 +0000 (23:33 +0000)
Mac/scripts/ConfigurePython.py
Mac/scripts/ConfigurePython.rsrc

index 88d66a416f6569346bcaff787bdcd3ce209cb60a..91e0af03d3cea519a451f90115bede884870cf24 100644 (file)
@@ -18,6 +18,9 @@ SPLASH_REMOVE=513
 SPLASH_CFM68K=514
 SPLASH_PPC=515
 SPLASH_NUMPY=516
+ALERT_NONBOOT=517
+ALERT_NONBOOT_COPY=1
+ALERT_NONBOOT_ALIAS=2
 
 ppc_goals = [
 ##     ("AE.ppc.slb", "toolboxmodules.ppc.slb"),
@@ -134,7 +137,19 @@ def mkcorealias(src, altsrc):
                os.unlink(dst)
        except os.error:
                pass
-       macostools.mkalias(os.path.join(sys.exec_prefix, src), dst)
+       do_copy = 0
+       if macfs.FSSpec(sys.exec_prefix).as_tuple()[0] != -1: # XXXX
+               try:
+                       import Dlg
+                       rv = Dlg.CautionAlert(ALERT_NONBOOT, None)
+                       if rv == ALERT_NONBOOT_COPY:
+                               do_copy = 1
+               except ImportError:
+                       pass
+       if do_copy:
+               macostools.copy(os.path.join(sys.exec_prefix, src), dst)
+       else:
+               macostools.mkalias(os.path.join(sys.exec_prefix, src), dst)
        if verbose:  print ' ', dst, '->', src
        return 1
        
index d55f604474df796645ffaeb30cf554c1666adaa1..2f23602ba1504c482ab2d58c2b39b40f32535377 100644 (file)
Binary files a/Mac/scripts/ConfigurePython.rsrc and b/Mac/scripts/ConfigurePython.rsrc differ