Created
February 22, 2016 03:45
-
-
Save shakalaca/86ac06a6be14a6d9331b to your computer and use it in GitHub Desktop.
Patch for x86_64 xposed
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/Xposed.pm b/Xposed.pm | |
index 12632d4..4758f2d 100644 | |
--- a/Xposed.pm | |
+++ b/Xposed.pm | |
@@ -121,7 +121,7 @@ sub expand_targets($;$) { | |
my %seen; | |
foreach (split(m/[\/ ]+/, $spec)) { | |
my ($pfspec, $sdkspec) = split(m/[: ]+/, $_, 2); | |
- my @pflist = ($pfspec ne 'all' && $pfspec ne 'all+') ? split(m/[, ]/, $pfspec) : ('arm', 'x86', 'arm64', 'armv5'); | |
+ my @pflist = ($pfspec ne 'all' && $pfspec ne 'all+') ? split(m/[, ]/, $pfspec) : ('arm', 'x86', 'arm64', 'armv5' , 'x86_64'); | |
if ($pfspec eq 'all+') { | |
push @pflist, 'host'; | |
push @pflist, 'hostd'; | |
@@ -156,6 +156,11 @@ sub check_target_sdk_platform($$;$) { | |
print_error('ARMv5 builds are only supported up to Android 4.2 (SDK 17)') unless $wildcard; | |
return 0; | |
} | |
+ } elsif ($platform eq 'x86_64') { | |
+ if ($sdk < 21) { | |
+ print_error('x86_64 builds are not supported prior to Android 5.0 (SDK 21)') unless $wildcard; | |
+ return 0; | |
+ } | |
} elsif ($platform eq 'arm64') { | |
if ($sdk < 21) { | |
print_error('arm64 builds are not supported prior to Android 5.0 (SDK 21)') unless $wildcard; | |
@@ -203,7 +208,7 @@ sub get_outdir($) { | |
return 'out/target/product/generic'; | |
} elsif ($platform eq 'armv5') { | |
return 'out_armv5/target/product/generic'; | |
- } elsif ($platform eq 'x86' || $platform eq 'arm64') { | |
+ } elsif ($platform eq 'x86' || $platform eq 'arm64' || $platform eq 'x86_64') { | |
return 'out/target/product/generic_' . $platform; | |
} else { | |
print_error("Could not determine output directory for $platform"); | |
@@ -227,6 +232,8 @@ sub get_lunch_mode($$) { | |
return ($sdk <= 17) ? 'full-eng' : 'aosp_arm-eng'; | |
} elsif ($platform eq 'x86') { | |
return ($sdk <= 17) ? 'full_x86-eng' : 'aosp_x86-eng'; | |
+ } elsif ($platform eq 'x86_64' && $sdk >= 21) { | |
+ return 'aosp_x86_64-eng'; | |
} elsif ($platform eq 'arm64' && $sdk >= 21) { | |
return 'aosp_arm64-eng'; | |
} else { | |
diff --git a/build.pl b/build.pl | |
index c820ae6..41f92b2 100755 | |
--- a/build.pl | |
+++ b/build.pl | |
@@ -268,7 +268,7 @@ sub get_compiled_files($$) { | |
); | |
} | |
- if ($platform eq 'arm64') { | |
+ if ($platform eq 'arm64' || $platform eq 'x86_64') { | |
# libart-disassembler is required by oatdump only, which is a 64-bit executable | |
delete $files{'/system/lib/libart-disassembler.so'}; | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Dear Sir,Any Update for x86_64 xposed frameworks ?