mirror of
https://github.com/coop-deluxe/sm64coopdx.git
synced 2024-11-22 03:55:11 +00:00
Merge branch 'unstable' of github.com:sm64ex-coop-dev/sm64ex-coop into unstable
This commit is contained in:
commit
2cf7a87ab4
3 changed files with 25 additions and 15 deletions
30
Makefile
30
Makefile
|
@ -2,9 +2,6 @@
|
||||||
|
|
||||||
include util.mk
|
include util.mk
|
||||||
|
|
||||||
# Dynos
|
|
||||||
include dynos.mk
|
|
||||||
|
|
||||||
# Default target
|
# Default target
|
||||||
default: all
|
default: all
|
||||||
|
|
||||||
|
@ -96,10 +93,10 @@ $(eval $(call validate-option,COMPILER,ido gcc))
|
||||||
|
|
||||||
ifeq ($(WINDOWS_AUTO_BUILDER),1)
|
ifeq ($(WINDOWS_AUTO_BUILDER),1)
|
||||||
export SHELL=sh.exe
|
export SHELL=sh.exe
|
||||||
EXTRA_INCLUDES := ../include/1 ../include/2 ../include/3 ../include/4
|
EXTRA_INCLUDES := -I ../include/1 -I ../include/2 -I ../include/3 -I ../include/4
|
||||||
EXTRA_CFLAGS := -Wno-expansion-to-defined
|
EXTRA_CFLAGS := -Wno-expansion-to-defined
|
||||||
|
|
||||||
EXTRA_CPP_INCLUDES := ../include/cpp
|
EXTRA_CPP_INCLUDES := -I ../include/cpp
|
||||||
EXTRA_CPP_FLAGS := -Wno-class-conversion -Wno-packed-not-aligned
|
EXTRA_CPP_FLAGS := -Wno-class-conversion -Wno-packed-not-aligned
|
||||||
else
|
else
|
||||||
EXTRA_INCLUDES ?=
|
EXTRA_INCLUDES ?=
|
||||||
|
@ -389,12 +386,15 @@ ifeq ($(filter clean distclean print-%,$(MAKECMDGOALS)),)
|
||||||
endif
|
endif
|
||||||
|
|
||||||
# Make tools if out of date
|
# Make tools if out of date
|
||||||
$(info Building tools...)
|
ifeq ($(WINDOWS_AUTO_BUILDER),0)
|
||||||
#DUMMY != $(MAKE) -s -C $(TOOLS_DIR) $(if $(filter-out ido0,$(COMPILER)$(USE_QEMU_IRIX)),all-except-recomp,) >&2 || echo FAIL
|
$(info Building tools...)
|
||||||
DUMMY != $(MAKE) -C $(TOOLS_DIR) >&2 || echo FAIL
|
#DUMMY != $(MAKE) -s -C $(TOOLS_DIR) $(if $(filter-out ido0,$(COMPILER)$(USE_QEMU_IRIX)),all-except-recomp,) >&2 || echo FAIL
|
||||||
ifeq ($(DUMMY),FAIL)
|
DUMMY != $(MAKE) -C $(TOOLS_DIR) >&2 || echo FAIL
|
||||||
$(error Failed to build tools)
|
ifeq ($(DUMMY),FAIL)
|
||||||
endif
|
$(error Failed to build tools)
|
||||||
|
endif
|
||||||
|
endif
|
||||||
|
|
||||||
$(info Building Game...)
|
$(info Building Game...)
|
||||||
|
|
||||||
endif
|
endif
|
||||||
|
@ -473,6 +473,9 @@ GODDARD_SRC_DIRS := src/goddard src/goddard/dynlists
|
||||||
# File dependencies and variables for specific files
|
# File dependencies and variables for specific files
|
||||||
include Makefile.split
|
include Makefile.split
|
||||||
|
|
||||||
|
# Dynos
|
||||||
|
include dynos.mk
|
||||||
|
|
||||||
# Source code files
|
# Source code files
|
||||||
LEVEL_C_FILES := $(wildcard levels/*/leveldata.c) $(wildcard levels/*/script.c) $(wildcard levels/*/geo.c)
|
LEVEL_C_FILES := $(wildcard levels/*/leveldata.c) $(wildcard levels/*/script.c) $(wildcard levels/*/geo.c)
|
||||||
C_FILES := $(foreach dir,$(SRC_DIRS),$(wildcard $(dir)/*.c)) $(LEVEL_C_FILES)
|
C_FILES := $(foreach dir,$(SRC_DIRS),$(wildcard $(dir)/*.c)) $(LEVEL_C_FILES)
|
||||||
|
@ -591,7 +594,10 @@ ifeq ($(OSX_BUILD),1)
|
||||||
AS := i686-w64-mingw32-as
|
AS := i686-w64-mingw32-as
|
||||||
endif
|
endif
|
||||||
|
|
||||||
ifeq ($(COMPILER),gcc)
|
ifeq ($(WINDOWS_AUTO_BUILDER),1)
|
||||||
|
CC := cc
|
||||||
|
CXX := g++
|
||||||
|
else ifeq ($(COMPILER),gcc)
|
||||||
CC := $(CROSS)gcc
|
CC := $(CROSS)gcc
|
||||||
CXX := $(CROSS)g++
|
CXX := $(CROSS)g++
|
||||||
else ifeq ($(TARGET_WEB),1) # As in, web PC port
|
else ifeq ($(TARGET_WEB),1) # As in, web PC port
|
||||||
|
|
|
@ -188,12 +188,16 @@ endef
|
||||||
|
|
||||||
ifneq ($(MAKECMDGOALS),clean)
|
ifneq ($(MAKECMDGOALS),clean)
|
||||||
ifneq ($(MAKECMDGOALS),distclean)
|
ifneq ($(MAKECMDGOALS),distclean)
|
||||||
|
ifeq ($(WINDOWS_AUTO_BUILDER),1)
|
||||||
|
include $(BUILD_DIR)/level_rules.mk
|
||||||
|
else
|
||||||
$(BUILD_DIR)/level_rules.mk: levels/level_rules.mk levels/level_defines.h
|
$(BUILD_DIR)/level_rules.mk: levels/level_rules.mk levels/level_defines.h
|
||||||
@$(PRINT) "$(GREEN)Preprocessing level make rules: $(BLUE)$@ $(NO_COL)\n"
|
@$(PRINT) "$(GREEN)Preprocessing level make rules: $(BLUE)$@ $(NO_COL)\n"
|
||||||
@$(CPP) $(VERSION_CFLAGS) -I . $(EXTRA_INCLUDES) -o $@ $<
|
$(V)$(CPP) $(VERSION_CFLAGS) -I . $(EXTRA_INCLUDES) -o $@ $<
|
||||||
include $(BUILD_DIR)/level_rules.mk
|
include $(BUILD_DIR)/level_rules.mk
|
||||||
endif
|
endif
|
||||||
endif
|
endif
|
||||||
|
endif
|
||||||
|
|
||||||
# --------------------------------------
|
# --------------------------------------
|
||||||
# Extra Level Rules
|
# Extra Level Rules
|
||||||
|
|
|
@ -337,8 +337,8 @@ static bool smlua_field_valid(struct LuaObjectField* data, enum LuaObjectType lo
|
||||||
size_t length = maximum - minimum;
|
size_t length = maximum - minimum;
|
||||||
size_t maxlength = sizeof(void*) + sizeof(u32);
|
size_t maxlength = sizeof(void*) + sizeof(u32);
|
||||||
|
|
||||||
if (length < maxlength) {
|
if (length >= maxlength) {
|
||||||
return (data->lot == lot) && (data->valueOffset == offset) && (lot != LOT_NONE);
|
return (data->lot == lot) && (lot != LOT_NONE);
|
||||||
}
|
}
|
||||||
|
|
||||||
return (length >= maxlength);
|
return (length >= maxlength);
|
||||||
|
|
Loading…
Reference in a new issue