<p><b>@bencoman</b> commented on this pull request.</p>

<hr>

<p>In <a href="https://github.com/OpenSmalltalk/opensmalltalk-vm/pull/312#discussion_r238049872">CMakeLists.txt</a>:</p>
<pre style='color:#555'>> @@ -2,6 +2,15 @@
 cmake_minimum_required(VERSION 3.1)
 project(OpenSmalltalkVM)
 
+# The following is temporary while understanding/debugging CMake build.
+message("START VARIABLES (A)")
+get_cmake_property(_variableNames VARIABLES)
+list (SORT _variableNames)
+foreach (_variableName ${_variableNames})
+    message(STATUS "${_variableName}=${${_variableName}}")
+endforeach()
+message("END VARIABLES (A)")
+
</pre>
<p>Ignore lines 5-13, they were just adding verbosity for debugging</p>

<hr>

<p>In <a href="https://github.com/OpenSmalltalk/opensmalltalk-vm/pull/312#discussion_r238049906">platforms/minheadless/windows/sqPlatformSpecific-Win32.c</a>:</p>
<pre style='color:#555'>> @@ -77,7 +77,7 @@ static void printCrashDebugInformation(LPEXCEPTION_POINTERS exp);
 #define PROCESS_PER_MONITOR_DPI_AWARE 2
 #endif
 
-typedef HRESULT WINAPI (*SetProcessDpiAwarenessFunctionPointer) (int awareness);
+typedef HRESULT (WINAPI *SetProcessDpiAwarenessFunctionPointer) (int awareness);
</pre>
<p>I see this is already covered in <a class="issue-link js-issue-link" data-error-text="Failed to load issue title" data-id="386385960" data-permission-text="Issue title is private" data-url="https://github.com/OpenSmalltalk/opensmalltalk-vm/issues/311" data-hovercard-type="pull_request" data-hovercard-url="/OpenSmalltalk/opensmalltalk-vm/pull/311/hovercard" href="https://github.com/OpenSmalltalk/opensmalltalk-vm/pull/311">#311</a></p>

<hr>

<p>In <a href="https://github.com/OpenSmalltalk/opensmalltalk-vm/pull/312#discussion_r238050105">CMakeLists.txt</a>:</p>
<pre style='color:#555'>> @@ -530,6 +540,15 @@ endif()
 
 add_library(${VM_LIBRARY_NAME} ${VM_CORE_LIBRARY_TYPE} ${VM_SOURCES} ${VM_INTERNAL_PLUGIN_SOURCES})
 
+# The following is temporary while understanding/debugging CMake build.
+message("START VARIABLES (B)")
+get_cmake_property(_variableNames VARIABLES)
+list (SORT _variableNames)
+foreach (_variableName ${_variableNames})
+    message(STATUS "${_variableName}=${${_variableName}}")
+endforeach()
+message("END VARIABLES (B)")
+
</pre>
<p>Ignore lines 543-551, they were just adding verbosity for debugging</p>

<hr>

<p>In <a href="https://github.com/OpenSmalltalk/opensmalltalk-vm/pull/312#discussion_r238060351">platforms/minheadless/windows/sqWin32Main.c</a>:</p>
<pre style='color:#555'>> @@ -28,6 +28,7 @@
  */
 
 #define WIN32_LEAN_AND_MEAN
+#define BUILD_VM_CORE
</pre>
<p>Not required per Ronie's comment.  It was to work around an unknown symbol "_imp_osvm_main", which BUILD_OSVM_STATIC fixed already.</p>

<hr>

<p>In <a href="https://github.com/OpenSmalltalk/opensmalltalk-vm/pull/312#discussion_r238060386">platforms/minheadless/windows/sqPlatformSpecific-Win32.h</a>:</p>
<pre style='color:#555'>> @@ -114,7 +114,7 @@ size_t sqImageFileWrite(const void *ptr, size_t sz, size_t count, sqImageFile h)
 error "Not Win32!"
 #endif /* WIN32 */
 
-int ioSetCursorARGB(sqInt bitsIndex, sqInt w, sqInt h, sqInt x, sqInt y);
+sqInt ioSetCursorARGB(sqInt bitsIndex, sqInt w, sqInt h, sqInt x, sqInt y);
</pre>
<p>Required. Latest Cog branch minheadless/x64 had the same compile error. Including this change only let the build complete.</p>

<hr>

<p>In <a href="https://github.com/OpenSmalltalk/opensmalltalk-vm/pull/312#discussion_r238060560">platforms/minheadless/windows/sqPlatformSpecific-Win32.c</a>:</p>
<pre style='color:#555'>> @@ -115,7 +115,12 @@ void
 ioInitPlatformSpecific(void)
 {
     /* Setup the FPU */
-    _controlfp(FPU_DEFAULT, _MCW_EM | _MCW_RC | _MCW_PC | _MCW_IC);
+       /**** 2018.08.07.BenComan TODO, help required.
+        **** x64 does not support _MCW_PC or _MCW_IC per https://msdn.microsoft.com/en-us/library/e9b52ceh.aspx
+        ****/
+       //Original Line// _controlfp(FPU_DEFAULT, _MCW_EM | _MCW_RC | _MCW_PC | _MCW_IC); 
+       _controlfp(FPU_DEFAULT, _MCW_EM | _MCW_RC);
+
</pre>
<p>Required. I've included this per Ronie's comment. Fixes a runtime error.</p>

<hr>

<p>In <a href="https://github.com/OpenSmalltalk/opensmalltalk-vm/pull/312#discussion_r238060606">platforms/minheadless/common/sqMain.c</a>:</p>
<pre style='color:#555'>> @@ -25,6 +25,7 @@
  *
  * Author: roniesalg@gmail.com
  */
+#define BUILD_VM_CORE
</pre>
<p>Not required per Ronie's comment.  It was to work around an unknown symbol "_imp_osvm_main", which BUILD_OSVM_STATIC fixed already.</p>

<hr>

<p>In <a href="https://github.com/OpenSmalltalk/opensmalltalk-vm/pull/312#discussion_r238060691">platforms/Cross/plugins/IA32ABI/xabicc.c</a>:</p>
<pre style='color:#555'>> @@ -5,7 +5,7 @@
  * The plugin is misnamed.  It should be the AlienPlugin, but its history
  * dictates otherwise.
  */
-#if i386|i486|i586|i686
+#if i386|i486|i586|i686|_M_IX86
</pre>
<p>Not required. Already fixed by PR <a class="issue-link js-issue-link" data-error-text="Failed to load issue title" data-id="386385960" data-permission-text="Issue title is private" data-url="https://github.com/OpenSmalltalk/opensmalltalk-vm/issues/311" data-hovercard-type="pull_request" data-hovercard-url="/OpenSmalltalk/opensmalltalk-vm/pull/311/hovercard" href="https://github.com/OpenSmalltalk/opensmalltalk-vm/pull/311">#311</a> using...<br>
<code>#if defined(_M_I386) || defined(_X86_) || defined(i386) || defined(i486) || defined(i586) || defined(i686) || defined(__i386__) || defined(__386__) || defined(X86) || defined(I386)</code></p>

<hr>

<p>In <a href="https://github.com/OpenSmalltalk/opensmalltalk-vm/pull/312#discussion_r238060762">platforms/Cross/plugins/IA32ABI/ia32abicc.c</a>:</p>
<pre style='color:#555'>> @@ -8,7 +8,7 @@
 /* null if compiled on other than x86, to get around gnu make bugs or
  * misunderstandings on our part.
  */
-#if i386|i486|i586|i686
+#if i386|i486|i586|i686|_M_IX86
</pre>
<p>Not required. Already fixed by PR <a class="issue-link js-issue-link" data-error-text="Failed to load issue title" data-id="386385960" data-permission-text="Issue title is private" data-url="https://github.com/OpenSmalltalk/opensmalltalk-vm/issues/311" data-hovercard-type="pull_request" data-hovercard-url="/OpenSmalltalk/opensmalltalk-vm/pull/311/hovercard" href="https://github.com/OpenSmalltalk/opensmalltalk-vm/pull/311">#311</a> using...<br>
<code>#if defined(_M_I386) || defined(_X86_) || defined(i386) || defined(i486) || defined(i586) || defined(i686) || defined(__i386__) || defined(__386__) || defined(X86) || defined(I386)</code></p>

<hr>

<p>In <a href="https://github.com/OpenSmalltalk/opensmalltalk-vm/pull/312#discussion_r238061066">platforms/Cross/plugins/IA32ABI/x64win64abicc.c</a>:</p>
<pre style='color:#555'>> @@ -38,6 +38,9 @@ extern
 #endif 
 struct VirtualMachine* interpreterProxy;
 
+#ifdef _MSC_VER
+# define alloca _alloca
+#endif
</pre>
<p>Required. Solves MSVC build error...<br>
LNK2019 unresolved external symbol 'alloca' referenced in function callIA32IntegralReturn  -- File PharoVMCore.lib(xabicc.c.obj)</p>
<p>Visual Studio 2017" has no "alloca" only "_alloca"<br>
<a href="https://docs.microsoft.com/en-us/cpp/c-runtime-library/reference/alloca" rel="nofollow">https://docs.microsoft.com/en-us/cpp/c-runtime-library/reference/alloca</a></p>

<p style="font-size:small;-webkit-text-size-adjust:none;color:#666;">—<br />You are receiving this because you are subscribed to this thread.<br />Reply to this email directly, <a href="https://github.com/OpenSmalltalk/opensmalltalk-vm/pull/312#pullrequestreview-180508863">view it on GitHub</a>, or <a href="https://github.com/notifications/unsubscribe-auth/AhLyWzBO4Wo5BXBhFfPUv4v_dB6zBeoXks5u0njlgaJpZM4Y8rne">mute the thread</a>.<img src="https://github.com/notifications/beacon/AhLyWw2xhlyAV_xkKveDM0fc0qtwtC4pks5u0njlgaJpZM4Y8rne.gif" height="1" width="1" alt="" /></p>
<script type="application/json" data-scope="inboxmarkup">{"api_version":"1.0","publisher":{"api_key":"05dde50f1d1a384dd78767c55493e4bb","name":"GitHub"},"entity":{"external_key":"github/OpenSmalltalk/opensmalltalk-vm","title":"OpenSmalltalk/opensmalltalk-vm","subtitle":"GitHub repository","main_image_url":"https://assets-cdn.github.com/images/email/message_cards/header.png","avatar_image_url":"https://assets-cdn.github.com/images/email/message_cards/avatar.png","action":{"name":"Open in GitHub","url":"https://github.com/OpenSmalltalk/opensmalltalk-vm"}},"updates":{"snippets":[{"icon":"PERSON","message":"@bencoman commented on #312"}],"action":{"name":"View Pull Request","url":"https://github.com/OpenSmalltalk/opensmalltalk-vm/pull/312#pullrequestreview-180508863"}}}</script>
<script type="application/ld+json">[
{
"@context": "http://schema.org",
"@type": "EmailMessage",
"potentialAction": {
"@type": "ViewAction",
"target": "https://github.com/OpenSmalltalk/opensmalltalk-vm/pull/312#pullrequestreview-180508863",
"url": "https://github.com/OpenSmalltalk/opensmalltalk-vm/pull/312#pullrequestreview-180508863",
"name": "View Pull Request"
},
"description": "View this Pull Request on GitHub",
"publisher": {
"@type": "Organization",
"name": "GitHub",
"url": "https://github.com"
}
},
{
"@type": "MessageCard",
"@context": "http://schema.org/extensions",
"hideOriginalBody": "false",
"originator": "AF6C5A86-E920-430C-9C59-A73278B5EFEB",
"title": "@bencoman commented on 312",
"sections": [
{
"text": "",
"activityTitle": "**Ben Coman**",
"activityImage": "https://assets-cdn.github.com/images/email/message_cards/avatar.png",
"activitySubtitle": "@bencoman",
"facts": [

]
}
],
"potentialAction": [
{
"targets": [
{
"os": "default",
"uri": "https://github.com/OpenSmalltalk/opensmalltalk-vm/pull/312#pullrequestreview-180508863"
}
],
"@type": "OpenUri",
"name": "View on GitHub"
},
{
"name": "Unsubscribe",
"@type": "HttpPOST",
"target": "https://api.github.com",
"body": "{\n\"commandName\": \"MuteNotification\",\n\"threadId\": 418560478\n}"
}
],
"themeColor": "26292E"
}
]</script>