forked from idispatch/opentyrian
-
Notifications
You must be signed in to change notification settings - Fork 0
/
crosscompile.mk
47 lines (33 loc) · 1.14 KB
/
crosscompile.mk
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
# CROSS-COMPILE SETTINGS ###################################
WIN32_PREFIX := /usr/i486-mingw32
WIN32_EPREFIX := /usr
WIN32_HOST := i486-mingw32
WIN32_EXT := .exe
GP2X_PREFIX := /opt/open2x/gcc-4.1.1-glibc-2.3.6
GP2X_EPREFIX := $(GP2X_PREFIX)
GP2X_HOST := arm-open2x-linux
GP2X_EXT := .gpe
GP2X_CFLAGS := -mcpu=arm920t -mtune=arm920t -msoft-float -ffast-math
DINGUX_PREFIX := /opt/mipsel-linux-uclibc/usr
DINGUX_EPREFIX := $(DINGUX_PREFIX)
DINGUX_HOST := mipsel-linux-uclibc
DINGUX_EXT := .dge
# END SETTINGS #############################################
CC := gcc
TARGET := $(TARGET)$($(PLATFORM)_EXT)
PREFIX := $($(PLATFORM)_PREFIX)
EPREFIX := $($(PLATFORM)_EPREFIX)
HOST := $($(PLATFORM)_HOST)
BINDIR := $(EPREFIX)/bin
LIBDIR := $(PREFIX)/lib
INCLUDEDIR := $(PREFIX)/include
ifneq ($(HOST), )
CC := $(HOST)-$(notdir $(CC))
STRIP := $(HOST)-$(notdir $(STRIP))
endif
CC := $(BINDIR)/$(notdir $(CC))
STRIP := $(BINDIR)/$(notdir $(STRIP))
SDL_CONFIG := $(PREFIX)/bin/$(SDL_CONFIG)
# FLAGS ####################################################
ALL_CFLAGS += -I$(INCLUDEDIR) $($(PLATFORM)_CFLAGS)
ALL_LDFLAGS += -L$(LIBDIR) $($(PLATFORM)_LDFLAGS)