<pre style='margin:0'>
Ryan Schmidt (ryandesign) pushed a commit to branch master
in repository macports-ports.
</pre>
<p><a href="https://github.com/macports/macports-ports/commit/93841773d08ebcce47c371e1efe1d645ee7dfac0">https://github.com/macports/macports-ports/commit/93841773d08ebcce47c371e1efe1d645ee7dfac0</a></p>
<pre style="white-space: pre; background: #F8F8F8"><span style='display:block; white-space:pre;color:#808000;'>commit 93841773d08ebcce47c371e1efe1d645ee7dfac0
</span>Author: Ryan Schmidt <ryandesign@macports.org>
AuthorDate: Mon Jul 2 22:40:27 2018 -0500
<span style='display:block; white-space:pre;color:#404040;'> minivmac*: Don't require discrete GPU for bootstrap
</span><span style='display:block; white-space:pre;color:#404040;'>
</span><span style='display:block; white-space:pre;color:#404040;'> This code is unfinished and insufficiently tested so only use it for the
</span><span style='display:block; white-space:pre;color:#404040;'> short-running bootstrap variation, not for variations built for the user.
</span>---
emulators/minivmac-devel/Portfile | 5 +++
.../files/AutomaticGraphicsSwitching.patch | 37 ++++++++++++++++++++++
emulators/minivmac/Portfile | 3 ++
.../files/AutomaticGraphicsSwitching.patch | 37 ++++++++++++++++++++++
4 files changed, 82 insertions(+)
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/emulators/minivmac-devel/Portfile b/emulators/minivmac-devel/Portfile
</span><span style='display:block; white-space:pre;color:#808080;'>index b34e17d..1cc7a93 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/emulators/minivmac-devel/Portfile
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/emulators/minivmac-devel/Portfile
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -297,6 +297,11 @@ if {${my_subport} eq ${my_name}} {
</span> system -W ${build.dir} "tar xf '${my_src_tarball}'"
move ${build.dir}/${my_variation} ${build.dir}/${my_variation_dir}
<span style='display:block; white-space:pre;background:#e0ffe0;'>+ if {${my_subport} eq "${my_name}-bootstrap"} {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # Don't require the discrete GPU.
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ system -W ${build.dir}/${my_variation_dir} "patch -p0 < ${filespath}/AutomaticGraphicsSwitching.patch"
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ }
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span> # Use the right compiler.
reinplace "s|gcc|${configure.cc}|g" ${build.dir}/${my_variation_dir}/Makefile
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/emulators/minivmac-devel/files/AutomaticGraphicsSwitching.patch b/emulators/minivmac-devel/files/AutomaticGraphicsSwitching.patch
</span>new file mode 100644
<span style='display:block; white-space:pre;color:#808080;'>index 0000000..20be305
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>--- /dev/null
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/emulators/minivmac-devel/files/AutomaticGraphicsSwitching.patch
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -0,0 +1,37 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+https://www.gryphel.com/c/mail/v8.html#m0
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+https://developer.apple.com/library/archive/qa/qa1734/
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+https://developer.apple.com/library/archive/technotes/tn2229/
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+--- src/Info.plist.orig 2018-06-22 05:58:58.000000000 -0500
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++++ src/Info.plist 2018-06-22 06:01:11.000000000 -0500
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -3,4 +3,6 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ <plist version="1.0">
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ <dict>
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ <key>NSSupportsAutomaticGraphicsSwitching</key>
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ <true/>
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ <key>CFBundleDevelopmentRegion</key>
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ <string>English</string>
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+--- src/OSGLUCCO.m.orig 2018-06-09 03:53:21.000000000 -0500
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++++ src/OSGLUCCO.m 2018-06-22 06:33:03.000000000 -0500
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -51,6 +51,8 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ typedef struct __CFError * CFErrorRef;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#define NSOpenGLPFAAllowOfflineRenderers (NSOpenGLPixelFormatAttribute)96
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ #endif
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ #if MAC_OS_X_VERSION_10_6 > MAC_OS_X_VERSION_MAX_ALLOWED
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -3160,2 +3162,3 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ NSOpenGLPixelFormatAttribute attr[] = {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ NSOpenGLPFAAllowOfflineRenderers,
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ 0};
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -3164,2 +3167,9 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ fmt = [[NSOpenGLPixelFormat alloc] initWithAttributes:attr];
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#if MAC_OS_X_VERSION_10_5 > MAC_OS_X_VERSION_MIN_REQUIRED
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ if (nil == fmt) {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ /* NSOpenGLPFAAllowOfflineRenderers is not supported; remove it */
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ attr[0] = (NSOpenGLPixelFormatAttribute)0;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ fmt = [[NSOpenGLPixelFormat alloc] initWithAttributes:attr];
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ }
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#endif
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if (nil == fmt) {
</span><span style='display:block; white-space:pre;color:#808080;'>diff --git a/emulators/minivmac/Portfile b/emulators/minivmac/Portfile
</span><span style='display:block; white-space:pre;color:#808080;'>index 9b5f842..6cad0f9 100644
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>--- a/emulators/minivmac/Portfile
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/emulators/minivmac/Portfile
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -285,6 +285,9 @@ if {${my_subport} eq ${my_name}} {
</span> # are written to the "out" directory instead of
# prompting for a location.
system -W ${build.dir}/${my_variation_dir} "patch -p0 < ${filespath}/SaveDialogDisable.patch"
<span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ # Don't require the discrete GPU.
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ system -W ${build.dir}/${my_variation_dir} "patch -p0 < ${filespath}/AutomaticGraphicsSwitching.patch"
</span> }
# Use the right compiler.
<span style='display:block; white-space:pre;color:#808080;'>diff --git a/emulators/minivmac/files/AutomaticGraphicsSwitching.patch b/emulators/minivmac/files/AutomaticGraphicsSwitching.patch
</span>new file mode 100644
<span style='display:block; white-space:pre;color:#808080;'>index 0000000..20be305
</span><span style='display:block; white-space:pre;background:#ffe0e0;'>--- /dev/null
</span><span style='display:block; white-space:pre;background:#e0e0ff;'>+++ b/emulators/minivmac/files/AutomaticGraphicsSwitching.patch
</span><span style='display:block; white-space:pre;background:#e0e0e0;'>@@ -0,0 +1,37 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+https://www.gryphel.com/c/mail/v8.html#m0
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+https://developer.apple.com/library/archive/qa/qa1734/
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+https://developer.apple.com/library/archive/technotes/tn2229/
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+--- src/Info.plist.orig 2018-06-22 05:58:58.000000000 -0500
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++++ src/Info.plist 2018-06-22 06:01:11.000000000 -0500
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -3,4 +3,6 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ <plist version="1.0">
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ <dict>
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ <key>NSSupportsAutomaticGraphicsSwitching</key>
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ <true/>
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ <key>CFBundleDevelopmentRegion</key>
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ <string>English</string>
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+--- src/OSGLUCCO.m.orig 2018-06-09 03:53:21.000000000 -0500
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++++ src/OSGLUCCO.m 2018-06-22 06:33:03.000000000 -0500
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -51,6 +51,8 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ typedef struct __CFError * CFErrorRef;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#define NSOpenGLPFAAllowOfflineRenderers (NSOpenGLPixelFormatAttribute)96
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ #endif
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ #if MAC_OS_X_VERSION_10_6 > MAC_OS_X_VERSION_MAX_ALLOWED
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -3160,2 +3162,3 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ NSOpenGLPixelFormatAttribute attr[] = {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ NSOpenGLPFAAllowOfflineRenderers,
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ 0};
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+@@ -3164,2 +3167,9 @@
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ fmt = [[NSOpenGLPixelFormat alloc] initWithAttributes:attr];
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#if MAC_OS_X_VERSION_10_5 > MAC_OS_X_VERSION_MIN_REQUIRED
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ if (nil == fmt) {
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ /* NSOpenGLPFAAllowOfflineRenderers is not supported; remove it */
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ attr[0] = (NSOpenGLPixelFormatAttribute)0;
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ fmt = [[NSOpenGLPixelFormat alloc] initWithAttributes:attr];
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++ }
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>++#endif
</span><span style='display:block; white-space:pre;background:#e0ffe0;'>+ if (nil == fmt) {
</span></pre><pre style='margin:0'>
</pre>