Skip to content
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

Compile error in 'develop' branch #248

Closed
niclash opened this issue Aug 1, 2023 · 3 comments
Closed

Compile error in 'develop' branch #248

niclash opened this issue Aug 1, 2023 · 3 comments

Comments

@niclash
Copy link

niclash commented Aug 1, 2023

The following compile error occurs in 'develop' branch. Removing static takes away the problem.

I am on Debian and gcc-12

[ 57%] Building CXX object canvas-example/CMakeFiles/imgui_node_editor.dir/home/niclas/dev/pony/imgui-node-editor/imgui_node_editor_api.cpp.o
In file included from /home/niclas/dev/pony/imgui-node-editor/imgui_extra_math.h:69,
                 from /home/niclas/dev/pony/imgui-node-editor/imgui_node_editor_internal.h:27,
                 from /home/niclas/dev/pony/imgui-node-editor/imgui_node_editor_api.cpp:12:
/home/niclas/dev/pony/imgui-node-editor/imgui_extra_math.inl:37:22: error: ‘ImVec2 operator-(const ImVec2&)’ was declared ‘extern’ and later ‘static’ [-fpermissive]
   37 | inline static ImVec2 operator-(const ImVec2& lhs)
      |                      ^~~~~~~~
/home/niclas/dev/pony/imgui-node-editor/imgui_extra_math.h:36:15: note: previous declaration of ‘ImVec2 operator-(const ImVec2&)’
   36 | inline ImVec2 operator-(const ImVec2& lhs);
      |               ^~~~~~~~
gmake[2]: *** [canvas-example/CMakeFiles/imgui_node_editor.dir/build.make:104: canvas-example/CMakeFiles/imgui_node_editor.dir/home/niclas/dev/pony/imgui-node-editor/imgui_node_editor_api.cpp.o] Error 1
@Tianyun-Xuan
Copy link

same error on gcc (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0

@Tianyun-Xuan
Copy link

The following compile error occurs in 'develop' branch. Removing static takes away the problem.

I am on Debian and gcc-12

[ 57%] Building CXX object canvas-example/CMakeFiles/imgui_node_editor.dir/home/niclas/dev/pony/imgui-node-editor/imgui_node_editor_api.cpp.o
In file included from /home/niclas/dev/pony/imgui-node-editor/imgui_extra_math.h:69,
                 from /home/niclas/dev/pony/imgui-node-editor/imgui_node_editor_internal.h:27,
                 from /home/niclas/dev/pony/imgui-node-editor/imgui_node_editor_api.cpp:12:
/home/niclas/dev/pony/imgui-node-editor/imgui_extra_math.inl:37:22: error: ‘ImVec2 operator-(const ImVec2&)’ was declared ‘extern’ and later ‘static’ [-fpermissive]
   37 | inline static ImVec2 operator-(const ImVec2& lhs)
      |                      ^~~~~~~~
/home/niclas/dev/pony/imgui-node-editor/imgui_extra_math.h:36:15: note: previous declaration of ‘ImVec2 operator-(const ImVec2&)’
   36 | inline ImVec2 operator-(const ImVec2& lhs);
      |               ^~~~~~~~
gmake[2]: *** [canvas-example/CMakeFiles/imgui_node_editor.dir/build.make:104: canvas-example/CMakeFiles/imgui_node_editor.dir/home/niclas/dev/pony/imgui-node-editor/imgui_node_editor_api.cpp.o] Error 1

Refer to the master branch, just remove the static on line 37 of imgui-node-editor/imgui_extra_math.inl
image

@thedmd
Copy link
Owner

thedmd commented Aug 31, 2023

Resolved on develop, thanks!

@thedmd thedmd closed this as completed Aug 31, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants