Fixes to WP8/WinRT support

This commit is contained in:
Alexey Pelykh 2013-01-29 14:21:02 +02:00
parent 1590bd0554
commit 4840f4a019
4 changed files with 9 additions and 16 deletions

View File

@ -547,7 +547,8 @@ Java_java_io_File_lastModified(JNIEnv* e, jclass, jstring path)
string_t chars = getChars(e, path); string_t chars = getChars(e, path);
if (chars) { if (chars) {
#ifdef PLATFORM_WINDOWS #ifdef PLATFORM_WINDOWS
# error "Implementation of last modified :)" # pragma message("Implementation of last modified")
return 0;
#else #else
struct stat st; struct stat st;
if (stat(chars, &st)) { if (stat(chars, &st)) {

View File

@ -618,7 +618,7 @@ ifeq ($(platform),wp8)
# Environment variable WP8_SDK not found. It should be something like # Environment variable WP8_SDK not found. It should be something like
# "C:\Program Files[ (x86)]\Microsoft Visual Studio 11.0\VC\WPSDK\WP80" # "C:\Program Files[ (x86)]\Microsoft Visual Studio 11.0\VC\WPSDK\WP80"
# TODO: Lookup in SOFTWARE\Microsoft\Microsoft SDKs\WindowsPhone\v8.0 # TODO: Lookup in SOFTWARE\Microsoft\Microsoft SDKs\WindowsPhone\v8.0
WP80_SDK = C:\$(programFiles)\Microsoft Visual Studio 11.0\VC\WPSDK\WP80 WP80_SDK = $(MSVS_ROOT)\VC\WPSDK\WP80
endif endif
ifeq ($(WP80_KIT),) ifeq ($(WP80_KIT),)
# Environment variable WP8_KIT not found. It should be something like # Environment variable WP8_KIT not found. It should be something like
@ -670,8 +670,6 @@ ifeq ($(platform),wp8)
asm-output = -o $(1) asm-output = -o $(1)
asm-input = $(1) asm-input = $(1)
machine_type = ARM machine_type = ARM
bootimage-symbols = binary_bootimage_bin_start:binary_bootimage_bin_end
codeimage-symbols = binary_codeimage_bin_start:binary_codeimage_bin_end
endif endif
ifeq ($(arch),i386) ifeq ($(arch),i386)
wp8_arch = wp8_arch =

View File

@ -1917,26 +1917,20 @@ public:
exit(1); exit(1);
} }
# if AVIAN_TARGET_FORMAT != AVIAN_FORMAT_PE
# define SYMBOL_PREFIX "_"
# else
# define SYMBOL_PREFIX
# endif
if(!bootimageStart) { if(!bootimageStart) {
bootimageStart = strdup(SYMBOL_PREFIX"binary_bootimage_bin_start"); bootimageStart = strdup("_binary_bootimage_bin_start");
} }
if(!bootimageEnd) { if(!bootimageEnd) {
bootimageEnd = strdup(SYMBOL_PREFIX"binary_bootimage_bin_end"); bootimageEnd = strdup("_binary_bootimage_bin_end");
} }
if(!codeimageStart) { if(!codeimageStart) {
codeimageStart = strdup(SYMBOL_PREFIX"binary_codeimage_bin_start"); codeimageStart = strdup("_binary_codeimage_bin_start");
} }
if(!codeimageEnd) { if(!codeimageEnd) {
codeimageEnd = strdup(SYMBOL_PREFIX"binary_codeimage_bin_end"); codeimageEnd = strdup("_binary_codeimage_bin_end");
} }
} }

View File

@ -34,10 +34,10 @@
WaitForSingleObjectEx((hHandle), (dwMilliseconds), FALSE) WaitForSingleObjectEx((hHandle), (dwMilliseconds), FALSE)
#define CreateEvent(lpEventAttributes, bManualReset, bInitialState, lpName) \ #define CreateEvent(lpEventAttributes, bManualReset, bInitialState, lpName) \
CreateEventEx((lpEventAttributes), (lpName), ((bManualReset)?CREATE_EVENT_MANUAL_RESET:0)|((bInitialState)?CREATE_EVENT_INITIAL_SET:0), EVENT_MODIFY_STATE) CreateEventEx((lpEventAttributes), (lpName), ((bManualReset)?CREATE_EVENT_MANUAL_RESET:0)|((bInitialState)?CREATE_EVENT_INITIAL_SET:0), EVENT_ALL_ACCESS)
#define CreateMutex(lpEventAttributes, bInitialOwner, lpName) \ #define CreateMutex(lpEventAttributes, bInitialOwner, lpName) \
CreateMutexEx((lpEventAttributes), (lpName), (bInitialOwner)?CREATE_MUTEX_INITIAL_OWNER:0, MUTEX_MODIFY_STATE) CreateMutexEx((lpEventAttributes), (lpName), (bInitialOwner)?CREATE_MUTEX_INITIAL_OWNER:0, MUTEX_ALL_ACCESS)
#include "thread-emulation.h" #include "thread-emulation.h"