deptofdefense / AndroidTacticalAssaultKit-CIV

Other
35 stars 17 forks source link

Building plugintemplate - No signature of method ... #268

Closed av-mario closed 2 years ago

av-mario commented 2 years ago

Hi,

I'm following the legendary ATAK plugin 101 tutorial: https://www.ballantyne.online/developing-atak-plugin-101/ but I have stumbled upon some issue which I am unable to resolve

A problem occurred evaluating project ':app'.
> No signature of method: build_d3zoxwx0ukactzgeikmtgjpce.android() is applicable for argument types: (build_d3zoxwx0ukactzgeikmtgjpce$_run_closure2) values: [build_d3zoxwx0ukactzgeikmtgjpce$_run_closure2@42dee75d]

This is when I compile the app in plugintemplate, which corresponds to this function:

android {
    compileSdkVersion 26
    buildToolsVersion "30.0.2"

    dexOptions {
        jumboMode = true
    } 
...
}

I have my local.properties defined like this:

takDebugKeyAlias=androiddebugkey
sdk.dir=/home/mario/Android/Sdk
ndk.dir=/home/mario/android-ndk-r12b
cmake.dir=/home/mario/cmake-3.14.7-Linux-x86_64
takReleaseKeyAlias=androiddebugkey
takReleaseKeyPassword=android
takDebugKeyPassword=android
takReleaseKeyFilePassword=android
takReleaseKeyFile=/home/mario/Downloads/debug.keystore
takDebugKeyFilePassword=android

takDebugKeyFile=/home/mario/Downloads/debug.keystore

And I hardcoded the location of my takdev-jar.

Is there any hint in my code of what could be wrong?

As far as I have looked, the function might be getting called from somewhere with the wrong arguments? Found here

I also do not see that the app is an app, but I think that is because the gradle failed?

e.g. in the tutorial it shows:

Screenshot-2020-08-18-at-10 52 22

but I see

image

Any hints here?

av-mario commented 2 years ago

264

av-mario commented 2 years ago

On thing that brought me one step further is

in build.gradle when it errors, go up to line 16 and change 'def ' to 'ext.

Hellikandra commented 2 years ago
  1. Have you created the *.jks ? -> cd ~/atak -> keytool -genkey -v -keystore my-release-key.jks -keyalg RSA -keysize 2048 -validity 10000 -alias my-alias

where main.jar / atak-gradle-takdev.jar is.

-> ln -s ~/atak/my-release-key.jks ~/atak/atak-civ/plugin-examples/plugintemplate/app

The ln command need to correspond of the folder where everything is. But it is important to put in in the app folder of your plugin.

sealfoss commented 1 year ago

Did you ever find a solution to this? Setting up the symbolic link didn't solve the problem for me.

sealfoss commented 1 year ago

Never mind, changing instances of 'def' to 'ext.' was the solution.