-
Notifications
You must be signed in to change notification settings - Fork 7.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fixed compile error. #7526
fixed compile error. #7526
Conversation
```bash # compile for android. $ ./build_native.py ``` Error message as follow: ``` ssize_tjni/../../cocos2d/cocos/./3d/CCBundleReader.cpp:94:23: error: return type of out-of-line definition of 'cocos2d::BundleReader::tell' differs from that in the declaration ssize_t BundleReader::tell() ^ jni/../../cocos2d/cocos/./3d/CCBundleReader.h:90:14: note: previous declaration is here long int tell(); ^ 1 error generated. ```
``` The import org.cocos2dx.lib cannot be resolved ... ```
Thanks. And please just do one think in a commit. Thanks. |
reproduce on environment as follow. My OS(x86_64) $ lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 14.04 LTS
Release: 14.04
Codename: trusty
$ uname -a
Linux vb 3.13.0-24-generic #46-Ubuntu SMP Thu Apr 10 19:11:08 UTC 2014 x86_64 x86_64 x86_64 GNU/Linux
$ gcc -v
Using built-in specs.
COLLECT_GCC=gcc
COLLECT_LTO_WRAPPER=/usr/lib/gcc/x86_64-linux-gnu/4.8/lto-wrapper
Target: x86_64-linux-gnu
Configured with: ../src/configure -v --with-pkgversion='Ubuntu 4.8.2-19ubuntu1' --with-bugurl=file:///usr/share/doc/gcc-4.8/README.Bugs --enable-languages=c,c++,java,go,d,fortran,objc,obj-c++ --prefix=/usr --program-suffix=-4.8 --enable-shared --enable-linker-build-id --libexecdir=/usr/lib --without-included-gettext --enable-threads=posix --with-gxx-include-dir=/usr/include/c++/4.8 --libdir=/usr/lib --enable-nls --with-sysroot=/ --enable-clocale=gnu --enable-libstdcxx-debug --enable-libstdcxx-time=yes --enable-gnu-unique-object --disable-libmudflap --enable-plugin --with-system-zlib --disable-browser-plugin --enable-java-awt=gtk --enable-gtk-cairo --with-java-home=/usr/lib/jvm/java-1.5.0-gcj-4.8-amd64/jre --enable-java-home --with-jvm-root-dir=/usr/lib/jvm/java-1.5.0-gcj-4.8-amd64 --with-jvm-jar-dir=/usr/lib/jvm-exports/java-1.5.0-gcj-4.8-amd64 --with-arch-directory=amd64 --with-ecj-jar=/usr/share/java/eclipse-ecj.jar --enable-objc-gc --enable-multiarch --disable-werror --with-arch-32=i686 --with-abi=m64 --with-multilib-list=m32,m64,mx32 --with-tune=generic --enable-checking=release --build=x86_64-linux-gnu --host=x86_64-linux-gnu --target=x86_64-linux-gnu
Thread model: posix
gcc version 4.8.2 (Ubuntu 4.8.2-19ubuntu1) |
Additional information: NDK:android-ndk-r10(64-bit)
|
Thanks. |
fixed compile error.
Why your selected toolchain is 4.8? |
I think it's is a bug. see alse method Paths of build_native.py: |
I know the issue. It is because it selects gcc version as previous. But the value will be replaced by the setting in |
The output is generated in build_native.py. |
User ndk r9d, compiled error whether existed??? |
# compile for android. $ ./build_native.py
Error message as follow: