Cannot process assets when packing cocos2d-x android

I just started working on cocos2d-x to create games. I have completed the setup. I get below errors when I run the HelloCpp sample.

(skipping file '.gitignore' due to ANDROID_AAPT_IGNORE pattern '.*')
Unable to add 'C:\cocos2d-x-2.2.1\samples\Cpp\HelloCpp\proj.android\assets\fonts\Marker Felt.ttf': Zip add failed
ERROR: unable to process assets while packaging 'C:\cocos2d-x-2.2.1\samples\Cpp\HelloCpp\proj.android\bin\resources.ap_'
ERROR: packaging of 'C:\cocos2d-x-2.2.1\samples\Cpp\HelloCpp\proj.android\bin\resources.ap_' failed

Please help me fix this problem.

Thanks.

+4
source share
1 answer

This problem has several solutions, and I tried each of them, and the latter worked correctly. I give you the exact steps that I have taken to make it work for me.

1. Check if Cygwin has the necessary packages if they are not installed. The following packages are required -

autoconf, automake, binutils, gcc-core, gcc-g++, gcc4-core, gcc4-g++, gdb, pcre, pcre-devel, gawk, make

(I skipped gcc4-core and gcc4-g ++)

2. Marker Felt.ttf, , C: .

3. Eclipse .

4. , . Asset build_native.sh. build_native.sh( )

chmod 777 -R "$APP_ANDROID_ROOT"/assets

, . , , . , eclipse , . , .

+4

All Articles