I'm using Mac OS X, my ant, java dependency satisfied the minimum requirement. When I build the source code by
ant build
I got the error like:
[echo] apache-cassandra: /Users/taiyuanz/git/cassandra-trunk/build.xml
[javac] Compiling 890 source files to /Users/taiyuanz/git/cassandra-trunk/build/classes/main
[javac] Note: Processing compiler hints annotations
[javac] warning: Supported source version 'RELEASE_6' from annotation processor 'org.openjdk.jmh.generators.BenchmarkProcessor' less than -source '1.8'
[javac] /Users/taiyuanz/git/cassandra-trunk/src/java/org/apache/cassandra/db/partitions/AbstractBTreePartition.java:33: error: reference to Row is ambiguous
[javac] public abstract class AbstractBTreePartition implements Partition, Iterable<Row>
[javac] ^
[javac] both interface org.apache.cassandra.db.rows.Row in org.apache.cassandra.db.rows and class org.apache.cassandra.db.Row in org.apache.cassandra.db match
[javac] /Users/taiyuanz/git/cassandra-trunk/src/java/org/apache/cassandra/db/partitions/PartitionUpdate.java:72: error: reference to Row is ambiguous
[javac] private BTree.Builder<Row> rowBuilder;
[javac] ^
[javac] both interface org.apache.cassandra.db.rows.Row in org.apache.cassandra.db.rows and class org.apache.cassandra.db.Row in org.apache.cassandra.db match
[javac] /Users/taiyuanz/git/cassandra-trunk/src/java/org/apache/cassandra/db/partitions/PartitionUpdate.java:164: error: reference to Row is ambiguous
[javac] public static PartitionUpdate singleRowUpdate(CFMetaData metadata, DecoratedKey key, Row row)
.......
All because of the same problem - ambiguity due to the Row class. How can one solve this?
It looks like you have source code from pre-3.0 and post-3.0 Cassandra in your source tree. I would run:
git clean -xfd
To see if that fixes it. Otherwise, delete the repository and start again with a clean clone.
Related
Am trying to build openJDK8 in windows 64-bit. Following https://stas-blogspot.blogspot.com/2012/09/building-openjdk-on-windows.html for building.
OS: Windows 7-64-bit
Installed Cygwin, Visual studio 2013, Microsoft SDK, Ant and set all the paths in environment variable.
Built make and freetype 64-bit. Using jdk7 from Oracle as boot-jdk. configure was success. Then when i given
make clean images
Getting build error in jdk:
d:\Preethi\openjdk8\jdk\src\share\classes\java\io\PrintStream.java:31: error: cannot access IllegalCharsetNameException
import java.nio.charset.IllegalCharsetNameException;
^
bad source file: d:\Preethi\openjdk8\build\windows-x86_64-normal-server-release\jdk\gensrc\java\nio\charset\IllegalCharsetNameException.java
file does not contain class java.nio.charset.IllegalCharsetNameException
Please remove or make sure it appears in the correct subdirectory of the sourcepath.
d:\Preethi\openjdk8\jdk\src\share\classes\java\io\ObjectOutputStream.java:37: error: cannot find symbol
import static java.io.ObjectStreamClass.processQueue;
^
symbol: static processQueue
location: class
d:\Preethi\openjdk8\jdk\src\share\classes\java\io\ObjectInputStream.java:44: error: cannot find symbol
import static java.io.ObjectStreamClass.processQueue;
^
symbol: static processQueue
location: class
d:\Preethi\openjdk8\jdk\src\share\classes\java\lang\annotation\Retention.java:44: error: cannot find symbol
#Retention(RetentionPolicy.RUNTIME)
^
symbol: method value()
location: #interface Retention
d:\Preethi\openjdk8\jdk\src\share\classes\java\lang\SuppressWarnings.java:52: error: cannot find symbol
#Target({TYPE, FIELD, METHOD, PARAMETER, CONSTRUCTOR, LOCAL_VARIABLE})
^
symbol: variable TYPE
d:\Preethi\openjdk8\jdk\src\share\classes\java\lang\SuppressWarnings.java:52: error: cannot find symbol
#Target({TYPE, FIELD, METHOD, PARAMETER, CONSTRUCTOR, LOCAL_VARIABLE})
^
symbol: variable FIELD
d:\Preethi\openjdk8\jdk\src\share\classes\java\lang\SuppressWarnings.java:52: error: cannot find symbol
#Target({TYPE, FIELD, METHOD, PARAMETER, CONSTRUCTOR, LOCAL_VARIABLE})
^
symbol: variable METHOD
d:\Preethi\openjdk8\jdk\src\share\classes\java\lang\SuppressWarnings.java:52: error: cannot find symbol
#Target({TYPE, FIELD, METHOD, PARAMETER, CONSTRUCTOR, LOCAL_VARIABLE})
^
symbol: variable PARAMETER
d:\Preethi\openjdk8\jdk\src\share\classes\java\lang\SuppressWarnings.java:52: error: cannot find symbol
#Target({TYPE, FIELD, METHOD, PARAMETER, CONSTRUCTOR, LOCAL_VARIABLE})
^
symbol: variable CONSTRUCTOR
d:\Preethi\openjdk8\jdk\src\share\classes\java\lang\SuppressWarnings.java:52: error: cannot find symbol
#Target({TYPE, FIELD, METHOD, PARAMETER, CONSTRUCTOR, LOCAL_VARIABLE})
^
symbol: variable LOCAL_VARIABLE
java.lang.AssertionError: annotationType(): unrecognized Attribute kind <error> (class com.sun.tools.javac.code.Attribute$Error)
at com.sun.tools.javac.util.Assert.error(Assert.java:133)
at com.sun.tools.javac.code.TypeAnnotations.annotationType(TypeAnnotations.java:180)
at com.sun.tools.javac.code.TypeAnnotations$TypeAnnotationPositions.separateAnnotationsKinds(TypeAnnotations.java:294)
at com.sun.tools.javac.code.TypeAnnotations$TypeAnnotationPositions.visitMethodDef(TypeAnnotations.java:1066)
at com.sun.tools.javac.tree.JCTree$JCMethodDecl.accept(JCTree.java:778)
at com.sun.tools.javac.tree.TreeScanner.scan(TreeScanner.java:49)
at com.sun.tools.javac.code.TypeAnnotations$TypeAnnotationPositions.scan(TypeAnnotations.java:275)
at com.sun.tools.javac.tree.TreeScanner.scan(TreeScanner.java:57)
at com.sun.tools.javac.code.TypeAnnotations$TypeAnnotationPositions.visitClassDef(TypeAnnotations.java:1042)
at com.sun.tools.javac.tree.JCTree$JCClassDecl.accept(JCTree.java:693)
at com.sun.tools.javac.tree.TreeScanner.scan(TreeScanner.java:49)
at com.sun.tools.javac.code.TypeAnnotations$TypeAnnotationPositions.scan(TypeAnnotations.java:275)
at com.sun.tools.javac.code.TypeAnnotations$1.run(TypeAnnotations.java:127)
at com.sun.tools.javac.comp.Annotate.flush(Annotate.java:152)
at com.sun.tools.javac.comp.Annotate.enterDone(Annotate.java:129)
at com.sun.tools.javac.comp.Enter.complete(Enter.java:512)
at com.sun.tools.javac.comp.Enter.main(Enter.java:471)
at com.sun.tools.javadoc.JavadocEnter.main(JavadocEnter.java:78)
at com.sun.tools.javadoc.JavadocTool.getRootDocImpl(JavadocTool.java:186)
at com.sun.tools.javadoc.Start.parseAndExecute(Start.java:346)
at com.sun.tools.javadoc.Start.begin(Start.java:219)
at com.sun.tools.javadoc.Start.begin(Start.java:205)
at com.sun.tools.javadoc.Main.execute(Main.java:64)
at com.sun.tools.javadoc.Main.main(Main.java:54)
javadoc: error - fatal error
makegensrc/GensrcSwing.gmk:77: recipe for target `/cygdrive/d/Preethi/openjdk8/build/windows-x86_64-normal-server-release/jdk/gensrc_no_srczip/_the.generated_be
aninfo' failed[2]: *** [/cygdrive/d/Preethi/openjdk8/build/windows-x86_64-normal-server-release/jdk/gensrc_no_srczip/_the.generated_beaninfo] Error 1
make[2]: *** Waiting for unfinished jobs....
BuildJdk.gmk:55: recipe for target `gensrc-only' failedmake[1]: *** [gensrc-only] Error 2
/cygdrive/d/Preethi/openjdk8//make/Main.gmk:116: recipe for target `jdk-only' failed
make: *** [jdk-only] Error 2
can somebody point-out the issue?
boot-jdk : java version "1.7.0_80" downloaded from Oracle. That blog is meant for openjdk 7 only. But i tried the same steps for building openjdk8 2 years back and it got success.
I just found this tool, MatJuice, which could save me days or even weeks of development, but it doesn't compile.
Although I don't know anything about Java, it doesn't look so hairy: the two errors are both located in the same file, in the same function, and the functionality looks generic (findParent), so maybe a Java programmer will know what it is about on the instant.
A breaking issue has been posted here more than a year ago and it doesn't seem the authors are willing to correct it. That is why I am asking here.
Bellow are the two errors :
[javac] /home/geoffrey/mclab-core/languages/Natlab/src/natlab/utils/NodeFinder.java:62: error: cannot find symbol
[javac] .filter(n -> clazz.isInstance(n) || n.getParent() == null)
[javac] ^
[javac] symbol: method getParent()
[javac] location: variable n of type Object
[javac] /home/geoffrey/mclab-core/languages/Natlab/src/natlab/utils/NodeFinder.java:66: error: incompatible types: Object cannot be converted to T
[javac] .orElse(null);
[javac] ^
[javac] where T is a type-variable:
[javac] T extends Object declared in method <T>findParent(Class<T>,ASTNode<?>)
Bellow is the related piece of code (the errors occur on line 3 and 7 in this extract)
public static <T> T findParent(Class<T> clazz, ASTNode<?> node) {
return Stream.iterate(node, ASTNode::getParent)
.filter(n -> clazz.isInstance(n) || n.getParent() == null)
.findFirst()
.filter(clazz::isInstance)
.map(clazz::cast)
.orElse(null);
}
The complete file is here (there are helpful comments in the file) along with the rest of the repo.
I tried to give it a go myself but with zero knowledge of Java, it is just too abstract for me to debug.
These errors are come out because of compiler doesn't know what ast.ASTNode is. There is no such class in the project. But there is Natlab.gen target from ant build file:
mclab-core/languages/Natlab/build.xml
Try to run Natlab.gen target and the directory gen (that contains necessary package ast.ASTNode) will be generated inside Natlab directory. This should fix compilation errors.
I am getting this error while smartbuilding my module named in.pispl.bankslipmodue and java package name in.pispl.bankslipmodule.ad_actionButton and class named ManualProcessActionHandler:
/opt/OpenbravoERP-3.0/openbravo-erp/srcAD/org/openbravo/erpCommon/ad_actionButton/ActionButtonJava_Responser.java:5294: cannot find symbol
[javac] symbol : method execute(org.openbravo.scheduling.ProcessBundle)
[javac] location: class in.pispl.bankslipmodule.ad_actionButton.ManualProcessActionHandler
[javac] new in.pispl.bankslipmodule.ad_actionButton.ManualProcessActionHandler().execute(pb);
Readme says
Android Screencast
Homepage : http://code.google.com/p/androidscreencast/
***********************
HOW TO BUILD THE PROJET
***********************
Copy file "andrdoiscreencast.conf.example" to parent folder.
Rename it to "androidscreencast.conf".
Use your text editor to tune the configuration
Launch ant (with target dist or jnpl).
`
androidscreencast.example.conf says this
// The tag added to produced jar (androidscreencast-xxxx.jar)
version=DEV
// The location of your android sdk installation
android.sdk=/a/b/c/android-sdk-linux_x86-1.5_r3
// JAR signing for jnlp startup
sign.keystore=../my_keystore
sign.storepass=xxx
sign.keypass=yyy
sign.alias=zzz
// for auto deployement to google code "downloads" section
gc.username=aaa#gmail.com
gc.password=www
I have installed ADT bundle which includes Eclpise and SDK to ~/ADT/adt-bundle-linux-x86_64-20131030 so what should I write in location of sdk? should it be adt-bundle-linux-x86_64-20131030/sdk ?
Ive tried the above but it fails with
ant -v -f AndroidScreencast/build.xml
Apache Ant(TM) version 1.9.3 compiled on February 19 2014
Buildfile: /home/euphoria/androidscreencast/AndroidScreencast/build.xml
Detected Java version: 1.8 in: /usr/lib/jvm/java-8-oracle/jre
Detected OS: Linux
parsing buildfile /home/euphoria/androidscreencast/AndroidScreencast/build.xml with URI = file:/home/euphoria/androidscreencast/AndroidScreencast/build.xml
Project base dir set to: /home/euphoria/androidscreencast/AndroidScreencast
parsing buildfile jar:file:/usr/share/ant/lib/ant.jar!/org/apache/tools/ant/antlib.xml with URI = jar:file:/usr/share/ant/lib/ant.jar!/org/apache/tools/ant/antlib.xml from a zip file
[property] Loading /home/euphoria/androidscreencast/androidscreencast.conf
Build sequence for target(s) `jnlp' is [init, compile, dist, jnlp]
Complete build sequence is [init, compile, dist, jnlp, clean, gc, ]
init:
[mkdir] Skipping /home/euphoria/androidscreencast/AndroidScreencast/bin because it already exists.
compile:
[javac] /home/euphoria/androidscreencast/AndroidScreencast/build.xml:26: warning: 'includeantruntime' was not set, defaulting to build.sysclasspath=last; set to false for repeatable builds
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/MyInjectEventApp.jar skipped - don't know how to handle it
[javac] net/srcz/android/screencast/Main.java added as net/srcz/android/screencast/Main.class doesn't exist.
[javac] net/srcz/android/screencast/api/AndroidDevice.java added as net/srcz/android/screencast/api/AndroidDevice.class doesn't exist.
[javac] net/srcz/android/screencast/api/StreamUtils.java added as net/srcz/android/screencast/api/StreamUtils.class doesn't exist.
[javac] net/srcz/android/screencast/api/file/FileInfo.java added as net/srcz/android/screencast/api/file/FileInfo.class doesn't exist.
[javac] net/srcz/android/screencast/api/injector/ConstEvtKey.java added as net/srcz/android/screencast/api/injector/ConstEvtKey.class doesn't exist.
[javac] net/srcz/android/screencast/api/injector/ConstEvtMotion.java added as net/srcz/android/screencast/api/injector/ConstEvtMotion.class doesn't exist.
[javac] net/srcz/android/screencast/api/injector/Injector.java added as net/srcz/android/screencast/api/injector/Injector.class doesn't exist.
[javac] net/srcz/android/screencast/api/injector/KeyCodeConverter.java added as net/srcz/android/screencast/api/injector/KeyCodeConverter.class doesn't exist.
[javac] net/srcz/android/screencast/api/injector/NullSyncProgressMonitor.java added as net/srcz/android/screencast/api/injector/NullSyncProgressMonitor.class doesn't exist.
[javac] net/srcz/android/screencast/api/injector/OutputStreamShellOutputReceiver.java added as net/srcz/android/screencast/api/injector/OutputStreamShellOutputReceiver.class doesn't exist.
[javac] net/srcz/android/screencast/api/injector/ScreenCaptureThread.java added as net/srcz/android/screencast/api/injector/ScreenCaptureThread.class doesn't exist.
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/api/injector/ddmlib.jar skipped - don't know how to handle it
[javac] net/srcz/android/screencast/api/recording/DataAtomOutputStream.java added as net/srcz/android/screencast/api/recording/DataAtomOutputStream.class doesn't exist.
[javac] net/srcz/android/screencast/api/recording/FilterImageOutputStream.java added as net/srcz/android/screencast/api/recording/FilterImageOutputStream.class doesn't exist.
[javac] net/srcz/android/screencast/api/recording/QuickTimeOutputStream.java added as net/srcz/android/screencast/api/recording/QuickTimeOutputStream.class doesn't exist.
[javac] net/srcz/android/screencast/app/Application.java added as net/srcz/android/screencast/app/Application.class doesn't exist.
[javac] net/srcz/android/screencast/app/SwingApplication.java added as net/srcz/android/screencast/app/SwingApplication.class doesn't exist.
[javac] net/srcz/android/screencast/ui/JDialogDeviceList.java added as net/srcz/android/screencast/ui/JDialogDeviceList.class doesn't exist.
[javac] net/srcz/android/screencast/ui/JDialogError.java added as net/srcz/android/screencast/ui/JDialogError.class doesn't exist.
[javac] net/srcz/android/screencast/ui/JDialogUrl.java added as net/srcz/android/screencast/ui/JDialogUrl.class doesn't exist.
[javac] net/srcz/android/screencast/ui/JFrameMain.java added as net/srcz/android/screencast/ui/JFrameMain.class doesn't exist.
[javac] net/srcz/android/screencast/ui/JPanelScreen.java added as net/srcz/android/screencast/ui/JPanelScreen.class doesn't exist.
[javac] net/srcz/android/screencast/ui/JSplashScreen.java added as net/srcz/android/screencast/ui/JSplashScreen.class doesn't exist.
[javac] net/srcz/android/screencast/ui/MultiLineLabelUI.java added as net/srcz/android/screencast/ui/MultiLineLabelUI.class doesn't exist.
[javac] net/srcz/android/screencast/ui/explorer/JFrameExplorer.java added as net/srcz/android/screencast/ui/explorer/JFrameExplorer.class doesn't exist.
[javac] net/srcz/android/screencast/ui/explorer/LazyLoadingTreeNode.java added as net/srcz/android/screencast/ui/explorer/LazyLoadingTreeNode.class doesn't exist.
[javac] net/srcz/android/screencast/ui/explorer/LazyMutableTreeNode.java added as net/srcz/android/screencast/ui/explorer/LazyMutableTreeNode.class doesn't exist.
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/ui/icon.png skipped - don't know how to handle it
[javac] net/srcz/android/screencast/ui/pm/JFrameApps.java added as net/srcz/android/screencast/ui/pm/JFrameApps.class doesn't exist.
[javac] net/srcz/android/screencast/ui/worker/AccumulativeRunnable.java added as net/srcz/android/screencast/ui/worker/AccumulativeRunnable.class doesn't exist.
[javac] net/srcz/android/screencast/ui/worker/SwingWorker.java added as net/srcz/android/screencast/ui/worker/SwingWorker.class doesn't exist.
[javac] Compiling 29 source files to /home/euphoria/androidscreencast/AndroidScreencast/bin
[javac] Using modern compiler
dropping /home/euphoria/androidscreencast/AndroidScreencast/ddmlib-DEV.jar from path as it doesn't exist
[javac] Compilation arguments:
[javac] '-nowarn'
[javac] '-d'
[javac] '/home/euphoria/androidscreencast/AndroidScreencast/bin'
[javac] '-classpath'
[javac] '/home/euphoria/androidscreencast/AndroidScreencast/bin:/usr/share/ant/lib/ant-launcher.jar:/usr/share/java/xmlParserAPIs.jar:/usr/share/java/xercesImpl.jar:/usr/share/ant/lib/ant-javamail.jar:/usr/share/ant/lib/ant-swing.jar:/usr/share/ant/lib/ant-junit.jar:/usr/share/ant/lib/ant-jsch.jar:/usr/share/ant/lib/ant-apache-bcel.jar:/usr/share/ant/lib/ant-apache-oro.jar:/usr/share/ant/lib/ant.jar:/usr/share/ant/lib/ant-apache-regexp.jar:/usr/share/ant/lib/ant-apache-bsf.jar:/usr/share/ant/lib/ant-apache-resolver.jar:/usr/share/ant/lib/ant-apache-xalan2.jar:/usr/share/ant/lib/ant-jmf.jar:/usr/share/ant/lib/ant-junit4.jar:/usr/share/ant/lib/ant-commons-logging.jar:/usr/share/ant/lib/ant-testutil.jar:/usr/share/ant/lib/ant-commons-net.jar:/usr/share/ant/lib/ant-apache-log4j.jar:/usr/share/ant/lib/ant-antlr.jar:/usr/share/ant/lib/ant-jdepend.jar:/usr/lib/jvm/java-8-oracle/lib/tools.jar'
[javac] '-sourcepath'
[javac] '/home/euphoria/androidscreencast/AndroidScreencast/src'
[javac] '-g:none'
[javac]
[javac] The ' characters around the executable and arguments are
[javac] not part of the command.
[javac] Files to be compiled:
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/Main.java
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/api/AndroidDevice.java
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/api/StreamUtils.java
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/api/file/FileInfo.java
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/api/injector/ConstEvtKey.java
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/api/injector/ConstEvtMotion.java
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/api/injector/Injector.java
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/api/injector/KeyCodeConverter.java
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/api/injector/NullSyncProgressMonitor.java
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/api/injector/OutputStreamShellOutputReceiver.java
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/api/injector/ScreenCaptureThread.java
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/api/recording/DataAtomOutputStream.java
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/api/recording/FilterImageOutputStream.java
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/api/recording/QuickTimeOutputStream.java
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/app/Application.java
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/app/SwingApplication.java
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/ui/JDialogDeviceList.java
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/ui/JDialogError.java
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/ui/JDialogUrl.java
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/ui/JFrameMain.java
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/ui/JPanelScreen.java
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/ui/JSplashScreen.java
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/ui/MultiLineLabelUI.java
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/ui/explorer/JFrameExplorer.java
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/ui/explorer/LazyLoadingTreeNode.java
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/ui/explorer/LazyMutableTreeNode.java
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/ui/pm/JFrameApps.java
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/ui/worker/AccumulativeRunnable.java
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/ui/worker/SwingWorker.java
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/Main.java:11: error: package com.android.ddmlib does not exist
[javac] import com.android.ddmlib.AndroidDebugBridge;
[javac] ^
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/Main.java:12: error: package com.android.ddmlib does not exist
[javac] import com.android.ddmlib.IDevice;
[javac] ^
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/api/injector/ScreenCaptureThread.java:12: error: package com.android.ddmlib does not exist
[javac] import com.android.ddmlib.IDevice;
[javac] ^
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/api/injector/ScreenCaptureThread.java:13: error: package com.android.ddmlib does not exist
[javac] import com.android.ddmlib.RawImage;
[javac] ^
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/ui/JFrameMain.java:34: error: package com.android.ddmlib does not exist
[javac] import com.android.ddmlib.IDevice;
[javac] ^
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/api/injector/Injector.java:12: error: package com.android.ddmlib does not exist
[javac] import com.android.ddmlib.IDevice;
[javac] ^
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/Main.java:18: error: cannot find symbol
[javac] IDevice device;
[javac] ^
[javac] symbol: class IDevice
[javac] location: class Main
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/Main.java:75: error: cannot find symbol
[javac] private void waitDeviceList(AndroidDebugBridge bridge) {
[javac] ^
[javac] symbol: class AndroidDebugBridge
[javac] location: class Main
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/ui/JFrameMain.java:70: error: cannot find symbol
[javac] private IDevice device;
[javac] ^
[javac] symbol: class IDevice
[javac] location: class JFrameMain
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/ui/JFrameMain.java:91: error: cannot find symbol
[javac] public JFrameMain(IDevice device) throws IOException {
[javac] ^
[javac] symbol: class IDevice
[javac] location: class JFrameMain
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/api/injector/ScreenCaptureThread.java:19: error: cannot find symbol
[javac] private IDevice device;
[javac] ^
[javac] symbol: class IDevice
[javac] location: class ScreenCaptureThread
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/api/injector/ScreenCaptureThread.java:37: error: cannot find symbol
[javac] public ScreenCaptureThread(IDevice device) {
[javac] ^
[javac] symbol: class IDevice
[javac] location: class ScreenCaptureThread
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/api/injector/ScreenCaptureThread.java:123: error: cannot find symbol
[javac] public void display(RawImage rawImage) {
[javac] ^
[javac] symbol: class RawImage
[javac] location: class ScreenCaptureThread
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/api/injector/Injector.java:19: error: cannot find symbol
[javac] IDevice device;
[javac] ^
[javac] symbol: class IDevice
[javac] location: class Injector
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/api/injector/Injector.java:35: error: cannot find symbol
[javac] public Injector(IDevice d) throws IOException {
[javac] ^
[javac] symbol: class IDevice
[javac] location: class Injector
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/api/AndroidDevice.java:13: error: package com.android.ddmlib does not exist
[javac] import com.android.ddmlib.IDevice;
[javac] ^
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/api/AndroidDevice.java:14: error: package com.android.ddmlib.SyncService does not exist
[javac] import com.android.ddmlib.SyncService.ISyncProgressMonitor;
[javac] ^
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/api/AndroidDevice.java:15: error: package com.android.ddmlib.SyncService does not exist
[javac] import com.android.ddmlib.SyncService.SyncResult;
[javac] ^
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/api/AndroidDevice.java:19: error: cannot find symbol
[javac] IDevice device;
[javac] ^
[javac] symbol: class IDevice
[javac] location: class AndroidDevice
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/api/AndroidDevice.java:21: error: cannot find symbol
[javac] public AndroidDevice(IDevice device) {
[javac] ^
[javac] symbol: class IDevice
[javac] location: class AndroidDevice
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/api/injector/NullSyncProgressMonitor.java:3: error: package com.android.ddmlib.SyncService does not exist
[javac] import com.android.ddmlib.SyncService.ISyncProgressMonitor;
[javac] ^
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/api/injector/NullSyncProgressMonitor.java:5: error: cannot find symbol
[javac] public class NullSyncProgressMonitor implements ISyncProgressMonitor {
[javac] ^
[javac] symbol: class ISyncProgressMonitor
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/api/injector/OutputStreamShellOutputReceiver.java:6: error: package com.android.ddmlib does not exist
[javac] import com.android.ddmlib.IShellOutputReceiver;
[javac] ^
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/api/injector/OutputStreamShellOutputReceiver.java:8: error: cannot find symbol
[javac] public class OutputStreamShellOutputReceiver implements IShellOutputReceiver {
[javac] ^
[javac] symbol: class IShellOutputReceiver
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/ui/JDialogDeviceList.java:21: error: package com.android.ddmlib does not exist
[javac] import com.android.ddmlib.IDevice;
[javac] ^
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/ui/JDialogDeviceList.java:38: error: cannot find symbol
[javac] IDevice[] devices;
[javac] ^
[javac] symbol: class IDevice
[javac] location: class JDialogDeviceList
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/ui/JDialogDeviceList.java:40: error: cannot find symbol
[javac] public JDialogDeviceList(IDevice[] devices) {
[javac] ^
[javac] symbol: class IDevice
[javac] location: class JDialogDeviceList
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/ui/JDialogDeviceList.java:95: error: cannot find symbol
[javac] public IDevice getDevice() {
[javac] ^
[javac] symbol: class IDevice
[javac] location: class JDialogDeviceList
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/ui/explorer/JFrameExplorer.java:28: error: package com.android.ddmlib does not exist
[javac] import com.android.ddmlib.IDevice;
[javac] ^
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/ui/explorer/JFrameExplorer.java:34: error: cannot find symbol
[javac] IDevice device;
[javac] ^
[javac] symbol: class IDevice
[javac] location: class JFrameExplorer
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/ui/explorer/JFrameExplorer.java:77: error: cannot find symbol
[javac] public JFrameExplorer(IDevice device) {
[javac] ^
[javac] symbol: class IDevice
[javac] location: class JFrameExplorer
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/Main.java:36: error: cannot find symbol
[javac] AndroidDebugBridge bridge = AndroidDebugBridge.createBridge();
[javac] ^
[javac] symbol: class AndroidDebugBridge
[javac] location: class Main
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/Main.java:36: error: cannot find symbol
[javac] AndroidDebugBridge bridge = AndroidDebugBridge.createBridge();
[javac] ^
[javac] symbol: variable AndroidDebugBridge
[javac] location: class Main
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/Main.java:39: error: cannot find symbol
[javac] IDevice devices[] = bridge.getDevices();
[javac] ^
[javac] symbol: class IDevice
[javac] location: class Main
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/Main.java:98: error: cannot find symbol
[javac] AndroidDebugBridge.terminate();
[javac] ^
[javac] symbol: variable AndroidDebugBridge
[javac] location: class Main
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/api/injector/ScreenCaptureThread.java:100: error: cannot find symbol
[javac] RawImage rawImage = null;
[javac] ^
[javac] symbol: class RawImage
[javac] location: class ScreenCaptureThread
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/api/AndroidDevice.java:45: error: cannot find symbol
[javac] SyncResult result = device.getSyncService().pushFile(localFrom.getAbsolutePath(),
[javac] ^
[javac] symbol: class SyncResult
[javac] location: class AndroidDevice
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/api/AndroidDevice.java:63: error: cannot find symbol
[javac] ISyncProgressMonitor.class);
[javac] ^
[javac] symbol: class ISyncProgressMonitor
[javac] location: class AndroidDevice
[javac] /home/euphoria/androidscreencast/AndroidScreencast/src/net/srcz/android/screencast/ui/JDialogDeviceList.java:98: error: cannot find symbol
[javac] return (IDevice)jlDevices.getSelectedValue();
[javac] ^
[javac] symbol: class IDevice
[javac] location: class JDialogDeviceList
[javac] Note: Some input files use unchecked or unsafe operations.
[javac] Note: Recompile with -Xlint:unchecked for details.
[javac] 39 errors
BUILD FAILED
/home/euphoria/androidscreencast/AndroidScreencast/build.xml:26: Compile failed; see the compiler error output for details.
at org.apache.tools.ant.taskdefs.Javac.compile(Javac.java:1174)
at org.apache.tools.ant.taskdefs.Javac.execute(Javac.java:930)
at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:292)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:483)
at org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106)
at org.apache.tools.ant.Task.perform(Task.java:348)
at org.apache.tools.ant.Target.execute(Target.java:435)
at org.apache.tools.ant.Target.performTasks(Target.java:456)
at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1393)
at org.apache.tools.ant.Project.executeTarget(Project.java:1364)
at org.apache.tools.ant.helper.DefaultExecutor.executeTargets(DefaultExecutor.java:41)
at org.apache.tools.ant.Project.executeTargets(Project.java:1248)
at org.apache.tools.ant.Main.runBuild(Main.java:851)
at org.apache.tools.ant.Main.startAnt(Main.java:235)
at org.apache.tools.ant.launch.Launcher.run(Launcher.java:280)
at org.apache.tools.ant.launch.Launcher.main(Launcher.java:109)`
Total time: 7 seconds
what does Launch ant (with target dist or jnpl) mean?
You cannot run this project at all because of the following error : -
java.io.FileNotFoundException: androidscreencast (The system cannot find the file specified)
at java.io.FileInputStream.open(Native Method)
at java.io.FileInputStream.<init>(Unknown Source)
at java.io.FileInputStream.<init>(Unknown Source)
at com.sun.javaws.jnl.LaunchDescFactory.buildDescriptor(Unknown Source)
at com.sun.javaws.Main.launchApp(Unknown Source)
at com.sun.javaws.Main.continueInSecureThread(Unknown Source)
at com.sun.javaws.Main.access$000(Unknown Source)
at com.sun.javaws.Main$1.run(Unknown Source)
at java.lang.Thread.run(Unknown Source)
Thanks !
Regarding the file "androidscreencast.conf" (which is a copy of "...example"):
Yes, enter path to your android-sdk-basedirectory (maybe /home/yourusername/adt-bundle-linux-x86_64-20131030/sdk/ in your case), build.xml expects a directory "tools/lib/" to be there:
android.sdk=/path/to/your/android/sdk/installation
If you don't know what to enter for...
sign.keystore=../my_keystore
sign.storepass=xxx
sign.keypass=yyy
sign.alias=zzz
...or run into trouble when it comes to signing/security, make yourself familiar with the "keytool" command - it's pretty simple once you get it. Basically you need to "keytool -genkeypair", or at least that's what I needed to do. then, edit the above lines from the config file to your needs. (You will know what to do after using "keytool".)
"Launch ant (with target dist or jnlp)" means:
Enter either "ant dist" or "ant jnlp" or both at the same time "ant dist jnlp" to compile/build androidscreencast. "dist" will create a subdirectory ("dist/") with the jar-files, "jnlp" does the signing (see above) of the jar-files.
To run androidscreencast:
Enter "dist/" directory, then type...
javaws androidscreencast-DEV.jnlp
(compare config file's first line: version=DEV)
Most likely you will run into trouble now.
First Bugfix: Remove the "codebase=...googlecode..." (line 3) from the androidscreencast-DEV.jnlp file. This will make the jnlp-file/javaws use local jar's instead of downloading from a outdated, non-existent URL.
Second Bugfix: When I enter "javaws" it's in fact "icedtea". Make sure you have IcedTea 1.6.2 or higher. (Some bugfix regarding null-pointer on application-initialization. Or something.)
Third Bugfix: You may have to copy "MyInjectEventApp.jar" and "icon.png" files from the src-tree to correct places. I think you have to copy "MyInjectEventApp.jar" to "bin/" and "icon.png" to "bin/net/srcz/android/screencast". (All inside the "AndroidScreencast/"-directory, not absolute linux filesystem paths!) ("grep" the source code folder for these two filenames to see the paths in the source code. Paths are relative to bin/net/srcz/android/screencast, which is the location of the "Main.class". A leading slash points to "bin/".) Then re-run "ant dist" to rebuild the jar-files to "dist/"-directory. (No need to re-run "ant jnlp" at this point.)
Fourth bugfix: ddmlib.jar not found / unknown symbol IDevice / ... - to fix these bugs edit "build.xml" to make use of the "ddmlib.jar" provided with the AndroidScreencast-archive, and not something else (nothing found, or newer version from the Android-SDK, which does not work with the sourcecode). You may have to download "ddmlib.jar" separately from where you downloaded AndroidScreencast. To make "build.xml" use your local "ddmlib.jar"-file now, change line 28...
<javac nowarn="true" srcdir="${src}" destdir="${build}" classpath="${ddmlib}"/>
...to:
<javac nowarn="true" srcdir="${src}" destdir="${build}" classpath="ddmlib.jar"/>
...and line 35...
<copy file="${sdk-ddmlib}" tofile="${dist}/${ddmlib}"/>
...to:
<copy file="ddmlib.jar" tofile="${dist}/${ddmlib}"/>
Phew, that should be it! I now can see my cellphone on my desktop! :-)
(Next step will be rooting the phone (Android 2.3.5) to be able to control it with the mouse & keyboard.)
This question is unlikely to help any future visitors; it is only relevant to a small geographic area, a specific moment in time, or an extraordinarily narrow situation that is not generally applicable to the worldwide audience of the internet. For help making this question more broadly applicable, visit the help center.
Closed 11 years ago.
I have following line in a jsp page from an open source project:
<html:option value="micg">µg</html:option>
When I compile it using maven following code is generated:
_jspx_th_html_005foption_005f9.setValue("micg");
int _jspx_eval_html_005foption_005f9 = _jspx_th_html_005foption_005f9.doStartTag();
if (_jspx_eval_html_005foption_005f9 != javax.servlet.jsp.tagext.Tag.SKIP_BODY) {
if (_jspx_eval_html_005foption_005f9 != javax.servlet.jsp.tagext.Tag.EVAL_BODY_INCLUDE) {
out = _jspx_page_context.pushBody();
_jspx_th_html_005foption_005f9.setBodyContent((javax.servlet.jsp.tagext.BodyContent) out);
_jspx_th_html_005foption_005f9.doInitBody();
}
do {
out.write('Â');
out.write('µ');
out.write('g');
int evalDoAfterBody = _jspx_th_html_005foption_005f9.doAfterBody();
if (evalDoAfterBody != javax.servlet.jsp.tagext.BodyTag.EVAL_BODY_AGAIN)
break;
} while (true);
if (_jspx_eval_html_005foption_005f9 != javax.servlet.jsp.tagext.Tag.EVAL_BODY_INCLUDE) {
out = _jspx_page_context.popBody();
}
}
This is causing following error in compiling generated java file:
[javac] Compiling 1375 source files
[javac] warning: [options] bootstrap class path not set in conjunction
with -source 1.5
[javac] D:\src\WriteScript_jsp.java:2310: error: unclosed character literal
[javac] out.write('Â');
[javac] ^
[javac] D:\src\WriteScript_jsp.java:2310: error: illegal character: \8218
[javac] out.write('Â');
[javac] ^
[javac] D:\src\WriteScript_jsp.java:2310: error: unclosed character literal
[javac] out.write('Â');
[javac] ^
[javac] D:\src\WriteScript_jsp.java:2311: error: unclosed character literal
[javac] out.write('µ');
[javac] ^
[javac] D:\src\WriteScript_jsp.java:2311: error: ';' expected
[javac] out.write('µ');
[javac] ^
[javac] D:\src\WriteScript_jsp.java:2311: error: unclosed character literal
[javac] out.write('µ');
[javac] ^
[javac] 6 errors
Please help me how to remove this error :( I am on Windows 7 64-bit and JDK version 1.7.
The presence of the  in the generated Java source indicates that you've saved the JSP source code as ISO-8859-x instead of UTF-8 (or that JSP parser is reading it as ISO-8859-x instead of UTF-8 which is unlikely). Check/reconfigure your source code editor and make sure that it saves the JSP source code as UTF-8.
An alternative to ensuring you have -encoding correct everywhere, as suggested by other responders, is to not use non-lower-ASCII characters in your file. This can be acomplished with the \u escape, for example, by writing:
out.write('\u006c');
..instead of:
out.write('Â');
Nowhere near as pretty or convenient, but much easier to get to work in large teams, especially if you only have Scary Foreign Moon Language Characters in limited locations in your applications, as most development teams who deal with this kind of thing do.