Skip to content

Commit

Permalink
Merge pull request #441 from bigfatbrowncat/cp_fix2
Browse files Browse the repository at this point in the history
fixed abs() compilation for Android classpath on OSX
  • Loading branch information
dicej committed Jun 24, 2015
2 parents 6ace3b6 + 2c7e396 commit 0797665
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/classpath-android.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,9 @@
There is NO WARRANTY for this software. See license.txt for
details. */

#include <cmath>
using namespace std;

struct JavaVM;
struct _JavaVM;
struct _JNIEnv;
Expand Down Expand Up @@ -1206,7 +1209,8 @@ extern "C" AVIAN_EXPORT int64_t JNICALL
extern "C" AVIAN_EXPORT int64_t JNICALL
Avian_java_lang_Math_abs__J(Thread*, object, uintptr_t* arguments)
{
return llabs(arguments[0]);
int64_t v; memcpy(&v, arguments, 8);
return llabs(v);
}

extern "C" AVIAN_EXPORT int64_t JNICALL
Expand Down

0 comments on commit 0797665

Please sign in to comment.