Migrating Python to 3.14 on macOS; Preparing for GoldenGate

This commit is contained in:
Kazunari.sekigawa 2026-07-29 07:00:28 +09:00
parent 87060b4364
commit 0e187ed957
20 changed files with 333 additions and 251 deletions

View File

@ -1,16 +1,17 @@
Relevant KLayout version: 0.30.5<br> Relevant KLayout version: 0.30.9<br>
Author: Kazzz-S<br> Author: Kazzz-S<br>
Last modified: 2025-11-10<br> Last modified: 2026-07-26<br>
# 1. Introduction # 1. Introduction
This directory **`macbuild`** contains various files required for building KLayout (http://www.klayout.de/) version 0.30.5 or later for different 64-bit macOS, including: This directory **`macbuild`** contains various files required for building KLayout (http://www.klayout.de/) version 0.30.9 or later for different 64-bit macOS, including:
* Golden Gate (27.x) : really experimental (on M4 Mac Mini)
* Tahoe (26.x) : really experimental (on M4 Mac Mini) * Tahoe (26.x) : really experimental (on M4 Mac Mini)
* Sequoia (15.x) : the primary development environment * Sequoia (15.x) : the primary development environment
* Sonoma (14.x) : experimental * Sonoma (14.x) : experimental
Building KLayout for the previous operating systems listed below has been discontinued.<br> Building KLayout for the previous operating systems listed below has been discontinued.<br>
Pre-built DMG packages are also not provided.<br> Pre-built DMG packages are also not provided.<br>
As of today (November 2025), Homebrew classifies macOS Catalina 10.15 - Ventura 13 as Tier 3. As of November 2025, Homebrew classifies macOS Catalina 10.15 - Ventura 13 as Tier 3.
* Ventura (13.7.8; the build would still be possible) * Ventura (13.7.8; the build would still be possible)
* Monterey (12.7.6; the build would still be possible) * Monterey (12.7.6; the build would still be possible)
* Big Sur (11.7.10) * Big Sur (11.7.10)
@ -47,7 +48,7 @@ Then, follow the instructions in Section 6F.
The migration work to "Qt6" is ongoing. You can try to use it; however, you might encounter some build or runtime errors.<br> The migration work to "Qt6" is ongoing. You can try to use it; however, you might encounter some build or runtime errors.<br>
If you use **Homebrew** to build KLayout >= 0.29.0, you need "Qt6" to address [the compilation issue](https://github.com/KLayout/klayout/issues/1599).<br> If you use **Homebrew** to build KLayout >= 0.29.0, you need "Qt6" to address [the compilation issue](https://github.com/KLayout/klayout/issues/1599).<br>
I have also tried migrating to "Python 3.13.x" (earlier, Python 3.12.x) in this version. I have also tried migrating to "Python 3.14.x" (earlier, Python 3.13.x) in this version.
# 3. Script language support: Ruby and Python # 3. Script language support: Ruby and Python
@ -72,7 +73,7 @@ The operating system type is detected automatically.
``` ```
----------------------------------------------------------------------------------------------------------- -----------------------------------------------------------------------------------------------------------
<< Usage of 'build4mac.py' >> << Usage of 'build4mac.py' >>
for building KLayout 0.30.5 or later on different Apple macOS platforms. for building KLayout 0.30.9 or later on different Apple macOS platforms.
$ [python] ./build4mac.py $ [python] ./build4mac.py
option & argument : descriptions (refer to 'macbuild/build4mac_env.py' for details) | default value option & argument : descriptions (refer to 'macbuild/build4mac_env.py' for details) | default value
@ -88,27 +89,27 @@ $ [python] ./build4mac.py
: (*) migration to Qt6 is ongoing | : (*) migration to Qt6 is ongoing |
[-r|--ruby <type>] : case-insensitive type=['nil', 'Sys', 'MP34', 'HB34', 'Ana3'] | sys [-r|--ruby <type>] : case-insensitive type=['nil', 'Sys', 'MP34', 'HB34', 'Ana3'] | sys
: nil: don't bind Ruby | : nil: don't bind Ruby |
: Sys: use [Tahoe|Sequoia|Sonoma]-bundled Ruby 2.6 | : Sys: use [GoldenGate|Tahoe|Sequoia|Sonoma]-bundled Ruby 2.6 |
: MP34: use Ruby 3.4 from MacPorts | : MP34: use Ruby 3.4 from MacPorts |
: HB34: use Ruby 3.4 from Homebrew | : HB34: use Ruby 3.4 from Homebrew |
: Ana3: use Ruby 3.4 from Anaconda3 | : Ana3: use Ruby 3.4 from Anaconda3 |
[-p|--python <type>] : case-insensitive type=['nil', 'Sys', 'MP313', 'HB313', 'Ana3', | sys [-p|--python <type>] : case-insensitive type=['nil', 'Sys', 'MP314', 'HB314', 'Ana3', | sys
: 'MP312', 'MP312', | : 'MP314', 'HB314', |
: 'MP311', 'HB311', 'HBAuto'] | : 'HB311', 'HBAuto'] |
: nil: don't bind Python | : nil: don't bind Python |
: Sys: use [Tahoe|Sequoia|Sonoma]-bundled Python 3.9 | : Sys: use [GoldenGate|Tahoe|Sequoia|Sonoma]-bundled Python 3.9 |
: MP313: use Python 3.13 from MacPorts | : MP314: use Python 3.14 from MacPorts |
: HB313: use Python 3.13 from Homebrew | : HB314: use Python 3.14 from Homebrew |
: Ana3: use Python 3.13 from Anaconda3 | : Ana3: use Python 3.14 from Anaconda3 |
: MP312: use Python 3.12 from MacPorts | : MP314: use Python 3.14 from MacPorts |
: HB312: use Python 3.12 from Homebrew | : HB314: use Python 3.14 from Homebrew |
: MP311: use Python 3.11 from MacPorts |
: HB311: use Python 3.11 from Homebrew (+) | : HB311: use Python 3.11 from Homebrew (+) |
: (+) required to provide the legacy pip in HW-*.dmg | : (+) required to provide the legacy pip in HW-*.dmg |
: HBAuto: use the latest Python 3.x auto-detected from Homebrew | : HBAuto: use the latest Python 3.x auto-detected from Homebrew |
[-P|--buildPymod] : build and deploy Pymod (*.whl) for LW-*.dmg | disabled [-P|--buildPymod] : build and deploy Pymod (*.whl) for LW-*.dmg | disabled
[-n|--noqtbinding] : don't create Qt bindings for ruby scripts | disabled [-n|--noqtbinding] : don't create Qt bindings for ruby scripts | disabled
[-u|--noqtuitools] : don't include uitools in Qt binding | disabled [-u|--noqtuitools] : don't include uitools in Qt binding | disabled
[-s|--no32bitcoord] : don't use short (32bit) coordinates; use long (64bit) instead | disabled
[-g|--nolibgit2] : don't include libgit2 for Git package support | disabled [-g|--nolibgit2] : don't include libgit2 for Git package support | disabled
[-m|--make <option>] : option passed to 'make' | '--jobs=4' [-m|--make <option>] : option passed to 'make' | '--jobs=4'
[-d|--debug] : enable debug mode build; AddressSanitizer (ASAN) is linked | disabled [-d|--debug] : enable debug mode build; AddressSanitizer (ASAN) is linked | disabled
@ -160,27 +161,28 @@ $ ./build4mac.py -q qt5macports -r sys -p sys
$ ./build4mac.py -q qt5macports -r sys -p sys -y $ ./build4mac.py -q qt5macports -r sys -p sys -y
``` ```
The application bundle **`klayout.app`** is located under:<br> The application bundle **`klayout.app`** is located under:<br>
**`ST-qt5MP.pkg.macos-Sequoia-release-RsysPsys`** directory, where **`ST-qt5MP.pkg.macos-Sequoia-C32-release-RsysPsys`** directory, where
* "ST-" means this is a standard package. * "ST-" means this is a standard package.
* "qt5MP" means that Qt5 from MacPorts is used. * "qt5MP" means that Qt5 from MacPorts is used.
* "C32" means that the coordinate representation is a 32-bit integer (C64, for 64-bit).
* "RsysPsys" means that Ruby is 2.6 provided by OS; Python is 3.9 provided by OS. * "RsysPsys" means that Ruby is 2.6 provided by OS; Python is 3.9 provided by OS.
4. Copy/move the generated application bundle **`klayout.app`** to your **`/Applications`** directory for installation. 4. Copy/move the generated application bundle **`klayout.app`** to your **`/Applications`** directory for installation.
### 6B. Fully MacPorts-flavored build with MacPorts Ruby 3.4 and MacPorts Python 3.13 ### 6B. Fully MacPorts-flavored build with MacPorts Ruby 3.4 and MacPorts Python 3.14
0. Install MacPorts, then install Qt5, Ruby 3.4, Python 3.13, and libgit2 by 0. Install MacPorts, then install Qt5, Ruby 3.4, Python 3.14, and libgit2 by
``` ```
$ sudo port install coreutils $ sudo port install coreutils
$ sudo port install findutils $ sudo port install findutils
$ sudo port install qt5 $ sudo port install qt5
$ sudo port install ruby34 $ sudo port install ruby34
$ sudo port install python313 $ sudo port install python314
$ sudo port install py313-pip $ sudo port install py314-pip
$ sudo port install libgit2 $ sudo port install libgit2
``` ```
1. Invoke **`build4mac.py`** with the following options: 1. Invoke **`build4mac.py`** with the following options:
``` ```
$ cd /where/'build.sh'/exists $ cd /where/'build.sh'/exists
$ ./build4mac.py -q qt5macports -r mp34 -p mp313 $ ./build4mac.py -q qt5macports -r mp34 -p mp314
``` ```
2. Confirm successful build (it will take about one hour, depending on your machine spec). 2. Confirm successful build (it will take about one hour, depending on your machine spec).
3. Rerun **`build4mac.py`** with the same options used in 1. PLUS "-Y" to deploy executables and libraries under **`klayout.app`** bundle.<br> 3. Rerun **`build4mac.py`** with the same options used in 1. PLUS "-Y" to deploy executables and libraries under **`klayout.app`** bundle.<br>
@ -188,50 +190,52 @@ $ ./build4mac.py -q qt5macports -r mp34 -p mp313
If you use `--buildPymod` option in Step-1 and Step-3, the KLayout Standalone Python Package (\*.whl) will be built and deployed under **klayout.app/Contents/pymod-dist/**. If you use `--buildPymod` option in Step-1 and Step-3, the KLayout Standalone Python Package (\*.whl) will be built and deployed under **klayout.app/Contents/pymod-dist/**.
``` ```
$ ./build4mac.py -q qt5macports -r mp34 -p mp313 -Y $ ./build4mac.py -q qt5macports -r mp34 -p mp314 -Y
``` ```
The application bundle **`klayout.app`** is located under:<br> The application bundle **`klayout.app`** is located under:<br>
**`LW-qt5MP.pkg.macos-Sequoia-release-Rmp34Pmp313`** directory, where **`LW-qt5MP.pkg.macos-Sequoia-C32-release-Rmp34Pmp314`** directory, where
* "LW-" means this is a lightweight package. * "LW-" means this is a lightweight package.
* "qt5MP" means that Qt5 from MacPorts is used. * "qt5MP" means that Qt5 from MacPorts is used.
* "Rmp34Pmp313" means that Ruby is 3.4 from MacPorts; Python is 3.13 from MacPorts. * "C32" means that the coordinate representation is a 32-bit integer (C64, for 64-bit).
* "Rmp34Pmp314" means that Ruby is 3.4 from MacPorts; Python is 3.14 from MacPorts.
4. Copy/move the generated application bundle **`klayout.app`** to your **`/Applications`** directory for installation. 4. Copy/move the generated application bundle **`klayout.app`** to your **`/Applications`** directory for installation.
### 6C. Fully Homebrew-flavored build with Homebrew Ruby 3.4 and Homebrew Python 3.13 ### 6C. Fully Homebrew-flavored build with Homebrew Ruby 3.4 and Homebrew Python 3.14
> [!IMPORTANT] > [!IMPORTANT]
> To build KLayout >= 0.29.0, you need "Qt6" >= 6.7.0 to address [the compilation issue](https://github.com/KLayout/klayout/issues/1599).<br> > To build KLayout >= 0.29.0, you need "Qt6" >= 6.7.0 to address [the compilation issue](https://github.com/KLayout/klayout/issues/1599).<br>
0. Install Homebrew, then install Qt6, Ruby 3.4, Python 3.13, and libgit2 by 0. Install Homebrew, then install Qt6, Ruby 3.4, Python 3.14, and libgit2 by
``` ```
$ brew install qt@6 $ brew install qt@6
$ brew install ruby@3.4 $ brew install ruby@3.4
$ brew install python@3.13 $ brew install python@3.14
$ brew install libgit2 $ brew install libgit2
$ cd /where/'build.sh'/exists $ cd /where/'build.sh'/exists
$ cd macbuild $ cd macbuild
$ ./python3HB.py -v 3.13 $ ./python3HB.py -v 3.14
``` ```
1. Invoke **`build4mac.py`** with the following options: 1. Invoke **`build4mac.py`** with the following options:
``` ```
$ cd /where/'build.sh'/exists $ cd /where/'build.sh'/exists
$ ./build4mac.py -q qt6brew -r hb34 -p hb313 $ ./build4mac.py -q qt6brew -r hb34 -p hb314
``` ```
2. Confirm successful build (it will take about one hour, depending on your machine spec). 2. Confirm successful build (it will take about one hour, depending on your machine spec).
3. Rerun **`build4mac.py`** with the same options used in 1. PLUS "-Y" to deploy executables and libraries under **`klayout.app`** bundle.<br> 3. Rerun **`build4mac.py`** with the same options used in 1. PLUS "-Y" to deploy executables and libraries under **`klayout.app`** bundle.<br>
The buddy command-line tools (strm*) will also be deployed under **klayout.app/Contents/Buddy/** in this step.<br> The buddy command-line tools (strm*) will also be deployed under **klayout.app/Contents/Buddy/** in this step.<br>
``` ```
$ ./build4mac.py -q qt6brew -r hb34 -p hb313 -Y $ ./build4mac.py -q qt6brew -r hb34 -p hb314 -Y
``` ```
The application bundle **`klayout.app`** is located under:<br> The application bundle **`klayout.app`** is located under:<br>
**`LW-qt6Brew.pkg.macos-Sequoia-release-Rhb34Phb313`** directory, where **`LW-qt6Brew.pkg.macos-Sequoia-C32-release-Rhb34Phb314`** directory, where
* "LW-" means this is a lightweight package. * "LW-" means this is a lightweight package.
* "qt6Brew" means that Qt6 from Homebrew is used. * "qt6Brew" means that Qt6 from Homebrew is used.
* "Rhb34Phb313" means that Ruby is 3.4 from Homebrew; Python is 3.13 from Homebrew. * "C32" means that the coordinate representation is a 32-bit integer (C64, for 64-bit).
* "Rhb34Phb314" means that Ruby is 3.4 from Homebrew; Python is 3.14 from Homebrew.
4. Copy/move the generated application bundle **`klayout.app`** to your **`/Applications`** directory for installation. 4. Copy/move the generated application bundle **`klayout.app`** to your **`/Applications`** directory for installation.
> [!WARNING] > [!WARNING]
> We can no longer use the legacy **pip** command with Homebew Python@3.13, and we will get, > We can no longer use the legacy **pip** command with Homebew Python@3.12-, and we will get,
> ``` > ```
> error: externally-managed-environment > error: externally-managed-environment
> ``` > ```
@ -264,9 +268,10 @@ $ ./build4mac.py -q qt6brew -r sys -p hb311
$ ./build4mac.py -q qt6brew -r sys -p hb311 -y $ ./build4mac.py -q qt6brew -r sys -p hb311 -y
``` ```
The application bundle **`klayout.app`** is located under:<br> The application bundle **`klayout.app`** is located under:<br>
**`HW-qt6Brew.pkg.macos-Sequoia-release-RsysPhb311`** directory, where **`HW-qt6Brew.pkg.macos-Sequoia-C32-release-RsysPhb311`** directory, where
* "HW-" means this is a heavyweight package because both Qt6 and Python Frameworks are deployed. * "HW-" means this is a heavyweight package because both Qt6 and Python Frameworks are deployed.
* "qt6Brew" means that Qt6 from Homebrew is used. * "qt6Brew" means that Qt6 from Homebrew is used.
* "C32" means that the coordinate representation is a 32-bit integer (C64, for 64-bit).
* "RsysPhb311" means that Ruby is OS-bundled; Python is 3.11 from Homebrew. * "RsysPhb311" means that Ruby is OS-bundled; Python is 3.11 from Homebrew.
4. Copy/move the generated application bundle **`klayout.app`** to your **`/Applications`** directory for installation. 4. Copy/move the generated application bundle **`klayout.app`** to your **`/Applications`** directory for installation.
> [!IMPORTANT] > [!IMPORTANT]
@ -306,9 +311,10 @@ $ ./build4mac.py -q qt5macports -r sys -p hb311
$ ./build4mac.py -q qt5macports -r sys -p hb311 -y $ ./build4mac.py -q qt5macports -r sys -p hb311 -y
``` ```
The application bundle **`klayout.app`** is located under:<br> The application bundle **`klayout.app`** is located under:<br>
**`HW-qt5MP.pkg.macos-Sequoia-release-RsysPhb311`** directory, where **`HW-qt5MP.pkg.macos-Sequoia-C32-release-RsysPhb311`** directory, where
* "HW-" means this is a heavyweight package because both Qt5 and Python Frameworks are deployed. * "HW-" means this is a heavyweight package because both Qt5 and Python Frameworks are deployed.
* "qt5MP" means that Qt5 from MacPorts is used. * "qt5MP" means that Qt5 from MacPorts is used.
* "C32" means that the coordinate representation is a 32-bit integer (C64, for 64-bit).
* "RsysPhb311" means that Ruby is OS-bundled; Python is 3.11 from Homebrew. * "RsysPhb311" means that Ruby is OS-bundled; Python is 3.11 from Homebrew.
4. Copy/move the generated application bundle **`klayout.app`** to your **`/Applications`** directory for installation. 4. Copy/move the generated application bundle **`klayout.app`** to your **`/Applications`** directory for installation.
@ -355,9 +361,10 @@ $ ./build4mac.py -q qt6ana3 -r ana3 -p ana3
$ ./build4mac.py -q qt6ana3 -r ana3 -p ana3 -Y $ ./build4mac.py -q qt6ana3 -r ana3 -p ana3 -Y
``` ```
The application bundle **`klayout.app`** is located under:<br> The application bundle **`klayout.app`** is located under:<br>
**`LW-qt6Ana3.pkg.macos-Sequoia-release-Rana3Pana3`** directory, where **`LW-qt6Ana3.pkg.macos-Sequoia-C32-release-Rana3Pana3`** directory, where
* "LW-" means this is a lightweight package. * "LW-" means this is a lightweight package.
* "qt6Ana3" means that Qt6 from Anaconda3 is used. * "qt6Ana3" means that Qt6 from Anaconda3 is used.
* "C32" means that the coordinate representation is a 32-bit integer (C64, for 64-bit).
* "Rana3Pana3" means that Ruby (3.4) is from Anaconda3; Python (3.13) is from Anaconda3. * "Rana3Pana3" means that Ruby (3.4) is from Anaconda3; Python (3.13) is from Anaconda3.
4. Copy/move the generated application bundle **`klayout.app`** to your **`/Applications`** directory for installation. 4. Copy/move the generated application bundle **`klayout.app`** to your **`/Applications`** directory for installation.
5. Now, you need to create an Automator wrapper app (Launcher) to start the application. 5. Now, you need to create an Automator wrapper app (Launcher) to start the application.
@ -420,11 +427,11 @@ makeDMG4mac.py -> macbuild/makeDMG4mac.py
2. Invoke **`makeDMG4mac.py`** with -p and -m options, for example, 2. Invoke **`makeDMG4mac.py`** with -p and -m options, for example,
``` ```
$ cd /where/'build.sh'/exists $ cd /where/'build.sh'/exists
$ ./makeDMG4mac.py -p LW-qt5MP.pkg.macos-Sequoia-release-Rmp34Pmp313 -m $ ./makeDMG4mac.py -p LW-qt5MP.pkg.macos-Sequoia-C32-release-Rmp34Pmp314 -m
``` ```
This command will generate the two files below:<br> This command will generate the two files below:<br>
* **`LW-klayout-0.30.5-macOS-Sequoia-1-qt5MP-Rmp34Pmp313.dmg`** ---(1) the main DMG file * **`LW-klayout-0.30.9-macOS-Sequoia-C32-1-qt5MP-Rmp34Pmp314.dmg`** ---(1) the main DMG file
* **`LW-klayout-0.30.5-macOS-Sequoia-1-qt5MP-Rmp34Pmp313.dmg.md5`** ---(2) MD5-value text file * **`LW-klayout-0.30.9-macOS-Sequoia-C32-1-qt5MP-Rmp34Pmp314.dmg.md5`** ---(2) MD5-value text file
# Known issues # Known issues
Because we assume some specific versions of non-OS-standard Ruby and Python, updating Homebrew, MacPorts, or Anaconda3 may cause build- and link errors.<br> Because we assume some specific versions of non-OS-standard Ruby and Python, updating Homebrew, MacPorts, or Anaconda3 may cause build- and link errors.<br>

Binary file not shown.

Before

Width:  |  Height:  |  Size: 210 KiB

After

Width:  |  Height:  |  Size: 214 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 210 KiB

After

Width:  |  Height:  |  Size: 214 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 209 KiB

After

Width:  |  Height:  |  Size: 212 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 209 KiB

After

Width:  |  Height:  |  Size: 212 KiB

View File

@ -5,7 +5,7 @@
# File: "macbuild/build4mac.py" # File: "macbuild/build4mac.py"
# #
# The top Python script for building KLayout (http://www.klayout.de/index.php). # The top Python script for building KLayout (http://www.klayout.de/index.php).
# version 0.30.5 or later on different Apple Mac OSX platforms. # version 0.30.9 or later on different Apple Mac OSX platforms.
#=============================================================================== #===============================================================================
import sys import sys
import os import os
@ -36,7 +36,7 @@ from bundle_qtconf import generate_qtconf, QtConfError
# @return (usage, moduleset)-tuple # @return (usage, moduleset)-tuple
#------------------------------------------------------------------------------- #-------------------------------------------------------------------------------
def GenerateUsage(platform): def GenerateUsage(platform):
if platform.upper() in [ "TAHOE", "SEQUOIA", "SONOMA", "VENTURA", "MONTEREY" ]: # with Xcode [13.1 .. ] if platform.upper() in [ "GOLDENGATE", "TAHOE", "SEQUOIA", "SONOMA", "VENTURA", "MONTEREY" ]: # with Xcode [13.1 .. ]
myQt56 = "qt5macports" myQt56 = "qt5macports"
myRuby = "sys" myRuby = "sys"
myPython = "sys" myPython = "sys"
@ -47,7 +47,7 @@ def GenerateUsage(platform):
usage = "\n" usage = "\n"
usage += "-----------------------------------------------------------------------------------------------------------\n" usage += "-----------------------------------------------------------------------------------------------------------\n"
usage += "<< Usage of 'build4mac.py' >>\n" usage += "<< Usage of 'build4mac.py' >>\n"
usage += " for building KLayout 0.30.5 or later on different Apple macOS platforms.\n" usage += " for building KLayout 0.30.9 or later on different Apple macOS platforms.\n"
usage += "\n" usage += "\n"
usage += "$ [python] ./build4mac.py\n" usage += "$ [python] ./build4mac.py\n"
usage += " option & argument : descriptions (refer to 'macbuild/build4mac_env.py' for details) | default value\n" usage += " option & argument : descriptions (refer to 'macbuild/build4mac_env.py' for details) | default value\n"
@ -63,27 +63,27 @@ def GenerateUsage(platform):
usage += " : (*) migration to Qt6 is ongoing |\n" usage += " : (*) migration to Qt6 is ongoing |\n"
usage += " [-r|--ruby <type>] : case-insensitive type=['nil', 'Sys', 'MP34', 'HB34', 'Ana3'] | %s\n" % myRuby usage += " [-r|--ruby <type>] : case-insensitive type=['nil', 'Sys', 'MP34', 'HB34', 'Ana3'] | %s\n" % myRuby
usage += " : nil: don't bind Ruby |\n" usage += " : nil: don't bind Ruby |\n"
usage += " : Sys: use [Tahoe|Sequoia|Sonoma]-bundled Ruby 2.6 |\n" usage += " : Sys: use [GoldenGate|Tahoe|Sequoia|Sonoma]-bundled Ruby 2.6 |\n"
usage += " : MP34: use Ruby 3.4 from MacPorts |\n" usage += " : MP34: use Ruby 3.4 from MacPorts |\n"
usage += " : HB34: use Ruby 3.4 from Homebrew |\n" usage += " : HB34: use Ruby 3.4 from Homebrew |\n"
usage += " : Ana3: use Ruby 3.4 from Anaconda3 |\n" usage += " : Ana3: use Ruby 3.4 from Anaconda3 |\n"
usage += " [-p|--python <type>] : case-insensitive type=['nil', 'Sys', 'MP313', 'HB313', 'Ana3', | %s\n" % myPython usage += " [-p|--python <type>] : case-insensitive type=['nil', 'Sys', 'MP314', 'HB314', 'Ana3', | %s\n" % myPython
usage += " : 'MP312', 'MP312', |\n" usage += " : 'MP313', 'HB313', |\n"
usage += " : 'MP311', 'HB311', 'HBAuto'] |\n" usage += " : 'HB311', 'HBAuto'] |\n"
usage += " : nil: don't bind Python |\n" usage += " : nil: don't bind Python |\n"
usage += " : Sys: use [Tahoe|Sequoia|Sonoma]-bundled Python 3.9 |\n" usage += " : Sys: use [GoldenGate|Tahoe|Sequoia|Sonoma]-bundled Python 3.9 |\n"
usage += " : MP314: use Python 3.14 from MacPorts |\n"
usage += " : HB314: use Python 3.14 from Homebrew |\n"
usage += " : Ana3: use Python 3.13 from Anaconda3 |\n"
usage += " : MP313: use Python 3.13 from MacPorts |\n" usage += " : MP313: use Python 3.13 from MacPorts |\n"
usage += " : HB313: use Python 3.13 from Homebrew |\n" usage += " : HB313: use Python 3.13 from Homebrew |\n"
usage += " : Ana3: use Python 3.13 from Anaconda3 |\n"
usage += " : MP312: use Python 3.12 from MacPorts |\n"
usage += " : HB312: use Python 3.12 from Homebrew |\n"
usage += " : MP311: use Python 3.11 from MacPorts |\n"
usage += " : HB311: use Python 3.11 from Homebrew (+) |\n" usage += " : HB311: use Python 3.11 from Homebrew (+) |\n"
usage += " : (+) required to provide the legacy pip in HW-*.dmg |\n" usage += " : (+) required to provide the legacy pip in HW-*.dmg |\n"
usage += " : HBAuto: use the latest Python 3.x auto-detected from Homebrew |\n" usage += " : HBAuto: use the latest Python 3.x auto-detected from Homebrew |\n"
usage += " [-P|--buildPymod] : build and deploy Pymod (*.whl) for LW-*.dmg | disabled\n" usage += " [-P|--buildPymod] : build and deploy Pymod (*.whl) for LW-*.dmg | disabled\n"
usage += " [-n|--noqtbinding] : don't create Qt bindings for ruby scripts | disabled\n" usage += " [-n|--noqtbinding] : don't create Qt bindings for ruby scripts | disabled\n"
usage += " [-u|--noqtuitools] : don't include uitools in Qt binding | disabled\n" usage += " [-u|--noqtuitools] : don't include uitools in Qt binding | disabled\n"
usage += " [-s|--no32bitcoord] : don't use short (32bit) coordinates; use long (64bit) instead | disabled\n"
usage += " [-g|--nolibgit2] : don't include libgit2 for Git package support | disabled\n" usage += " [-g|--nolibgit2] : don't include libgit2 for Git package support | disabled\n"
usage += " [-m|--make <option>] : option passed to 'make' | '--jobs=4'\n" usage += " [-m|--make <option>] : option passed to 'make' | '--jobs=4'\n"
usage += " [-d|--debug] : enable debug mode build; AddressSanitizer (ASAN) is linked | disabled\n" usage += " [-d|--debug] : enable debug mode build; AddressSanitizer (ASAN) is linked | disabled\n"
@ -123,7 +123,9 @@ def Get_Default_Config():
# Dropped [ElCapitan - BigSur] (2023-10-24). # Dropped [ElCapitan - BigSur] (2023-10-24).
# See 415b5aa2efca04928f1148a69e77efd5d76f8c1d for the previous states. # See 415b5aa2efca04928f1148a69e77efd5d76f8c1d for the previous states.
#---------------------------------------------------------------------------- #----------------------------------------------------------------------------
if release == 25: if release == 27:
Platform = "GoldenGate"
elif release == 25:
Platform = "Tahoe" Platform = "Tahoe"
elif release == 24: elif release == 24:
Platform = "Sequoia" Platform = "Sequoia"
@ -142,7 +144,7 @@ def Get_Default_Config():
if not Machine == "x86_64": if not Machine == "x86_64":
# with an Apple Silicon Chip? # with an Apple Silicon Chip?
if Machine == "arm64" and Platform in ["Tahoe", "Sequoia", "Sonoma", "Ventura", "Monterey"]: if Machine == "arm64" and Platform in ["GoldenGate", "Tahoe", "Sequoia", "Sonoma", "Ventura", "Monterey"]:
print("") print("")
print( "### Your Mac equips an Apple Silicon Chip ###" ) print( "### Your Mac equips an Apple Silicon Chip ###" )
print( " Setting QMAKE_APPLE_DEVICE_ARCHS=arm64\n") print( " Setting QMAKE_APPLE_DEVICE_ARCHS=arm64\n")
@ -160,7 +162,11 @@ def Get_Default_Config():
ToolDebug = list() ToolDebug = list()
# Set the default modules # Set the default modules
if Platform == "Tahoe": if Platform == "GoldenGate":
ModuleQt = "Qt5MacPorts"
ModuleRuby = "Sys"
ModulePython = "Sys"
elif Platform == "Tahoe":
ModuleQt = "Qt5MacPorts" ModuleQt = "Qt5MacPorts"
ModuleRuby = "Sys" ModuleRuby = "Sys"
ModulePython = "Sys" ModulePython = "Sys"
@ -189,6 +195,7 @@ def Get_Default_Config():
NonOSStdLang = False NonOSStdLang = False
NoQtBindings = False NoQtBindings = False
NoQtUiTools = False NoQtUiTools = False
No32bitCoord = False
NoLibGit2 = False NoLibGit2 = False
MakeOptions = "--jobs=4" MakeOptions = "--jobs=4"
DebugMode = False DebugMode = False
@ -214,6 +221,7 @@ def Get_Default_Config():
config['NonOSStdLang'] = NonOSStdLang # True if non-OS-standard language is chosen config['NonOSStdLang'] = NonOSStdLang # True if non-OS-standard language is chosen
config['NoQtBindings'] = NoQtBindings # True if not creating Qt bindings for Ruby scripts config['NoQtBindings'] = NoQtBindings # True if not creating Qt bindings for Ruby scripts
config['NoQtUiTools'] = NoQtUiTools # True if not to include QtUiTools in Qt binding config['NoQtUiTools'] = NoQtUiTools # True if not to include QtUiTools in Qt binding
config['No32bitCoord'] = No32bitCoord # True if not use the short (32bit) coordinate
config['NoLibGit2'] = NoLibGit2 # True if not to include libgit2 for Git package support config['NoLibGit2'] = NoLibGit2 # True if not to include libgit2 for Git package support
config['MakeOptions'] = MakeOptions # options passed to `make` config['MakeOptions'] = MakeOptions # options passed to `make`
config['DebugMode'] = DebugMode # True if debug mode build config['DebugMode'] = DebugMode # True if debug mode build
@ -259,6 +267,7 @@ def Parse_CLI_Args(config):
NonOSStdLang = config['NonOSStdLang'] NonOSStdLang = config['NonOSStdLang']
NoQtBindings = config['NoQtBindings'] NoQtBindings = config['NoQtBindings']
NoQtUiTools = config['NoQtUiTools'] NoQtUiTools = config['NoQtUiTools']
No32bitCoord = config['No32bitCoord']
NoLibGit2 = config['NoLibGit2'] NoLibGit2 = config['NoLibGit2']
MakeOptions = config['MakeOptions'] MakeOptions = config['MakeOptions']
DebugMode = config['DebugMode'] DebugMode = config['DebugMode']
@ -287,7 +296,7 @@ def Parse_CLI_Args(config):
p.add_option( '-p', '--python', p.add_option( '-p', '--python',
dest='type_python', dest='type_python',
help="Python type=['nil', 'Sys', 'MP313', 'HB313', 'Ana3', 'MP312', 'HB312', 'MP311', 'HB311', 'HBAuto']" ) help="Python type=['nil', 'Sys', 'MP314', 'HB314', 'Ana3', 'MP313', 'HB313', 'HB311', 'HBAuto']" )
p.add_option( '-P', '--buildPymod', p.add_option( '-P', '--buildPymod',
action='store_true', action='store_true',
@ -307,6 +316,12 @@ def Parse_CLI_Args(config):
default=False, default=False,
help="don't include uitools in Qt binding" ) help="don't include uitools in Qt binding" )
p.add_option( '-s', '--no32bitcoord',
action='store_true',
dest='no_32_bitcoord',
default=False,
help="don't use short (32bit) coordinates; use long (64bit) instead " )
p.add_option( '-g', '--nolibgit2', p.add_option( '-g', '--nolibgit2',
action='store_true', action='store_true',
dest='no_libgit2', dest='no_libgit2',
@ -356,13 +371,14 @@ def Parse_CLI_Args(config):
default=False, default=False,
help='check usage' ) help='check usage' )
if Platform.upper() in [ "TAHOE", "SEQUOIA", "SONOMA", "VENTURA", "MONTEREY" ]: # with Xcode [13.1 .. ] if Platform.upper() in [ "GOLDENGATE", "TAHOE", "SEQUOIA", "SONOMA", "VENTURA", "MONTEREY" ]: # with Xcode [13.1 .. ]
p.set_defaults( type_qt = "qt5macports", p.set_defaults( type_qt = "qt5macports",
type_ruby = "sys", type_ruby = "sys",
type_python = "sys", type_python = "sys",
build_pymod_whl = False, build_pymod_whl = False,
no_qt_binding = False, no_qt_binding = False,
no_qt_uitools = False, no_qt_uitools = False,
no_32_bitcoord = False,
no_libgit2 = False, no_libgit2 = False,
make_option = "--jobs=4", make_option = "--jobs=4",
debug_build = False, debug_build = False,
@ -432,7 +448,9 @@ def Parse_CLI_Args(config):
if choiceRuby == "nil": if choiceRuby == "nil":
ModuleRuby = 'nil' ModuleRuby = 'nil'
elif choiceRuby == "Sys": elif choiceRuby == "Sys":
if Platform == "Tahoe": if Platform == "GoldenGate":
ModuleRuby = 'RubyGoldenGate'
elif Platform == "Tahoe":
ModuleRuby = 'RubyTahoe' ModuleRuby = 'RubyTahoe'
elif Platform == "Sequoia": elif Platform == "Sequoia":
ModuleRuby = 'RubySequoia' ModuleRuby = 'RubySequoia'
@ -465,12 +483,11 @@ def Parse_CLI_Args(config):
candidates = dict() candidates = dict()
candidates['NIL'] = 'nil' candidates['NIL'] = 'nil'
candidates['SYS'] = 'Sys' candidates['SYS'] = 'Sys'
candidates['MP314'] = 'MP314'
candidates['HB314'] = 'HB314'
candidates['ANA3'] = 'Ana3'
candidates['MP313'] = 'MP313' candidates['MP313'] = 'MP313'
candidates['HB313'] = 'HB313' candidates['HB313'] = 'HB313'
candidates['ANA3'] = 'Ana3'
candidates['MP312'] = 'MP312'
candidates['HB312'] = 'HB312'
candidates['MP311'] = 'MP311'
candidates['HB311'] = 'HB311' candidates['HB311'] = 'HB311'
candidates['HBAUTO'] = 'HBAuto' candidates['HBAUTO'] = 'HBAuto'
try: try:
@ -484,7 +501,10 @@ def Parse_CLI_Args(config):
ModulePython = 'nil' ModulePython = 'nil'
OSPython3FW = None OSPython3FW = None
elif choicePython == "Sys": elif choicePython == "Sys":
if Platform == "Tahoe": if Platform == "GoldenGate":
ModulePython = 'PythonGoldenGate'
OSPython3FW = GoldenGatePy3FW
elif Platform == "Tahoe":
ModulePython = 'PythonTahoe' ModulePython = 'PythonTahoe'
OSPython3FW = TahoePy3FW OSPython3FW = TahoePy3FW
elif Platform == "Sequoia": elif Platform == "Sequoia":
@ -499,12 +519,12 @@ def Parse_CLI_Args(config):
elif Platform == "Monterey": elif Platform == "Monterey":
ModulePython = 'PythonMonterey' ModulePython = 'PythonMonterey'
OSPython3FW = MontereyPy3FW OSPython3FW = MontereyPy3FW
elif choicePython == "MP313": elif choicePython == "MP314":
ModulePython = 'Python313MacPorts' ModulePython = 'Python314MacPorts'
OSPython3FW = None OSPython3FW = None
NonOSStdLang = True NonOSStdLang = True
elif choicePython == "HB313": elif choicePython == "HB314":
ModulePython = 'Python313Brew' ModulePython = 'Python314Brew'
OSPython3FW = None OSPython3FW = None
NonOSStdLang = True NonOSStdLang = True
elif choicePython == "Ana3": elif choicePython == "Ana3":
@ -514,12 +534,12 @@ def Parse_CLI_Args(config):
ModulePython = 'PythonAnaconda3V6' ModulePython = 'PythonAnaconda3V6'
OSPython3FW = None OSPython3FW = None
NonOSStdLang = True NonOSStdLang = True
elif choicePython == "MP312": elif choicePython == "MP313":
ModulePython = 'Python312MacPorts' ModulePython = 'Python313MacPorts'
OSPython3FW = None OSPython3FW = None
NonOSStdLang = True NonOSStdLang = True
elif choicePython == "HB312": elif choicePython == "HB313":
ModulePython = 'Python312Brew' ModulePython = 'Python313Brew'
OSPython3FW = None OSPython3FW = None
NonOSStdLang = True NonOSStdLang = True
elif choicePython == "HB311": elif choicePython == "HB311":
@ -544,6 +564,7 @@ def Parse_CLI_Args(config):
BuildPymodWhl = opt.build_pymod_whl BuildPymodWhl = opt.build_pymod_whl
NoQtBindings = opt.no_qt_binding NoQtBindings = opt.no_qt_binding
NoQtUiTools = opt.no_qt_uitools NoQtUiTools = opt.no_qt_uitools
No32bitCoord = opt.no_32_bitcoord
NoLibGit2 = opt.no_libgit2 NoLibGit2 = opt.no_libgit2
MakeOptions = opt.make_option MakeOptions = opt.make_option
DebugMode = opt.debug_build DebugMode = opt.debug_build
@ -630,6 +651,7 @@ def Parse_CLI_Args(config):
config['NonOSStdLang'] = NonOSStdLang config['NonOSStdLang'] = NonOSStdLang
config['NoQtBindings'] = NoQtBindings config['NoQtBindings'] = NoQtBindings
config['NoQtUiTools'] = NoQtUiTools config['NoQtUiTools'] = NoQtUiTools
config['No32bitCoord'] = No32bitCoord
config['NoLibGit2'] = NoLibGit2 config['NoLibGit2'] = NoLibGit2
config['MakeOptions'] = MakeOptions config['MakeOptions'] = MakeOptions
config['DebugMode'] = DebugMode config['DebugMode'] = DebugMode
@ -674,6 +696,7 @@ def Get_Build_Parameters(config):
ModuleSet = config['ModuleSet'] ModuleSet = config['ModuleSet']
NoQtBindings = config['NoQtBindings'] NoQtBindings = config['NoQtBindings']
NoQtUiTools = config['NoQtUiTools'] NoQtUiTools = config['NoQtUiTools']
No32bitCoord = config['No32bitCoord']
NoLibGit2 = config['NoLibGit2'] NoLibGit2 = config['NoLibGit2']
MakeOptions = config['MakeOptions'] MakeOptions = config['MakeOptions']
DebugMode = config['DebugMode'] DebugMode = config['DebugMode']
@ -701,34 +724,46 @@ def Get_Build_Parameters(config):
(qt, ruby, python) = ModuleSet # ( 'qt6Brew', 'Sys', 'Sys' ) (qt, ruby, python) = ModuleSet # ( 'qt6Brew', 'Sys', 'Sys' )
ruby_python = "R%sP%s" % ( ruby.lower(), python.lower() ) ruby_python = "R%sP%s" % ( ruby.lower(), python.lower() )
# (C) Target directories and files # (C) Coordinate size
MacPkgDir = "%s%s.pkg.macos-%s-%s-%s" % (PackagePrefix, qt, Platform, mode, ruby_python) if No32bitCoord:
MacBinDir = "%s.bin.macos-%s-%s-%s" % ( qt, Platform, mode, ruby_python) coordSize = "C64"
MacBuildDir = "%s.build.macos-%s-%s-%s" % ( qt, Platform, mode, ruby_python) else:
MacBuildLog = "%s.build.macos-%s-%s-%s.log" % ( qt, Platform, mode, ruby_python) coordSize = "C32"
# (D) Target directories and files
MacPkgDir = "%s%s.pkg.macos-%s-%s-%s-%s" % (PackagePrefix, qt, Platform, coordSize, mode, ruby_python)
MacBinDir = "%s.bin.macos-%s-%s-%s-%s" % ( qt, Platform, coordSize, mode, ruby_python)
MacBuildDir = "%s.build.macos-%s-%s-%s-%s" % ( qt, Platform, coordSize, mode, ruby_python)
MacBuildLog = "%s.build.macos-%s-%s-%s-%s.log" % ( qt, Platform, coordSize, mode, ruby_python)
MacBuildDirQAT = MacBuildDir + ".macQAT" MacBuildDirQAT = MacBuildDir + ".macQAT"
parameters['bin'] = MacBinDir parameters['bin'] = MacBinDir
parameters['build'] = MacBuildDir parameters['build'] = MacBuildDir
parameters['logfile'] = MacBuildLog parameters['logfile'] = MacBuildLog
# (D) about Qt[5|6] # (E) about Qt[5|6]
parameters['qmake'] = Qt56Dictionary[ModuleQt]['qmake'] parameters['qmake'] = Qt56Dictionary[ModuleQt]['qmake']
parameters['deploy_tool'] = Qt56Dictionary[ModuleQt]['deploy'] parameters['deploy_tool'] = Qt56Dictionary[ModuleQt]['deploy']
parameters['qt_lib_root'] = Qt56Dictionary[ModuleQt]['libdir'] parameters['qt_lib_root'] = Qt56Dictionary[ModuleQt]['libdir']
# (E) rpath # (F) rpath
if OSPython3FW in [ MontereyPy3FW, VenturaPy3FW, SonomaPy3FW, SequoiaPy3FW, TahoePy3FW ]: if OSPython3FW in [ MontereyPy3FW, VenturaPy3FW, SonomaPy3FW, SequoiaPy3FW, TahoePy3FW ]:
parameters['rpath'] = OSPython3FW parameters['rpath'] = OSPython3FW
else: else:
parameters['rpath'] = "@executable_path/../Frameworks" parameters['rpath'] = "@executable_path/../Frameworks"
# (F) want Qt bindings with Ruby scripts? # (G) want Qt bindings with Ruby scripts?
parameters['no_qt_bindings'] = NoQtBindings parameters['no_qt_bindings'] = NoQtBindings
# (G) want QtUiTools? # (H) want QtUiTools?
parameters['no_qt_uitools'] = NoQtUiTools parameters['no_qt_uitools'] = NoQtUiTools
# (H) options to `make` tool # (I) want 32bitCoord?
parameters['no_32_bitcoord'] = No32bitCoord
# (J) want libgit2?
parameters['no_libgit2'] = NoLibGit2
# (K) options to `make` tool
if not MakeOptions == "": if not MakeOptions == "":
parameters['make_options'] = MakeOptions parameters['make_options'] = MakeOptions
try: try:
@ -739,7 +774,7 @@ def Get_Build_Parameters(config):
else: else:
parameters['num_parallel'] = pnum parameters['num_parallel'] = pnum
# (I) about Ruby # (L) about Ruby
if ModuleRuby != "nil": if ModuleRuby != "nil":
parameters['ruby'] = RubyDictionary[ModuleRuby]['exe'] parameters['ruby'] = RubyDictionary[ModuleRuby]['exe']
parameters['rbinc'] = RubyDictionary[ModuleRuby]['inc'] parameters['rbinc'] = RubyDictionary[ModuleRuby]['inc']
@ -747,7 +782,7 @@ def Get_Build_Parameters(config):
if 'inc2' in RubyDictionary[ModuleRuby]: if 'inc2' in RubyDictionary[ModuleRuby]:
parameters['rbinc2'] = RubyDictionary[ModuleRuby]['inc2'] parameters['rbinc2'] = RubyDictionary[ModuleRuby]['inc2']
# (J) about Python # (M) about Python
if ModulePython != "nil": if ModulePython != "nil":
parameters['python'] = PythonDictionary[ModulePython]['exe'] parameters['python'] = PythonDictionary[ModulePython]['exe']
parameters['pyinc'] = PythonDictionary[ModulePython]['inc'] parameters['pyinc'] = PythonDictionary[ModulePython]['inc']
@ -759,28 +794,28 @@ def Get_Build_Parameters(config):
config['MacBuildDirQAT'] = MacBuildDirQAT # relative path to build directory for QATest config['MacBuildDirQAT'] = MacBuildDirQAT # relative path to build directory for QATest
config['MacBuildLog'] = MacBuildLog # relative path to build log file config['MacBuildLog'] = MacBuildLog # relative path to build log file
# (K) Extra parameters needed for deployment # (N) Extra parameters needed for deployment
parameters['project_dir'] = ProjectDir parameters['project_dir'] = ProjectDir
# (L) Extra parameters needed for <pymod> # (O) Extra parameters needed for <pymod>
# <pymod> will be built if: # <pymod> will be built if:
# BuildPymodWhl = True # BuildPymodWhl = True
# Platform = [ 'Tahoe', 'Sequoia', 'Sonoma', 'Ventura', 'Monterey' ] # Platform = [ 'GoldenGate', 'Tahoe', 'Sequoia', 'Sonoma', 'Ventura', 'Monterey' ]
# ModuleRuby = [ 'Ruby34MacPorts', 'Ruby34Brew', 'RubyAnaconda3' ] # ModuleRuby = [ 'Ruby34MacPorts', 'Ruby34Brew', 'RubyAnaconda3V5', 'RubyAnaconda3V6' ]
# ModulePython = [ 'Python313MacPorts', 'Python312MacPorts', 'Python311MacPorts', # ModulePython = [ 'Python314MacPorts', 'Python313MacPorts',
# 'Python313Brew', 'Python312Brew', 'Python311Brew', # 'Python314Brew', 'Python313Brew', 'Python311Brew',
# 'PythonAnaconda3' ] # 'PythonAnaconda3V5', 'PythonAnaconda3V6' ]
parameters['BuildPymodWhl'] = BuildPymodWhl parameters['BuildPymodWhl'] = BuildPymodWhl
parameters['Platform'] = Platform parameters['Platform'] = Platform
parameters['ModuleRuby'] = ModuleRuby parameters['ModuleRuby'] = ModuleRuby
parameters['ModulePython'] = ModulePython parameters['ModulePython'] = ModulePython
PymodDistDir = dict() PymodDistDir = dict()
if Platform in [ 'Tahoe', 'Sequoia', 'Sonoma', 'Ventura', 'Monterey' ]: if Platform in [ 'GoldenGate', 'Tahoe', 'Sequoia', 'Sonoma', 'Ventura', 'Monterey' ]:
if ModuleRuby in [ 'Ruby34MacPorts', 'Ruby34Brew', 'RubyAnaconda3V5', 'RubyAnaconda3V6' ]: if ModuleRuby in [ 'Ruby34MacPorts', 'Ruby34Brew', 'RubyAnaconda3V5', 'RubyAnaconda3V6' ]:
if ModulePython in [ 'Python313MacPorts', 'Python312MacPorts', 'Python311MacPorts' ]: if ModulePython in [ 'Python314MacPorts', 'Python313MacPorts' ]:
PymodDistDir[ModulePython] = 'dist-MP3-%s' % ModuleQt PymodDistDir[ModulePython] = 'dist-MP3-%s' % ModuleQt
elif ModulePython in [ 'Python313Brew', 'Python312Brew', 'Python311Brew' ]: elif ModulePython in [ 'Python314Brew', 'Python313Brew', 'Python311Brew' ]:
PymodDistDir[ModulePython] = 'dist-HB3-%s' % ModuleQt PymodDistDir[ModulePython] = 'dist-HB3-%s' % ModuleQt
elif ModulePython in [ 'PythonAnaconda3V5', 'PythonAnaconda3V6' ]: elif ModulePython in [ 'PythonAnaconda3V5', 'PythonAnaconda3V6' ]:
PymodDistDir[ModulePython] = 'dist-ana3-%s' % ModuleQt PymodDistDir[ModulePython] = 'dist-ana3-%s' % ModuleQt
@ -799,10 +834,10 @@ def Build_pymod_wheel(parameters):
#----------------------------------------------------------------------------------------------------------- #-----------------------------------------------------------------------------------------------------------
# [1] <pymod> will be built if: # [1] <pymod> will be built if:
# BuildPymodWhl = True # BuildPymodWhl = True
# Platform = [ 'Tahoe', 'Sequoia', 'Sonoma', 'Ventura', 'Monterey' ] # Platform = [ 'GoldenGate', 'Tahoe', 'Sequoia', 'Sonoma', 'Ventura', 'Monterey' ]
# ModuleRuby = [ 'Ruby34MacPorts', 'Ruby34Brew', 'RubyAnaconda3V5', 'RubyAnaconda3V6' ] # ModuleRuby = [ 'Ruby34MacPorts', 'Ruby34Brew', 'RubyAnaconda3V5', 'RubyAnaconda3V6' ]
# ModulePython = [ 'Python313MacPorts', 'Python312MacPorts', 'Python311MacPorts', # ModulePython = [ 'Python314MacPorts', 'Python313MacPorts',
# 'Python313Brew', 'Python312Brew', 'Python311Brew', # 'Python314Brew', 'Python313Brew', 'Python311Brew',
# 'PythonAnaconda3V5', 'PythonAnaconda3V6' ] # 'PythonAnaconda3V5', 'PythonAnaconda3V6' ]
#----------------------------------------------------------------------------------------------------------- #-----------------------------------------------------------------------------------------------------------
BuildPymodWhl = parameters['BuildPymodWhl'] BuildPymodWhl = parameters['BuildPymodWhl']
@ -811,12 +846,12 @@ def Build_pymod_wheel(parameters):
ModulePython = parameters['ModulePython'] ModulePython = parameters['ModulePython']
if not BuildPymodWhl: if not BuildPymodWhl:
return 0 return 0
if not Platform in [ 'Tahoe', 'Sequoia', 'Sonoma', 'Ventura', 'Monterey' ]: if not Platform in [ 'GoldenGate', 'Tahoe', 'Sequoia', 'Sonoma', 'Ventura', 'Monterey' ]:
return 0 return 0
elif not ModuleRuby in [ 'Ruby34MacPorts', 'Ruby34Brew', 'RubyAnaconda3V5', 'RubyAnaconda3V6' ]: elif not ModuleRuby in [ 'Ruby34MacPorts', 'Ruby34Brew', 'RubyAnaconda3V5', 'RubyAnaconda3V6' ]:
return 0 return 0
elif not ModulePython in [ 'Python313MacPorts', 'Python312MacPorts', 'Python311MacPorts', \ elif not ModulePython in [ 'Python314MacPorts', 'Python313MacPorts', \
'Python313Brew', 'Python312Brew', 'Python311Brew', \ 'Python314Brew', 'Python313Brew', 'Python311Brew', \
'PythonAnaconda3V5', 'PythonAnaconda3V6' ]: 'PythonAnaconda3V5', 'PythonAnaconda3V6' ]:
return 0 return 0
@ -1124,25 +1159,31 @@ def Run_Build_Command(config, parameters):
cmd_args += " \\\n -build %s" % parameters['build'] cmd_args += " \\\n -build %s" % parameters['build']
cmd_args += " \\\n -rpath %s" % parameters['rpath'] cmd_args += " \\\n -rpath %s" % parameters['rpath']
# (E) want Qt bindings with Ruby scripts? # (F) want Qt bindings with Ruby scripts?
if parameters['no_qt_bindings']: if parameters['no_qt_bindings']:
cmd_args += " \\\n -without-qtbinding" cmd_args += " \\\n -without-qtbinding"
else: else:
cmd_args += " \\\n -with-qtbinding" cmd_args += " \\\n -with-qtbinding"
# (F) want QtUiTools? # (G) want QtUiTools?
if parameters['no_qt_uitools']: if parameters['no_qt_uitools']:
cmd_args += " \\\n -without-qt-uitools" cmd_args += " \\\n -without-qt-uitools"
# (G) don't want to use libgit2? # (I) want 32bitCoord?
if NoLibGit2: if parameters['no_32_bitcoord']:
cmd_args += " \\\n -libgit2" cmd_args += " \\\n -with-64bit-coord" # EXPERIMENTAL FEATURE
else:
cmd_args += " \\\n -without-64bit-coord" # default
# (H) options to `make` tool # (J) want libgit2?
if parameters['no_libgit2']:
cmd_args += " \\\n -nolibgit2"
# (K) options to `make` tool
if 'make_options' in parameters: if 'make_options' in parameters:
cmd_args += " \\\n -option %s" % parameters['make_options'] cmd_args += " \\\n -option %s" % parameters['make_options']
# (I) about Ruby # (L) about Ruby
if 'ruby' in parameters: if 'ruby' in parameters:
cmd_args += " \\\n -ruby %s" % parameters['ruby'] cmd_args += " \\\n -ruby %s" % parameters['ruby']
cmd_args += " \\\n -rbinc %s" % parameters['rbinc'] cmd_args += " \\\n -rbinc %s" % parameters['rbinc']
@ -1152,7 +1193,7 @@ def Run_Build_Command(config, parameters):
else: else:
cmd_args += " \\\n -noruby" cmd_args += " \\\n -noruby"
# (J) about Python # (M) about Python
if 'python' in parameters: if 'python' in parameters:
cmd_args += " \\\n -python %s" % parameters['python'] cmd_args += " \\\n -python %s" % parameters['python']
cmd_args += " \\\n -pyinc %s" % parameters['pyinc'] cmd_args += " \\\n -pyinc %s" % parameters['pyinc']
@ -1645,9 +1686,10 @@ def Deploy_Binaries_For_Bundle(config, parameters):
regQt = re.compile(patQt) regQt = re.compile(patQt)
# (4) Python frameworks (only for Homebrew) # in the case of Intel Mac... # (4) Python frameworks (only for Homebrew) # in the case of Intel Mac...
libPy3_1 = "%s/" % HBPython312FrameworkPath # /usr/local/opt/python@3.12/Frameworks/Python.framework/ libPy3_1 = "%s/" % HBPython314FrameworkPath # /usr/local/opt/python@3.14/Frameworks/Python.framework/
libPy3_2 = "%s/" % HBPython311FrameworkPath # /usr/local/opt/python@3.11/Frameworks/Python.framework/ libPy3_2 = "%s/" % HBPython313FrameworkPath # /usr/local/opt/python@3.13/Frameworks/Python.framework/
patPy3 = r'^(%s|%s)(.+)' % (libPy3_1, libPy3_2) libPy3_3 = "%s/" % HBPython311FrameworkPath # /usr/local/opt/python@3.11/Frameworks/Python.framework/
patPy3 = r'^(%s|%s|%s)(.+)' % (libPy3_1, libPy3_2, libPy3_3)
regPy3 = re.compile(patPy3) regPy3 = re.compile(patPy3)
#------------------------------------------------------------------------------- #-------------------------------------------------------------------------------
@ -2285,7 +2327,7 @@ def Deploy_Binaries_For_Bundle(config, parameters):
#------------------------------------------------------------- #-------------------------------------------------------------
# [11] Sign the application bundle # [11] Sign the application bundle
#------------------------------------------------------------- #-------------------------------------------------------------
if Platform in ['Tahoe']: if Platform in ['GoldenGate', 'Tahoe']:
print( " [11] Signing the macOS application bundle (ad-hoc) after all post-build edits (install_name_tool/strip)..." ) print( " [11] Signing the macOS application bundle (ad-hoc) after all post-build edits (install_name_tool/strip)..." )
appbundle = "%s/klayout.app" % AbsMacPkgDir appbundle = "%s/klayout.app" % AbsMacPkgDir
res = Sign_App_Bundle(appbundle) res = Sign_App_Bundle(appbundle)

View File

@ -6,7 +6,7 @@
# #
# Here are dictionaries of ... # Here are dictionaries of ...
# different modules for building KLayout (http://www.klayout.de/index.php) # different modules for building KLayout (http://www.klayout.de/index.php)
# version 0.30.5 or later on different Apple Mac OSX platforms. # version 0.30.9 or later on different Apple Mac OSX platforms.
# #
# This file is imported by the 'build4mac.py' script. # This file is imported by the 'build4mac.py' script.
#=============================================================================== #===============================================================================
@ -255,7 +255,7 @@ Qt56Dictionary = { 'Qt5MacPorts': Qt5MacPorts,
# for the previous states. # for the previous states.
#----------------------------------------------------- #-----------------------------------------------------
RubyNil = [ 'nil' ] RubyNil = [ 'nil' ]
RubySys = [ 'RubyMonterey', 'RubyVentura', 'RubySonoma', 'RubySequoia', 'RubyTahoe' ] RubySys = [ 'RubyMonterey', 'RubyVentura', 'RubySonoma', 'RubySequoia', 'RubyTahoe', 'RubyGoldenGate' ]
RubyExt = [ 'Ruby34MacPorts', 'Ruby34Brew', 'RubyAnaconda3' ] RubyExt = [ 'Ruby34MacPorts', 'Ruby34Brew', 'RubyAnaconda3' ]
Rubies = RubyNil + RubySys + RubyExt Rubies = RubyNil + RubySys + RubyExt
@ -324,11 +324,21 @@ RubyTahoe = { 'exe': '/System/Library/Frameworks/Ruby.framework/Versions
'lib': '%s/System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/libruby.tbd' % TahoeXcSDK 'lib': '%s/System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/libruby.tbd' % TahoeXcSDK
} }
# Bundled with Golden Gate (27.x)
# [Key Type Name] = 'Sys'
GoldenGateXcSDK = "/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX.sdk"
GoldenGateCLTSDK = "/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk"
RubyGoldenGate = { 'exe': '/System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/bin/ruby',
'inc': '%s/System/Library/Frameworks/Ruby.framework/Headers' % GoldenGateXcSDK,
'inc2': '%s/System/Library/Frameworks/Ruby.framework/Headers/ruby' % GoldenGateXcSDK,
'lib': '%s/System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/libruby.tbd' % GoldenGateXcSDK
}
# Ruby 3.4 from MacPorts (https://www.macports.org/) # Ruby 3.4 from MacPorts (https://www.macports.org/)
# install with 'sudo port install ruby34' # install with 'sudo port install ruby34'
# [Key Type Name] = 'MP34' # [Key Type Name] = 'MP34'
Ruby34MacPorts = { 'exe': '/opt/local/bin/ruby3.4', Ruby34MacPorts = { 'exe': '/opt/local/bin/ruby3.4',
'inc': '/opt/local/include/ruby-3.4.9', 'inc': '/opt/local/include/ruby-3.4.10',
'lib': '/opt/local/lib/libruby.3.4.dylib' 'lib': '/opt/local/lib/libruby.3.4.dylib'
} }
@ -361,6 +371,7 @@ RubyDictionary = { 'nil' : None,
'RubySonoma' : RubySonoma, 'RubySonoma' : RubySonoma,
'RubySequoia' : RubySequoia, 'RubySequoia' : RubySequoia,
'RubyTahoe' : RubyTahoe, 'RubyTahoe' : RubyTahoe,
'RubyGoldenGate' : RubyGoldenGate,
'Ruby34MacPorts' : Ruby34MacPorts, 'Ruby34MacPorts' : Ruby34MacPorts,
'Ruby34Brew' : Ruby34Brew, 'Ruby34Brew' : Ruby34Brew,
'RubyAnaconda3V5' : RubyAnaconda3V5, 'RubyAnaconda3V5' : RubyAnaconda3V5,
@ -376,9 +387,9 @@ RubyDictionary = { 'nil' : None,
# for the previous states. # for the previous states.
#----------------------------------------------------- #-----------------------------------------------------
PythonNil = [ 'nil' ] PythonNil = [ 'nil' ]
PythonSys = [ 'PythonMonterey', 'PythonVentura', 'PythonSonoma', 'PythonSequoia', 'PythonTahoe' ] PythonSys = [ 'PythonMonterey', 'PythonVentura', 'PythonSonoma', 'PythonSequoia', 'PythonTahoe', 'PythonGoldenGate' ]
PythonExt = [ 'Python311MacPorts', 'Python312MacPorts', 'Python313MacPorts' ] PythonExt = [ 'Python314MacPorts', 'Python313MacPorts' ]
PythonExt += [ 'Python311Brew', 'Python312Brew', 'Python313Brew', 'PythonAutoBrew' ] PythonExt += [ 'Python314Brew', 'Python313Brew', 'Python311Brew', 'PythonAutoBrew' ]
PythonExt += [ 'PythonAnaconda3' ] PythonExt += [ 'PythonAnaconda3' ]
Pythons = PythonNil + PythonSys + PythonExt Pythons = PythonNil + PythonSys + PythonExt
@ -430,20 +441,21 @@ PythonTahoe = { 'exe': '%s/Python3.framework/Versions/3.9/bin/python3.9' %
'lib': '%s/Python3.framework/Versions/3.9/lib/libpython3.9.dylib' % TahoePy3FW 'lib': '%s/Python3.framework/Versions/3.9/lib/libpython3.9.dylib' % TahoePy3FW
} }
# Python 3.11 from MacPorts (https://www.macports.org/) # Bundled with Golden Gate (27.x)
# install with 'sudo port install python311' # [Key Type Name] = 'Sys'
# [Key Type Name] = 'MP311' GoldenGatePy3FWXc = "/Applications/Xcode.app/Contents/Developer/Library/Frameworks"
Python311MacPorts = { 'exe': '/opt/local/Library/Frameworks/Python.framework/Versions/3.11/bin/python3.11', GoldenGatePy3FW = "/Library/Developer/CommandLineTools/Library/Frameworks"
'inc': '/opt/local/Library/Frameworks/Python.framework/Versions/3.11/include/python3.11', PythonGoldenGate = { 'exe': '%s/Python3.framework/Versions/3.9/bin/python3.9' % GoldenGatePy3FW,
'lib': '/opt/local/Library/Frameworks/Python.framework/Versions/3.11/lib/libpython3.11.dylib' 'inc': '%s/Python3.framework/Versions/3.9/include/python3.9' % GoldenGatePy3FW,
'lib': '%s/Python3.framework/Versions/3.9/lib/libpython3.9.dylib' % GoldenGatePy3FW
} }
# Python 3.12 from MacPorts (https://www.macports.org/) # Python 3.14 from MacPorts (https://www.macports.org/)
# install with 'sudo port install python312' # install with 'sudo port install python314'
# [Key Type Name] = 'MP312' # [Key Type Name] = 'MP314'
Python312MacPorts = { 'exe': '/opt/local/Library/Frameworks/Python.framework/Versions/3.12/bin/python3.12', Python314MacPorts = { 'exe': '/opt/local/Library/Frameworks/Python.framework/Versions/3.14/bin/python3.14',
'inc': '/opt/local/Library/Frameworks/Python.framework/Versions/3.12/include/python3.12', 'inc': '/opt/local/Library/Frameworks/Python.framework/Versions/3.14/include/python3.14',
'lib': '/opt/local/Library/Frameworks/Python.framework/Versions/3.12/lib/libpython3.12.dylib' 'lib': '/opt/local/Library/Frameworks/Python.framework/Versions/3.14/lib/libpython3.14.dylib'
} }
# Python 3.13 from MacPorts (https://www.macports.org/) # Python 3.13 from MacPorts (https://www.macports.org/)
@ -454,22 +466,13 @@ Python313MacPorts = { 'exe': '/opt/local/Library/Frameworks/Python.framework/Ver
'lib': '/opt/local/Library/Frameworks/Python.framework/Versions/3.13/lib/libpython3.13.dylib' 'lib': '/opt/local/Library/Frameworks/Python.framework/Versions/3.13/lib/libpython3.13.dylib'
} }
# Python 3.11 from Homebrew # Python 3.14 from Homebrew
# install with 'brew install python@3.11' # install with 'brew install python@3.14'
# [Key Type Name] = 'HB311' # [Key Type Name] = 'HB314'
HBPython311FrameworkPath = '%s/opt/python@3.11/Frameworks/Python.framework' % DefaultHomebrewRoot HBPython314FrameworkPath = '%s/opt/python@3.14/Frameworks/Python.framework' % DefaultHomebrewRoot
Python311Brew = { 'exe': '%s/Versions/3.11/bin/python3.11' % HBPython311FrameworkPath, Python314Brew = { 'exe': '%s/Versions/3.14/bin/python3.14' % HBPython314FrameworkPath,
'inc': '%s/Versions/3.11/include/python3.11' % HBPython311FrameworkPath, 'inc': '%s/Versions/3.14/include/python3.14' % HBPython314FrameworkPath,
'lib': '%s/Versions/3.11/lib/libpython3.11.dylib' % HBPython311FrameworkPath 'lib': '%s/Versions/3.14/lib/libpython3.14.dylib' % HBPython314FrameworkPath
}
# Python 3.12 from Homebrew
# install with 'brew install python@3.12'
# [Key Type Name] = 'HB312'
HBPython312FrameworkPath = '%s/opt/python@3.12/Frameworks/Python.framework' % DefaultHomebrewRoot
Python312Brew = { 'exe': '%s/Versions/3.12/bin/python3.12' % HBPython312FrameworkPath,
'inc': '%s/Versions/3.12/include/python3.12' % HBPython312FrameworkPath,
'lib': '%s/Versions/3.12/lib/libpython3.12.dylib' % HBPython312FrameworkPath
} }
# Python 3.13 from Homebrew # Python 3.13 from Homebrew
@ -481,6 +484,15 @@ Python313Brew = { 'exe': '%s/Versions/3.13/bin/python3.13' % HBPython313Fram
'lib': '%s/Versions/3.13/lib/libpython3.13.dylib' % HBPython313FrameworkPath 'lib': '%s/Versions/3.13/lib/libpython3.13.dylib' % HBPython313FrameworkPath
} }
# Python 3.11 from Homebrew
# install with 'brew install python@3.11'
# [Key Type Name] = 'HB311'
HBPython311FrameworkPath = '%s/opt/python@3.11/Frameworks/Python.framework' % DefaultHomebrewRoot
Python311Brew = { 'exe': '%s/Versions/3.11/bin/python3.11' % HBPython311FrameworkPath,
'inc': '%s/Versions/3.11/include/python3.11' % HBPython311FrameworkPath,
'lib': '%s/Versions/3.11/lib/libpython3.11.dylib' % HBPython311FrameworkPath
}
# Python 3.13 installed under [/opt|/Applications]/anaconda3/klayout-qt[5|6] # Python 3.13 installed under [/opt|/Applications]/anaconda3/klayout-qt[5|6]
# See the [Qt5] [Qt6] section above. # See the [Qt5] [Qt6] section above.
# [Key Type Name] = 'Ana3' # [Key Type Name] = 'Ana3'
@ -551,13 +563,13 @@ PythonDictionary = { 'nil' : None,
'PythonSonoma' : PythonSonoma, 'PythonSonoma' : PythonSonoma,
'PythonSequoia' : PythonSequoia, 'PythonSequoia' : PythonSequoia,
'PythonTahoe' : PythonTahoe, 'PythonTahoe' : PythonTahoe,
'PythonGoldenGate' : PythonGoldenGate,
'Python314MacPorts' : Python314MacPorts,
'Python313MacPorts' : Python313MacPorts, 'Python313MacPorts' : Python313MacPorts,
'Python314Brew' : Python314Brew,
'Python313Brew' : Python313Brew, 'Python313Brew' : Python313Brew,
'PythonAnaconda3V5' : PythonAnaconda3V5, 'PythonAnaconda3V5' : PythonAnaconda3V5,
'PythonAnaconda3V6' : PythonAnaconda3V6, 'PythonAnaconda3V6' : PythonAnaconda3V6,
'Python312MacPorts' : Python312MacPorts,
'Python312Brew' : Python312Brew,
'Python311MacPorts' : Python311MacPorts,
'Python311Brew' : Python311Brew 'Python311Brew' : Python311Brew
} }
if _have_Homebrew_Python: if _have_Homebrew_Python:

View File

@ -6,7 +6,7 @@
# #
# Here are utility functions and classes ... # Here are utility functions and classes ...
# for building KLayout (http://www.klayout.de/index.php) # for building KLayout (http://www.klayout.de/index.php)
# version 0.30.5 or later on different Apple Mac OSX platforms. # version 0.30.9 or later on different Apple Mac OSX platforms.
# #
# This file is imported by 'build4mac.py' script. # This file is imported by 'build4mac.py' script.
#======================================================================================== #========================================================================================

View File

@ -78,13 +78,13 @@ def SetGlobals():
Usage = "\n" Usage = "\n"
Usage += "---------------------------------------------------------------------------------------------------------\n" Usage += "---------------------------------------------------------------------------------------------------------\n"
Usage += "<< Usage of 'makeDMG4mac.py' >>\n" Usage += "<< Usage of 'makeDMG4mac.py' >>\n"
Usage += " for making a DMG file of KLayout 0.30.5 or later on different Apple macOS platforms.\n" Usage += " for making a DMG file of KLayout 0.30.9 or later on different Apple macOS platforms.\n"
Usage += "\n" Usage += "\n"
Usage += "$ [python] ./makeDMG4mac.py\n" Usage += "$ [python] ./makeDMG4mac.py\n"
Usage += " option & argument : descriptions | default value\n" Usage += " option & argument : descriptions | default value\n"
Usage += " ----------------------------------------------------------------------------------+-----------------\n" Usage += " ----------------------------------------------------------------------------------+-----------------\n"
Usage += " <-p|--pkg <dir>> : package directory created by `build4mac.py` with [-y|-Y] | ``\n" Usage += " <-p|--pkg <dir>> : package directory created by `build4mac.py` with [-y|-Y] | ``\n"
Usage += " : like 'LW-qt5MP.pkg.macos-Sequoia-release-Rmp34Pmp313' | \n" Usage += " : like 'LW-qt5MP.pkg.macos-Sequoia-C32-release-Rmp34Pmp314' | \n"
Usage += " <-c|--clean> : clean the work directory | disabled\n" Usage += " <-c|--clean> : clean the work directory | disabled\n"
Usage += " <-m|--make> : make a compressed DMG file | disabled\n" Usage += " <-m|--make> : make a compressed DMG file | disabled\n"
Usage += " : <-c|--clean> and <-m|--make> are mutually exclusive | \n" Usage += " : <-c|--clean> and <-m|--make> are mutually exclusive | \n"
@ -106,7 +106,11 @@ def SetGlobals():
release = int( Release.split(".")[0] ) # take the first of ['21', '0', '0'] release = int( Release.split(".")[0] ) # take the first of ['21', '0', '0']
LatestOS = "" LatestOS = ""
if release == 25: if release == 27:
GenOSName = "macOS"
Platform = "GoldenGate"
LatestOS = Platform
elif release == 25:
GenOSName = "macOS" GenOSName = "macOS"
Platform = "Tahoe" Platform = "Tahoe"
LatestOS = Platform LatestOS = Platform
@ -135,7 +139,7 @@ def SetGlobals():
if not Machine == "x86_64": if not Machine == "x86_64":
# with an Apple Silicon Chip? # with an Apple Silicon Chip?
if Machine == "arm64" and Platform in ["Tahoe", "Sequoia", "Sonoma", "Ventura", "Monterey"]: if Machine == "arm64" and Platform in ["GoldenGate", "Tahoe", "Sequoia", "Sonoma", "Ventura", "Monterey"]:
print("") print("")
print( "### Your Mac equips an Apple Silicon Chip ###" ) print( "### Your Mac equips an Apple Silicon Chip ###" )
print("") print("")
@ -222,17 +226,17 @@ def SetGlobals():
## To check the contents of the package directory ## To check the contents of the package directory
# #
# The package directory name should look like: # The package directory name should look like:
# * ST-qt5MP.pkg.macos-Sequoia-release-RsysPsys # * ST-qt5MP.pkg.macos-Sequoia-C32-release-RsysPsys
# * LW-qt5Ana3.pkg.macos-Sequoia-release-Rana3Pana3 # * LW-qt5Ana3.pkg.macos-Sequoia-C32-release-Rana3Pana3
# * LW-qt6Brew.pkg.macos-Sequoia-release-Rhb34Phb312 --- (1) # * LW-qt6Brew.pkg.macos-Sequoia-C32-release-Rhb34Phb312 --- (1)
# * LW-qt5MP.pkg.macos-Sequoia-release-Rmp33Pmp312 # * LW-qt5MP.pkg.macos-Sequoia-C32-release-Rmp33Pmp312
# * HW-qt6Brew.pkg.macos-Sequoia-release-RsysPhb311 # * HW-qt6Brew.pkg.macos-Sequoia-C32-release-RsysPhb311
# #
# * ST-qt6MP.pkg.macos-Sequoia-release-RsysPsys # * ST-qt6MP.pkg.macos-Sequoia-C32-release-RsysPsys
# * LW-qt6MP.pkg.macos-Sequoia-release-Rmp33Pmp312 # * LW-qt6MP.pkg.macos-Sequoia-C32-release-Rmp33Pmp312
# #
# Generated DMG will be, for example, # Generated DMG will be, for example,
# (1) ---> LW-klayout-0.30.2-macOS-Sequoia-1-qt6Brew-Rhb34Phb312.dmg # (1) ---> LW-klayout-0.30.2-macOS-Sequoia-C32-1-qt6Brew-Rhb34Phb312.dmg
# #
# @return on success, positive integer in [MB] that tells approx. occupied disc space; # @return on success, positive integer in [MB] that tells approx. occupied disc space;
# on failure, -1 # on failure, -1
@ -247,6 +251,7 @@ def CheckPkgDirectory():
global BundleName global BundleName
global PackagePrefix global PackagePrefix
global QtIdentification global QtIdentification
global CoordSize
global BuildType global BuildType
global RubyPythonID global RubyPythonID
global BackgroundPNG global BackgroundPNG
@ -272,18 +277,18 @@ def CheckPkgDirectory():
#----------------------------------------------------------------------------------------------- #-----------------------------------------------------------------------------------------------
# [2] Identify (Qt, Ruby, Python) from PkgDir # [2] Identify (Qt, Ruby, Python) from PkgDir
# * ST-qt5MP.pkg.macos-Sequoia-release-RsysPsys # * ST-qt5MP.pkg.macos-Sequoia-C32-release-RsysPsys
# * LW-qt5Ana3.pkg.macos-Sequoia-release-Rana3Pana3 # * LW-qt5Ana3.pkg.macos-Sequoia-C32-release-Rana3Pana3
# * LW-qt6Brew.pkg.macos-Sequoia-release-Rhb34Phb312 # * LW-qt6Brew.pkg.macos-Sequoia-C32-release-Rhb34Phb312
# * LW-qt5MP.pkg.macos-Sequoia-release-Rmp33Pmp312 # * LW-qt5MP.pkg.macos-Sequoia-C32-release-Rmp33Pmp312
# * HW-qt6Brew.pkg.macos-Sequoia-release-RsysPhb311 # * HW-qt6Brew.pkg.macos-Sequoia-C32-release-RsysPhb311
# * EX-qt5MP.pkg.macos-Sequoia-release-Rhb34Pmp312 # * EX-qt5MP.pkg.macos-Sequoia-C32-release-Rhb34Pmp312
# #
# * ST-qt6MP.pkg.macos-Sequoia-release-RsysPsys # * ST-qt6MP.pkg.macos-Sequoia-C32-release-RsysPsys
# * LW-qt6MP.pkg.macos-Sequoia-release-Rmp33Pmp312 # * LW-qt6MP.pkg.macos-Sequoia-C32-release-Rmp33Pmp312
#----------------------------------------------------------------------------------------------- #-----------------------------------------------------------------------------------------------
# 0 1 2 3 4 5 6 7 # 0 1 2 3 4 5 6 7 8 9
patQRP = r'(ST|LW|HW|EX)([-])([qt5|qt6][0-9A-Za-z]+)([.]pkg[.])([A-Za-z]+[-][A-Za-z]+[-])(release|debug)([-])([0-9A-Za-z]+)' patQRP = r'(ST|LW|HW|EX)([-])([qt5|qt6][0-9A-Za-z]+)([.]pkg[.])([A-Za-z]+[-][A-Za-z]+[-])(C32|C64)([-])(release|debug)([-])([0-9A-Za-z]+)'
regQRP = re.compile(patQRP) regQRP = re.compile(patQRP)
if not regQRP.match(PkgDir): if not regQRP.match(PkgDir):
print( "! Cannot identify (Qt, Ruby, Python) from the package directory name" ) print( "! Cannot identify (Qt, Ruby, Python) from the package directory name" )
@ -309,14 +314,25 @@ def CheckPkgDirectory():
else: else:
BackgroundPNG = None BackgroundPNG = None
raise Exception( "! neither qt5 nor qt6" ) raise Exception( "! neither qt5 nor qt6" )
if pkgdirComponents[5] == 'release':
if pkgdirComponents[5] == 'C32':
CoordSize = 'C32'
elif pkgdirComponents[5] == 'C64':
CoordSize = 'C64'
else:
CoordSize = None
raise Exception( "! neither C32 nor C64" )
RubyPythonID = pkgdirComponents[7]
if pkgdirComponents[7] == 'release':
BuildType = 'release' BuildType = 'release'
elif pkgdirComponents[5] == 'debug': elif pkgdirComponents[7] == 'debug':
BuildType = 'debug' BuildType = 'debug'
else: else:
BuildType = None BuildType = None
raise Exception( "! neither release nor debug" ) raise Exception( "! neither release nor debug" )
RubyPythonID = pkgdirComponents[7]
RubyPythonID = pkgdirComponents[9]
#----------------------------------------------------------------------------- #-----------------------------------------------------------------------------
# [3] Check if the "LatestOS" with MacPorts / Homebrew / Anaconda3 # [3] Check if the "LatestOS" with MacPorts / Homebrew / Anaconda3
@ -329,12 +345,12 @@ def CheckPkgDirectory():
LatestOSMacPorts = Platform == LatestOS LatestOSMacPorts = Platform == LatestOS
LatestOSMacPorts &= PackagePrefix == "LW" LatestOSMacPorts &= PackagePrefix == "LW"
LatestOSMacPorts &= QtIdentification in [ "qt5MP", "qt6MP" ] LatestOSMacPorts &= QtIdentification in [ "qt5MP", "qt6MP" ]
LatestOSMacPorts &= RubyPythonID in [ "Rmp34Pmp313", "Rmp34Pmp312", "Rmp34Pmp311" ] LatestOSMacPorts &= RubyPythonID in [ "Rmp34Pmp314", "Rmp34Pmp313" ]
LatestOSHomebrew = Platform == LatestOS LatestOSHomebrew = Platform == LatestOS
LatestOSHomebrew &= PackagePrefix == "LW" LatestOSHomebrew &= PackagePrefix == "LW"
LatestOSHomebrew &= QtIdentification in [ "qt5Brew", "qt6Brew", "qt5MP", "qt6MP" ] # "qt[5|6]MP" are the alternatives LatestOSHomebrew &= QtIdentification in [ "qt5Brew", "qt6Brew", "qt5MP", "qt6MP" ] # "qt[5|6]MP" are the alternatives
LatestOSHomebrew &= RubyPythonID in [ "Rhb34Phb313", "Rhb34Phb312", "Rhb34Phb311", "Rhb34Phbauto" ] LatestOSHomebrew &= RubyPythonID in [ "Rhb34Phb314", "Rhb34Phb313", "Rhb34Phb311", "Rhb34Phbauto" ]
LatestOSAnaconda3 = Platform == LatestOS LatestOSAnaconda3 = Platform == LatestOS
LatestOSAnaconda3 &= PackagePrefix == "LW" LatestOSAnaconda3 &= PackagePrefix == "LW"
@ -555,8 +571,8 @@ def ParseCommandLineArguments():
if opt.target_dmg != "": if opt.target_dmg != "":
TargetDMG = opt.target_dmg TargetDMG = opt.target_dmg
else: else:
TargetDMG = "%s-klayout-%s-%s-%s-%d-%s-%s.dmg" \ TargetDMG = "%s-klayout-%s-%s-%s-%s-%d-%s-%s.dmg" \
% (PackagePrefix, KLVersion, GenOSName, Platform, DMGSerialNum, QtIdentification, RubyPythonID) % (PackagePrefix, KLVersion, GenOSName, Platform, CoordSize, DMGSerialNum, QtIdentification, RubyPythonID)
if Machine == "arm64": # with an Apple Silicon Chip if Machine == "arm64": # with an Apple Silicon Chip
TargetDMG = Machine + TargetDMG TargetDMG = Machine + TargetDMG
if BuildType == "debug": # in the case of 'debug' build if BuildType == "debug": # in the case of 'debug' build

View File

@ -30,14 +30,16 @@ import pandas as pd
# #
# @return matching platform name on success; "" on failure # @return matching platform name on success; "" on failure
#------------------------------------------------------------------------------ #------------------------------------------------------------------------------
def Test_My_Platform( platforms=[ 'Monterey', 'Ventura', 'Sonoma', 'Sequoia', 'Tahoe' ] ): def Test_My_Platform( platforms=[ 'Monterey', 'Ventura', 'Sonoma', 'Sequoia', 'Tahoe', 'GoldenGate' ] ):
(System, Node, Release, MacVersion, Machine, Processor) = platform.uname() (System, Node, Release, MacVersion, Machine, Processor) = platform.uname()
if not System == "Darwin": if not System == "Darwin":
return "" return ""
release = int( Release.split(".")[0] ) # take the first of ['21', '0', '0'] release = int( Release.split(".")[0] ) # take the first of ['21', '0', '0']
if release == 25: if release == 27:
Platform = "GoldenGate"
elif release == 25:
Platform = "Tahoe" Platform = "Tahoe"
elif release == 24: elif release == 24:
Platform = "Sequoia" Platform = "Sequoia"
@ -80,12 +82,13 @@ def Get_Build_Target_Dict():
# #
# @param[in] targetDic build target dictionary # @param[in] targetDic build target dictionary
# @param[in] platform platform name # @param[in] platform platform name
# @param[in] coordsize coordinate size (default='C32')
# #
# @return (dictionary1, dictionary2)-tupple # @return (dictionary1, dictionary2)-tupple
# dictionary1: key=(qtVer, mnemonic, bdType), value=build option list # dictionary1: key=(qtVer, mnemonic, bdType), value=build option list
# dictionary2: key=(qtVer, mnemonic, bdType), value=log file name # dictionary2: key=(qtVer, mnemonic, bdType), value=log file name
#------------------------------------------------------------------------------ #------------------------------------------------------------------------------
def Get_Build_Options( targetDic, platform ): def Get_Build_Options( targetDic, platform, coordsize='C32'):
buildOp = dict() buildOp = dict()
logfile = dict() logfile = dict()
@ -99,49 +102,49 @@ def Get_Build_Options( targetDic, platform ):
target = targetDic[key] target = targetDic[key]
if target == "std": if target == "std":
buildOp[(qtVer, "std", "r")] = [ '-q', '%sMacPorts' % qtType, '-r', 'sys', '-p', 'sys' ] buildOp[(qtVer, "std", "r")] = [ '-q', '%sMacPorts' % qtType, '-r', 'sys', '-p', 'sys' ]
logfile[(qtVer, "std", "r")] = "%sMP.build.macos-%s-%s-%s.log" % (qtType.lower(), platform, "release", "RsysPsys") logfile[(qtVer, "std", "r")] = "%sMP.build.macos-%s-%s-%s-%s.log" % (qtType.lower(), platform, coordsize, "release", "RsysPsys")
buildOp[(qtVer, "std", "d")] = [ '-q', '%sMacPorts' % qtType, '-r', 'sys', '-p', 'sys', '--debug' ] buildOp[(qtVer, "std", "d")] = [ '-q', '%sMacPorts' % qtType, '-r', 'sys', '-p', 'sys', '--debug' ]
logfile[(qtVer, "std", "d")] = "%sMP.build.macos-%s-%s-%s.log" % (qtType.lower(), platform, "debug", "RsysPsys") logfile[(qtVer, "std", "d")] = "%sMP.build.macos-%s-%s-%s-%s.log" % (qtType.lower(), platform, coordsize, "debug", "RsysPsys")
elif target == "ports": elif target == "ports":
buildOp[(qtVer, "ports", "r")] = [ '-q', '%sMacPorts' % qtType, '-r', 'MP34', '-p', 'MP313' ] buildOp[(qtVer, "ports", "r")] = [ '-q', '%sMacPorts' % qtType, '-r', 'MP34', '-p', 'MP314' ]
logfile[(qtVer, "ports", "r")] = "%sMP.build.macos-%s-%s-%s.log" % (qtType.lower(), platform, "release", "Rmp34Pmp313") logfile[(qtVer, "ports", "r")] = "%sMP.build.macos-%s-%s-%s-%s.log" % (qtType.lower(), platform, coordsize, "release", "Rmp34Pmp314")
buildOp[(qtVer, "ports", "d")] = [ '-q', '%sMacPorts' % qtType, '-r', 'MP34', '-p', 'MP313', '--debug' ] buildOp[(qtVer, "ports", "d")] = [ '-q', '%sMacPorts' % qtType, '-r', 'MP34', '-p', 'MP314', '--debug' ]
logfile[(qtVer, "ports", "d")] = "%sMP.build.macos-%s-%s-%s.log" % (qtType.lower(), platform, "debug", "Rmp34Pmp313") logfile[(qtVer, "ports", "d")] = "%sMP.build.macos-%s-%s-%s-%s.log" % (qtType.lower(), platform, coordsize, "debug", "Rmp34Pmp314")
elif target == "brew": elif target == "brew":
buildOp[(qtVer, "brew", "r")] = [ '-q', '%sBrew' % qtType, '-r', 'HB34', '-p', 'HB313' ] buildOp[(qtVer, "brew", "r")] = [ '-q', '%sBrew' % qtType, '-r', 'HB34', '-p', 'HB314' ]
logfile[(qtVer, "brew", "r")] = "%sBrew.build.macos-%s-%s-%s.log" % (qtType.lower(), platform, "release", "Rhb34Phb313") logfile[(qtVer, "brew", "r")] = "%sBrew.build.macos-%s-%s-%s-%s.log" % (qtType.lower(), platform, coordsize, "release", "Rhb34Phb314")
buildOp[(qtVer, "brew", "d")] = [ '-q', '%sBrew' % qtType, '-r', 'HB34', '-p', 'HB313', '--debug' ] buildOp[(qtVer, "brew", "d")] = [ '-q', '%sBrew' % qtType, '-r', 'HB34', '-p', 'HB314', '--debug' ]
logfile[(qtVer, "brew", "d")] = "%sBrew.build.macos-%s-%s-%s.log" % (qtType.lower(), platform, "debug", "Rhb34Phb313") logfile[(qtVer, "brew", "d")] = "%sBrew.build.macos-%s-%s-%s-%s.log" % (qtType.lower(), platform, coordsize, "debug", "Rhb34Phb314")
elif target == "brewHW": elif target == "brewHW":
buildOp[(qtVer, "brewHW", "r")] = [ '-q', '%sBrew' % qtType, '-r', 'sys', '-p', 'HB311' ] buildOp[(qtVer, "brewHW", "r")] = [ '-q', '%sBrew' % qtType, '-r', 'sys', '-p', 'HB311' ]
logfile[(qtVer, "brewHW", "r")] = "%sBrew.build.macos-%s-%s-%s.log" % (qtType.lower(), platform, "release", "RsysPhb311") logfile[(qtVer, "brewHW", "r")] = "%sBrew.build.macos-%s-%s-%s-%s.log" % (qtType.lower(), platform, coordsize, "release", "RsysPhb311")
buildOp[(qtVer, "brewHW", "d")] = [ '-q', '%sBrew' % qtType, '-r', 'sys', '-p', 'HB311', '--debug' ] buildOp[(qtVer, "brewHW", "d")] = [ '-q', '%sBrew' % qtType, '-r', 'sys', '-p', 'HB311', '--debug' ]
logfile[(qtVer, "brewHW", "d")] = "%sBrew.build.macos-%s-%s-%s.log" % (qtType.lower(), platform, "debug", "RsysPhb311") logfile[(qtVer, "brewHW", "d")] = "%sBrew.build.macos-%s-%s-%s-%s.log" % (qtType.lower(), platform, coordsize, "debug", "RsysPhb311")
elif target == "ana3": elif target == "ana3":
buildOp[(qtVer, "ana3", "r")] = [ '-q', '%sAna3' % qtType, '-r', 'Ana3', '-p', 'Ana3' ] buildOp[(qtVer, "ana3", "r")] = [ '-q', '%sAna3' % qtType, '-r', 'Ana3', '-p', 'Ana3' ]
logfile[(qtVer, "ana3", "r")] = "%sAna3.build.macos-%s-%s-%s.log" % (qtType.lower(), platform, "release", "Rana3Pana3") logfile[(qtVer, "ana3", "r")] = "%sAna3.build.macos-%s-%s-%s-%s.log" % (qtType.lower(), platform, coordsize, "release", "Rana3Pana3")
buildOp[(qtVer, "ana3", "d")] = [ '-q', '%sAna3' % qtType, '-r', 'Ana3', '-p', 'Ana3', '--debug' ] buildOp[(qtVer, "ana3", "d")] = [ '-q', '%sAna3' % qtType, '-r', 'Ana3', '-p', 'Ana3', '--debug' ]
logfile[(qtVer, "ana3", "d")] = "%sAna3.build.macos-%s-%s-%s.log" % (qtType.lower(), platform, "debug", "Rana3Pana3") logfile[(qtVer, "ana3", "d")] = "%sAna3.build.macos-%s-%s-%s-%s.log" % (qtType.lower(), platform, coordsize, "debug", "Rana3Pana3")
elif target == "brewA": elif target == "brewA":
buildOp[(qtVer, "brewA", "r")] = [ '-q', '%sBrew' % qtType, '-r', 'HB34', '-p', 'HBAuto' ] buildOp[(qtVer, "brewA", "r")] = [ '-q', '%sBrew' % qtType, '-r', 'HB34', '-p', 'HBAuto' ]
logfile[(qtVer, "brewA", "r")] = "%sBrew.build.macos-%s-%s-%s.log" % (qtType.lower(), platform, "release", "Rhb34Phbauto") logfile[(qtVer, "brewA", "r")] = "%sBrew.build.macos-%s-%s-%s-%s.log" % (qtType.lower(), platform, coordsize, "release", "Rhb34Phbauto")
buildOp[(qtVer, "brewA", "d")] = [ '-q', '%sBrew' % qtType, '-r', 'HB34', '-p', 'HBAuto', '--debug' ] buildOp[(qtVer, "brewA", "d")] = [ '-q', '%sBrew' % qtType, '-r', 'HB34', '-p', 'HBAuto', '--debug' ]
logfile[(qtVer, "brewA", "d")] = "%sBrew.build.macos-%s-%s-%s.log" % (qtType.lower(), platform, "debug", "Rhb34Phbauto") logfile[(qtVer, "brewA", "d")] = "%sBrew.build.macos-%s-%s-%s-%s.log" % (qtType.lower(), platform, coordsize, "debug", "Rhb34Phbauto")
elif target == "brewAHW": elif target == "brewAHW":
buildOp[(qtVer, "brewAHW", "r")] = [ '-q', '%sBrew' % qtType, '-r', 'sys', '-p', 'HBAuto' ] buildOp[(qtVer, "brewAHW", "r")] = [ '-q', '%sBrew' % qtType, '-r', 'sys', '-p', 'HBAuto' ]
logfile[(qtVer, "brewAHW", "r")] = "%sBrew.build.macos-%s-%s-%s.log" % (qtType.lower(), platform, "release", "RsysPhbauto") logfile[(qtVer, "brewAHW", "r")] = "%sBrew.build.macos-%s-%s-%s-%s.log" % (qtType.lower(), platform, coordsize, "release", "RsysPhbauto")
buildOp[(qtVer, "brewAHW", "d")] = [ '-q', '%sBrew' % qtType, '-r', 'sys', '-p', 'HBAuto', '--debug' ] buildOp[(qtVer, "brewAHW", "d")] = [ '-q', '%sBrew' % qtType, '-r', 'sys', '-p', 'HBAuto', '--debug' ]
logfile[(qtVer, "brewAHW", "d")] = "%sBrew.build.macos-%s-%s-%s.log" % (qtType.lower(), platform, "debug", "RsysPhbauto") logfile[(qtVer, "brewAHW", "d")] = "%sBrew.build.macos-%s-%s-%s-%s.log" % (qtType.lower(), platform, coordsize, "debug", "RsysPhbauto")
elif target == "pbrew": elif target == "pbrew":
buildOp[(qtVer, "pbrew", "r")] = [ '-q', '%sMacPorts' % qtType, '-r', 'HB34', '-p', 'HB313' ] buildOp[(qtVer, "pbrew", "r")] = [ '-q', '%sMacPorts' % qtType, '-r', 'HB34', '-p', 'HB314' ]
logfile[(qtVer, "pbrew", "r")] = "%sMP.build.macos-%s-%s-%s.log" % (qtType.lower(), platform, "release", "Rhb34Phb313") logfile[(qtVer, "pbrew", "r")] = "%sMP.build.macos-%s-%s-%s-%s.log" % (qtType.lower(), platform, coordsize, "release", "Rhb34Phb314")
buildOp[(qtVer, "pbrew", "d")] = [ '-q', '%sMacPorts' % qtType, '-r', 'HB34', '-p', 'HB313', '--debug' ] buildOp[(qtVer, "pbrew", "d")] = [ '-q', '%sMacPorts' % qtType, '-r', 'HB34', '-p', 'HB314', '--debug' ]
logfile[(qtVer, "pbrew", "d")] = "%sMP.build.macos-%s-%s-%s.log" % (qtType.lower(), platform, "debug", "Rhb34Phb313") logfile[(qtVer, "pbrew", "d")] = "%sMP.build.macos-%s-%s-%s-%s.log" % (qtType.lower(), platform, coordsize, "debug", "Rhb34Phb314")
elif target == "pbrewHW": elif target == "pbrewHW":
buildOp[(qtVer, "pbrewHW", "r")] = [ '-q', '%sMacPorts' % qtType, '-r', 'sys', '-p', 'HB311' ] buildOp[(qtVer, "pbrewHW", "r")] = [ '-q', '%sMacPorts' % qtType, '-r', 'sys', '-p', 'HB311' ]
logfile[(qtVer, "pbrewHW", "r")] = "%sMP.build.macos-%s-%s-%s.log" % (qtType.lower(), platform, "release", "RsysPhb311") logfile[(qtVer, "pbrewHW", "r")] = "%sMP.build.macos-%s-%s-%s-%s.log" % (qtType.lower(), platform, coordsize, "release", "RsysPhb311")
buildOp[(qtVer, "pbrewHW", "d")] = [ '-q', '%sMacPorts' % qtType, '-r', 'sys', '-p', 'HB311', '--debug' ] buildOp[(qtVer, "pbrewHW", "d")] = [ '-q', '%sMacPorts' % qtType, '-r', 'sys', '-p', 'HB311', '--debug' ]
logfile[(qtVer, "pbrewHW", "d")] = "%sMP.build.macos-%s-%s-%s.log" % (qtType.lower(), platform, "debug", "RsysPhb311") logfile[(qtVer, "pbrewHW", "d")] = "%sMP.build.macos-%s-%s-%s-%s.log" % (qtType.lower(), platform, coordsize, "debug", "RsysPhb311")
if WithPymod: if WithPymod:
buildOp[(qtVer, "ports", "r")] = buildOp[(qtVer, "ports", "r")] + ['--buildPymod'] buildOp[(qtVer, "ports", "r")] = buildOp[(qtVer, "ports", "r")] + ['--buildPymod']
@ -161,10 +164,11 @@ def Get_Build_Options( targetDic, platform ):
# #
# @param[in] targetDic build target dictionary # @param[in] targetDic build target dictionary
# @param[in] platform platform name # @param[in] platform platform name
# @param[in] coordsize coordinate size (default='C32')
# #
# @return a dictionary; key=(qtVer, mnemonic, bdType), value=".macQAT" directory # @return a dictionary; key=(qtVer, mnemonic, bdType), value=".macQAT" directory
#------------------------------------------------------------------------------ #------------------------------------------------------------------------------
def Get_QAT_Directory( targetDic, platform ): def Get_QAT_Directory( targetDic, platform, coordsize='C32' ):
dirQAT = dict() dirQAT = dict()
for qtVer in [5, 6]: for qtVer in [5, 6]:
@ -176,32 +180,32 @@ def Get_QAT_Directory( targetDic, platform ):
for key in targetDic.keys(): for key in targetDic.keys():
target = targetDic[key] target = targetDic[key]
if target == "std": if target == "std":
dirQAT[(qtVer, "std", "r")] = '%sMP.build.macos-%s-release-RsysPsys.macQAT' % (qtType.lower(), platform) dirQAT[(qtVer, "std", "r")] = '%sMP.build.macos-%s-%s-release-RsysPsys.macQAT' % (qtType.lower(), platform, coordsize)
dirQAT[(qtVer, "std", "d")] = '%sMP.build.macos-%s-debug-RsysPsys.macQAT' % (qtType.lower(), platform) dirQAT[(qtVer, "std", "d")] = '%sMP.build.macos-%s-%s-debug-RsysPsys.macQAT' % (qtType.lower(), platform, coordsize)
elif target == "ports": elif target == "ports":
dirQAT[(qtVer, "ports", "r")] = '%sMP.build.macos-%s-release-Rmp34Pmp313.macQAT' % (qtType.lower(), platform) dirQAT[(qtVer, "ports", "r")] = '%sMP.build.macos-%s-%s-release-Rmp34Pmp314.macQAT' % (qtType.lower(), platform, coordsize)
dirQAT[(qtVer, "ports", "d")] = '%sMP.build.macos-%s-debug-Rmp34Pmp313.macQAT' % (qtType.lower(), platform) dirQAT[(qtVer, "ports", "d")] = '%sMP.build.macos-%s-%s-debug-Rmp34Pmp314.macQAT' % (qtType.lower(), platform, coordsize)
elif target == "brew": elif target == "brew":
dirQAT[(qtVer, "brew", "r")] = '%sBrew.build.macos-%s-release-Rhb34Phb313.macQAT' % (qtType.lower(), platform) dirQAT[(qtVer, "brew", "r")] = '%sBrew.build.macos-%s-%s-release-Rhb34Phb314.macQAT' % (qtType.lower(), platform, coordsize)
dirQAT[(qtVer, "brew", "d")] = '%sBrew.build.macos-%s-debug-Rhb34Phb313.macQAT' % (qtType.lower(), platform) dirQAT[(qtVer, "brew", "d")] = '%sBrew.build.macos-%s-%s-debug-Rhb34Phb314.macQAT' % (qtType.lower(), platform, coordsize)
elif target == "brewHW": elif target == "brewHW":
dirQAT[(qtVer, "brewHW", "r")] = '%sBrew.build.macos-%s-release-RsysPhb311.macQAT' % (qtType.lower(), platform) dirQAT[(qtVer, "brewHW", "r")] = '%sBrew.build.macos-%s-%s-release-RsysPhb311.macQAT' % (qtType.lower(), platform, coordsize)
dirQAT[(qtVer, "brewHW", "d")] = '%sBrew.build.macos-%s-debug-RsysPhb311.macQAT' % (qtType.lower(), platform) dirQAT[(qtVer, "brewHW", "d")] = '%sBrew.build.macos-%s-%s-debug-RsysPhb311.macQAT' % (qtType.lower(), platform, coordsize)
elif target == "ana3": elif target == "ana3":
dirQAT[(qtVer, "ana3", "r")] = '%sAna3.build.macos-%s-release-Rana3Pana3.macQAT' % (qtType.lower(), platform) dirQAT[(qtVer, "ana3", "r")] = '%sAna3.build.macos-%s-%s-release-Rana3Pana3.macQAT' % (qtType.lower(), platform, coordsize)
dirQAT[(qtVer, "ana3", "d")] = '%sAna3.build.macos-%s-debug-Rana3Pana3.macQAT' % (qtType.lower(), platform) dirQAT[(qtVer, "ana3", "d")] = '%sAna3.build.macos-%s-%s-debug-Rana3Pana3.macQAT' % (qtType.lower(), platform, coordsize)
elif target == "brewA": elif target == "brewA":
dirQAT[(qtVer, "brewA", "r")] = '%sBrew.build.macos-%s-release-Rhb34Phbauto.macQAT' % (qtType.lower(), platform) dirQAT[(qtVer, "brewA", "r")] = '%sBrew.build.macos-%s-%s-release-Rhb34Phbauto.macQAT' % (qtType.lower(), platform, coordsize)
dirQAT[(qtVer, "brewA", "d")] = '%sBrew.build.macos-%s-debug-Rhb34Phbauto.macQAT' % (qtType.lower(), platform) dirQAT[(qtVer, "brewA", "d")] = '%sBrew.build.macos-%s-%s-debug-Rhb34Phbauto.macQAT' % (qtType.lower(), platform, coordsize)
elif target == "brewAHW": elif target == "brewAHW":
dirQAT[(qtVer, "brewAHW", "r")] = '%sBrew.build.macos-%s-release-RsysPhbauto.macQAT' % (qtType.lower(), platform) dirQAT[(qtVer, "brewAHW", "r")] = '%sBrew.build.macos-%s-%s-release-RsysPhbauto.macQAT' % (qtType.lower(), platform, coordsize)
dirQAT[(qtVer, "brewAHW", "d")] = '%sBrew.build.macos-%s-debug-RsysPhbauto.macQAT' % (qtType.lower(), platform) dirQAT[(qtVer, "brewAHW", "d")] = '%sBrew.build.macos-%s-%s-debug-RsysPhbauto.macQAT' % (qtType.lower(), platform, coordsize)
elif target == "pbrew": elif target == "pbrew":
dirQAT[(qtVer, "pbrew", "r")] = '%sMP.build.macos-%s-release-Rhb34Phb313.macQAT' % (qtType.lower(), platform) dirQAT[(qtVer, "pbrew", "r")] = '%sMP.build.macos-%s-%s-release-Rhb34Phb314.macQAT' % (qtType.lower(), platform, coordsize)
dirQAT[(qtVer, "pbrew", "d")] = '%sMP.build.macos-%s-debug-Rhb34Phb313.macQAT' % (qtType.lower(), platform) dirQAT[(qtVer, "pbrew", "d")] = '%sMP.build.macos-%s-%s-debug-Rhb34Phb314.macQAT' % (qtType.lower(), platform, coordsize)
elif target == "pbrewHW": elif target == "pbrewHW":
dirQAT[(qtVer, "pbrewHW", "r")] = '%sMP.build.macos-%s-release-RsysPhb311.macQAT' % (qtType.lower(), platform) dirQAT[(qtVer, "pbrewHW", "r")] = '%sMP.build.macos-%s-%s-release-RsysPhb311.macQAT' % (qtType.lower(), platform, coordsize)
dirQAT[(qtVer, "pbrewHW", "d")] = '%sMP.build.macos-%s-debug-RsysPhb311.macQAT' % (qtType.lower(), platform) dirQAT[(qtVer, "pbrewHW", "d")] = '%sMP.build.macos-%s-%s-debug-RsysPhb311.macQAT' % (qtType.lower(), platform, coordsize)
return dirQAT return dirQAT
@ -212,10 +216,11 @@ def Get_QAT_Directory( targetDic, platform ):
# @param[in] platform platform name # @param[in] platform platform name
# @param[in] srlDMG serial number of DMG # @param[in] srlDMG serial number of DMG
# @param[in] makeflag True to make; False to clean # @param[in] makeflag True to make; False to clean
# @param[in] coordsize coordinate size (default='C32')
# #
# @return a dictionary; key=(qtVer, mnemonic, bdType), value=build option list # @return a dictionary; key=(qtVer, mnemonic, bdType), value=build option list
#------------------------------------------------------------------------------ #------------------------------------------------------------------------------
def Get_Package_Options( targetDic, platform, srlDMG, makeflag ): def Get_Package_Options( targetDic, platform, srlDMG, makeflag, coordsize='C32' ):
packOp = dict() packOp = dict()
if makeflag: if makeflag:
@ -232,49 +237,49 @@ def Get_Package_Options( targetDic, platform, srlDMG, makeflag ):
for key in targetDic.keys(): for key in targetDic.keys():
target = targetDic[key] target = targetDic[key]
if target == "std": if target == "std":
packOp[(qtVer, "std", "r")] = [ '-p', 'ST-%sMP.pkg.macos-%s-release-RsysPsys' % (qtType.lower(), platform), packOp[(qtVer, "std", "r")] = [ '-p', 'ST-%sMP.pkg.macos-%s-%s-release-RsysPsys' % (qtType.lower(), platform, coordsize),
'-s', '%d' % srlDMG, '%s' % flag ] '-s', '%d' % srlDMG, '%s' % flag ]
packOp[(qtVer, "std", "d")] = [ '-p', 'ST-%sMP.pkg.macos-%s-debug-RsysPsys' % (qtType.lower(), platform), packOp[(qtVer, "std", "d")] = [ '-p', 'ST-%sMP.pkg.macos-%s-%s-debug-RsysPsys' % (qtType.lower(), platform, coordsize),
'-s', '%d' % srlDMG, '%s' % flag ] '-s', '%d' % srlDMG, '%s' % flag ]
elif target == "ports": elif target == "ports":
packOp[(qtVer, "ports", "r")] = [ '-p', 'LW-%sMP.pkg.macos-%s-release-Rmp34Pmp313' % (qtType.lower(), platform), packOp[(qtVer, "ports", "r")] = [ '-p', 'LW-%sMP.pkg.macos-%s-%s-release-Rmp34Pmp314' % (qtType.lower(), platform, coordsize),
'-s', '%d' % srlDMG, '%s' % flag ] '-s', '%d' % srlDMG, '%s' % flag ]
packOp[(qtVer, "ports", "d")] = [ '-p', 'LW-%sMP.pkg.macos-%s-debug-Rmp34Pmp313' % (qtType.lower(), platform), packOp[(qtVer, "ports", "d")] = [ '-p', 'LW-%sMP.pkg.macos-%s-%s-debug-Rmp34Pmp314' % (qtType.lower(), platform, coordsize),
'-s', '%d' % srlDMG, '%s' % flag ] '-s', '%d' % srlDMG, '%s' % flag ]
elif target == "brew": elif target == "brew":
packOp[(qtVer, "brew", "r")] = [ '-p', 'LW-%sBrew.pkg.macos-%s-release-Rhb34Phb313' % (qtType.lower(), platform), packOp[(qtVer, "brew", "r")] = [ '-p', 'LW-%sBrew.pkg.macos-%s-%s-release-Rhb34Phb314' % (qtType.lower(), platform, coordsize),
'-s', '%d' % srlDMG, '%s' % flag ] '-s', '%d' % srlDMG, '%s' % flag ]
packOp[(qtVer, "brew", "d")] = [ '-p', 'LW-%sBrew.pkg.macos-%s-debug-Rhb34Phb313' % (qtType.lower(), platform), packOp[(qtVer, "brew", "d")] = [ '-p', 'LW-%sBrew.pkg.macos-%s-%s-debug-Rhb34Phb314' % (qtType.lower(), platform, coordsize),
'-s', '%d' % srlDMG, '%s' % flag ] '-s', '%d' % srlDMG, '%s' % flag ]
elif target == "brewHW": elif target == "brewHW":
packOp[(qtVer, "brewHW", "r")] = [ '-p', 'HW-%sBrew.pkg.macos-%s-release-RsysPhb311' % (qtType.lower(), platform), packOp[(qtVer, "brewHW", "r")] = [ '-p', 'HW-%sBrew.pkg.macos-%s-%s-release-RsysPhb311' % (qtType.lower(), platform, coordsize),
'-s', '%d' % srlDMG, '%s' % flag ] '-s', '%d' % srlDMG, '%s' % flag ]
packOp[(qtVer, "brewHW", "d")] = [ '-p', 'HW-%sBrew.pkg.macos-%s-debug-RsysPhb311' % (qtType.lower(), platform), packOp[(qtVer, "brewHW", "d")] = [ '-p', 'HW-%sBrew.pkg.macos-%s-%s-debug-RsysPhb311' % (qtType.lower(), platform, coordsize),
'-s', '%d' % srlDMG, '%s' % flag ] '-s', '%d' % srlDMG, '%s' % flag ]
elif target == "ana3": elif target == "ana3":
packOp[(qtVer, "ana3", "r")] = [ '-p', 'LW-%sAna3.pkg.macos-%s-release-Rana3Pana3' % (qtType.lower(), platform), packOp[(qtVer, "ana3", "r")] = [ '-p', 'LW-%sAna3.pkg.macos-%s-%s-release-Rana3Pana3' % (qtType.lower(), platform, coordsize),
'-s', '%d' % srlDMG, '%s' % flag ] '-s', '%d' % srlDMG, '%s' % flag ]
packOp[(qtVer, "ana3", "d")] = [ '-p', 'LW-%sAna3.pkg.macos-%s-debug-Rana3Pana3' % (qtType.lower(), platform), packOp[(qtVer, "ana3", "d")] = [ '-p', 'LW-%sAna3.pkg.macos-%s-%s-debug-Rana3Pana3' % (qtType.lower(), platform, coordsize),
'-s', '%d' % srlDMG, '%s' % flag ] '-s', '%d' % srlDMG, '%s' % flag ]
elif target == "brewA": elif target == "brewA":
packOp[(qtVer, "brewA", "r")] = [ '-p', 'LW-%sBrew.pkg.macos-%s-release-Rhb34Phbauto' % (qtType.lower(), platform), packOp[(qtVer, "brewA", "r")] = [ '-p', 'LW-%sBrew.pkg.macos-%s-%s-release-Rhb34Phbauto' % (qtType.lower(), platform, coordsize),
'-s', '%d' % srlDMG, '%s' % flag ] '-s', '%d' % srlDMG, '%s' % flag ]
packOp[(qtVer, "brewA", "d")] = [ '-p', 'LW-%sBrew.pkg.macos-%s-debug-Rhb34Phbauto' % (qtType.lower(), platform), packOp[(qtVer, "brewA", "d")] = [ '-p', 'LW-%sBrew.pkg.macos-%s-%s-debug-Rhb34Phbauto' % (qtType.lower(), platform, coordsize),
'-s', '%d' % srlDMG, '%s' % flag ] '-s', '%d' % srlDMG, '%s' % flag ]
elif target == "brewAHW": elif target == "brewAHW":
packOp[(qtVer, "brewAHW", "r")] = [ '-p', 'HW-%sBrew.pkg.macos-%s-release-RsysPhbauto' % (qtType.lower(), platform), packOp[(qtVer, "brewAHW", "r")] = [ '-p', 'HW-%sBrew.pkg.macos-%s-%s-release-RsysPhbauto' % (qtType.lower(), platform, coordsize),
'-s', '%d' % srlDMG, '%s' % flag ] '-s', '%d' % srlDMG, '%s' % flag ]
packOp[(qtVer, "brewAHW", "d")] = [ '-p', 'HW-%sBrew.pkg.macos-%s-debug-RsysPhbauto' % (qtType.lower(), platform), packOp[(qtVer, "brewAHW", "d")] = [ '-p', 'HW-%sBrew.pkg.macos-%s-%s-debug-RsysPhbauto' % (qtType.lower(), platform, coordsize),
'-s', '%d' % srlDMG, '%s' % flag ] '-s', '%d' % srlDMG, '%s' % flag ]
elif target == "pbrew": elif target == "pbrew":
packOp[(qtVer, "pbrew", "r")] = [ '-p', 'LW-%sMP.pkg.macos-%s-release-Rhb34Phb313' % (qtType.lower(), platform), packOp[(qtVer, "pbrew", "r")] = [ '-p', 'LW-%sMP.pkg.macos-%s-%s-release-Rhb34Phb314' % (qtType.lower(), platform, coordsize),
'-s', '%d' % srlDMG, '%s' % flag ] '-s', '%d' % srlDMG, '%s' % flag ]
packOp[(qtVer, "pbrew", "d")] = [ '-p', 'LW-%sMP.pkg.macos-%s-debug-Rhb34Phb313' % (qtType.lower(), platform), packOp[(qtVer, "pbrew", "d")] = [ '-p', 'LW-%sMP.pkg.macos-%s-%s-debug-Rhb34Phb314' % (qtType.lower(), platform, coordsize),
'-s', '%d' % srlDMG, '%s' % flag ] '-s', '%d' % srlDMG, '%s' % flag ]
elif target == "pbrewHW": elif target == "pbrewHW":
packOp[(qtVer, "pbrewHW", "r")] = [ '-p', 'HW-%sMP.pkg.macos-%s-release-RsysPhb311' % (qtType.lower(), platform), packOp[(qtVer, "pbrewHW", "r")] = [ '-p', 'HW-%sMP.pkg.macos-%s-%s-release-RsysPhb311' % (qtType.lower(), platform, coordsize),
'-s', '%d' % srlDMG, '%s' % flag ] '-s', '%d' % srlDMG, '%s' % flag ]
packOp[(qtVer, "pbrewHW", "d")] = [ '-p', 'HW-%sMP.pkg.macos-%s-debug-RsysPhb311' % (qtType.lower(), platform), packOp[(qtVer, "pbrewHW", "d")] = [ '-p', 'HW-%sMP.pkg.macos-%s-%s-debug-RsysPhb311' % (qtType.lower(), platform, coordsize),
'-s', '%d' % srlDMG, '%s' % flag ] '-s', '%d' % srlDMG, '%s' % flag ]
return packOp return packOp
@ -299,7 +304,7 @@ def Parse_CommandLine_Arguments():
global DryRun # True for dry-run global DryRun # True for dry-run
platform = Test_My_Platform() platform = Test_My_Platform()
if platform in [ "Tahoe", "Sequoia", "Sonoma", "Ventura", "Monterey" ]: if platform in [ "GoldenGate", "Tahoe", "Sequoia", "Sonoma", "Ventura", "Monterey" ]:
targetopt = "0,1,2,13,4" targetopt = "0,1,2,13,4"
else: else:
targetopt = "" targetopt = ""
@ -308,7 +313,7 @@ def Parse_CommandLine_Arguments():
Usage += "----------------------------------------------------------------------------------------------------------\n" Usage += "----------------------------------------------------------------------------------------------------------\n"
Usage += " nightlyBuild.py [EXPERIMENTAL]\n" Usage += " nightlyBuild.py [EXPERIMENTAL]\n"
Usage += " << To execute the jobs for making KLayout's DMGs for\n" Usage += " << To execute the jobs for making KLayout's DMGs for\n"
Usage += " macOS Monterey, Ventura, Sonoma, or Sequoia >>\n" Usage += " macOS Monterey, Ventura, Sonoma, Sequoia, Tahoe, or GoldenGate >>\n"
Usage += "\n" Usage += "\n"
Usage += "$ [python] nightlyBuild.py\n" Usage += "$ [python] nightlyBuild.py\n"
Usage += " option & argument : comment on option if any | default value\n" Usage += " option & argument : comment on option if any | default value\n"
@ -343,7 +348,7 @@ def Parse_CommandLine_Arguments():
Usage += " (3) $ ./nightlyBuild.py --test |\n" Usage += " (3) $ ./nightlyBuild.py --test |\n"
Usage += " (4) $ ./nightlyBuild.py --check (confirm the QA Test results) |\n" Usage += " (4) $ ./nightlyBuild.py --check (confirm the QA Test results) |\n"
Usage += " (5) $ ./nightlyBuild.py --makedmg 1 |\n" Usage += " (5) $ ./nightlyBuild.py --makedmg 1 |\n"
Usage += " (6) $ ./nightlyBuild.py --upload '0.30.2' |\n" Usage += " (6) $ ./nightlyBuild.py --upload '0.30.9' |\n"
Usage += " (7) $ ./nightlyBuild.py --cleandmg 1 |\n" Usage += " (7) $ ./nightlyBuild.py --cleandmg 1 |\n"
Usage += "-----------------------------------------------------------------------------+----------------------------\n" Usage += "-----------------------------------------------------------------------------+----------------------------\n"
@ -434,7 +439,7 @@ def Parse_CommandLine_Arguments():
print(Usage) print(Usage)
sys.exit(0) sys.exit(0)
myPlatform = Test_My_Platform( [ 'Monterey', 'Ventura', 'Sonoma', 'Sequoia', 'Tahoe' ] ) myPlatform = Test_My_Platform( [ '', 'Monterey', 'Ventura', 'Sonoma', 'Sequoia', 'Tahoe' ] )
if myPlatform == "": if myPlatform == "":
print( "! Current platform is not [ 'Monterey', 'Ventura', 'Sonoma', 'Sequoia', 'Tahoe' ]" ) print( "! Current platform is not [ 'Monterey', 'Ventura', 'Sonoma', 'Sequoia', 'Tahoe' ]" )
print(Usage) print(Usage)

View File

@ -33,7 +33,7 @@ def SetGlobals():
Usage += "\n" Usage += "\n"
Usage += " option & argument : descriptions | default value\n" Usage += " option & argument : descriptions | default value\n"
Usage += " -------------------------------------------------------------------+---------------\n" Usage += " -------------------------------------------------------------------+---------------\n"
Usage += " <-v|--version <number>>: in ['3.11', '3.12','3.13'] | ''\n" Usage += " <-v|--version <number>>: in ['3.11', '3.12','3.13', '3.14'] | ''\n"
Usage += " [-u|-unlink] : unlink only | disabled\n" Usage += " [-u|-unlink] : unlink only | disabled\n"
Usage += " [-?|--?] : print this usage and exit | disabled\n" Usage += " [-?|--?] : print this usage and exit | disabled\n"
Usage += "----------------------------------------------------------------------+-----------------\n" Usage += "----------------------------------------------------------------------+-----------------\n"
@ -49,7 +49,7 @@ def Parse_CLI_Args():
p.add_option( '-v', '--version', p.add_option( '-v', '--version',
dest='version', dest='version',
help="python3 version=['3.11', '3.12', '3.13']" ) help="python3 version=['3.11', '3.12', '3.13', '3.14']" )
p.add_option( '-u', '--unlink', p.add_option( '-u', '--unlink',
action='store_true', action='store_true',
@ -74,7 +74,7 @@ def Parse_CLI_Args():
Version = opt.version Version = opt.version
UnlinkOnly = opt.unlink UnlinkOnly = opt.unlink
if not Version in [ '3.11', '3.12', '3.13' ]: if not Version in [ '3.11', '3.12', '3.13', '3.14' ]:
print( "! Unsupported Python 3 version <%s>" % Version ) print( "! Unsupported Python 3 version <%s>" % Version )
print(Usage) print(Usage)
sys.exit(0) sys.exit(0)