Commit Graph

409 Commits

Author SHA1 Message Date
Joel Dice
443097f3bc add support for Xcode 4.3 2012-03-07 08:55:01 -07:00
Matt Weaver
6a20d0289c switching to armv7 2012-03-02 16:00:08 -07:00
Joel Dice
b5fda8ee13 use avian.http.Handler for http(s) URLs, not avian.file.Handler 2012-02-27 13:38:47 -07:00
Joel Dice
574a8ea1e2 Merge branch 'master' into prv-ga-merge 2012-02-27 13:28:06 -07:00
Joel Dice
d09eb3c671 Merge remote branch 'oss/master' 2012-02-22 10:08:14 -07:00
Seth Goings
e849d8f9c9 Updates to .gitignore to get rid of any possibility of checking in binaries in lib/distrib directories, and generalized method of setting location of win32 and win64 libs. 2012-02-20 16:25:37 -07:00
Joel Dice
999e90c332 fix MSVC build 2012-02-16 18:22:11 -07:00
Joshua Warner
a1c5cccd96 undo accidental modification of makefile 2012-02-13 10:04:13 -07:00
Joshua Warner
bbb4529752 implement File.setExecutable(), File.canExecute(), and File.createTempFile() 2012-02-09 14:23:24 -07:00
Joshua Warner
edc768f837 implement File.setExecutable(), File.canExecute(), and File.createTempFile() 2012-02-09 14:04:42 -07:00
Joel Dice
d29513c653 fix Avian_sun_misc_Unsafe_compareAndSwapLong for platforms without atomicCompareAndSwap64
We never define atomicCompareAndSwap64 for ARM or PowerPC, and
apparently only very recent ARM chips support it, so we must fall back
to synchronization-based emulation.
2012-01-15 10:02:36 -07:00
Joel Dice
1c85ea8a6e fix GCC 4.6 LTO build
On Ubuntu 11.10, the optimized build was breaking, apparently because
it was eliminating most of the symbols defined in assembly code
(e.g. vmJump) as unreachable when linking libjvm.so, which left
avian-dynamic unlinkable due to an unresolved symbol.

The solution in this commit is to export makeSystem and makeFinder
from libjvm.so rather than build redundant versions of finder.cpp and
posix.cpp/windows.cpp into avian-dynamic like we've been doing.  This
avoids the whole problem of vmJump reachability and reduces the size
of avian-dynamic at the same time.

This commit also turns off LTO for the avian-dynamic link since we get
odd undefined symbol errors about libc-defined symbols otherwise.
This may merit future investigation, but avian-dynamic is so small and
simple that there's no need to optimize it anyway.
2011-11-19 19:26:25 -07:00
Joel Dice
4026ad208c update makefile to point to iPhoneOS5.0.sdk 2011-11-04 08:25:26 -06:00
Joel Dice
d89a96ae6d use absolute path for test-executable in makefile
This is necessary to avoid crashes on OS X due to
CFBundleGetMainBundle and friends not behaving well otherwise.
2011-09-30 18:46:54 -06:00
Joel Dice
df4626c260 fix Windows cross build 2011-09-30 15:21:12 -06:00
Joel Dice
b063f10ad5 fix Windows build 2011-09-30 14:44:25 -06:00
Joel Dice
21d1a6c883 add __attribute__ ((used)) to EXPORT macro definition
This ensures that exported functions are not stripped when using the
-dead_strip option to the Apple linker.
2011-09-22 16:57:44 -06:00
Joel Dice
c537dcfd34 generate read-only code image in bootimage build
This avoids the requirement of putting the code image in a
section/segment which is both writable and executable, which is good
for security and avoids trouble with systems like iOS which disallow
such things.

The implementation relies on relative addressing such that the offset
of the desired address is fixed as a compile-time constant relative to
the start of the memory area of interest (e.g. the code image, heap
image, or thunk table).  At runtime, the base pointer to the memory
area is retrieved from the thread structure and added to the offset to
compute the final address.  Using the thread pointer allows us to
generate read-only, position-independent code while avoiding the use
of IP-relative addressing, which is not available on all
architectures.
2011-09-20 16:30:30 -06:00
Joel Dice
178dd7af34 Merge remote branch 'origin/master' into ios 2011-09-16 20:46:03 -06:00
Joel Dice
029a9ca507 fix MinGW (non-w64) build
Commit a2dca0dc fixed the MinGW-w64 openjdk-src build but broke the
traditional MinGW build.  This should ensure that both work.
2011-09-16 18:42:18 -06:00
Joel Dice
e505cbe99d more progress towards cross-architecture bootimage builds
This commit fixes a lot of bugs.  All tests are now pass for Linux
x86_64 to Linux i386 cross builds.
2011-08-31 21:18:00 -06:00
Joel Dice
6923c74c4c Merge branch 'ios' of oss:/var/local/git/avian into ios
Conflicts:
	makefile
2011-08-29 19:07:42 -06:00
Joel Dice
5b4f17997f progress towards cross-architecture bootimage builds
This monster commit is the first step towards supporting
cross-architecture bootimage builds.  The challenge is to build a heap
and code image for the target platform where the word size and
endianess may differ from those of the build architecture.  That means
the memory layout of objects may differ due to alignment and size
differences, so we can't just copy objects into the heap image
unchanged; we must copy field by field, resizing values, reversing
endianess and shifting offsets as necessary.

This commit also removes POD (plain old data) type support from the
type generator because it added a lot of complication and little
value.
2011-08-29 19:00:17 -06:00
Joel Dice
9522842b4b support cross builds on OS X to non-Mac targets 2011-08-23 17:04:04 -06:00
Joel Dice
e5a8d5c824 add support for Apple iOS on ARM
Most tests are passing, but not all, so this still needs more work.
2011-08-10 19:21:48 -06:00
Joel Dice
e3662f13a9 update copyright years and increment version number 2011-07-13 08:25:21 -06:00
Joel Dice
a2dca0dc62 fix Cygwin 1.7.x build
Recent versions of Cygwin's GCC no longer support the -mno-cygwin flag
(compilation works, but linking fails).  However, Cygwin now includes
mingw64-i686-gcc, mingw64-x86_64-gcc, and related packages, so we use
those compilers instead.  This has the added benefit that we can build
native x86_64 binaries on Cygwin now.

This will break the build for old Cygwin installs, so it will be
necessary to upgrade Cygwin and install the aforementioned packages to
build Avian going forward.
2011-07-12 22:58:51 +00:00
Joel Dice
50a699a08f Merge remote branch 'origin/B14038_Lion_appshare' into oss-master 2011-06-03 17:35:40 -06:00
Joel Dice
bcc72e8c9d Merge remote branch 'remotes/origin/B14038_Lion_appshare' into oss-master 2011-06-03 14:39:50 -06:00
Matt Klich
698138f649 OSX Lion build changes
Added JavaVM to include path. Also allow dynamically building with
different SDK versions through the OSX_SDK_VERSION and OSX_SDK_SYSROOT
environment variables (these default to the previosly hardcoded value of
10.4 and 10.4u respectively).
2011-06-02 15:15:08 -06:00
Matt Klich
c7c0a45a61 Revert "OSX Lion build changes"
This commit introduced conditional includes which is not the preferred
method. Will do it in the makefile instead.

This reverts commit 7148556979.
2011-06-01 13:56:03 -06:00
Matt Klich
7148556979 OSX Lion build changes 2011-05-26 11:57:30 -06:00
Joel Dice
a17045b02f avoid naming conflicts in OpenJDK build of libavian.a
OpenJDK's compile.c and Avian's compile.cpp were both being compiled
to compile.o, which led to a conflict when building libavian.a.  We
now append "-openjdk" to the object file name for OpenJDK code to
avoid such conflicts.
2011-04-14 16:12:12 -06:00
Joel Dice
1d98d977ce only include security policy jars if they exist 2011-04-10 15:51:17 -06:00
Joel Dice
f617c5c9ef Merge remote branch 'origin/localization' into oss-master 2011-04-09 21:43:44 -06:00
Joel Dice
686cbc3637 implement JVM_ResolveClass
This just reuses code in avian.Classes which was formerly only used in
the Avian classpath build.
2011-03-26 23:24:48 -06:00
Joel Dice
6bd9ec3735 enable link time optimization when using GCC 4.6 or greater 2011-03-26 14:44:08 -06:00
JET
b29e692c31 Merge branch 'master' into localization 2011-03-23 10:24:44 -06:00
Joel Dice
48e569c65a add tail call test 2011-03-15 17:51:32 -06:00
Joel Dice
78790a0f68 fix OpenJDK JCE support
This primarily required additions to classpath-openjdk.cpp to
intercept ZipFile, ZipEntry, and JarFile native methods to consult
embedded encryption policy jars when required.
2011-03-04 16:55:31 -07:00
Joel Dice
7a91074a32 fix OS X cross-arch build regression 2011-03-01 12:20:49 -07:00
Joel Dice
5f50226ae0 enable Linux/PowerPC cross build 2011-02-27 22:54:59 -07:00
Joel Dice
9e1ee7e974 enable Linux PowerPC build 2011-02-26 12:45:22 -07:00
Joel Dice
6014cb93b1 fix Mac OS PowerPC cross build
While we can use Linux's jni.h to cross compile the i386 Mac OS build,
that doesn't work for the PowerPC one.  Now we use the proper
/System/Library/Frameworks/JavaVM.framework/Versions/1.5.0/Headers/jni.h
from the sysroot instead.
2011-02-22 15:45:46 -07:00
JET
f6e2f4af21 Merge branch 'master' into localization 2011-02-21 17:58:50 -07:00
Joel Dice
19c443254d Merge remote branch 'oss/r0.5' into dev 2011-02-17 17:41:21 -07:00
Joel Dice
1ca8a20731 enable i686-apple-darwin8 cross compile 2011-02-17 17:39:41 -07:00
Joel Dice
c761ac6717 fix Subroutine test for use with OpenJDK build 2011-02-17 14:28:51 -07:00
Joel Dice
2216b22ccb add lib/currency.data to javahome-files on Windows
This file is needed by OpenJDK for both Windows and Posix systems.
2011-02-17 14:11:37 -07:00
Joel Dice
c743140e08 add new subroutine test
This test covers the case where a local stack slot is first used to
store an object reference and later to store a subroutine return
address.  Unfortunately, this confuses the VM's stack mapping code;
I'll be working on a fix for that next.

The new test requires generating bytecode from scratch, since there's
no reliable way to get javac to generate the code we want.  Since we
already had primitive bytecode construction code in Proxy.java, I
factored it out so we can reuse it in Subroutine.java.
2011-02-16 11:41:33 -07:00