Hello, I’m trying to create an extension according to the guide here:
I did everything, everything is good, in java code I entered the code that is in the tutorial, and it does not work! I put everything in the path they wrote, and I run the command: ant extensions on the appinventor folder. This shows me the error:
Build failed```
And in the tutorial it is not written to create the file: build.xml!
CommonVersion:
[exec] Result: 128
[exec] Result: 128
[javac] Compiling 3 source files to /storage/emulated/0/appinventor-sources/appinventor/common/build/classes/CommonVersion
[javac] warning: [options] bootstrap class path not set in conjunction with -source 7
[javac] warning: [options] source value 7 is obsolete and will be removed in a future release
[javac] warning: [options] target value 7 is obsolete and will be removed in a future release
[javac] warning: [options] To suppress warnings about obsolete options, use -Xlint:-options.
[javac] /storage/emulated/0/appinventor-sources/appinventor/common/build/src/com/google/appinventor/common/version/GitBuildId.java:17: error: unclosed string literal
[javac] public static final String GIT_BUILD_VERSION = “fatal: not a git repository (or any parent up to mount point /storage)
[javac] ^
[javac] /storage/emulated/0/appinventor-sources/appinventor/common/build/src/com/google/appinventor/common/version/GitBuildId.java:18: error: ‘;’ expected
[javac] Stopping at filesystem boundary (GIT_DISCOVERY_ACROSS_FILESYSTEM not set).”;
[javac] ^
[javac] /storage/emulated/0/appinventor-sources/appinventor/common/build/src/com/google/appinventor/common/version/GitBuildId.java:18: error: ‘,’, ‘)’, or ‘[’ expected
[javac] Stopping at filesystem boundary (GIT_DISCOVERY_ACROSS_FILESYSTEM not set).";
[javac] ^
[javac] /storage/emulated/0/appinventor-sources/appinventor/common/build/src/com/google/appinventor/common/version/GitBuildId.java:18: error: unclosed string literal
[javac] Stopping at filesystem boundary (GIT_DISCOVERY_ACROSS_FILESYSTEM not set).";
[javac] ^
[javac] /storage/emulated/0/appinventor-sources/appinventor/common/build/src/com/google/appinventor/common/version/GitBuildId.java:19: error: unclosed string literal
[javac] public static final String GIT_BUILD_FINGERPRINT = “fatal: not a git repository (or any parent up to mount point /storage)
[javac] ^
[javac] /storage/emulated/0/appinventor-sources/appinventor/common/build/src/com/google/appinventor/common/version/GitBuildId.java:20: error: ‘;’ expected
[javac] Stopping at filesystem boundary (GIT_DISCOVERY_ACROSS_FILESYSTEM not set).”;
[javac] ^
[javac] /storage/emulated/0/appinventor-sources/appinventor/common/build/src/com/google/appinventor/common/version/GitBuildId.java:20: error: ‘,’, ‘)’, or ‘[’ expected
[javac] Stopping at filesystem boundary (GIT_DISCOVERY_ACROSS_FILESYSTEM not set).";
[javac] ^
[javac] /storage/emulated/0/appinventor-sources/appinventor/common/build/src/com/google/appinventor/common/version/GitBuildId.java:20: error: unclosed string literal
[javac] Stopping at filesystem boundary (GIT_DISCOVERY_ACROSS_FILESYSTEM not set).";
[javac] ^
[javac] 8 errors
[javac] 4 warnings
BUILD FAILED
/storage/emulated/0/appinventor-sources/appinventor/build.xml:46: The following error occurred while executing this line:
/storage/emulated/0/appinventor-sources/appinventor/build-common.xml:321: The following error occurred while executing this line:
/storage/emulated/0/appinventor-sources/appinventor/common/build.xml:118: The following error occurred while executing this line:
/storage/emulated/0/appinventor-sources/appinventor/build-common.xml:125: Compile failed; see the compiler error output for details.
Yes, I’m on vacation, I’m not home and I do not have the computer next to me, so I tried over the phone …
I thought it would work, because I installed everything properly …
By using proot (which could easily be done with a script by AnLiunux), it is possible to install jdk8 and apache-ant. I have built an extension successfully with the original appinventor-sources, but no luck with rush-cli.
Anyway, in my opinion, the most convenient way is what @vknow360 suggested, if you trust the website well enough.
Can you get me a Java code of an extension that will work? I tried a certain code and it did not work for me. I’d be happy if you bring me a code to check.
In the same page they have given link for collintree code, copy and paste into onecompiler.com , download it as java and upload into this site and click submit, you will see the aix
I went to the site you brought, downloaded the code that is there as Java, uploaded to the site of the extensions, sent and received the error:
Error: Config does not contain a field package failed auto detecting package info