aboutsummaryrefslogtreecommitdiff
path: root/src/makefile
diff options
context:
space:
mode:
authorPalaui <sucdepressec@gmail.com>2014-12-09 13:10:28 +0100
committerPalaui <sucdepressec@gmail.com>2014-12-09 13:10:28 +0100
commita2c8ddca1345722603637bddc3421f64025d7e5e (patch)
tree0623e6f7c0ada0319c6b8bd8febd48d0e17c9973 /src/makefile
parent29d8b48503f3064cdc1f3a87c01b4264e716a220 (diff)
downloadraylib-a2c8ddca1345722603637bddc3421f64025d7e5e.tar.gz
raylib-a2c8ddca1345722603637bddc3421f64025d7e5e.zip
Revert "Corrected some bugs..."
This reverts commit 29d8b48503f3064cdc1f3a87c01b4264e716a220.
Diffstat (limited to 'src/makefile')
-rw-r--r--src/makefile31
1 files changed, 8 insertions, 23 deletions
diff --git a/src/makefile b/src/makefile
index 76984bbe..bb37748a 100644
--- a/src/makefile
+++ b/src/makefile
@@ -24,7 +24,7 @@
#**************************************************************************************************
# define raylib platform (by default, compile for RPI)
-# Other possible platforms: PLATFORM_DESKTOP_WIN PLATFORM_DESKTOP_LINUX PLATFORM_DESKTOP_MAC PLATFORM_WEB
+# Other possible platforms: PLATFORM_DESKTOP PLATFORM_DESKTOP_LINUX
PLATFORM ?= PLATFORM_RPI
# define raylib graphics api depending on selected platform
@@ -40,26 +40,16 @@ endif
# NOTE: makefiles targets require tab indentation
# define compiler: gcc for C program, define as g++ for C++
-ifeq ($(PLATFORM),PLATFORM_WEB)
- # define emscripten compiler
- CC = emcc
-else
- # define default gcc compiler
- CC = gcc
-endif
+CC = gcc
# define compiler flags:
# -O2 defines optimization level
# -Wall turns on most, but not all, compiler warnings
# -std=c99 use standard C from 1999 revision
-ifeq ($(PLATFORM),PLATFORM_WEB)
- CFLAGS = -O3 -s USE_GLFW=3 -s LEGACY_GL_EMULATION=1
-else
ifeq ($(PLATFORM),PLATFORM_RPI)
CFLAGS = -O2 -Wall -std=gnu99 -fgnu89-inline
else
- CFLAGS = -O2 -Wall -std=c99
-endif
+ CFLAGS = -O2 -Wall -std=c99 -fgnu89-inline
endif
#CFLAGSEXTRA = -Wextra -Wmissing-prototypes -Wstrict-prototypes
@@ -79,16 +69,11 @@ default: raylib
# compile raylib library
raylib: $(OBJS)
-ifeq ($(PLATFORM),PLATFORM_WEB)
- emcc $(OBJS) -o raylib.bc
-else
ar rcs libraylib.a $(OBJS)
-endif
# compile core module
-# emcc core.c -o core.bc -DPLATFORM_DESKTOP
core.o: core.c
- $(CC) -c core.c $(CFLAGS) $(INCLUDES) -D$(PLATFORM) -D$(GRAPHICS)
+ $(CC) -c core.c $(CFLAGS) $(INCLUDES) -D$(PLATFORM)
# compile rlgl module
rlgl.o: rlgl.c
@@ -100,19 +85,19 @@ raymath.o: raymath.c
# compile shapes module
shapes.o: shapes.c
- $(CC) -c shapes.c $(CFLAGS) $(INCLUDES) -D$(PLATFORM) -D$(GRAPHICS)
+ $(CC) -c shapes.c $(CFLAGS) $(INCLUDES) -D$(PLATFORM)
# compile textures module
textures.o: textures.c
- $(CC) -c textures.c $(CFLAGS) $(INCLUDES) -D$(PLATFORM) -D$(GRAPHICS)
+ $(CC) -c textures.c $(CFLAGS) $(INCLUDES) -D$(PLATFORM)
# compile text module
text.o: text.c
- $(CC) -c text.c $(CFLAGS) $(INCLUDES) -D$(PLATFORM) -D$(GRAPHICS)
+ $(CC) -c text.c $(CFLAGS) $(INCLUDES) -D$(PLATFORM)
# compile models module
models.o: models.c
- $(CC) -c models.c $(CFLAGS) $(INCLUDES) -D$(PLATFORM) -D$(GRAPHICS)
+ $(CC) -c models.c $(CFLAGS) $(INCLUDES) -D$(PLATFORM)
# compile audio module
audio.o: audio.c