parent
e1422078dd
commit
eb311258d0
@ -1 +1,2 @@
|
||||
/Box2D_v2.2.1.zip
|
||||
/Box2D-2.3.1.tar.gz
|
||||
|
@ -1,44 +0,0 @@
|
||||
--- CMakeLists.txt~ 2011-03-06 18:29:20.000000000 -0600
|
||||
+++ CMakeLists.txt 2012-07-28 14:23:58.712181310 -0500
|
||||
@@ -25,7 +25,7 @@
|
||||
|
||||
# Testbed and dependencies.
|
||||
find_package(OpenGL REQUIRED)
|
||||
- add_subdirectory(freeglut)
|
||||
+# add_subdirectory(freeglut)
|
||||
add_subdirectory(glui)
|
||||
add_subdirectory(Testbed)
|
||||
endif(BOX2D_BUILD_EXAMPLES)
|
||||
--- Testbed/Framework/Render.cpp~ 2011-09-11 20:52:20.000000000 -0500
|
||||
+++ Testbed/Framework/Render.cpp 2012-08-02 10:20:24.235457638 -0500
|
||||
@@ -21,7 +21,7 @@
|
||||
#ifdef __APPLE__
|
||||
#include <GLUT/glut.h>
|
||||
#else
|
||||
- #include "freeglut/freeglut.h"
|
||||
+ #include <GL/freeglut.h>
|
||||
#endif
|
||||
|
||||
#include <cstdio>
|
||||
--- Testbed/Tests/TestEntries.cpp~ 2011-09-11 23:55:26.000000000 -0500
|
||||
+++ Testbed/Tests/TestEntries.cpp 2012-08-02 10:22:09.535455225 -0500
|
||||
@@ -22,7 +22,7 @@
|
||||
#ifdef __APPLE__
|
||||
#include <GLUT/glut.h>
|
||||
#else
|
||||
- #include "freeglut/freeglut.h"
|
||||
+ #include <GL/freeglut.h>
|
||||
#endif
|
||||
|
||||
#include <cstring>
|
||||
--- Testbed/CMakeLists.txt~ 2011-09-06 17:47:48.000000000 -0500
|
||||
+++ Testbed/CMakeLists.txt 2012-08-02 10:26:16.954449762 -0500
|
||||
@@ -85,7 +85,7 @@
|
||||
target_link_libraries (
|
||||
Testbed
|
||||
Box2D
|
||||
- freeglut_static
|
||||
+# freeglut_static
|
||||
glui
|
||||
${ADDITIONAL_LIBRARIES}
|
||||
${OPENGL_LIBRARIES}
|
@ -1,52 +0,0 @@
|
||||
--- CMakeLists.txt~ 2012-08-02 10:08:39.000000000 -0500
|
||||
+++ CMakeLists.txt 2012-08-02 10:09:28.467472258 -0500
|
||||
@@ -26,7 +26,7 @@
|
||||
# Testbed and dependencies.
|
||||
find_package(OpenGL REQUIRED)
|
||||
# add_subdirectory(freeglut)
|
||||
- add_subdirectory(glui)
|
||||
+# add_subdirectory(glui)
|
||||
add_subdirectory(Testbed)
|
||||
endif(BOX2D_BUILD_EXAMPLES)
|
||||
|
||||
--- Testbed/Framework/Main.cpp~ 2011-09-11 23:36:08.000000000 -0500
|
||||
+++ Testbed/Framework/Main.cpp 2012-08-02 10:12:15.007468514 -0500
|
||||
@@ -18,7 +18,7 @@
|
||||
|
||||
#include "Render.h"
|
||||
#include "Test.h"
|
||||
-#include "glui/glui.h"
|
||||
+#include <GL/glui.h>
|
||||
|
||||
#include <cstdio>
|
||||
using namespace std;
|
||||
--- Testbed/Framework/Main.cpp~ 2012-08-02 10:12:47.000000000 -0500
|
||||
+++ Testbed/Framework/Main.cpp 2012-08-02 10:18:30.138460153 -0500
|
||||
@@ -19,6 +19,7 @@
|
||||
#include "Render.h"
|
||||
#include "Test.h"
|
||||
#include <GL/glui.h>
|
||||
+#include <GL/freeglut_ext.h>
|
||||
|
||||
#include <cstdio>
|
||||
using namespace std;
|
||||
--- Testbed/CMakeLists.txt~ 2012-08-02 10:26:16.000000000 -0500
|
||||
+++ Testbed/CMakeLists.txt 2012-08-02 10:26:54.562448928 -0500
|
||||
@@ -86,7 +86,7 @@
|
||||
Testbed
|
||||
Box2D
|
||||
# freeglut_static
|
||||
- glui
|
||||
+# glui
|
||||
${ADDITIONAL_LIBRARIES}
|
||||
${OPENGL_LIBRARIES}
|
||||
)
|
||||
--- Testbed/CMakeLists.txt~ 2012-08-02 10:27:10.000000000 -0500
|
||||
+++ Testbed/CMakeLists.txt 2012-08-02 10:32:25.082441562 -0500
|
||||
@@ -1,5 +1,5 @@
|
||||
# Some flags for Freeglut and GLUI.
|
||||
-add_definitions( -DFREEGLUT_EXPORTS -DFREEGLUT_STATIC -D_CRT_SECURE_NO_WARNINGS )
|
||||
+#add_definitions( -DFREEGLUT_EXPORTS -DFREEGLUT_STATIC -D_CRT_SECURE_NO_WARNINGS )
|
||||
|
||||
# Define the framework files.
|
||||
set(Testbed_Framework_SRCS
|
@ -0,0 +1,136 @@
|
||||
This fixes the CMake build. Fixed upstream here:
|
||||
https://code.google.com/p/box2d/source/detail?r=313
|
||||
|
||||
This does not use the bundled glew and glfw.
|
||||
|
||||
Lubomir Rintel <lkundrak@v3.sk>
|
||||
|
||||
diff -urp Box2D-2.3.1/CMakeLists.txt Box2D-2.3.1.fix/CMakeLists.txt
|
||||
--- Box2D-2.3.1/CMakeLists.txt 2015-02-20 14:14:39.000000000 +0100
|
||||
+++ Box2D-2.3.1.fix/CMakeLists.txt 2015-02-20 14:31:34.347669244 +0100
|
||||
@@ -26,8 +26,6 @@ if(BOX2D_BUILD_EXAMPLES)
|
||||
|
||||
# Testbed and dependencies.
|
||||
find_package(OpenGL REQUIRED)
|
||||
- add_subdirectory(freeglut)
|
||||
- add_subdirectory(glui)
|
||||
add_subdirectory(Testbed)
|
||||
endif(BOX2D_BUILD_EXAMPLES)
|
||||
|
||||
diff -urp Box2D-2.3.1/Testbed/CMakeLists.txt Box2D-2.3.1.fix/Testbed/CMakeLists.txt
|
||||
--- Box2D-2.3.1/Testbed/CMakeLists.txt 2015-02-20 14:14:39.000000000 +0100
|
||||
+++ Box2D-2.3.1.fix/Testbed/CMakeLists.txt 2015-02-20 14:32:42.322404515 +0100
|
||||
@@ -1,13 +1,17 @@
|
||||
# Some flags for Freeglut and GLUI.
|
||||
-add_definitions( -DFREEGLUT_EXPORTS -DFREEGLUT_STATIC -D_CRT_SECURE_NO_WARNINGS )
|
||||
+add_definitions( -D_CRT_SECURE_NO_WARNINGS )
|
||||
|
||||
# Define the framework files.
|
||||
set(Testbed_Framework_SRCS
|
||||
Framework/Main.cpp
|
||||
- Framework/Render.cpp
|
||||
- Framework/Render.h
|
||||
+ Framework/RenderGL3.cpp
|
||||
+ Framework/RenderGL3.h
|
||||
Framework/Test.cpp
|
||||
Framework/Test.h
|
||||
+ Framework/DebugDraw.cpp
|
||||
+ Framework/DebugDraw.h
|
||||
+ Framework/imgui.cpp
|
||||
+ Framework/imgui.h
|
||||
)
|
||||
|
||||
#define the test files.
|
||||
@@ -72,7 +76,7 @@ if(APPLE)
|
||||
# We are not using the Apple's framework version, but X11's
|
||||
include_directories( /usr/X11/include )
|
||||
link_directories( /usr/X11/lib )
|
||||
- set (OPENGL_LIBRARIES GL GLU GLUT X11)
|
||||
+ set (OPENGL_LIBRARIES GL GLU X11)
|
||||
elseif(WIN32)
|
||||
set (ADDITIONAL_LIBRARIES winmm)
|
||||
endif(APPLE)
|
||||
@@ -85,8 +89,8 @@ add_executable(Testbed
|
||||
target_link_libraries (
|
||||
Testbed
|
||||
Box2D
|
||||
- freeglut_static
|
||||
- glui
|
||||
+ glfw
|
||||
+ GLEW
|
||||
${ADDITIONAL_LIBRARIES}
|
||||
${OPENGL_LIBRARIES}
|
||||
)
|
||||
diff --git a/Testbed/Framework/Test.h b/Testbed/Framework/Test.h
|
||||
index 7e621d4..bb4cb13 100644
|
||||
--- a/Testbed/Framework/Test.h
|
||||
+++ b/Testbed/Framework/Test.h
|
||||
@@ -25,7 +25,7 @@
|
||||
#if defined(__APPLE__)
|
||||
#include <OpenGL/gl3.h>
|
||||
#else
|
||||
-#include <glew/glew.h>
|
||||
+#include <GL/glew.h>
|
||||
#endif
|
||||
#include <glfw/glfw3.h>
|
||||
|
||||
diff --git a/Testbed/Framework/DebugDraw.cpp b/Testbed/Framework/DebugDraw.cpp
|
||||
index 8299611..2a7da6b 100644
|
||||
--- a/Testbed/Framework/DebugDraw.cpp
|
||||
+++ b/Testbed/Framework/DebugDraw.cpp
|
||||
@@ -21,10 +21,10 @@
|
||||
#if defined(__APPLE_CC__)
|
||||
#include <OpenGL/gl3.h>
|
||||
#else
|
||||
-#include <glew/glew.h>
|
||||
+#include <GL/glew.h>
|
||||
#endif
|
||||
|
||||
-#include <glfw/glfw3.h>
|
||||
+#include <GLFW/glfw3.h>
|
||||
#include <stdio.h>
|
||||
#include <stdarg.h>
|
||||
|
||||
diff --git a/Testbed/Framework/Main.cpp b/Testbed/Framework/Main.cpp
|
||||
index b494da9..79e2c05 100644
|
||||
--- a/Testbed/Framework/Main.cpp
|
||||
+++ b/Testbed/Framework/Main.cpp
|
||||
@@ -24,10 +24,10 @@
|
||||
#if defined(__APPLE__)
|
||||
#include <OpenGL/gl3.h>
|
||||
#else
|
||||
-#include <glew/glew.h>
|
||||
+#include <GL/glew.h>
|
||||
#endif
|
||||
|
||||
-#include <glfw/glfw3.h>
|
||||
+#include <GLFW/glfw3.h>
|
||||
#include <stdio.h>
|
||||
|
||||
#ifdef _MSC_VER
|
||||
diff --git a/Testbed/Framework/RenderGL3.cpp b/Testbed/Framework/RenderGL3.cpp
|
||||
index 4613541..115cb93 100644
|
||||
--- a/Testbed/Framework/RenderGL3.cpp
|
||||
+++ b/Testbed/Framework/RenderGL3.cpp
|
||||
@@ -25,7 +25,7 @@
|
||||
#ifdef __APPLE__
|
||||
#include <OpenGL/gl3.h>
|
||||
#else
|
||||
-#include <glew/glew.h>
|
||||
+#include <GL/glew.h>
|
||||
#include <GL/gl.h>
|
||||
#endif
|
||||
|
||||
diff --git a/Testbed/Framework/Test.h b/Testbed/Framework/Test.h
|
||||
index bb4cb13..f6c69f3 100644
|
||||
--- a/Testbed/Framework/Test.h
|
||||
+++ b/Testbed/Framework/Test.h
|
||||
@@ -27,7 +27,7 @@
|
||||
#else
|
||||
#include <GL/glew.h>
|
||||
#endif
|
||||
-#include <glfw/glfw3.h>
|
||||
+#include <GLFW/glfw3.h>
|
||||
|
||||
#include <stdlib.h>
|
||||
|
Loading…
Reference in new issue