Hi! I downloaded xcode 11 beta and i tried to run my game. Cocos library does not compile and gives teh following error. I am using cocos2d-x 3.15.1. Can anyone help?
bulletphysics:master
ā EmilNorden:master
opened 06:44AM - 04 May 19 UTC
Build fails on Clang 8.0.0 with:
```
argument value 10880 is outside the validā¦ range [0, 255]
[-Wargument-outside-range]
```
opened 05:57AM - 18 Feb 19 UTC
closed 04:39AM - 01 May 19 UTC
**OS**: `macOS 10.14.2`
**Compiler**: `Clang 7.0.1`
I'm still relatively newā¦ to C++ so it's likely I'm doing something dumb but I'm getting the following error when I run `./build_cmake_pybullet_double.sh`:
```
/Users/collen/Dev/Language/C++/bullet3/src/Bullet3Common/b3Vector3.h:290:7: error: argument value 10880 is outside the valid range [0, 255]
[-Wargument-outside-range]
```
Any ideas how to fix this?
# Full Trace
```
$ ./build_cmake_pybullet_double.sh
-- The C compiler identification is Clang 7.0.1
-- The CXX compiler identification is Clang 7.0.1
-- Check for working C compiler: /usr/local/opt/llvm/bin/clang
-- Check for working C compiler: /usr/local/opt/llvm/bin/clang -- works
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Detecting C compile features
-- Detecting C compile features - done
-- Check for working CXX compiler: /usr/local/opt/llvm/bin/clang++
-- Check for working CXX compiler: /usr/local/opt/llvm/bin/clang++ -- works
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Detecting CXX compile features
-- Detecting CXX compile features - done
Apple
-- Found OpenGL: /System/Library/Frameworks/OpenGL.framework
OPENGL FOUND
/System/Library/Frameworks/OpenGL.framework/System/Library/Frameworks/OpenGL.framework
-- Found PythonInterp: /usr/local/bin/python3 (found version "3.7.2")
-- Looking for versions: 3.7.2;3.7
-- Looking for python version '3.7.2' by checking executables: /usr/local/bin/python3;python;python3;python3.7.
-- Found executable /usr/local/bin/python3 with suitable version 3.7.2
-- Found PythonLibs: /usr/local/opt/python/Frameworks/Python.framework/Versions/3.7/lib/libpython3.7.dylib (found suitable exact version "3.7.2")
-- Found PythonLibs: /usr/local/opt/python/Frameworks/Python.framework/Versions/3.7/lib/libpython3.7.dylib (found version "3.7.2")
-- Found NumPy: /usr/local/lib/python3.7/site-packages/numpy/core/include (found version "1.16.1")
-- NumPy ver. 1.16.1 found (include: /usr/local/lib/python3.7/site-packages/numpy/core/include)
NumPy found
Mac OSX Version is 10.14
/System/Library/Frameworks/Cocoa.framework
/System/Library/Frameworks/Cocoa.framework
/System/Library/Frameworks/Cocoa.framework
/System/Library/Frameworks/Cocoa.framework
CL64
/System/Library/Frameworks/Cocoa.framework
-- Configuring done
-- Generating done
CMake Warning:
Manually-specified variables were not used by the project:
BT_USE_EGL
-- Build files have been written to: /Users/collen/Dev/Language/C++/bullet3/build_cmake
Scanning dependencies of target Bullet3Common
Scanning dependencies of target BussIK
Scanning dependencies of target clsocket
Scanning dependencies of target gtest
Scanning dependencies of target HACD
Scanning dependencies of target LinearMath
Scanning dependencies of target gwen
[ 0%] Building CXX object examples/ThirdPartyLibs/clsocket/CMakeFiles/clsocket.dir/src/SimpleSocket.o
[ 0%] Building CXX object Extras/HACD/CMakeFiles/HACD.dir/hacdGraph.o
[ 1%] Building CXX object examples/ThirdPartyLibs/clsocket/CMakeFiles/clsocket.dir/src/ActiveSocket.o
[ 1%] Building CXX object src/Bullet3Common/CMakeFiles/Bullet3Common.dir/b3AlignedAllocator.o
[ 1%] Building CXX object examples/ThirdPartyLibs/BussIK/CMakeFiles/BussIK.dir/Jacobian.o
[ 1%] Building CXX object src/LinearMath/CMakeFiles/LinearMath.dir/btAlignedAllocator.o
[ 1%] Building CXX object test/gtest-1.7.0/CMakeFiles/gtest.dir/src/gtest-all.o
[ 1%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Anim.o
[ 1%] Building CXX object src/LinearMath/CMakeFiles/LinearMath.dir/btConvexHull.o
[ 1%] Building CXX object Extras/HACD/CMakeFiles/HACD.dir/hacdHACD.o
[ 1%] Building CXX object src/Bullet3Common/CMakeFiles/Bullet3Common.dir/b3Vector3.o
[ 1%] Building CXX object examples/ThirdPartyLibs/clsocket/CMakeFiles/clsocket.dir/src/PassiveSocket.o
In file included from /Users/collen/Dev/Language/C++/bullet3/src/Bullet3Common/b3Vector3.cpp:21:
/Users/collen/Dev/Language/C++/bullet3/src/Bullet3Common/b3Vector3.h:290:7: error: argument value 10880 is outside the valid range [0, 255]
[-Wargument-outside-range]
y = b3_splat_ps(y, 0x80);
^~~~~~~~~~~~~~~~~~~~
/Users/collen/Dev/Language/C++/bullet3/src/Bullet3Common/b3Vector3.h:43:29: note: expanded from macro 'b3_splat_ps'
#define b3_splat_ps(_a, _i) b3_pshufd_ps((_a), B3_SHUFFLE(_i, _i, _i, _i))
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/Users/collen/Dev/Language/C++/bullet3/src/Bullet3Common/b3Vector3.h:41:33: note: expanded from macro 'b3_pshufd_ps'
#define b3_pshufd_ps(_a, _mask) _mm_shuffle_ps((_a), (_a), (_mask))
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
/usr/local/Cellar/llvm/7.0.1/lib/clang/7.0.1/include/xmmintrin.h:2608:11: note: expanded from macro '_mm_shuffle_ps'
(__m128)__builtin_ia32_shufps((__v4sf)(__m128)(a), (__v4sf)(__m128)(b), \
^
1 error generated.
make[2]: *** [src/Bullet3Common/CMakeFiles/Bullet3Common.dir/b3Vector3.o] Error 1
make[1]: *** [src/Bullet3Common/CMakeFiles/Bullet3Common.dir/all] Error 2
make[1]: *** Waiting for unfinished jobs....
[ 1%] Building CXX object examples/ThirdPartyLibs/BussIK/CMakeFiles/BussIK.dir/LinearR2.o
[ 1%] Linking CXX static library libclsocket.a
[ 1%] Built target clsocket
[ 1%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/BaseRender.o
[ 1%] Building CXX object src/LinearMath/CMakeFiles/LinearMath.dir/btConvexHullComputer.o
[ 1%] Building CXX object examples/ThirdPartyLibs/BussIK/CMakeFiles/BussIK.dir/LinearR3.o
[ 1%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Controls/Base.o
[ 2%] Building CXX object Extras/HACD/CMakeFiles/HACD.dir/hacdICHull.o
[ 2%] Building CXX object src/LinearMath/CMakeFiles/LinearMath.dir/btGeometryUtil.o
[ 2%] Building CXX object Extras/HACD/CMakeFiles/HACD.dir/hacdManifoldMesh.o
[ 2%] Building CXX object examples/ThirdPartyLibs/BussIK/CMakeFiles/BussIK.dir/LinearR4.o
[ 2%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Controls/Button.o
[ 2%] Building CXX object src/LinearMath/CMakeFiles/LinearMath.dir/btPolarDecomposition.o
[ 2%] Building CXX object examples/ThirdPartyLibs/BussIK/CMakeFiles/BussIK.dir/MatrixRmn.o
[ 2%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Controls/Canvas.o
[ 2%] Building CXX object src/LinearMath/CMakeFiles/LinearMath.dir/btQuickprof.o
[ 2%] Building CXX object src/LinearMath/CMakeFiles/LinearMath.dir/btSerializer.o
[ 2%] Building CXX object examples/ThirdPartyLibs/BussIK/CMakeFiles/BussIK.dir/Misc.o
[ 3%] Building CXX object src/LinearMath/CMakeFiles/LinearMath.dir/btSerializer64.o
[ 4%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Controls/CheckBox.o
[ 4%] Building CXX object src/LinearMath/CMakeFiles/LinearMath.dir/btThreads.o
[ 4%] Building CXX object examples/ThirdPartyLibs/BussIK/CMakeFiles/BussIK.dir/Node.o
[ 4%] Linking CXX shared library libHACD.dylib
[ 4%] Built target HACD
[ 4%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Controls/ColorControls.o
[ 4%] Building CXX object src/LinearMath/CMakeFiles/LinearMath.dir/btVector3.o
[ 4%] Building CXX object src/LinearMath/CMakeFiles/LinearMath.dir/TaskScheduler/btTaskScheduler.o
[ 4%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Controls/ColorPicker.o
[ 4%] Building CXX object src/LinearMath/CMakeFiles/LinearMath.dir/TaskScheduler/btThreadSupportPosix.o
[ 4%] Building CXX object src/LinearMath/CMakeFiles/LinearMath.dir/TaskScheduler/btThreadSupportWin32.o
[ 4%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Controls/ComboBox.o
[ 4%] Linking CXX shared library libLinearMath.dylib
[ 4%] Built target LinearMath
[ 4%] Building CXX object examples/ThirdPartyLibs/BussIK/CMakeFiles/BussIK.dir/Tree.o
[ 5%] Building CXX object examples/ThirdPartyLibs/BussIK/CMakeFiles/BussIK.dir/VectorRn.o
[ 5%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Controls/Dialog/FileOpen.o
[ 5%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Controls/CrossSplitter.o
[ 5%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Controls/Dialog/FileSave.o
[ 5%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Controls/Dialog/Query.o
[ 5%] Linking CXX shared library libBussIK.dylib
[ 5%] Built target BussIK
[ 5%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Controls/DockBase.o
[ 5%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Controls/DockedTabControl.o
[ 6%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Controls/Dragger.o
[ 6%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Controls/GroupBox.o
[ 6%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Controls/HSVColorPicker.o
[ 6%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Controls/HorizontalScrollBar.o
[ 6%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Controls/HorizontalSlider.o
[ 6%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Controls/ImagePanel.o
[ 6%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Controls/Label.o
[ 6%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Controls/LabelClickable.o
[ 6%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Controls/ListBox.o
[ 6%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Controls/Menu.o
[ 6%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Controls/MenuItem.o
[ 7%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Controls/MenuStrip.o
[ 7%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Controls/NumericUpDown.o
[ 7%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Controls/PanelListPanel.o
[ 7%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Controls/ProgressBar.o
[ 7%] Linking CXX shared library libgtest.dylib
[ 7%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Controls/Properties.o
[ 7%] Built target gtest
[ 7%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Controls/RadioButton.o
[ 7%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Controls/RadioButtonController.o
[ 7%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Controls/ResizableControl.o
[ 7%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Controls/Resizer.o
[ 7%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Controls/RichLabel.o
[ 8%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Controls/ScrollBar.o
[ 8%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Controls/ScrollBarBar.o
[ 8%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Controls/ScrollBarButton.o
[ 8%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Controls/ScrollControl.o
[ 8%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Controls/Slider.o
[ 8%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Controls/SplitterBar.o
[ 8%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Controls/TabButton.o
[ 8%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Controls/TabControl.o
[ 8%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Controls/TabStrip.o
[ 8%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Controls/Text.o
[ 9%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Controls/TextBox.o
[ 9%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Controls/TextBoxNumeric.o
[ 9%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Controls/TreeControl.o
[ 9%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Controls/TreeNode.o
[ 9%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Controls/VerticalScrollBar.o
[ 9%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Controls/VerticalSlider.o
[ 9%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Controls/WindowControl.o
[ 9%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/DragAndDrop.o
[ 9%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Gwen.o
[ 9%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Hook.o
[ 9%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Platforms/Windows.o
[ 10%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Platforms/Null.o
[ 10%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Renderers/OpenGL_DebugFont.o
[ 10%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Skin.o
[ 10%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/ToolTip.o
[ 10%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/Utility.o
[ 10%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/events.o
[ 10%] Building CXX object examples/ThirdPartyLibs/Gwen/CMakeFiles/gwen.dir/inputhandler.o
[ 10%] Linking CXX shared library libgwen.dylib
ld: warning: text-based stub file /System/Library/Frameworks//OpenGL.framework/OpenGL.tbd and library file /System/Library/Frameworks//OpenGL.framework/OpenGL are out of sync. Falling back to library file for linking.
ld: warning: text-based stub file /System/Library/Frameworks/OpenGL.framework/Versions/A/Libraries/libGLU.tbd and library file /System/Library/Frameworks/OpenGL.framework/Versions/A/Libraries/libGLU.dylib are out of sync. Falling back to library file for linking.
ld: warning: text-based stub file /System/Library/Frameworks/OpenGL.framework/Versions/A/Libraries/libGL.tbd and library file /System/Library/Frameworks/OpenGL.framework/Versions/A/Libraries/libGL.dylib are out of sync. Falling back to library file for linking.
[ 10%] Built target gwen
make: *** [all] Error 2
```
1 Like
We havenāt done any testing with the new Apple software offerings. I plan to once I test a few things I promised to do.
1 Like
lorwy
August 1, 2019, 8:29am
4
hi, Have you solved this problem. I have the same problem as youļ¼
If you suffer from āArgument value 10880 is outside the valid range [0, 255]ā error, then just replace cocos2d/external/bullet/include/bullet/LinearMath/btVector3.h line 42:
#define BT_SHUFFLE(x,y,z,w) ((w)<<6 | (z)<<4 | (y)<<2 | (x))
with new one:
#define BT_SHUFFLE(x, y, z, w) (((w) << 6 | (z) << 4 | (y) << 2 | (x)) & 0xff)
5 Likes
kerryk
August 2, 2019, 9:47am
6
Most probably, we have to wait for Bullet library update. If you dont use it you can just remove it and cocos will run fine. Or try to fix it e.g. using @hexerror solution.
lorwy
August 5, 2019, 1:55am
7
OKļ¼thanks! I had another problem; This issue doesnāt happen in iOS 11 or iOS 12. I donāt believe it happened in earlier iOS 13 betas. The game crashed when I played video, but it looked more like an Appleās bug
2019-08-02 17:01:26.763235+0800 App[14522:138289] [] nw_endpoint_get_type called with null endpoint
2019-08-02 17:01:26.763235+0800 App [14522:138289] [] nw_endpoint_get_type called with null endpoint, dumping backtrace:
[x86_64] libnetcore-1872
0 libnetwork.dylib 0x00007fff500df068 __nw_create_backtrace_string + 120
1 libnetwork.dylib 0x00007fff5004149f nw_endpoint_get_type + 175
2 libboringssl.dylib 0x00007fff4ef09a6a nw_protocol_boringssl_get_subject_name + 178
3 libboringssl.dylib 0x00007fff4ef0c911 nw_protocol_boringssl_connected + 916
4 libnetwork.dylib 0x00007fff4fefcfdf nw_socket_handle_socket_event + 1711
5 libdispatch.dylib 0x000000010db10d58 _dispatch_client_callout + 8
6 libdispatch.dylib 0x000000010db136ca _dispatch_continuation_pop + 552
7 libdispatch.dylib 0x000000010db26a83 _dispatch_source_invoke + 2205
8 libdispatch.dylib 0x000000010db19815 _dispatch_workloop_invoke + 2631
9 libdispatch.dylib 0x000000010db23a4d _dispatch_workloop_worker_thread + 722
10 libsystem_pthread.dylib 0x00007fff511f3611 _pthread_wqthread + 421
11 libsystem_pthread.dylib 0x00007fff511f33fd start_wqthread + 13
kerryk
August 5, 2019, 6:23am
8
You are correct, not relevant to cocos. Which ad network caused the crash? Itās best u inform them. Most probably, all ad networks companies will released their updated ios 13 compatible SDKās close to ios 13 release.