Merge pull request #362 from dicej/master

StringWriter.getBuffer, System.mapLibraryName, and makefile cleanup
This commit is contained in:
Joshua Warner 2014-10-29 08:55:52 -06:00
commit adca99b0ae
3 changed files with 7 additions and 3 deletions

View File

@ -46,7 +46,7 @@
#define SO_PREFIX "lib" #define SO_PREFIX "lib"
#ifdef __APPLE__ #ifdef __APPLE__
#define SO_SUFFIX ".jnilib" #define SO_SUFFIX ".dylib"
#include <TargetConditionals.h> #include <TargetConditionals.h>
#if !TARGET_IPHONE_SIMULATOR && !TARGET_OS_IPHONE #if !TARGET_IPHONE_SIMULATOR && !TARGET_OS_IPHONE
#include <CoreServices/CoreServices.h> #include <CoreServices/CoreServices.h>

View File

@ -11,7 +11,7 @@
package java.io; package java.io;
public class StringWriter extends Writer { public class StringWriter extends Writer {
private final StringBuilder out = new StringBuilder(); private final StringBuffer out = new StringBuffer();
public void write(char[] b, int offset, int length) throws IOException { public void write(char[] b, int offset, int length) throws IOException {
out.append(b, offset, length); out.append(b, offset, length);
@ -24,4 +24,8 @@ public class StringWriter extends Writer {
public void flush() throws IOException { } public void flush() throws IOException { }
public void close() throws IOException { } public void close() throws IOException { }
public StringBuffer getBuffer() {
return out;
}
} }

View File

@ -67,7 +67,7 @@ ifeq ($(filter x86_64 i386 arm,$(arch)),)
endif endif
ifeq ($(platform),darwin) ifeq ($(platform),darwin)
x := $(error "please use 'platform=macosx' or 'platform=ios' instead of 'platform=$platform'") x := $(error "please use 'platform=macosx' or 'platform=ios' instead of 'platform=$(platform)'")
endif endif
ifneq ($(ios),) ifneq ($(ios),)