godotengine / godot

Godot Engine – Multi-platform 2D and 3D game engine
https://godotengine.org
MIT License
88.89k stars 20.15k forks source link

Exporting APK in Ubuntu Linux. #3539

Closed OBKF closed 8 years ago

OBKF commented 8 years ago

Hello, I am trying to export my game to apk in Ubuntu but i can't find the jarsigner binary, when i use thejarsigner command in the terminal i got this: Picked up JAVA_TOOL_OPTIONS: -javaagent:/usr/share/java/jayatanaag.jar Usage: jarsigner [options] jar-file alias jarsigner -verify [options] jar-file [alias...]

i tried to use it for the export but the apk doesn't run on my phone.

freemanfromgodotengine commented 8 years ago

You need JDK 6. Also system needs to know where your java is installed, so you need for example if you use oracles jdk6: export JAVA_HOME=/usr/lib/jvm/java-6-oracle

In this case the jarsigner should be located for at /usr/lib/jvm/java-6-oracle/bin . You should be able to also run it from that directory.

Apk does not run cause it is not signed.

akien-mga commented 8 years ago

You need JDK 6.

As far as I know OpenJDK 8 works fine too.

volzhs commented 8 years ago

I have used OpenJDK 7 recently, and it's fine.

freemanfromgodotengine commented 8 years ago

I used JDK 7 before, but wanted to be save when helping and I remember that official wiki says about JDK 6.

akien-mga commented 8 years ago

@godotengine/documentation The wiki needs to be fixed indeed:

OBKF commented 8 years ago

i have found it in /usr/lib/jvm/java-8-oracle/bin i have now a problem with

Picked up JAVA_TOOL_OPTIONS: -javaagent:/usr/share/java/jayatanaag.jar jarsigner error: java.lang.RuntimeException: keystore load: Keystore was tampered with, or password was incorrect returned: 4753, waiting for: 4753 ERROR: add_io_error: 'jarsigner' returned with error #1 At: tools/editor/editor_node.cpp:3879. TextureButton: 16,-4 Label: 146,63 HBoxContainer: 53,27 ERROR: export_platform: Exporting failed! At: tools/editor/project_export.cpp:528.

akien-mga commented 8 years ago

IIRC I fixed this in the documentation.

akien-mga commented 8 years ago

@Oussama-dev About your last comment, it seems that your keystore is invalid, you might have to generate a new one.