more cleanup. Get Crittercism stuff compiling.

This commit is contained in:
Eric House 2017-01-18 19:03:36 -08:00
parent 0d1e22fc83
commit 1f5ffaa712
35 changed files with 14 additions and 1114 deletions

View file

@ -1 +0,0 @@
values-??/strings.xml

View file

@ -1,26 +0,0 @@
/clear_all__gen.png
/search__gen.png
/select_all__gen.png
back__gen.png
content_copy__gen.png
content_discard__gen.png
content_edit.png
content_new__gen.png
dict__gen.png
down__gen.png
download__gen.png
email__gen.png
new_group__gen.png
prefs__gen.png
relabel__gen.png
reset__gen.png
save__gen.png
send__gen.png
up__gen.png
clear_all__gen.png
search__gen.png
select_all__gen.png
content_new_net__gen.png
content_new_solo__gen.png
multigame__gen.png
sologame__gen.png

View file

@ -1,26 +0,0 @@
/clear_all__gen.png
/search__gen.png
/select_all__gen.png
back__gen.png
content_copy__gen.png
content_discard__gen.png
content_edit.png
content_new__gen.png
dict__gen.png
down__gen.png
download__gen.png
email__gen.png
new_group__gen.png
prefs__gen.png
relabel__gen.png
reset__gen.png
save__gen.png
send__gen.png
up__gen.png
clear_all__gen.png
search__gen.png
select_all__gen.png
content_new_net__gen.png
content_new_solo__gen.png
multigame__gen.png
sologame__gen.png

View file

@ -1,26 +0,0 @@
/clear_all__gen.png
/search__gen.png
/select_all__gen.png
back__gen.png
content_copy__gen.png
content_discard__gen.png
content_edit.png
content_new__gen.png
dict__gen.png
down__gen.png
download__gen.png
email__gen.png
new_group__gen.png
prefs__gen.png
relabel__gen.png
reset__gen.png
save__gen.png
send__gen.png
up__gen.png
clear_all__gen.png
search__gen.png
select_all__gen.png
content_new_net__gen.png
content_new_solo__gen.png
multigame__gen.png
sologame__gen.png

View file

@ -1,30 +0,0 @@
dicticon.png
downarrow.png
expander_ic_maximized.9.png
expander_ic_minimized.9.png
flip.png
icon48x48.png
ic_popup_sync_1.png
netarrow_allconn.png
netarrow_someconn.png
netarrow_unconn.png
next_hint.png
origin.png
prev_hint.png
refresh.png
relaygame.png
rightarrow.png
shuffle.png
sologame.png
stat_notify_chat.png
stat_notify_sync.png
undo.png
values.png
zoom.png
bluetooth_active.png
bluetooth_disabled.png
in_arrow_active.png
in_arrow.png
out_arrow_active.png
out_arrow.png
notify.png

View file

@ -1 +0,0 @@
board.xml

View file

@ -1,54 +0,0 @@
about_dlg.xml
board.xml
btinviter_item.xml.~1~
chat_history_local.xml
chat_history_remote.xml
chat.xml
color_display.xml
color_edit.xml
dflt_name.xml
dict_browser.xml
dict_browse.xml
divider_view.xml
force_remote.xml
game_config.xml
game_list_item.xml
game_list.xml
import_dict.xml
list_item.xml
lookup.xml
new_game.xml
passwd_view.xml
player_edit.xml
player_list_elem.xml
prefs_w_buttons.xml
relay_game_config.xml
rename_game.xml
select_dialog_item.xml
confirm_sms.xml
game_list_group.xml
studylist.xml
loc_list_item.xml
loc_main.xml
loc_item_edit.xml
import_dict_item.xml
list_group.xml
conn_types_display.xml
expander_header.xml
msg_label_and_edit.xml
not_again_view.xml
relayinviter.xml
remote_dict_details.xml
toolbar.xml
chat_row.xml
fragact.xml
main.xml
dualcontainer.xml
dict_browser_list.xml
inviter_item.xml
inviter.xml
bt_buttons.xml
relay_buttons.xml
sms_buttons.xml
inviter_item_frame.xml
two_strs_item.xml

View file

@ -1 +0,0 @@
board_menu.xml

View file

@ -1,11 +0,0 @@
board_menu.xml
chat_menu.xml
dicts_item_menu.xml
games_list_menu.xml
dicts_menu.xml
studylist.xml
loc_menu.xml
empty.xml
loc_item_menu.xml
games_list_group_menu.xml
games_list_game_menu.xml

View file

@ -1 +0,0 @@
changes

View file

@ -1 +0,0 @@
styles.xml

View file

@ -1,6 +0,0 @@
strings.xml
styles.xml
common_rsrc.xml
gen_strings.xml
app_name.xml
dimensions.xml

View file

@ -1,4 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<resources>
<bool name="dualpane_enabled">false</bool>
</resources>

View file

@ -1 +0,0 @@
xwprefs.xml

View file

@ -1,20 +0,0 @@
*.apk
.DS_Store
.gradle
/.idea/libraries
/.idea/workspace.xml
/build
/captures
/libs-debug
/libs-release
/local.properties
/obj-debug
/obj-release
ant_out.txt
bin
gen
obj
proguard.cfg
res/drawable*/*gen.png
.idea/
*.iml

View file

@ -1 +0,0 @@
/build

View file

@ -1,237 +0,0 @@
def VARIANT_NAME = 'xw4'
def INITIAL_CLIENT_VERS = 6
def CHAT_ENABLED = true
def LIBS_DEBUG = 'libs-debug'
def LIBS_RELEASE = 'libs-release'
def VERSION_CODE_BASE = 1
def VARIANTS = [ "Xw4", "Xw4dbg" ]
def BUILDS = [ "Debug", "Release" ]
apply plugin: 'com.android.application'
dependencies {
compile files('../libs/gcm.jar')
compile files('../libs/android-support-v13.jar')
}
android {
compileSdkVersion 23
buildToolsVersion "23.0.2"
defaultConfig {
minSdkVersion 7
targetSdkVersion 23
}
// Rename all output artifacts to include version information
// applicationVariants.all { variant ->
// renameArtifact(variant)
// variant.buildConfigField "String", "FIELD_NAME", "\"my String\""
// }
flavorDimensions "variant"//, "abi"
productFlavors {
xw4 {
dimension "variant"
applicationId "org.eehouse.android.xw4"
}
xw4dbg {
dimension "variant"
applicationId "org.eehouse.android.xw4dbg"
}
// WARNING: "all" breaks things. Seems to be a keyword. Need
// to figure out how to express include-all-abis
// all {
// dimension "abi"
// versionCode 0 + VERSION_CODE_BASE
// }
// armeabi {
// dimension "abi"
// versionCode 1 + VERSION_CODE_BASE
// }
// x86 {
// dimension "abi"
// versionCode 2 + VERSION_CODE_BASE
// }
// armeabiv7a {
// dimension "abi"
// versionCode 3 + VERSION_CODE_BASE
// }
}
signingConfigs {
release {
storeFile file(System.getenv("HOME") + "/.keystore")
keyAlias "mykey"
// These two lines make gradle believe that the signingConfigs
// section is complete. Without them, tasks like installRelease
// will not be available!
storePassword "notReal"
keyPassword "notReal"
}
}
buildTypes {
release {
signingConfig signingConfigs.release
debuggable false
minifyEnabled true
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
debug {
debuggable true
// This doesn't work on marshmallow: duplicate permission error
// applicationIdSuffix ".debug"
}
}
sourceSets {
// Use symlinks instead of setting non-conventional
// directories here. AS doesn't respect what's set here: it'll
// compile, but post-install app launch and source-level
// debugging don't work.
release {
jniLibs.srcDir "../$LIBS_RELEASE"
}
debug {
jniLibs.srcDir "../$LIBS_DEBUG"
}
}
lintOptions {
abortOnError false
}
def gitrev = "git describe --tags".execute().text.trim()
applicationVariants.all { variant ->
variant.outputs.each { output ->
output.outputFile =
new File(output.outputFile.parent,
output.outputFile.name.replace(".apk", "-${gitrev}.apk"))
}
}
}
// Prevent release builds. They haven't been tested, and now that
// f-droid has been releasing them they're KNOWN not to work.
android.applicationVariants.all { variant ->
if ( variant.name.endsWith("Release") ) {
String NAME = "check" + variant.name.capitalize() + "Manifest"
task "$NAME"(overwrite: true) << {
throw new RuntimeException('<<<<< Release builds should not be built '
+ 'using gradle! Please use ant for now. >>>>>');
}
}
}
dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
}
task genVers(type: Exec) {
workingDir '../'
commandLine '../scripts/genvers.sh', '--variant', VARIANT_NAME,
'--client-vers', INITIAL_CLIENT_VERS,
'--vers-outfile', "assets/gitvers.txt"
}
task mkImages(type: Exec) {
workingDir '../'
commandLine '../scripts/mkimages.sh'
}
task copyStrings(type: Exec) {
workingDir '../'
commandLine '../scripts/copy-strings.py'
}
task ndkSetup(type: Exec) {
workingDir '../'
commandLine "../scripts/ndksetup.sh"
}
task myPreBuild(dependsOn: ['genVers', 'ndkSetup', 'mkImages', 'copyStrings', 'mkXml']) {
}
preBuild.dependsOn myPreBuild
task ndkBuildDebug(type: Exec) {
workingDir '../'
commandLine '../scripts/ndkbuild.sh', '-j3', "CHAT_ENABLED=$CHAT_ENABLED",
'BUILD_TARGET=debug', "INITIAL_CLIENT_VERS=$INITIAL_CLIENT_VERS",
"VARIANT=$VARIANT_NAME", "NDK_LIBS_OUT=$LIBS_DEBUG", 'NDK_OUT=./obj-debug'
}
task ndkBuildRelease(type: Exec) {
workingDir '../'
commandLine '../scripts/ndkbuild.sh', '-j3', "CHAT_ENABLED=$CHAT_ENABLED",
'BUILD_TARGET=release', "INITIAL_CLIENT_VERS=$INITIAL_CLIENT_VERS",
"VARIANT=$VARIANT_NAME", "NDK_LIBS_OUT=$LIBS_RELEASE", 'NDK_OUT=./obj-release'
}
task mkXml(type: Exec) {
workingDir '../'
commandLine '../scripts/mk_xml.py', '-o',
"src/org/eehouse/android/$VARIANT_NAME/loc/LocIDsData.java",
'-t', "debug", '-v', "$VARIANT_NAME"
}
afterEvaluate {
VARIANTS.each { VARIANT ->
String compileTask = "compile${VARIANT}ReleaseNdk"
tasks.getByName(compileTask).dependsOn ndkBuildRelease
compileTask = "compile${VARIANT}DebugNdk"
tasks.getByName(compileTask).dependsOn ndkBuildDebug
}
}
task askForPassword << {
def password = System.getenv("ANDROID_KEY_PASS")
if (null == password || 0 == password.length()) {
if ( null != System.console() ) {
password = new String(System.console()
.readPassword("ANDROID_KEY_PASS not set; "
+ "Keystore password: "))
} else {
password = null
println( "ANDROID_KEY_PASS not set and no console; " )
println( "sign it yerself later. (Or you might try" )
println( " running gradlew with the --no-daemon flag)" )
}
}
if ( null != password ) {
android.signingConfigs.release.storePassword = password
android.signingConfigs.release.keyPassword = password
}
}
tasks.whenTaskAdded { theTask ->
if (theTask.name.equals("packageRelease")) {
theTask.dependsOn "askForPassword"
}
}
// def getVersionName() {
// try {
// def stdout = new ByteArrayOutputStream()
// exec {
// commandLine 'git', 'describe', '--dirty'
// standardOutput = stdout
// }
// return stdout.toString().trim()
// }
// catch (ignored) {
// return null;
// }
// }
// def renameArtifact(variant) {
// variant.outputs.each { output ->
// def name = String.format( "XWords4-%s-%s.apk", variant.name,
// getVersionName() )
// output.outputFile = new File( (String)output.outputFile.parent,
// (String)name )
// }
// }

View file

@ -1 +0,0 @@
gitvers.txt

View file

@ -1,112 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<project name="XWords4" default="release">
<!-- eeh: allow ant files to refer e.g. to ${env.HOME} -->
<property environment="env" />
<!-- The local.properties file is created and updated by the 'android' tool.
It contains the path to the SDK. It should *NOT* be checked into
Version Control Systems. -->
<loadproperties srcFile="local.properties" />
<!-- The ant.properties file can be created by you. It is only edited by the
'android' tool to add properties to it.
This is the place to change some Ant specific build properties.
Here are some properties you may want to change/update:
source.dir
The name of the source directory. Default is 'src'.
out.dir
The name of the output directory. Default is 'bin'.
For other overridable properties, look at the beginning of the rules
files in the SDK, at tools/ant/build.xml
Properties related to the SDK location or the project target should
be updated using the 'android' tool with the 'update' action.
This file is an integral part of the build system for your
application and should be checked into Version Control Systems.
-->
<property file="ant.properties" />
<!-- The project.properties file is created and updated by the 'android'
tool, as well as ADT.
This contains project specific properties such as project target, and library
dependencies. Lower level build properties are stored in ant.properties
(or in .classpath for Eclipse projects).
This file is an integral part of the build system for your
application and should be checked into Version Control Systems. -->
<loadproperties srcFile="project.properties" />
<!-- An attempt to define stuff to be included from multiple build.xml files -->
<import file="../scripts/common_targets.xml" />
<!-- quick check on sdk.dir -->
<fail
message="sdk.dir is missing. Make sure to generate local.properties using 'android update project'"
unless="sdk.dir"
/>
<!-- extension targets. Uncomment the ones where you want to do custom work
in between standard targets -->
<property name="INITIAL_CLIENT_VERS" value="8"/>
<property name="VARIANT_NAME" value="xw4"/>
<property name="APP_NAME" value="Crosswords"/>
<property name="SKIP_LANGS" value="values-de"/>
<property name="WIDIR_ENABLED" value="false" />
<target name="-pre-clean">
<antcall target="my-pre-clean" />
</target>
<target name="-pre-build" depends="my-copy-src, my-check-props">
<antcall target="my-pre-build">
<param name="VARIANT_NAME" value="${VARIANT_NAME}"/>
<param name="APP_NAME" value="${APP_NAME}"/>
</antcall>
</target>
<target name="-pre-compile">
<antcall target="my-pre-compile">
<param name="VARIANT_NAME" value="${VARIANT_NAME}"/>
</antcall>
</target>
<!--
<target name="-pre-compile">
</target>
/* This is typically used for code obfuscation.
Compiled code location: ${out.classes.absolute.dir}
If this is not done in place, override ${out.dex.input.absolute.dir} */
<target name="-post-compile">
</target>
-->
<!-- Import the actual build file.
To customize existing targets, there are two options:
- Customize only one target:
- copy/paste the target into this file, *before* the
<import> task.
- customize it to your needs.
- Customize the whole content of build.xml
- copy/paste the content of the rules files (minus the top node)
into this file, replacing the <import> task.
- customize to your needs.
***********************
****** IMPORTANT ******
***********************
In all cases you must update the value of version-tag below to read 'custom' instead of an integer,
in order to avoid having your file be overridden by tools such as "android update project"
-->
<!-- version-tag: 1 -->
<import file="${sdk.dir}/tools/ant/build.xml" />
</project>

View file

@ -1,516 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<project name="XWords4" default="release">
<!-- The local.properties file is created and updated by the 'android' tool.
It contains the path to the SDK. It should *NOT* be checked in in Version
Control Systems. -->
<exec dir=".." executable="./scripts/setup_local_props.sh" output="ant_out.txt" />
<property file="local.properties" />
<!-- The build.properties file can be created by you and is never touched
by the 'android' tool. This is the place to change some of the default property values
used by the Ant rules.
Here are some properties you may want to change/update:
application.package
the name of your application package as defined in the manifest. Used by the
'uninstall' rule.
source.dir
the name of the source directory. Default is 'src'.
out.dir
the name of the output directory. Default is 'bin'.
Properties related to the SDK location or the project target should be updated
using the 'android' tool with the 'update' action.
This file is an integral part of the build system for your application and
should be checked in in Version Control Systems.
-->
<property file="build.properties" />
<!-- The default.properties file is created and updated by the 'android' tool, as well
as ADT.
This file is an integral part of the build system for your application and
should be checked in in Version Control Systems. -->
<property file="default.properties" />
<!-- Custom Android task to deal with the project target, and import the proper rules.
This requires ant 1.6.0 or above. -->
<path id="android.antlibs">
<pathelement path="${sdk.dir}/tools/lib/anttasks.jar" />
<pathelement path="${sdk.dir}/tools/lib/sdklib.jar" />
<pathelement path="${sdk.dir}/tools/lib/androidprefs.jar" />
<pathelement path="${sdk.dir}/tools/lib/apkbuilder.jar" />
<pathelement path="${sdk.dir}/tools/lib/jarutils.jar" />
</path>
<taskdef name="setup"
classname="com.android.ant.SetupTask"
classpathref="android.antlibs" />
<exec dir=".." executable="./scripts/genvers.sh" output="ant_out.txt" />
<!-- Execute the Android Setup task that will setup some properties specific to the target,
and import the build rules files.
The rules file is imported from
<SDK>/platforms/<target_platform>/templates/android_rules.xml
To customize some build steps for your project:
- copy the content of the main node <project> from android_rules.xml
- paste it in this build.xml below the <setup /> task.
- disable the import by changing the setup task below to <setup import="false" />
This will ensure that the properties are setup correctly but that your customized
build steps are used.
-->
<setup import="false"/>
<!--
This rules file is meant to be imported by the custom Ant task:
com.android.ant.AndroidInitTask
The following properties are put in place by the importing task:
android.jar, android.aidl, aapt, aidl, and dx
Additionnaly, the task sets up the following classpath reference:
android.target.classpath
This is used by the compiler task as the boot classpath.
-->
<!-- Custom tasks -->
<taskdef name="aaptexec"
classname="com.android.ant.AaptExecLoopTask"
classpathref="android.antlibs" />
<taskdef name="apkbuilder"
classname="com.android.ant.ApkBuilderTask"
classpathref="android.antlibs" />
<taskdef name="xpath"
classname="com.android.ant.XPathTask"
classpathref="android.antlibs" />
<!-- Properties -->
<!-- Tells adb which device to target. You can change this from the command line
by invoking "ant -Dadb.device.arg=-d" for device "ant -Dadb.device.arg=-e" for
the emulator. -->
<property name="adb.device.arg" value="" />
<property name="android.tools.dir" location="${sdk.dir}/tools" />
<!-- Name of the application package extracted from manifest file -->
<xpath input="AndroidManifest.xml" expression="/manifest/@package"
output="manifest.package" />
<!-- Input directories -->
<property name="source.dir" value="src" />
<property name="source.absolute.dir" location="${source.dir}" />
<property name="gen.dir" value="gen" />
<property name="gen.absolute.dir" location="${gen.dir}" />
<property name="resource.dir" value="res" />
<property name="resource.absolute.dir" location="${resource.dir}" />
<property name="asset.dir" value="assets" />
<property name="asset.absolute.dir" location="${asset.dir}" />
<!-- Directory for the third party java libraries -->
<property name="external.libs.dir" value="libs" />
<property name="external.libs.absolute.dir" location="${external.libs.dir}" />
<!-- Directory for the native libraries -->
<property name="native.libs.dir" value="libs" />
<property name="native.libs.absolute.dir" location="${native.libs.dir}" />
<!-- Output directories -->
<property name="out.dir" value="bin" />
<property name="out.absolute.dir" location="${out.dir}" />
<property name="out.classes.dir" value="${out.absolute.dir}/classes" />
<property name="out.classes.absolute.dir" location="${out.classes.dir}" />
<!-- Intermediate files -->
<property name="dex.file.name" value="classes.dex" />
<property name="intermediate.dex.file" location="${out.absolute.dir}/${dex.file.name}" />
<!-- The final package file to generate -->
<property name="out.debug.unaligned.package"
location="${out.absolute.dir}/${ant.project.name}-debug-unaligned.apk" />
<property name="out.debug.package"
location="${out.absolute.dir}/${ant.project.name}-debug.apk" />
<property name="out.unsigned.package"
location="${out.absolute.dir}/${ant.project.name}-unsigned.apk" />
<property name="out.unaligned.package"
location="${out.absolute.dir}/${ant.project.name}-unaligned.apk" />
<property name="out.release.package"
location="${out.absolute.dir}/${ant.project.name}-release.apk" />
<!-- Verbosity -->
<property name="verbose" value="false" />
<!-- This is needed by emma as it uses multilevel verbosity instead of simple 'true' or 'false'
The property 'verbosity' is not user configurable and depends exclusively on 'verbose'
value.-->
<condition property="verbosity" value="verbose" else="quiet">
<istrue value="${verbose}" />
</condition>
<!-- This is needed to switch verbosity of zipalign and aapt. Depends exclusively on 'verbose'
-->
<condition property="v.option" value="-v" else="">
<istrue value="${verbose}" />
</condition>
<!-- This is needed to switch verbosity of dx. Depends exclusively on 'verbose' -->
<condition property="verbose.option" value="--verbose" else="">
<istrue value="${verbose}" />
</condition>
<!-- Tools -->
<condition property="exe" value=".exe" else=""><os family="windows" /></condition>
<property name="adb" location="${android.tools.dir}/adb${exe}" />
<property name="zipalign" location="${android.tools.dir}/zipalign${exe}" />
<!-- Emma configuration -->
<property name="emma.dir" value="${sdk.dir}/tools/lib" />
<path id="emma.lib">
<pathelement location="${emma.dir}/emma.jar" />
<pathelement location="${emma.dir}/emma_ant.jar" />
</path>
<taskdef resource="emma_ant.properties" classpathref="emma.lib" />
<!-- End of emma configuration -->
<!-- Macros -->
<!-- Configurable macro, which allows to pass as parameters output directory,
output dex filename and external libraries to dex (optional) -->
<macrodef name="dex-helper">
<element name="external-libs" optional="yes" />
<element name="extra-parameters" optional="yes" />
<sequential>
<echo>Converting compiled files and external libraries into ${intermediate.dex.file}...
</echo>
<apply executable="${dx}" failonerror="true" parallel="true">
<arg value="--dex" />
<arg value="--output=${intermediate.dex.file}" />
<extra-parameters />
<arg line="${verbose.option}" />
<arg path="${out.classes.absolute.dir}" />
<fileset dir="${external.libs.absolute.dir}" includes="*.jar" />
<external-libs />
</apply>
</sequential>
</macrodef>
<!-- This is macro that enable passing variable list of external jar files to ApkBuilder
Example of use:
<package-helper>
<extra-jars>
<jarfolder path="my_jars" />
<jarfile path="foo/bar.jar" />
<jarfolder path="your_jars" />
</extra-jars>
</package-helper> -->
<macrodef name="package-helper">
<attribute name="sign.package" />
<element name="extra-jars" optional="yes" />
<sequential>
<apkbuilder
outfolder="${out.absolute.dir}"
basename="${ant.project.name}"
signed="@{sign.package}"
verbose="${verbose}">
<file path="${intermediate.dex.file}" />
<sourcefolder path="${source.absolute.dir}" />
<nativefolder path="${native.libs.absolute.dir}" />
<jarfolder path="${external.libs.absolute.dir}" />
<extra-jars/>
</apkbuilder>
</sequential>
</macrodef>
<!-- This is macro which zipaligns in.package and outputs it to out.package. Used by targets
debug, -debug-with-emma and release.-->
<macrodef name="zipalign-helper">
<attribute name="in.package" />
<attribute name="out.package" />
<sequential>
<echo>Running zip align on final apk...</echo>
<exec executable="${zipalign}" failonerror="true">
<arg line="${v.option}" />
<arg value="-f" />
<arg value="4" />
<arg path="@{in.package}" />
<arg path="@{out.package}" />
</exec>
</sequential>
</macrodef>
<!-- This is macro used only for sharing code among two targets, -install and
-install-with-emma which do exactly the same but differ in dependencies -->
<macrodef name="install-helper">
<sequential>
<echo>Installing ${out.debug.package} onto default emulator or device...</echo>
<exec executable="${adb}" failonerror="true">
<arg line="${adb.device.arg}" />
<arg value="install" />
<arg value="-r" />
<arg path="${out.debug.package}" />
</exec>
</sequential>
</macrodef>
<!-- Rules -->
<!-- Creates the output directories if they don't exist yet. -->
<target name="-dirs">
<echo>Creating output directories if needed...</echo>
<mkdir dir="${resource.absolute.dir}" />
<mkdir dir="${external.libs.absolute.dir}" />
<mkdir dir="${gen.absolute.dir}" />
<mkdir dir="${out.absolute.dir}" />
<mkdir dir="${out.classes.absolute.dir}" />
</target>
<!-- Generates the R.java file for this project's resources. -->
<target name="-resource-src" depends="-dirs">
<echo>Generating R.java / Manifest.java from the resources...</echo>
<exec executable="${aapt}" failonerror="true">
<arg value="package" />
<arg line="${v.option}" />
<arg value="-m" />
<arg value="-J" />
<arg path="${gen.absolute.dir}" />
<arg value="-M" />
<arg path="AndroidManifest.xml" />
<arg value="-S" />
<arg path="${resource.absolute.dir}" />
<arg value="-I" />
<arg path="${android.jar}" />
</exec>
</target>
<!-- Generates java classes from .aidl files. -->
<target name="-aidl" depends="-dirs">
<echo>Compiling aidl files into Java classes...</echo>
<apply executable="${aidl}" failonerror="true">
<arg value="-p${android.aidl}" />
<arg value="-I${source.absolute.dir}" />
<arg value="-o${gen.absolute.dir}" />
<fileset dir="${source.absolute.dir}">
<include name="**/*.aidl" />
</fileset>
</apply>
</target>
<!-- Compiles this project's .java files into .class files. -->
<target name="compile" depends="-resource-src, -aidl"
description="Compiles project's .java files into .class files">
<!-- If android rules are used for a test project, its classpath should include
tested project's location -->
<condition property="extensible.classpath"
value="${tested.project.absolute.dir}/bin/classes" else=".">
<isset property="tested.project.absolute.dir" />
</condition>
<javac encoding="ascii" target="1.5" debug="true" extdirs=""
destdir="${out.classes.absolute.dir}"
bootclasspathref="android.target.classpath"
verbose="${verbose}" classpath="${extensible.classpath}">
<src path="${source.absolute.dir}" />
<src path="${gen.absolute.dir}" />
<classpath>
<fileset dir="${external.libs.absolute.dir}" includes="*.jar" />
</classpath>
<compilerarg value="-Xlint:unchecked"/>
</javac>
</target>
<!-- Converts this project's .class files into .dex files -->
<target name="-dex" depends="compile">
<dex-helper />
</target>
<!-- Puts the project's resources into the output package file
This actually can create multiple resource package in case
Some custom apk with specific configuration have been
declared in default.properties.
-->
<target name="-package-resources">
<echo>Packaging resources</echo>
<aaptexec executable="${aapt}"
command="package"
manifest="AndroidManifest.xml"
resources="${resource.absolute.dir}"
assets="${asset.absolute.dir}"
androidjar="${android.jar}"
outfolder="${out.absolute.dir}"
basename="${ant.project.name}" />
</target>
<!-- Packages the application and sign it with a debug key. -->
<target name="-package-debug-sign" depends="-dex, -package-resources">
<package-helper sign.package="true" />
</target>
<!-- Packages the application without signing it. -->
<target name="-package-no-sign" depends="-dex, -package-resources">
<package-helper sign.package="false" />
</target>
<target name="-compile-tested-if-test" if="tested.project.dir" unless="do.not.compile.again">
<subant target="compile">
<fileset dir="${tested.project.absolute.dir}" includes="build.xml" />
</subant>
</target>
<!-- Builds debug output package, provided all the necessary files are already dexed -->
<target name="debug" depends="-compile-tested-if-test, -package-debug-sign"
description="Builds the application and signs it with a debug key.">
<zipalign-helper in.package="${out.debug.unaligned.package}"
out.package="${out.debug.package}" />
<echo>Debug Package: ${out.debug.package}</echo>
</target>
<target name="-release-check">
<condition property="release.sign">
<and>
<isset property="key.store" />
<isset property="key.alias" />
</and>
</condition>
</target>
<target name="-release-nosign" depends="-release-check" unless="release.sign">
<echo>No key.store and key.alias properties found in build.properties.</echo>
<echo>Please sign ${out.unsigned.package} manually</echo>
<echo>and run zipalign from the Android SDK tools.</echo>
</target>
<target name="release" depends="-package-no-sign, -release-nosign" if="release.sign"
description="Builds the application. The generated apk file must be signed before
it is published.">
<!-- Gets passwords -->
<input
message="Please enter keystore password (store:${key.store}):"
addproperty="key.store.password" />
<input
message="Please enter password for alias '${key.alias}':"
addproperty="key.alias.password" />
<!-- Signs the APK -->
<echo>Signing final apk...</echo>
<signjar
jar="${out.unsigned.package}"
signedjar="${out.unaligned.package}"
keystore="${key.store}"
storepass="${key.store.password}"
alias="${key.alias}"
keypass="${key.alias.password}"
verbose="${verbose}" />
<!-- Zip aligns the APK -->
<zipalign-helper in.package="${out.unaligned.package}"
out.package="${out.release.package}" />
<echo>Release Package: ${out.release.package}</echo>
</target>
<target name="install" depends="debug"
description="Installs/reinstalls the debug package onto a running
emulator or device. If the application was previously installed,
the signatures must match." >
<install-helper />
</target>
<target name="-uninstall-check">
<condition property="uninstall.run">
<isset property="manifest.package" />
</condition>
</target>
<target name="-uninstall-error" depends="-uninstall-check" unless="uninstall.run">
<echo>Unable to run 'ant uninstall', manifest.package property is not defined.
</echo>
</target>
<!-- Uninstalls the package from the default emulator/device -->
<target name="uninstall" depends="-uninstall-error" if="uninstall.run"
description="Uninstalls the application from a running emulator or device.">
<echo>Uninstalling ${manifest.package} from the default emulator or device...</echo>
<exec executable="${adb}" failonerror="true">
<arg line="${adb.device.arg}" />
<arg value="uninstall" />
<arg value="${manifest.package}" />
</exec>
</target>
<target name="clean" description="Removes output files created by other targets.">
<delete dir="${out.absolute.dir}" verbose="${verbose}" />
<delete dir="${gen.absolute.dir}" verbose="${verbose}" />
</target>
<!-- Targets for code-coverage measurement purposes, invoked from external file -->
<!-- Emma-instruments tested project classes (compiles the tested project if necessary)
and writes instrumented classes to ${instrumentation.absolute.dir}/classes -->
<target name="-emma-instrument" depends="compile">
<echo>Instrumenting classes from ${out.absolute.dir}/classes...</echo>
<!-- It only instruments class files, not any external libs -->
<emma enabled="true">
<instr verbosity="${verbosity}"
mode="overwrite"
instrpath="${out.absolute.dir}/classes"
outdir="${out.absolute.dir}/classes">
</instr>
<!-- TODO: exclusion filters on R*.class and allowing custom exclusion from
user defined file -->
</emma>
</target>
<target name="-dex-instrumented" depends="-emma-instrument">
<dex-helper>
<extra-parameters>
<arg value="--no-locals" />
</extra-parameters>
<external-libs>
<fileset file="${emma.dir}/emma_device.jar" />
</external-libs>
</dex-helper>
</target>
<!-- Invoked from external files for code coverage purposes -->
<target name="-package-with-emma" depends="-dex-instrumented, -package-resources">
<package-helper sign.package="true">
<extra-jars>
<!-- Injected from external file -->
<jarfile path="${emma.dir}/emma_device.jar" />
</extra-jars>
</package-helper>
</target>
<target name="-debug-with-emma" depends="-package-with-emma">
<zipalign-helper in.package="${out.debug.unaligned.package}"
out.package="${out.debug.package}" />
</target>
<target name="-install-with-emma" depends="-debug-with-emma">
<install-helper />
</target>
<!-- End of targets for code-coverage measurement purposes -->
<target name="help">
<!-- displays starts at col 13
|13 80| -->
<echo>Android Ant Build. Available targets:</echo>
<echo> help: Displays this help.</echo>
<echo> clean: Removes output files created by other targets.</echo>
<echo> compile: Compiles project's .java files into .class files.</echo>
<echo> debug: Builds the application and signs it with a debug key.</echo>
<echo> release: Builds the application. The generated apk file must be</echo>
<echo> signed before it is published.</echo>
<echo> install: Installs/reinstalls the debug package onto a running</echo>
<echo> emulator or device.</echo>
<echo> If the application was previously installed, the</echo>
<echo> signatures must match.</echo>
<echo> uninstall: Uninstalls the application from a running emulator or</echo>
<echo> device.</echo>
</target>
</project>

View file

@ -1,2 +0,0 @@
/armeabi
/x86

View file

@ -1,14 +0,0 @@
# This file is automatically generated by Android Tools.
# Do not modify this file -- YOUR CHANGES WILL BE ERASED!
#
# This file must be checked in Version Control Systems.
#
# To customize properties used by the Ant build system edit
# "ant.properties", and override values to adapt the script to your
# project structure.
#
# To enable ProGuard to shrink and obfuscate your code, uncomment this (available properties: sdk.dir, user.home):
# proguard.config=${sdk.dir}/tools/proguard/proguard-android.txt:proguard-project.txt
# Project target.
target=android-23

View file

@ -1,4 +0,0 @@
/GitVersion.java
BuildConstants.java
GCMConsts.java
nohup.out

View file

@ -1 +0,0 @@
LocIDsData.java

View file

@ -1,2 +0,0 @@
BuildConstants.java
Utils.java

View file

@ -1 +0,0 @@
gitvers.txt

View file

@ -1 +0,0 @@
gitvers.txt

View file

@ -10,11 +10,6 @@ def BUILDS = [ "Debug", "Release" ]
apply plugin: 'com.android.application'
dependencies {
compile files('../libs/gcm.jar')
compile files('../libs/android-support-v13.jar')
}
android {
buildToolsVersion '23.0.2'
defaultConfig {
@ -145,7 +140,15 @@ android {
}
dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
// Look into replacing this with a fetch too PENDING
compile files('../libs/gcm.jar')
// Should probably choose a version rather than risk having it
// upgraded on me. PENDING
compile 'com.android.support:support-v4:+'
// compile files('../libs/android-support-v13.jar')
xw4dbgCompile 'com.crittercism:crittercism-android-agent:+'
}
task mkImages(type: Exec) {

View file

@ -8,7 +8,6 @@
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="org.eehouse.android.xw4"
android:versionCode="111"
android:versionName="@string/app_version"
>
<!-- BE SURE TO MODIFY project.properties AND the variable TARGET in

View file

@ -6,9 +6,8 @@
own application, the package name must be changed from "com.example.*"
to come from a domain that you own or have control over. -->
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
package="org.eehouse.android.xw4dbg"
android:versionCode="110"
android:versionName="@string/app_version"
package="org.eehouse.android.xw4"
android:versionCode="111"
>
<!-- BE SURE TO MODIFY project.properties AND the variable TARGET in

View file

@ -17,7 +17,7 @@
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
*/
package org.eehouse.android.xw4dbg;
package org.eehouse.android.xw4;
import android.content.Context;
@ -28,9 +28,9 @@ import com.crittercism.app.Crittercism;
public class CrashTrack {
public static void init( Context context ) {
if ( 0 < BuildConstants.CRITTERCISM_APP_ID.length() ) {
if ( 0 < BuildConfig.CRITTERCISM_APP_ID.length() ) {
Crittercism.initialize(context.getApplicationContext(),
BuildConstants.CRITTERCISM_APP_ID );
BuildConfig.CRITTERCISM_APP_ID );
}
}
}