
TARGET = embox

ARCH = mips

PLATFORM=mipssim

/* if you use mips*-linux-* compiler you have to
 uncomment this lines and define(OUTPUT_FORMAT_STRING, "elf32-tradbigmips")
 in lds.conf. Also you have to uncomment 'include third_party.gcc.libgcc' 
 in mods.conf
*/
/* CROSS_COMPILE = mips-linux-gnu- */

/* for mips-elf- compiler */
CROSS_COMPILE = mips-elf-

CFLAGS += -O0 -g

CFLAGS += -G0 -march=24kf -EB

CFLAGS += -fno-pic -mno-abicalls -mabi=32
CFLAGS += -Wa,-mno-shared -mno-shared
CFLAGS += -Wa,-xgot -mxgot -mplt -mno-mips16

/* Workaround for https://gcc.gnu.org/bugzilla/show_bug.cgi?id=64569
   See also https://patchwork.linux-mips.org//patch/8355/ */
CFLAGS += -msoft-float -Wa,-msoft-float
/*
CFLAGS += -mhard-float -Wa,-mhard-float
CFLAGS += -msingle-float -Wa,-msingle-float
*/

LDFLAGS += -G0 -EB

CXXFLAGS += -O0 -g
CXXFLAGS += -G0 -march=24kf -EB

CXXFLAGS += -fno-pic -mno-abicalls -mabi=32
CXXFLAGS += -Wa,-mno-shared -mno-shared
CXXFLAGS += -Wa,-xgot -mxgot -mplt -mno-mips16
CXXFLAGS += -fno-threadsafe-statics

//CXXFLAGS += -fno-rtti
//CXXFLAGS += -fno-exceptions
