SDKBOX Facebook plugin android

So Facebook plugin works well in iOS, but on Android I can’t even compile, I get this error:

/Users/edvinas/Development/Cocos2d-x/Android/android-ndk-r10e/build/gmsl/__gmsl:512: *** non-numeric second argument to `wordlist' function: '9 15'.  Stop.
make: Leaving directory `/Users/edvinas/Development/Cocos2d-x/Projects/MyProject/proj.android'

I saw that Likon fixed this problem by editing ndk Facebook plugin compilation error but I don’t think that, thats the way to solve problem (by editing ndk files) also if I use this method later I get new error (same as Likon). So how to fix this problem?

And also @nite when sdkbox 1.2.2 version will be release, because in roadmap it says 8/13.

If you check the comments on the roadmap, you’ll see it has been delayed :smile:

Yeah it was delayed from 8/6 to 8/13 but now there is no info about second delay.

Oh ok, since I checked 5 days ago, I didn’t know if the displayed date was accounting for the delay or not :smile:

try this repo https://github.com/darkdukey/sdkbox-facebook-sample

Ok so I was away for few days. Now I found what causes the problem but I still don’t have any solution for that…

So if I use only facebook plugin and no other plugins it compiles, but if I use facebook plugin and for example iAP plugin it won’t compile I get this error:

 /Users/edvinas/Development/Cocos2d-x/Android/android-ndk-r10e/build/gmsl/__gmsl:512: *** non-numeric second argument to `wordlist' function: '15 9'.  Stop.
make: Leaving directory `/Users/edvinas/Development/Cocos2d-x/Projects/MyProject/proj.android'

So I think it’s a bug. @nite can you confirm?

Yes, it’s a bug in Application.mk

-APP_PLATFORM += android-9
+APP_PLATFORM += android-9 android-19

-_-||

Just

APP_PLATFORM += android-19
1 Like

Thank you!!!

Thanks fixed issue, so I would say that sdkbox incorrectly modifying Application.mk file, why it removing IF statements for debug/release?

BTW: issue still exist in latest version of SDKBOX, downloaded today 4.09.2015 and got that error!

It is strange, but i also have this issue and my Application.mk has the line:

APP_PLATFORM := android-9 android-15

and the error disappears when i remove ‘android-15’, leaving only ‘android-9’, like this:

APP_PLATFORM := android-9

But after that i got another error:
BUILD FAILED
/Users/myusenamer/bin/android-sdk/tools/ant/build.xml:597: The following error occurred while executing this line:
/Users/myusenamer/bin/android-sdk/tools/ant/build.xml:716: The following error occurred while executing this line:
/Users/myusenamer/bin/android-sdk/tools/ant/build.xml:730: Compile failed; see the compiler error output for details.

but i have no any error in the compiler output

What version of SDKBOX Installer?

What version of the SDKBOX Facebook plugin?

Facebook requires API-15 (4.0.3) as stated here: http://sdkbox-doc.github.io/en/plugins/facebook/v3-cpp/

Thanks for the reply.
I don’t know exactly how to determine the version of sdkbox, but when i run it i have this printed in the terminal:

Copyright © 2015 Chukong Technologies Inc. v0.5.7.13

I have downloaded it from the facebook plugin page from the link called “auto installer”
I tried to install it using the command “sdkbox import facebook” which finished with the error message

“failed to patch file Cocos2dxActivity.java”,

and I patched it manually according to the instruction. I don’t know how to determine the version of the plugin.

I have cocos2d-js engine version 3.6.1 downloaded from the Cocos Store.

Sorry, BUILD FAILED was due to lack of JDK 7. But the patching bug and the platform bug are still exist, but after changing project’s platform I can build and run my project with iap, facebook and googleanalytics plugins together without problems. Thanks for the help!

Glad that you ave it working now. Enjoy.

This patching bug is still in the current version of sdkbox v0.5.7.24.

I dont see the bug in the new release of sdkbox.

This is the Application.mk file generated after facebook import.

APP_STL := gnustl_static

APP_CPPFLAGS := -frtti -DCC_ENABLE_CHIPMUNK_INTEGRATION=1 -std=c++11 -fsigned-char
APP_LDFLAGS := -latomic


ifeq ($(NDK_DEBUG),1)
APP_CPPFLAGS += -DCOCOS2D_DEBUG=1
APP_OPTIM := debug
else
APP_CPPFLAGS += -DNDEBUG
APP_OPTIM := release
endif
APP_PLATFORM := android-15

Sorry, I got the same bug adding in app purchase to an app.

hi @blueled

I don’t follow you.
could you please tell what bug you are facing exactly, because i tried with IAP import also.
there seems to be no patching issue and no duplicate project target.

I had this error

*** non-numeric second argument to `wordlist’ function: ‘9 10’. Stop.

And it was in the Application.mk file after being patched by version v0.5.7.24 of SDKBOX.

Hope that helps.

Can you post your Application.mk file?