Extension-googleplaygames


#1

Getting this error:

C:\Users\Desktop\Zephyr\bin\android\release\bin\deps\gpgex\build\intermediates\bundles\release\aapt\AndroidManifest.xml:11:28-65: AAPT: No resource found that matches the given name (at ‘value’ with value ‘@integer/google_play_services_version’).

Can I set this value in project.xml and if so how?


#2

It looks like you can set it like this:

<set name="GOOGLE_PLAY_GAMES_ID" value="yourAppID" />

You can find your app ID in the Google Play Developer Console.


#3

The README.md says to use the ‘setenv’ tag.
Neither one is working for me, same error.
Do I have to worry about the order of the tags?


#4

That works too. I suggested set because it’s shorter and it actually does set both. (The difference is that setenv also calls Sys.putEnv(), which might matter in other situations.)

Something like if="googlePlus" is evaluated while project.xml is being processed, so you have to have set googlePlus before then.

However, GOOGLE_PLAY_GAMES_ID is used in the template copy phase, which happens after Lime has finished processing project.xml and include.xml. So in this case, order doesn’t matter.

But feel free to put things in order if you find that easier than remembering the difference.

Ok, turns out this was another thing I got wrong. GOOGLE_PLAY_GAMES_ID only sets the value of these two lines, and the problem actually comes from this line. (Don’t delete GOOGLE_PLAY_GAMES_ID, though. It’s useful for other reasons.)

From all the documentation I found, you shouldn’t need to set google_play_services_version manually - importing the Google Play Services should be enough.

Can you check app/build/intermediates/res/merged/release/values/values.xml for that value?


By the way, I fixed a “multiple dex files define” error. Update my library for the fix.


#5

There is no folder /values/ in folder app/build/intermediates/res/merged/release/

I tried haxelib git google-play-services https://github.com/player-03/google-play-services
and got std@sys_read_dir

Don’t know what I’m doing wrong, is there a better way to update the lib?


#6

Also getting std@set_cwd when trying to update with other methods


#7

Which means the build failed earlier than that point in the process. Not sure what point that is, just that it’s well before the end.

Try this and see if you find anything.

If you’ve already installed from Git, then haxelib update google-play-services should do it.


#8
  • What went wrong:
    Execution failed for task ‘:deps:gpgex:processReleaseResources’.

com.android.ide.common.process.ProcessException: org.gradle.process.internal.E
xecException: Process ‘command ‘C:\Development\Android SDK\build-tools\24.0.1\aa
pt.exe’’ finished with non-zero exit value 1

I’ll try the next level of verbosity as well


#9

Got this:

All input files are considered out-of-date for incremental task ‘:deps:gpgex:pro
cessReleaseResources’.


#10

That one’s giving me the error: std@set_cwd
I think I fucked my copy of your google-play-services lib, it won’t even let me delete it to start over.
And haxelib remove throws the error: std@sys_red_dir


#11

I looked it up, and most people find that doing a clean rebuild solves that one. Other people get it because something’s wrong with one of their resource files.

Restart your computer and that should go away.


#12

Doesn’t have google_play_services_version but it does have my app id and a message about misconfiguration:

resources
string name=“APP_ID”>253066465387 /string>
string name=“gamehelper_app_misconfigured”>The application is incorrectly configured. Check that the package name and signing certificate match the client ID created in Developer Console. Also, if the application is not yet published, check that the account you are trying to sign in with is listed as a tester account. See logs for more information.
License check failed.
Failed to sign in. Please check your network connection and try again.
Unknown error.

Is this the error I should be getting or is it just there in case of such an error?


#13

No wait, I’m in the wrong folder again.
Still don’t have app/build/intermediates/res/merged/release/values/
Herp derp


#14

About this clean rebuild thing, I usually just delete my bin folder and hit test.
What exactly do people mean by clean rebuild, is there a -clean command to use or can I just hit build project?

I’ll bet that’s what the problem is and it takes another couple of days to find it :stuck_out_tongue:


#15

It’s there just in case of such an error. If that error happened, the message would be displayed by the app (which is why it gets compiled into said app).

That works.

There is actually. You can run openfl test android -clean to delete your output folder and then build, or you can run gradlew clean to delete only Gradle’s output files.

Either way, “clean” means deleting output files. And “rebuild” just means “build again.”

I think these were resource files they were directly responsible for. I don’t think Google would release a version of the Play Services with a corrupt resource.

I think it’s time to try this from a different angle. Let’s both create a sample project and try to build it. Steps:

  1. Download version 4.0.0 of openfl-samples (either haxelib install openfl-samples or haxelib update openfl-samples).
  2. Make sure that you’re using the git version of Lime and OpenFL, and that both are up to date (haxelib set openfl git, haxelib set lime git, haxelib update openfl, haxelib update lime).
  3. Make sure you’re using Haxe version 3.2.1 (haxe -version).
  4. Execute tools.hxml (open haxe/lib/lime/git/tools in Command Prompt, then run haxe tools.hxml).
  5. Copy the ndlls from Lime 3.1.0 (ctrl+drag the contents of lime/3,1,0/ndlls into lime/git/ndlls).
  6. Create DisplayingABitmap somewhere appropriate (openfl create DisplayingABitmap).
  7. Include my library (add <set name="googlePlus" /> and <haxelib name="google-play-services" /> to project.xml).
  8. Build for Android (openfl build android).

This results in “BUILD SUCCESSFUL” for me. If it fails for you, we’ll examine the differences between our computers. If it works for you, we’ll examine the differences between DisplayingABitmap and Zephyr.


#16

Still getting the ‘no resource found’ error.
Turns out I have at least 2 copies of all my haxelibs, one in C:\HaxeToolkit\haxe\lib and one in C:\Users\android.
I think it’s using the ones in android but I copied the ndlls and executed tools.hxml on both of them, no change.


#17

Actually I got build successful for DisplayingABitmap.
I was trying an empty OpenFL project created by FlashDevelop and HaxeDevelop which gave me the no resource found error.


#18

Huh. When I try a new HaxeDevelop project, I get the aapt.exe error.

Currently trying to figure out what the difference is.


#19

Looks like the difference is that I didn’t specify a package when I created the project in HaxeDevelop. When I create a new project with a package, it builds on the first try.

I tested with and without my library enabled, and it worked both times.

Does your empty project work once you set <meta package="com.something.or.other" />? (Do a clean build, of course.)


#20

Nope doesn’t work with 3 package segments
Here’s the full error:

C:\HaxeDevelop\Test\bin\android\release\bin\deps\gpgex\build\intermediates\bundles\release\aapt\AndroidManifest.xml:11:28-65: AAPT: No resource found that matches the given name (at ‘value’ with value ‘@integer/google_play_services_version’).

:deps:gpgex:processReleaseResources FAILED

FAILURE: Build failed with an exception.

  • What went wrong:
    Execution failed for task ‘:deps:gpgex:processReleaseResources’.

com.android.ide.common.process.ProcessException: org.gradle.process.internal.ExecException: Process ‘command ‘C:\Development\Android SDK\build-tools\24.0.1\aapt.exe’’ finished with non-zero exit value 1

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

BUILD FAILED

Total time: 11.351 secs

Please make sure you have Google Play Services version 9.4.0.
If not, use the Android SDK Manager to download it.
Picked up _JAVA_OPTIONS: -Xmx3072M
Build halted with errors.