getting compilation error on javafx,android

489 views
Skip to first unread message

Satish Niche

unread,
Dec 27, 2013, 7:20:11 AM12/27/13
to javafx...@googlegroups.com

Please help,

I am getting the following error

-dex:
    [mkdir] Created dir: /opt/HelloWorld/bin/app_dex
     [exec]
     [exec] UNEXPECTED TOP-LEVEL EXCEPTION:
     [exec] java.io.FileNotFoundException: app-libs/Application_classes.jar (No such file or directory)
     [exec]     at java.util.zip.ZipFile.open(Native Method)
     [exec]     at java.util.zip.ZipFile.<init>(ZipFile.java:215)
     [exec]     at java.util.zip.ZipFile.<init>(ZipFile.java:145)
     [exec]     at java.util.zip.ZipFile.<init>(ZipFile.java:159)
     [exec]     at com.android.dx.cf.direct.ClassPathOpener.processArchive(ClassPathOpener.java:244)
     [exec]     at com.android.dx.cf.direct.ClassPathOpener.processOne(ClassPathOpener.java:166)
     [exec]     at com.android.dx.cf.direct.ClassPathOpener.process(ClassPathOpener.java:144)
     [exec]     at com.android.dx.command.dexer.Main.processOne(Main.java:596)
     [exec]     at com.android.dx.command.dexer.Main.processAllFiles(Main.java:498)
     [exec]     at com.android.dx.command.dexer.Main.runMonoDex(Main.java:264)
     [exec]     at com.android.dx.command.dexer.Main.run(Main.java:230)
     [exec]     at com.android.dx.command.dexer.Main.main(Main.java:199)
     [exec]     at com.android.dx.command.Main.main(Main.java:103)
     [exec] 1 error; aborting

BUILD FAILED
/opt/HelloWorld/build-extras.xml:51: The following error occurred while executing this line:
/opt/HelloWorld/build-extras.xml:52: The following error occurred while executing this line:
/opt/HelloWorld/build-extras.xml:62: The following error occurred while executing this line:
/opt/HelloWorld/build-extras.xml:38: exec returned: 1

snf...@gmx.de

unread,
Dec 27, 2013, 6:55:30 PM12/27/13
to javafx...@googlegroups.com
Hi,

can you please post the create script, with which you created your android project?

The android project contains a base.properties file. The jfx.app.dist.dir property in this file should point to a directory, which should contain the jar file(s) of your application.

Stefan

Satish Niche

unread,
Dec 30, 2013, 12:26:28 AM12/30/13
to javafx...@googlegroups.com

Hi Stefan,

Please find the script

#!/bin/bash
# this is an example script. Change the parameters according to your local setup
# in particular,
# * change JAVA_APP_DIR to the directory containing your jar(s)
# * change MAIN_CLASS to the fqn of your main class
# * change WORKDIR to the directory where you want the android project to be created
export ANDROID_SDK=/opt/android-sdk-linux
export PATH=$ANDROID_SDK/tools:$PATH
export CURRENT_DIR=`pwd`
export WORKDIR=/opt/
export JAVA_APP_DIR=/opt/jfxports/apps/samples/Ensemble8/dict
export MAIN_CLASS=ensemble.EnsembleApp
/opt/gradle-1.4/bin/gradle --info createProject -PDEBUG -PDIR=$WORKDIR -PPACKAGE=org.javafxports -PNAME=HelloWorld -PANDROID_SDK=$ANDROID_SDK -PJFX_SDK=$CURRENT_DIR/.. -PJFX_APP=$JAVA_APP_DIR -PJFX_MAIN=$MAIN_CLASS

Thanks
Shahid

Satish Niche

unread,
Dec 30, 2013, 12:29:56 AM12/30/13
to javafx...@googlegroups.com


On Monday, December 30, 2013 10:56:28 AM UTC+5:30, Satish Niche wrote:

Hi Stefan,

Please find the script

#!/bin/bash
# this is an example script. Change the parameters according to your local setup
# in particular,
# * change JAVA_APP_DIR to the directory containing your jar(s)
# * change MAIN_CLASS to the fqn of your main class
# * change WORKDIR to the directory where you want the android project to be created
export ANDROID_SDK=/opt/android-sdk-linux
export PATH=$ANDROID_SDK/tools:$PATH
export CURRENT_DIR=`pwd`
export WORKDIR=/opt/
export JAVA_APP_DIR=/opt/jfxports/apps/samples/Ensemble8/dict
export MAIN_CLASS=ensemble.EnsembleApp
/opt/gradle-1.4/bin/gradle --info createProject -PDEBUG -PDIR=$WORKDIR -PPACKAGE=org.javafxports -PNAME=HelloWorld -PANDROID_SDK=$ANDROID_SDK -PJFX_SDK=$CURRENT_DIR/.. -PJFX_APP=$JAVA_APP_DIR -PJFX_MAIN=$MAIN_CLASS

base.properties file

jfx.sdk=/opt/dalvik-sdk/android-tools/..
jfx.app.dist.dir=/opt/jfxports/apps/samples/Ensemble8/dict
isDalvik=true

but /opt/jfxports/apps/samples/Ensemble8/dict, directory contains no jar files.

Please help me, where can i point this.

 
 

Stefan Fuchs

unread,
Dec 30, 2013, 8:28:54 AM12/30/13
to javafx...@googlegroups.com
Hi,

first of all, I don't think it is a good idea to assign your workdir to /opt . You should probably use some directory within your users home.

I assume you are trying to build Ensemble8?
To build Ensemble8 you must build the JavaFX Android SDK with the command: gradle apps.
This should create the Ensemble8.jar in .... apps/samples/Ensemble8/dist.
Note that the directory is dist as in distribution and not dict.

regards,

Stefan

Satish Niche

unread,
Jan 2, 2014, 12:46:56 AM1/2/14
to javafx...@googlegroups.com

Hi Stefan,

When i am running gradle apps command in JavaFX Android SDK.

Getting the following error.
FAILURE: Build failed with an exception.

* Where:
Script '/opt/jfxports/buildSrc/linux.gradle' line: 102

* What went wrong:
A problem occurred evaluating script.
> Cannot invoke method split() on null object

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.

BUILD FAILED

Thanks

Stefan Fuchs

unread,
Jan 3, 2014, 9:33:59 AM1/3/14
to javafx...@googlegroups.com
Hi,

please make sure, that your user can write to /opt/jfxports/ and that you have all the required development packages installed.
See https://wiki.openjdk.java.net/display/OpenJFX/Building+OpenJFX#BuildingOpenJFX-LinuxDesktopBuildLinux.

- Stefan

bek.h...@gmail.com

unread,
Apr 17, 2014, 7:12:16 AM4/17/14
to javafx...@googlegroups.com
Hi i have the same problem do you fix it ?
I work whith Mac os x 10.9 and oracle jdk 7_u45

Picked up JAVA_TOOL_OPTIONS: -agentlib:TakipiAgent
Buildfile: /Volumes/data/work/mobile/workspaces/nb/samplejfx/build.xml

-set-mode-check:

-set-debug-files:

-check-env:
[checkenv] Android SDK Tools Revision 22.6.2
[checkenv] Installed at /Volumes/data/work/mobile/adt-bundle-mac-x86_64-20130729/sdk

-setup:
[echo] Project Name: samplejfx
[gettype] Project Type: Application

-set-debug-mode:

-debug-obfuscation-check:

-check-jfx.uptodate:

-jfx.bootstrap:

-check-app.uptodate:

-app.bootstrap:

-pre-build:

-build-setup:
[getbuildtools] Using latest Build Tools: 19.0.3
[echo] Resolving Build Target for samplejfx...
[gettarget] Project Target: Android 4.3
[gettarget] API level: 18
[gettarget] WARNING: No minSdkVersion value set. Application will install on all Android versions.
[echo] ----------
[echo] Creating output directories if needed...
[mkdir] Created dir: /Volumes/data/work/mobile/workspaces/nb/samplejfx/bin/rsObj
[mkdir] Created dir: /Volumes/data/work/mobile/workspaces/nb/samplejfx/bin/rsLibs
[echo] ----------
[echo] Resolving Dependencies for samplejfx...
[dependency] Library dependencies:
[dependency] No Libraries
[dependency]
[dependency] ------------------
[echo] ----------
[echo] Building Libraries with 'debug'...
[subant] No sub-builds to iterate on

-code-gen:
[mergemanifest] No changes in the AndroidManifest files.
[echo] Handling aidl files...
[aidl] No AIDL files to compile.
[echo] ----------
[echo] Handling RenderScript files...
[echo] ----------
[echo] Handling Resources...
[aapt] No changed resources. R.java and Manifest.java untouched.
[echo] ----------
[echo] Handling BuildConfig class...
[buildconfig] Generating BuildConfig class.

-pre-compile:

-compile:
[javac] Compiling 1 source file to /Volumes/data/work/mobile/workspaces/nb/samplejfx/bin/classes

-post-compile:

-obfuscate:

-application.jar:

-pre-dex:

-dex:
[exec] Picked up JAVA_TOOL_OPTIONS: -agentlib:TakipiAgent
[exec] Picked up JAVA_TOOL_OPTIONS: -agentlib:TakipiAgent


[exec]
[exec] UNEXPECTED TOP-LEVEL EXCEPTION:

[exec] java.io.FileNotFoundException: /Volumes/data/work/mobile/workspaces/nb/samplejfx/app-libs/Application_classes.jar (No such file or directory)


[exec] at java.util.zip.ZipFile.open(Native Method)
[exec] at java.util.zip.ZipFile.<init>(ZipFile.java:215)
[exec] at java.util.zip.ZipFile.<init>(ZipFile.java:145)
[exec] at java.util.zip.ZipFile.<init>(ZipFile.java:159)
[exec] at com.android.dx.cf.direct.ClassPathOpener.processArchive(ClassPathOpener.java:244)
[exec] at com.android.dx.cf.direct.ClassPathOpener.processOne(ClassPathOpener.java:166)
[exec] at com.android.dx.cf.direct.ClassPathOpener.process(ClassPathOpener.java:144)
[exec] at com.android.dx.command.dexer.Main.processOne(Main.java:596)
[exec] at com.android.dx.command.dexer.Main.processAllFiles(Main.java:498)

[exec] at com.android.dx.command.dexer.Main.runMultiDex(Main.java:317)
[exec] at com.android.dx.command.dexer.Main.run(Main.java:228)


[exec] at com.android.dx.command.dexer.Main.main(Main.java:199)
[exec] at com.android.dx.command.Main.main(Main.java:103)
[exec] 1 error; aborting

BUILD FAILED
/Volumes/data/work/mobile/workspaces/nb/dalvik-sdk/android-tools/build-extras.xml:117: The following error occurred while executing this line:
/Volumes/data/work/mobile/workspaces/nb/dalvik-sdk/android-tools/build-extras.xml:118: The following error occurred while executing this line:
/Volumes/data/work/mobile/workspaces/nb/dalvik-sdk/android-tools/build-extras.xml:128: The following error occurred while executing this line:
/Volumes/data/work/mobile/workspaces/nb/dalvik-sdk/android-tools/build-extras.xml:103: exec returned: 1

Stefan Fuchs

unread,
Apr 20, 2014, 10:50:30 PM4/20/14
to javafx...@googlegroups.com, bek.h...@gmail.com
Hi,

can you please post the contents of
/Volumes/data/work/mobile/workspaces/nb/samplejfx/app-libs/ ?

Does it contain an Application.jar file?
Does your JFX_APP dir contain any jar files?

regards,

Stefan

Message has been deleted

bek.h...@gmail.com

unread,
Apr 29, 2014, 12:30:02 PM4/29/14
to javafx...@googlegroups.com, bek.h...@gmail.com

Hi stefan
the"../samplejfx/app-libs/" contain one file "Application.jar"
and for JFX_APP which is the dist i suppose is empty

thank you

Stefan Fuchs

unread,
Apr 30, 2014, 6:42:21 PM4/30/14
to javafx...@googlegroups.com, bek.h...@gmail.com
Hi Satish,

with JFX_APP I mean the parameter to the create script for the Android Project. It should point to a directory containing jar file(s) of your compiled javafx application. This directory must not be empty. You must provide your application in this directory.

Regards,
Stefan
Reply all
Reply to author
Forward
0 new messages