Last active
December 14, 2019 17:06
-
-
Save huberflores/4714824 to your computer and use it in GitHub Desktop.
Re-compiling dalvik machine
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
/* | |
* author Huber Flores | |
*/ | |
#We also can provide you with Amazon image (AMI) public with Android x86 | |
#Please contact to huber AT UT DOT ee for granting access | |
# CyanogendMod/Android environment must be set up first | |
# refer to CM7Guide (https://gist.github.com/huberflores/4687766) | |
$ cd ./android/system/ | |
$ . build/envsetup.sh | |
$ lunch | |
. | |
. | |
103. cyanogen_espresso-eng | |
104. cyanogen_fascinatemtd-eng | |
105. cyanogen_galaxys2-eng (This one) | |
106. cyanogen_galaxys2att-eng | |
. | |
. | |
Which would you like? [full-eng] 105 | |
============================================ | |
PLATFORM_VERSION_CODENAME=REL | |
PLATFORM_VERSION=2.3.7 | |
TARGET_PRODUCT=cyanogen_galaxys2 | |
TARGET_BUILD_VARIANT=eng | |
TARGET_SIMULATOR=false | |
TARGET_BUILD_TYPE=release | |
TARGET_BUILD_APPS= | |
TARGET_ARCH=arm | |
TARGET_ARCH_VARIANT=armv7-a-neon | |
HOST_ARCH=x86 | |
HOST_OS=linux | |
HOST_BUILD_TYPE=release | |
BUILD_ID=GINGERBREAD | |
============================================ | |
# After environment is configured | |
$ make -j10 libdvm | |
or | |
$ make dalvikvm dalvik | |
============================================ | |
PLATFORM_VERSION_CODENAME=REL | |
PLATFORM_VERSION=2.3.7 | |
TARGET_PRODUCT=cyanogen_galaxys2 | |
TARGET_BUILD_VARIANT=eng | |
TARGET_SIMULATOR=false | |
TARGET_BUILD_TYPE=release | |
TARGET_BUILD_APPS= | |
TARGET_ARCH=arm | |
TARGET_ARCH_VARIANT=armv7-a-neon | |
HOST_ARCH=x86 | |
HOST_OS=linux | |
HOST_BUILD_TYPE=release | |
BUILD_ID=GINGERBREAD | |
============================================ | |
. | |
. | |
. | |
Install: out/host/linux-x86/bin/apriori | |
Install: out/host/linux-x86/bin/soslim | |
Copy: out/host/linux-x86/usr/icu/icudt44l.dat | |
Copy: out/host/linux-x86/etc/security/cacerts.bks | |
Install: out/host/linux-x86/lib/libcrypto.so | |
Install: out/target/product/galaxys2/system/lib/libdl.so | |
Install: out/target/product/galaxys2/system/lib/libc.so | |
Install: out/target/product/galaxys2/system/lib/libstdc++.so | |
Install: out/target/product/galaxys2/system/lib/libm.so | |
Install: out/target/product/galaxys2/system/lib/liblog.so | |
Install: out/target/product/galaxys2/system/lib/libz.so | |
Install: out/target/product/galaxys2/system/lib/libicuuc.so | |
Install: out/target/product/galaxys2/system/lib/libexpat.so | |
Install: out/target/product/galaxys2/system/lib/libcutils.so | |
Install: out/target/product/galaxys2/system/lib/libcrypto.so | |
Install: out/target/product/galaxys2/system/lib/libicui18n.so | |
Install: out/target/product/galaxys2/system/lib/libssl.so | |
Install: out/target/product/galaxys2/system/lib/libutils.so | |
Install: out/host/linux-x86/lib/libssl.so | |
Install: out/target/product/galaxys2/system/lib/libsqlite.so | |
Install: out/target/product/galaxys2/system/lib/libnativehelper.so | |
Install: out/target/product/galaxys2/system/lib/libdvm.so ###Dalvik engine for Galaxy S2 i9100### | |
Install: out/host/linux-x86/lib/libicuuc.so | |
Install: out/host/linux-x86/lib/libicui18n.so | |
Install: out/host/linux-x86/lib/libdvm.so ###Dalvik engine for x_86### | |
< | |
(optional) | |
# Android x86 | |
$ ./out/host/linux-x86/bin/dalvikvm | |
# Launch script for the Dalvik Virtual Machine in x86 | |
# Here you actually could wrap .class files into .dex files and execute them within your computer :) | |
> | |
# Replace libdvm.so in your phone | |
# Plug galaxys2 (in my case :P) phone to your computer | |
$ adb root | |
adbd is already running as root | |
$ adb remount | |
remount succeeded | |
$ adb push ./android/system/out/target/product/galaxys2/system/lib/libdvm.so /system/lib/liddvm.so | |
3990 KB/s (671576 bytes in 0.164s) | |
$ adb reboot | |
Your phone will restart with the new Dalvik engine |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment