Last active
July 30, 2016 13:13
-
-
Save niltonvasques/221ca6e119f61bba5dfc1ac1947a91ee to your computer and use it in GitHub Desktop.
Basic android Makefile
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
APP_NAME=MyAppName | |
PACKAGE=com.example.package | |
CC=./gradlew | |
ADB=adb | |
.PHONY: build uninstall install log | |
all: build uninstall install log | |
build: | |
$(CC) assembleDebug | |
install: | |
find . -name *debug.apk | xargs adb install -d | |
uninstall: | |
$(ADB) uninstall $(PACKAGE) | |
log: | |
$(eval PID=`adb shell dumpsys meminfo $(PACKAGE) | grep "pid [0-9]*" -oh | grep "[0-9]*" -oh`) | |
$(ADB) logcat | grep "($(PID))" | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment