()
| 1709 | shellQuote(filePath))) |
| 1710 | |
| 1711 | def main(): |
| 1712 | # First parse options and check if we can perform our work |
| 1713 | parseOptions() |
| 1714 | checkEnvironment() |
| 1715 | |
| 1716 | os.environ['MACOSX_DEPLOYMENT_TARGET'] = DEPTARGET |
| 1717 | os.environ['CC'] = CC |
| 1718 | os.environ['CXX'] = CXX |
| 1719 | |
| 1720 | if os.path.exists(WORKDIR): |
| 1721 | shutil.rmtree(WORKDIR) |
| 1722 | os.mkdir(WORKDIR) |
| 1723 | |
| 1724 | os.environ['LC_ALL'] = 'C' |
| 1725 | |
| 1726 | # Then build third-party libraries such as sleepycat DB4. |
| 1727 | buildLibraries() |
| 1728 | |
| 1729 | # Now build python itself |
| 1730 | buildPython() |
| 1731 | |
| 1732 | # And then build the documentation |
| 1733 | # Remove the Deployment Target from the shell |
| 1734 | # environment, it's no longer needed and |
| 1735 | # an unexpected build target can cause problems |
| 1736 | # when Sphinx and its dependencies need to |
| 1737 | # be (re-)installed. |
| 1738 | del os.environ['MACOSX_DEPLOYMENT_TARGET'] |
| 1739 | buildPythonDocs() |
| 1740 | |
| 1741 | |
| 1742 | # Prepare the applications folder |
| 1743 | folder = os.path.join(WORKDIR, "_root", "Applications", "Python %s"%( |
| 1744 | getVersion(),)) |
| 1745 | fn = os.path.join(folder, "License.rtf") |
| 1746 | patchFile("resources/License.rtf", fn) |
| 1747 | fn = os.path.join(folder, "ReadMe.rtf") |
| 1748 | patchFile("resources/ReadMe.rtf", fn) |
| 1749 | fn = os.path.join(folder, "Update Shell Profile.command") |
| 1750 | patchScript("resources/update_shell_profile.command", fn) |
| 1751 | fn = os.path.join(folder, "Install Certificates.command") |
| 1752 | patchScript("resources/install_certificates.command", fn) |
| 1753 | os.chmod(folder, STAT_0o755) |
| 1754 | setIcon(folder, "../Icons/Python Folder.icns") |
| 1755 | |
| 1756 | # Create the installer |
| 1757 | buildInstaller() |
| 1758 | |
| 1759 | # And copy the readme into the directory containing the installer |
| 1760 | patchFile('resources/ReadMe.rtf', |
| 1761 | os.path.join(WORKDIR, 'installer', 'ReadMe.rtf')) |
| 1762 | |
| 1763 | # Ditto for the license file. |
| 1764 | patchFile('resources/License.rtf', |
| 1765 | os.path.join(WORKDIR, 'installer', 'License.rtf')) |
| 1766 | |
| 1767 | fp = open(os.path.join(WORKDIR, 'installer', 'Build.txt'), 'w') |
| 1768 | fp.write("# BUILD INFO\n") |
no test coverage detected
searching dependent graphs…