aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorsol-prog <solarianprogrammer@gmail.com>2016-07-22 11:55:04 -0400
committersol-prog <solarianprogrammer@gmail.com>2016-07-22 11:55:04 -0400
commit32a671b9da172a5e8405bf6da916c53fc748c126 (patch)
tree438e6c7a9c9a6082029a283937ded012cdf77a54
parentab0d19f356dc6aadff11ab4034880c8759315000 (diff)
downloadraylib-32a671b9da172a5e8405bf6da916c53fc748c126.tar.gz
raylib-32a671b9da172a5e8405bf6da916c53fc748c126.zip
OS X comaptiblity changes and compiled library
-rw-r--r--release/osx/helpme!0
-rw-r--r--release/osx/libraylib.abin0 -> 559760 bytes
-rw-r--r--src/Makefile12
-rw-r--r--src/raylib.h10
-rw-r--r--src/rlgl.c16
5 files changed, 24 insertions, 14 deletions
diff --git a/release/osx/helpme! b/release/osx/helpme!
deleted file mode 100644
index e69de29b..00000000
--- a/release/osx/helpme!
+++ /dev/null
diff --git a/release/osx/libraylib.a b/release/osx/libraylib.a
new file mode 100644
index 00000000..32ca7a24
--- /dev/null
+++ b/release/osx/libraylib.a
Binary files differ
diff --git a/src/Makefile b/src/Makefile
index 3c66e4f4..c41fe2f5 100644
--- a/src/Makefile
+++ b/src/Makefile
@@ -169,15 +169,15 @@ endif
# compile core module
core.o : core.c raylib.h rlgl.h utils.h raymath.h
- $(CC) -c $< $(CFLAGS) $(INCLUDE) -D$(PLATFORM)
+ $(CC) -c $< $(CFLAGS) $(INCLUDES) -D$(PLATFORM)
# compile rlgl module
rlgl.o : rlgl.c rlgl.h raymath.h
- $(CC) -c $< $(CFLAGS) $(INCLUDE) -D$(GRAPHICS)
+ $(CC) -c $< $(CFLAGS) $(INCLUDES) -D$(GRAPHICS)
# compile shapes module
shapes.o : shapes.c raylib.h rlgl.h
- $(CC) -c $< $(CFLAGS) $(INCLUDE)
+ $(CC) -c $< $(CFLAGS) $(INCLUDES)
# compile textures module
textures.o : textures.c rlgl.h utils.h
@@ -185,11 +185,11 @@ textures.o : textures.c rlgl.h utils.h
# compile text module
text.o : text.c raylib.h utils.h
- $(CC) -c $< $(CFLAGS) $(INCLUDE)
+ $(CC) -c $< $(CFLAGS) $(INCLUDES)
# compile models module
models.o : models.c raylib.h rlgl.h raymath.h
- $(CC) -c $< $(CFLAGS) $(INCLUDE) -D$(PLATFORM)
+ $(CC) -c $< $(CFLAGS) $(INCLUDES) -D$(PLATFORM)
# compile audio module
audio.o : audio.c raylib.h
@@ -209,7 +209,7 @@ camera.o : camera.c raylib.h
#compile gestures module
gestures.o : gestures.c raylib.h
- $(CC) -c $< $(CFLAGS) $(INCLUDE)
+ $(CC) -c $< $(CFLAGS) $(INCLUDES)
# It installs generated and needed files to compile projects using raylib.
# The installation works manually.
diff --git a/src/raylib.h b/src/raylib.h
index 19c67712..fee6aa91 100644
--- a/src/raylib.h
+++ b/src/raylib.h
@@ -268,9 +268,13 @@
//----------------------------------------------------------------------------------
#ifndef __cplusplus
// Boolean type
- #if !defined(_STDBOOL_H)
- typedef enum { false, true } bool;
- #define _STDBOOL_H
+ #ifndef __APPLE__
+ #if !defined(_STDBOOL_H)
+ typedef enum { false, true } bool;
+ #define _STDBOOL_H
+ #endif
+ #else
+ #include <stdbool.h>
#endif
#endif
diff --git a/src/rlgl.c b/src/rlgl.c
index 6477efaa..2b551469 100644
--- a/src/rlgl.c
+++ b/src/rlgl.c
@@ -1275,14 +1275,20 @@ void rlglLoadExtensions(void *loader)
{
#if defined(GRAPHICS_API_OPENGL_21) || defined(GRAPHICS_API_OPENGL_33)
// NOTE: glad is generated and contains only required OpenGL 3.3 Core extensions (and lower versions)
- if (!gladLoadGLLoader((GLADloadproc)loader)) TraceLog(WARNING, "GLAD: Cannot load OpenGL extensions");
- else TraceLog(INFO, "GLAD: OpenGL extensions loaded successfully");
+ #ifndef __APPLE__
+ if (!gladLoadGLLoader((GLADloadproc)loader)) TraceLog(WARNING, "GLAD: Cannot load OpenGL extensions");
+ else TraceLog(INFO, "GLAD: OpenGL extensions loaded successfully");
+ #endif
#if defined(GRAPHICS_API_OPENGL_21)
- if (GLAD_GL_VERSION_2_1) TraceLog(INFO, "OpenGL 2.1 profile supported");
+ #ifndef __APPLE__
+ if (GLAD_GL_VERSION_2_1) TraceLog(INFO, "OpenGL 2.1 profile supported");
+ #endif
#elif defined(GRAPHICS_API_OPENGL_33)
- if(GLAD_GL_VERSION_3_3) TraceLog(INFO, "OpenGL 3.3 Core profile supported");
- else TraceLog(ERROR, "OpenGL 3.3 Core profile not supported");
+ #ifndef __APPLE__
+ if(GLAD_GL_VERSION_3_3) TraceLog(INFO, "OpenGL 3.3 Core profile supported");
+ else TraceLog(ERROR, "OpenGL 3.3 Core profile not supported");
+ #endif
#endif
// With GLAD, we can check if an extension is supported using the GLAD_GL_xxx booleans