Revision history [back]

click to hide/show revision 1
initial version

Error while building for java with Ubuntu

Hi,

I started All Joyn All Seen installation from here.

My machine: virtual box with ubuntu 14.04 LTS 64 bit

[Build tools and libs]

1) sudo apt-get install build-essential libgtk2.0-dev libssl-dev xsltproc ia32-libs libxml2-dev

[out]

Reading package lists... Done Building dependency tree
Reading state information... Done build-essential is already the newest version. libgtk2.0-dev is already the newest version. The following packages were automatically installed and are no longer required: kde-l10n-engb kde-l10n-it Use 'apt-get autoremove' to remove them. 0 upgraded, 0 newly installed, 0 to remove and 7 not upgraded.]

2) - skip, I'm working on a 64 bit (virtual) machine

[Python v2.6/2.7]

1) which python

[out]

/usr/bin/python

python --version

[out]

Python 2.7.6

[SCons v2.0]

sudo apt-get install scons

[out]

Reading package lists... Done Building dependency tree
Reading state information... Done scons is already the newest version. The following packages were automatically installed and are no longer required: kde-l10n-engb kde-l10n-it Use 'apt-get autoremove' to remove them. 0 upgraded, 0 newly installed, 0 to remove and 7 not upgraded.

[openSSL]

sudo apt-get install libssl-dev

[out]

Reading package lists... Done Building dependency tree
Reading state information... Done libssl-dev is already the newest version. The following packages were automatically installed and are no longer required: kde-l10n-engb kde-l10n-it Use 'apt-get autoremove' to remove them. 0 upgraded, 0 newly installed, 0 to remove and 7 not upgraded.

[git v1.7]

sudo apt-get install git-core

[out]

Reading package lists... Done Building dependency tree
Reading state information... Done git-core is already the newest version. The following packages were automatically installed and are no longer required: kde-l10n-engb kde-l10n-it Use 'apt-get autoremove' to remove them. 0 upgraded, 0 newly installed, 0 to remove and 7 not upgraded.

[Repo]

skip

[Uncrustify v0.57]

download from http://packages.ubuntu.com/precise/uncrustify downloaded: uncrustify_0.57-1_amd64.deb sudo dpkg -i uncrustify_0.57-1_amd64.deb

[out]

Reading package lists... Done Building dependency tree
Reading state information... Done git-core is already the newest version. The following packages were automatically installed and are no longer required: kde-l10n-engb kde-l10n-it Use 'apt-get autoremove' to remove them. 0 upgraded, 0 newly installed, 0 to remove and 7 not upgraded. toshi@toshi-VirtualBox:~/Desktop/sdk$ ^C toshi@toshi-VirtualBox:~/Desktop/sdk$ cd /home/toshi/Downloads/ toshi@toshi-VirtualBox:~/Downloads$ sudo dpkg -i uncrustify_0.57-1_amd64.deb (Reading database ... 241486 files and directories currently installed.) Preparing to unpack uncrustify_0.57-1_amd64.deb ... Unpacking uncrustify (0.57-1) over (0.57-1) ... Setting up uncrustify (0.57-1) ... Processing triggers for man-db (2.6.7.1-1ubuntu1) ...

[Doxygen]

sudo apt-get install doxygen

[out]

Reading package lists... Done Building dependency tree
Reading state information... Done doxygen is already the newest version. The following packages were automatically installed and are no longer required: kde-l10n-engb kde-l10n-it Use 'apt-get autoremove' to remove them. 0 upgraded, 0 newly installed, 0 to remove and 7 not upgraded.

[Graphviz]

sudo apt-get install graphviz

[out]

Reading package lists... Done Building dependency tree
Reading state information... Done graphviz is already the newest version. The following packages were automatically installed and are no longer required: kde-l10n-engb kde-l10n-it Use 'apt-get autoremove' to remove them. 0 upgraded, 0 newly installed, 0 to remove and 7 not upgraded.

[TeX Live]

sudo apt-get install texlive

[out]

Reading package lists... Done Building dependency tree
Reading state information... Done texlive is already the newest version. The following packages were automatically installed and are no longer required: kde-l10n-engb kde-l10n-it Use 'apt-get autoremove' to remove them. 0 upgraded, 0 newly installed, 0 to remove and 7 not upgraded.

[Gecko SDK]

not installed.

[Install Java - Installing Java 6 when using Ubuntu 12.04 or newer]

downloaded jdk-6u32-linux-x64.bin

chmod +x jdk-6u32-linux-x64.bin ./jdk-6u32-linux-x64.bin sudo mv jdk1.6.0_32 /usr/lib/jvm/

sudo update-alternatives --install /usr/bin/javac javac /usr/lib/jvm/jdk1.6.0_32/bin/javac 2 sudo update-alternatives --install /usr/bin/java java /usr/lib/jvm/jdk1.6.0_32/bin/java 2 sudo update-alternatives --install /usr/bin/javaws javaws /usr/lib/jvm/jdk1.6.0_32/bin/javaws 2 sudo update-alternatives --config javac sudo update-alternatives --config java sudo update-alternatives --config javaws

[out]

There is only one alternative in link group javaws (providing /usr/bin/javaws): /usr/lib/jvm/jdk1.6.0_32/bin/javaws Nothing to configure.

java -version

[out]

java version "1.6.0_32" Java(TM) SE Runtime Environment (build 1.6.0_32-b05) Java HotSpot(TM) 64-Bit Server VM (build 20.7-b02, mixed mode)

ls -la /etc/alternatives/java*

[out]

lrwxrwxrwx 1 root root 33 dic 23 11:28 /etc/alternatives/java -> /usr/lib/jvm/jdk1.6.0_32/bin/java lrwxrwxrwx 1 root root 34 dic 23 19:11 /etc/alternatives/javac -> /usr/lib/jvm/jdk1.6.0_32/bin/javac lrwxrwxrwx 1 root root 45 dic 23 15:18 /etc/alternatives/javadoc -> /usr/lib/jvm/java-7-openjdk-amd64/bin/javadoc lrwxrwxrwx 1 root root 55 dic 23 15:18 /etc/alternatives/javadoc.1.gz -> /usr/lib/jvm/java-7-openjdk-amd64/man/man1/javadoc.1.gz lrwxrwxrwx 1 root root 43 dic 23 15:18 /etc/alternatives/javah -> /usr/lib/jvm/java-7-openjdk-amd64/bin/javah lrwxrwxrwx 1 root root 53 dic 23 15:18 /etc/alternatives/javah.1.gz -> /usr/lib/jvm/java-7-openjdk-amd64/man/man1/javah.1.gz lrwxrwxrwx 1 root root 43 dic 23 15:18 /etc/alternatives/javap -> /usr/lib/jvm/java-7-openjdk-amd64/bin/javap lrwxrwxrwx 1 root root 53 dic 23 15:18 /etc/alternatives/javap.1.gz -> /usr/lib/jvm/java-7-openjdk-amd64/man/man1/javap.1.gz lrwxrwxrwx 1 root root 35 dic 19 17:59 /etc/alternatives/javaws -> /usr/lib/jvm/jdk1.6.0_32/bin/javaws

No Java plug-in for Mozilla!

Junit download from https://github.com/junit-team/junit/wiki/Download-and-Install

Downloaded junit-4.12.jar. sudo cp junit-4.12.jar /usr/share/java/ sudo apt-get install ant

Reading package lists... Done Building dependency tree
Reading state information... Done ant is already the newest version. The following packages were automatically installed and are no longer required: kde-l10n-engb kde-l10n-it Use 'apt-get autoremove' to remove them. 0 upgraded, 0 newly installed, 0 to remove and 7 not upgraded.

[googletest]

no installation

[Obtain the AllJoyn source]

git clone https://git.allseenalliance.org/gerrit/core/alljoyn.git

cd alljoyn

[Building the AllJoyn Framework]

export JAVA_HOME="/usr/lib/jvm/java-6-sun"

export CLASSPATH="/usr/share/java/junit-4.12.jar"

scons CPU=x86_64 BINDINGS="cpp,java"

[out]

scons: * No SConstruct file found. File "/usr/lib/scons/SCons/Script/Main.py", line 905, in _main toshi@toshi-VirtualBox:~/Desktop/sdk/alljoyn/alljoyn_core$ cd .. toshi@toshi-VirtualBox:~/Desktop/sdk/alljoyn$ scons CPU=x86_64 BINDINGS="cpp,java" scons: Reading SConscript files ... Building bindings: cpp, java Building services: BULLSEYE_BIN not specified GTEST_DIR not specified skipping common unit test build BULLSEYE_BIN not specified GTEST_DIR not specified skipping About Service unit test build GTEST_DIR not specified skipping alljoyn_core unit test build

scons: warning: Ignoring missing SConscript 'build/linux/x86_64/debug/obj/services/about/SConscript' File "/home/toshi/Desktop/sdk/alljoyn/alljoyn_core/samples/eventaction/SConscript", line 35, in <module> scons: done reading SConscript files. scons: Building targets ... [JAVAC] alljoyn_java/src/org/alljoyn/bus/AboutDataListener.java error: error reading /usr/share/java/junit-4.12.jar; error in opening zip file 1 error scons: * [build/linux/x86_64/debug/obj/alljoyn_java/classes/org/alljoyn/bus/AboutDataListener.class] Error 1 scons: building terminated because of errors.

scons CPU=x86_64 BINDINGS="cpp" WS=off

execution seemd to work properly, with java instead only error!

Is it a problem related to the junit document? For sure it is defined in usr/share/java! Could you help please? Thanks!