Fix 32 bit builds

This commit is contained in:
MysterD 2023-05-04 01:03:18 -07:00
parent 117379eba4
commit 14e80106c4
2 changed files with 13 additions and 11 deletions

View file

@ -160,7 +160,7 @@ ifeq ($(WINDOWS_AUTO_BUILDER),1)
ifeq ($(TARGET_BITS),32) ifeq ($(TARGET_BITS),32)
EXTRA_INCLUDES := ../include/1 ../include/2 ../include/3 ../include/4 EXTRA_INCLUDES := ../include/1 ../include/2 ../include/3 ../include/4
EXTRA_CPP_INCLUDES := ../include/cpp EXTRA_CPP_INCLUDES := -I../include/cpp
else else
EXTRA_INCLUDES := EXTRA_INCLUDES :=
EXTRA_CPP_INCLUDES := EXTRA_CPP_INCLUDES :=
@ -1644,7 +1644,7 @@ ifeq ($(TARGET_N64),1)
else else
$(EXE): $(O_FILES) $(MIO0_FILES:.mio0=.o) $(ULTRA_O_FILES) $(GODDARD_O_FILES) $(BUILD_DIR)/$(RPC_LIBS) $(BUILD_DIR)/$(DISCORD_SDK_LIBS) $(BUILD_DIR)/$(BASS_LIBS) $(BUILD_DIR)/$(COOPNET_LIBS) $(BUILD_DIR)/$(LANG_DIR) $(BUILD_DIR)/$(MOD_DIR) $(EXE): $(O_FILES) $(MIO0_FILES:.mio0=.o) $(ULTRA_O_FILES) $(GODDARD_O_FILES) $(BUILD_DIR)/$(RPC_LIBS) $(BUILD_DIR)/$(DISCORD_SDK_LIBS) $(BUILD_DIR)/$(BASS_LIBS) $(BUILD_DIR)/$(COOPNET_LIBS) $(BUILD_DIR)/$(LANG_DIR) $(BUILD_DIR)/$(MOD_DIR)
@$(PRINT) "$(GREEN)Linking executable: $(BLUE)$@ $(NO_COL)\n" @$(PRINT) "$(GREEN)Linking executable: $(BLUE)$@ $(NO_COL)\n"
$(V)$(LD) $(PROF_FLAGS) -L $(BUILD_DIR) -o $@ $(O_FILES) $(ULTRA_O_FILES) $(GODDARD_O_FILES) $(LDFLAGS) $(EXTRA_INCLUDES) $(V)$(LD) $(PROF_FLAGS) -L $(BUILD_DIR) -o $@ $(O_FILES) $(ULTRA_O_FILES) $(GODDARD_O_FILES) $(LDFLAGS)
endif endif

View file

@ -330,8 +330,9 @@ static f32 unmat_unscale_shear(f32 shear, f32 scale) {
// tranfs is returned as follows: // tranfs is returned as follows:
// scale(x, y, z), shear(xy, xz, zy), rotation(a, b, c, d), translation(x, y, z) // scale(x, y, z), shear(xy, xz, zy), rotation(a, b, c, d), translation(x, y, z)
static void unmatrix(Mtx * mat, f32 tranfs[13]) { static void unmatrix(Mtx * mat, f32 tranfs[13]) {
register int i; int i = 0;
Vec3f axisVecs[3], yzCross; Vec3f axisVecs[3] = { 0 };
Vec3f yzCross = { 0 };
Mtx locMat = *mat; Mtx locMat = *mat;
@ -430,13 +431,13 @@ static void unmatrix(Mtx * mat, f32 tranfs[13]) {
// builds a transformation matrix from a decomposed sequence from unmatrix // builds a transformation matrix from a decomposed sequence from unmatrix
// see unmatrix for what tranfs means // see unmatrix for what tranfs means
static void rematrix(Mtx * mat, f32 tranfs[13]) { static void rematrix(Mtx * mat, f32 tranfs[13]) {
register int i; int i;
Vec3f rotAxes[3]; Vec3f rotAxes[3] = { 0 };
Mat4 rotMat; Mat4 rotMat = { 0 };
// start with the identity matrix // start with the identity matrix
for (i = 0; i < 4; ++i) { for (i = 0; i < 4; ++i) {
register int j; int j;
mat->m[i][i] = 1.0f; mat->m[i][i] = 1.0f;
for (j = 3; j > i; --j) { for (j = 3; j > i; --j) {
@ -476,8 +477,9 @@ static void rematrix(Mtx * mat, f32 tranfs[13]) {
} }
void delta_interpolate_mtx_accurate(Mtx* out, Mtx* a, Mtx* b, f32 delta) { void delta_interpolate_mtx_accurate(Mtx* out, Mtx* a, Mtx* b, f32 delta) {
register int i; int i;
f32 matTranfsA[13], matTranfsB[13]; f32 matTranfsA[13] = { 0 };
f32 matTranfsB[13] = { 0 };
f32 antiDelta = 1.0f - delta; f32 antiDelta = 1.0f - delta;