Skip to content

Commit

Permalink
Merge pull request #4204 from nbhuiyan/fix-plinux
Browse files Browse the repository at this point in the history
Add missing platform check for defining NASM_ASSEMBLER macro
  • Loading branch information
0xdaryl authored Jan 8, 2019
2 parents b5fb4ca + e60752d commit 6be82a8
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 4 deletions.
4 changes: 2 additions & 2 deletions runtime/compiler/runtime/asmprotos.h
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*******************************************************************************
* Copyright (c) 2000, 2018 IBM Corp. and others
* Copyright (c) 2000, 2019 IBM Corp. and others
*
* This program and the accompanying materials are made available under
* the terms of the Eclipse Public License 2.0 which accompanies this
Expand Down Expand Up @@ -64,7 +64,7 @@ extern "C" {
* is set for OS variants that currently use NASM and is used to
* decide the version of helper names to use.
*/
#if defined(OSX) || (defined(LINUX) && defined(TR_HOST_64BIT))
#if defined(OSX) || (defined(LINUX) && defined(TR_HOST_X86) && defined(TR_HOST_64BIT))
#define NASM_ASSEMBLER
#endif

Expand Down
8 changes: 6 additions & 2 deletions runtime/jilgen/jilconsts.c
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/*******************************************************************************
* Copyright (c) 1991, 2018 IBM Corp. and others
* Copyright (c) 1991, 2019 IBM Corp. and others
*
* This program and the accompanying materials are made available under
* the terms of the Eclipse Public License 2.0 which accompanies this
Expand Down Expand Up @@ -76,7 +76,11 @@ createConstant(OMRPortLibrary *OMRPORTLIB, char const *name, UDATA value)
return omrstr_printf(line, sizeof(line), "#define %s %zu\n", name, value);
#elif defined(LINUX) /* J9VM_ARCH_POWER || J9VM_ARCH_ARM */
#if defined(J9VM_ENV_DATA64)
return omrstr_printf(line, sizeof(line), "%%define %s %zu\n", name, value);
#if defined(J9VM_ARCH_X86)
return omrstr_printf(line, sizeof(line), "%%define %s %zu\n", name, value);
#else /* J9VM_ARCH_X86 */
return omrstr_printf(line, sizeof(line), "%s = %zu\n", name, value);
#endif /* J9VM_ARCH_X86 */
#else /* J9VM_ENV_DATA64 */
return omrstr_printf(line, sizeof(line), "%s = %zu\n", name, value);
#endif
Expand Down

0 comments on commit 6be82a8

Please sign in to comment.