mirror of https://github.com/OpenTTD/OpenTTD
(svn r8678) [PSP] -Add: added LIBS and CFLAGS needed to compile PSP
-Fix: PSP needs to link with gcc, not with g++ (don't ask) -Fix: PSP doens't support threadsrelease/0.6
parent
d84e14f55f
commit
53785810c8
|
@ -224,7 +224,11 @@ $(BIN_DIR)/$(TTD): $(TTD)
|
||||||
|
|
||||||
$(TTD): rev.o $(OBJS) $(CONFIG_CACHE_LINKER)
|
$(TTD): rev.o $(OBJS) $(CONFIG_CACHE_LINKER)
|
||||||
$(E) '$(STAGE) Linking $@'
|
$(E) '$(STAGE) Linking $@'
|
||||||
|
ifeq ($(OS), PSP)
|
||||||
|
$(Q)$(CC_HOST) $(LDFLAGS) rev.o $(OBJS) $(LIBS) -o $@
|
||||||
|
else
|
||||||
$(Q)$(CXX_HOST) $(LDFLAGS) rev.o $(OBJS) $(LIBS) -o $@
|
$(Q)$(CXX_HOST) $(LDFLAGS) rev.o $(OBJS) $(LIBS) -o $@
|
||||||
|
endif
|
||||||
ifdef STRIP
|
ifdef STRIP
|
||||||
$(Q)$(STRIP) $@
|
$(Q)$(STRIP) $@
|
||||||
endif
|
endif
|
||||||
|
|
|
@ -606,6 +606,9 @@ make_cflags_and_ldflags() {
|
||||||
# Each debug level reduces the optimalization by a bit
|
# Each debug level reduces the optimalization by a bit
|
||||||
if [ $enable_debug -ge 1 ]; then
|
if [ $enable_debug -ge 1 ]; then
|
||||||
CFLAGS="$CFLAGS -g -D_DEBUG"
|
CFLAGS="$CFLAGS -g -D_DEBUG"
|
||||||
|
if [ "$os" = "PSP" ]; then
|
||||||
|
CFLAGS="$CFLAGS -G0"
|
||||||
|
fi
|
||||||
fi
|
fi
|
||||||
if [ $enable_debug -ge 2 ]; then
|
if [ $enable_debug -ge 2 ]; then
|
||||||
CFLAGS="$CFLAGS -fno-inline"
|
CFLAGS="$CFLAGS -fno-inline"
|
||||||
|
@ -668,6 +671,9 @@ make_cflags_and_ldflags() {
|
||||||
if [ "$os" = "PSP" ]; then
|
if [ "$os" = "PSP" ]; then
|
||||||
CFLAGS="$CFLAGS -I`$psp_config -p`/include"
|
CFLAGS="$CFLAGS -I`$psp_config -p`/include"
|
||||||
LDFLAGS="$LDFLAGS -L`$psp_config -p`/lib"
|
LDFLAGS="$LDFLAGS -L`$psp_config -p`/lib"
|
||||||
|
|
||||||
|
CFLAGS="$CFLAGS -fno-exceptions -fno-rtti -D_PSP_FW_VERSION=150"
|
||||||
|
LIBS="$LIBS -D_PSP_FW_VERSION=150 -lpspdebug -lpspdisplay -lpspge -lpspctrl -lpspsdk -lpspnet -lpspnet_inet -lpspnet_apctl -lpspnet_resolver -lpsputility -lpspuser -lpspkernel -lm"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
if [ "$os" = "MORPHOS" ]; then
|
if [ "$os" = "MORPHOS" ]; then
|
||||||
|
|
|
@ -5,7 +5,7 @@
|
||||||
#include <stdlib.h>
|
#include <stdlib.h>
|
||||||
#include "helpers.hpp"
|
#include "helpers.hpp"
|
||||||
|
|
||||||
#if defined(__AMIGA__) || defined(__MORPHOS__) || defined(NO_THREADS)
|
#if defined(__AMIGA__) || defined(__MORPHOS__) || defined(PSP) || defined(NO_THREADS)
|
||||||
OTTDThread *OTTDCreateThread(OTTDThreadFunc function, void *arg) { return NULL; }
|
OTTDThread *OTTDCreateThread(OTTDThreadFunc function, void *arg) { return NULL; }
|
||||||
void *OTTDJoinThread(OTTDThread *t) { return NULL; }
|
void *OTTDJoinThread(OTTDThread *t) { return NULL; }
|
||||||
void OTTDExitThread(void) { NOT_REACHED(); };
|
void OTTDExitThread(void) { NOT_REACHED(); };
|
||||||
|
|
Loading…
Reference in New Issue