Mercurial > hg > graal-compiler
comparison src/cpu/x86/vm/jni_x86.h @ 10231:58bb870a0cbd
8009729: Refix hotspot jni_<cpu>.h JNIEXPORT and JNIIMPORT definitions to match jdk version
Summary: Update JNIEXPORT and JNIIMPORT to work with other compilers that don't necessarily have the __attribute__ type qualifier
Reviewed-by: dholmes, dcubed, coleenp
author | emc |
---|---|
date | Tue, 07 May 2013 13:45:59 -0400 |
parents | 203f64878aab |
children |
comparison
equal
deleted
inserted
replaced
10229:f6a055fcf47d | 10231:58bb870a0cbd |
---|---|
26 #ifndef _JAVASOFT_JNI_MD_H_ | 26 #ifndef _JAVASOFT_JNI_MD_H_ |
27 #define _JAVASOFT_JNI_MD_H_ | 27 #define _JAVASOFT_JNI_MD_H_ |
28 | 28 |
29 #if defined(SOLARIS) || defined(LINUX) || defined(_ALLBSD_SOURCE) | 29 #if defined(SOLARIS) || defined(LINUX) || defined(_ALLBSD_SOURCE) |
30 | 30 |
31 #if defined(__GNUC__) && (__GNUC__ > 4) || (__GNUC__ == 4) && (__GNUC_MINOR__ > 2) | 31 |
32 // Note: please do not change these without also changing jni_md.h in the JDK | |
33 // repository | |
34 #ifndef __has_attribute | |
35 #define __has_attribute(x) 0 | |
36 #endif | |
37 #if (defined(__GNUC__) && ((__GNUC__ > 4) || (__GNUC__ == 4) && (__GNUC_MINOR__ > 2))) || __has_attribute(visibility) | |
32 #define JNIEXPORT __attribute__((visibility("default"))) | 38 #define JNIEXPORT __attribute__((visibility("default"))) |
33 #define JNIIMPORT __attribute__((visibility("default"))) | 39 #define JNIIMPORT __attribute__((visibility("default"))) |
34 #else | 40 #else |
35 #define JNIEXPORT | 41 #define JNIEXPORT |
36 #define JNIIMPORT | 42 #define JNIIMPORT |