Browse Source

Updated build script to generate .a on WebAssembly

This is the recommended way
pull/1381/head
raysan5 4 years ago
parent
commit
789c5fbdf9
2 changed files with 3 additions and 3 deletions
  1. +1
    -1
      examples/Makefile
  2. +2
    -2
      src/Makefile

+ 1
- 1
examples/Makefile View File

@ -353,7 +353,7 @@ ifeq ($(PLATFORM),PLATFORM_RPI)
endif
ifeq ($(PLATFORM),PLATFORM_WEB)
# Libraries for web (HTML5) compiling
LDLIBS = $(RAYLIB_RELEASE_PATH)/libraylib.bc
LDLIBS = $(RAYLIB_RELEASE_PATH)/libraylib.a
endif
# Define all object files required

+ 2
- 2
src/Makefile View File

@ -468,8 +468,8 @@ all: raylib
raylib: $(OBJS)
ifeq ($(PLATFORM),PLATFORM_WEB)
# Compile raylib libray for web
#$(AR) rcs $(RAYLIB_RELEASE_PATH)/lib$(RAYLIB_LIB_NAME).a $(OBJS)
$(CC) $(OBJS) -r -o $(RAYLIB_RELEASE_PATH)/lib$(RAYLIB_LIB_NAME).bc
#$(CC) $(OBJS) -r -o $(RAYLIB_RELEASE_PATH)/lib$(RAYLIB_LIB_NAME).bc
$(AR) rcs $(RAYLIB_RELEASE_PATH)/lib$(RAYLIB_LIB_NAME).a $(OBJS)
@echo "raylib library generated (lib$(RAYLIB_LIB_NAME).a)!"
else
ifeq ($(RAYLIB_LIBTYPE),SHARED)

Loading…
Cancel
Save