Closed asmaloney closed 4 years ago
Regression from 0da84b5 (cherry picked from commit 51e1614, without cherry picking 26fcf2b first).
Welp, we'll have to be carefully when cherrypicking from now on unless we decide to use override
in 3.2
(but it would break third-party code so I'm not in favour of doing it).
(cherry picked from commit 51e1614, without cherry picking 26fcf2b first)
I don't think that's correct - you don't want override
in 3.2 code.
Removing override
seems to be the correct fix.
PR incoming...
Fixed by #40573.
I'm still getting this issue when compiling mono with a custom module (sg_physics_2d). I'm using the 3.5.stable source code, and I move the custom module under the modules folder prior to compiling.
In file included from modules/sg_physics_2d/register_types.cpp:34:
In file included from modules/sg_physics_2d/./scene/2d/sg_fixed_position_2d.h:27:
modules/sg_physics_2d/./scene/2d/sg_fixed_node_2d.h:35:2: error: 'get_class' overrides a member function but is not marked 'override' [-Werror,-Winconsistent-missing-override]
GDCLASS(SGFixedNode2D, Node2D);
^
./core/object.h:270:17: note: expanded from macro 'GDCLASS'
virtual String get_class() const { \
^
./scene/2d/node_2d.h:37:2: note: overridden virtual function is here
GDCLASS(Node2D, CanvasItem);
^
./core/object.h:270:17: note: expanded from macro 'GDCLASS'
virtual String get_class() const { \
^
In file included from modules/sg_physics_2d/register_types.cpp:34:
In file included from modules/sg_physics_2d/./scene/2d/sg_fixed_position_2d.h:27:
modules/sg_physics_2d/./scene/2d/sg_fixed_node_2d.h:35:2: error: '_get_class_namev' overrides a member function but is not marked 'override' [-Werror,-Winconsistent-missing-override]
GDCLASS(SGFixedNode2D, Node2D);
^
This is an issue with that module, you should report it on that module's repository. Its 3.x branch shouldn't use override
.
Godot version:
Godot 3.2.x from commit 7b4b83e9dcb91b44b39e8cc87df3ddecdb29b689
OS/device including version:
macOS 10.14.6
Issue description:
Trying to follow the instructions to build with C# support.
I'm using the following options to scons:
This produces many build errors because
-Werror
and-Winconsistent-missing-override
are both specified.Example build errors:
Example compile command
clang++ -o modules/mono/mono_gd/gd_mono_method.osx.tools.64.o -c -std=gnu++14 -Wctor-dtor-privacy -Wnon-virtual-dtor -g3 -arch x86_64 -mmacosx-version-min=10.9 -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX10.15.sdk -Wall -Wextra -Wno-unused-parameter -Wwrite-strings -Werror -DDEBUG_ENABLED -DDEBUG_MEMORY_ENABLED -DDEBUG_MEMORY_ALLOC -DDISABLE_FORCED_INLINE -DTYPED_METHOD_BIND -DOSX_ENABLED -DUNIX_ENABLED -DGLES_ENABLED -DAPPLE_STYLE_KEYS -DCOREAUDIO_ENABLED -DCOREMIDI_ENABLED -DGL_SILENCE_DEPRECATION -DPTRCALL_ENABLED -DTOOLS_ENABLED -DGDSCRIPT_ENABLED -DMINIZIP_ENABLED -DZSTD_STATIC_LINKING_ONLY -DGLAD_ENABLED -DGLES_OVER_GL -DMODULE_ASSIMP_ENABLED -DMODULE_BMP_ENABLED -DMODULE_BULLET_ENABLED -DMODULE_CAMERA_ENABLED -DMODULE_CSG_ENABLED -DMODULE_CVTT_ENABLED -DMODULE_DDS_ENABLED -DMODULE_ENET_ENABLED -DMODULE_ETC_ENABLED -DMODULE_FREETYPE_ENABLED -DMODULE_GDNATIVE_ENABLED -DMODULE_GDSCRIPT_ENABLED -DMODULE_GRIDMAP_ENABLED -DMODULE_HDR_ENABLED -DMODULE_JPG_ENABLED -DMODULE_JSONRPC_ENABLED -DMODULE_MBEDTLS_ENABLED -DMODULE_MOBILE_VR_ENABLED -DMODULE_MONO_ENABLED -DHAVE_CXX11_THREAD_LOCAL -DGD_MONO_HOT_RELOAD -D_REENTRANT -I/Library/Frameworks/Mono.framework/Versions/Current/include/mono-2.0 -Ithirdparty/libpng -Ithirdparty/glad -Ithirdparty/zstd -Ithirdparty/zlib -Iplatform/osx -I. modules/mono/mono_gd/gd_mono_method.cpp