Closed funkytaco closed 9 years ago
I Installed OpenNI-MacOSX-x64-2.2.0.33 and now I get:
g++ src/OSCeleton.cpp src/viewer.cpp -O3 -Wno-write-strings -Iliblo-0.26-modified -I/usr/X11/include -I/usr/include/ni -lOpenNI -lstdc++ -L/usr/X11/lib -lGL -lGLU -lglut liblo-0.26-modified/src/.libs/*.o -o osceleton
In file included from src/OSCeleton.cpp:28:
src/common.h:5:10: error: 'GL/glut.h' file not found with <angled> include; use "quotes" instead
#include <GL/glut.h>
^~~~~~~~~~~
"GL/glut.h"
In file included from src/OSCeleton.cpp:28:
In file included from src/common.h:5:
src/GL/glut.h:137:10: fatal error: 'GL/gl.h' file not found
#include <GL/gl.h>
^
2 errors generated.
In file included from src/viewer.cpp:1:
src/common.h:5:10: error: 'GL/glut.h' file not found with <angled> include; use "quotes" instead
#include <GL/glut.h>
^~~~~~~~~~~
"GL/glut.h"
In file included from src/viewer.cpp:1:
In file included from src/common.h:5:
src/GL/glut.h:137:10: fatal error: 'GL/gl.h' file not found
#include <GL/gl.h>
^
2 errors generated.
make: *** [osceleton] Error 1
I modified one line in the Makefile:
g++ src/OSCeleton.cpp src/viewer.cpp -O3 -Wno-write-strings -Iliblo-0.26-modified -I/usr/X11/include -I/usr/include/ni -lOpenNI -lstdc++ -L/usr/X11/lib -framework OpenGL -framework GLUT liblo-0.26-modified/src/.libs/*.o -o osceleton
Based on this SO answer I modified viewer.cpp:
#ifndef __MAC__
#define __MAC__ 1
#endif
#ifdef __MAC__
# include <OpenGL/glu.h>
# include <OpenGL/gl.h>
#else
#include <GL/glu.h>
# include <GL/gl.h>
#endif
$ ls /System/Library/Frameworks/GLUT.framework/headers
copy.h glsmapint.h glutf90.h intersect.h segment.h vvector.h
extrude.h glut.h glutstroke.h port.h tube.h
glsmap.h glutbitmap.h gutil.h rot.h tube_gc.h
$ ls /System/Library/Frameworks/OpenGL.framework/Headers/
CGLContext.h CGLMacro.h OpenGLAvailability.h glext.h glu.h
CGLCurrent.h CGLRenderers.h gl.h gliContext.h gluContext.h
CGLDevice.h CGLTypes.h gl3.h gliDispatch.h gluMacro.h
CGLIOSurface.h OpenGL.h gl3ext.h gltypes.h
I changed common.h to this:
#ifndef __MAC__
#define __MAC__ 1
#endif
#ifdef __MAC__
# include <GLUT/glut.h>
#else
#endif
extern int window;
#include "viewer.h"
I may have modified another file or two, but if I did, they were all errors relationg to the GL library.
I ran
make
and get this error:I' don't see any prerequisites listed.