michelou / android-examples Goto Github PK
View Code? Open in Web Editor NEWAndroid code examples written in Scala
Android code examples written in Scala
Regardless of what project I run this with, I keep getting this error:
> ant debug
...
-compile-scala:
[scalac] Scala compiler version 2.9.2 - http://scala-lang.org
[scalac] Compiling 1 source file to android-sdks/android-examples/android-sdk/HelloActivity/bin/classes
[scalac] Compiling 0 scala and 2 java source files to android-sdks/android-examples/android-sdk/HelloActivity/bin/classes
BUILD FAILED
android-sdks/android-examples/android-sdk/HelloActivity/build-scala.xml:35: The following error occurred while executing this line:
android-sdks/android-examples/android-sdk/HelloActivity/build-scala.xml:44: /Users/lisaneigut/android-sdks/android-examples/android-sdk/HelloActivity/${extensible.libs.classpath} does not exist.
I can't find where this reference is being set.
Running the project as release:
> ant release
...
-compile-scala:
[scalac] Scala compiler version 2.9.2 - http://scala-lang.org
[scalac] Compiling 1 source file to android-sdks/android-examples/android-sdk/HelloActivity/bin/classes
[scalac] Compiling 0 scala and 2 java source files to android-sdks/android-examples/android-sdk/HelloActivity/bin/classes
BUILD FAILED
android-sdks/android-examples/android-sdk/HelloActivity/build-scala.xml:35: The following error occurred while executing this line:
android-sdks/android-examples/android-sdk/HelloActivity/build-scala.xml:44: /Users/lisaneigut/android-sdks/android-examples/android-sdk/HelloActivity/${extensible.libs.classpath} does not exist.
For reference:
Apache Ant(TM) version 1.8.2
java version "1.6.0_33
Scala 2.9.2
OS X 10.7.4
Great stuff! -- but needed at least one hack to the ant stuff: it appears that in Android SDK R18 the path id jar.libs.ref
has fallen out of the ant setup (I guess), so I had to resort to adding this to build-scala.xml:
<path id="jar.libs.ref">
<fileset dir="${jar.libs.absolute.dir}" includes="*.jar" />
<path refid="project.libraries.jars" />
</path>
(stolen from http://stackoverflow.com/questions/5312478/how-do-i-reference-external-jar-files-in-a-common-directory-not-libs-to-build).
(I also added a target my-compile-scala
depending on -compile-scala
, as I couldn't figure out how to run the target -compile-scala
: ant keeps complaining about the hyphen ... it's probably just me being dense :-)
In addition, the project needs a update before the first build:
> cd android-sdk/HelloActivity
> android update project -p . --target <something>
(where <something>
comes from > android list targets
) to build local.properties and update project.properties.
As a reference, here are the versions I'm using:
Cheers /festerman
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.