diff options
Diffstat (limited to 'apps/plugins/pacbox/Makefile')
-rw-r--r-- | apps/plugins/pacbox/Makefile | 108 |
1 files changed, 0 insertions, 108 deletions
diff --git a/apps/plugins/pacbox/Makefile b/apps/plugins/pacbox/Makefile deleted file mode 100644 index e1b998a7aa..0000000000 --- a/apps/plugins/pacbox/Makefile +++ /dev/null | |||
@@ -1,108 +0,0 @@ | |||
1 | # __________ __ ___. | ||
2 | # Open \______ \ ____ ____ | | _\_ |__ _______ ___ | ||
3 | # Source | _// _ \_/ ___\| |/ /| __ \ / _ \ \/ / | ||
4 | # Jukebox | | ( <_> ) \___| < | \_\ ( <_> > < < | ||
5 | # Firmware |____|_ /\____/ \___ >__|_ \|___ /\____/__/\_ \ | ||
6 | # \/ \/ \/ \/ \/ | ||
7 | # $Id$ | ||
8 | # | ||
9 | |||
10 | INCLUDES = -I$(APPSDIR) -I.. -I. $(TARGET_INC) -I$(FIRMDIR)/include -I$(FIRMDIR)/export \ | ||
11 | -I$(FIRMDIR)/common -I$(FIRMDIR)/drivers -I$(OUTDIR) -I$(BUILDDIR) | ||
12 | CFLAGS = $(INCLUDES) $(GCCOPTS) -O2 $(TARGET) $(EXTRA_DEFINES) \ | ||
13 | -DTARGET_ID=$(TARGET_ID) -DMEM=${MEMORYSIZE} -DPLUGIN | ||
14 | |||
15 | ifdef APPEXTRA | ||
16 | INCLUDES += $(patsubst %,-I$(APPSDIR)/%,$(subst :, ,$(APPEXTRA))) | ||
17 | endif | ||
18 | |||
19 | LINKFILE := $(OBJDIR)/link.lds | ||
20 | DEPFILE = $(OBJDIR)/dep-pacbox | ||
21 | |||
22 | # This sets up 'SRC' based on the files mentioned in SOURCES | ||
23 | include $(TOOLSDIR)/makesrc.inc | ||
24 | |||
25 | SOURCES = $(SRC) | ||
26 | OBJS2 := $(SRC:%.c=$(OBJDIR)/%.o) | ||
27 | OBJS = $(patsubst %.S, $(OBJDIR)/%.o, $(OBJS2)) | ||
28 | DIRS = . | ||
29 | |||
30 | LDS := ../plugin.lds | ||
31 | OUTPUT = $(OUTDIR)/pacbox.rock | ||
32 | |||
33 | all: $(OUTPUT) | ||
34 | |||
35 | ifndef SIMVER | ||
36 | $(OBJDIR)/pacbox.elf: $(OBJS) $(LINKFILE) | ||
37 | $(call PRINTS,LD $(@F))$(CC) $(CFLAGS) -o $@ $(OBJS) -L$(BUILDDIR) -lplugin -lgcc \ | ||
38 | -T$(LINKFILE) -Wl,--gc-sections -Wl,-Map,$(OBJDIR)/pacbox.map | ||
39 | |||
40 | $(OUTPUT): $(OBJDIR)/pacbox.elf | ||
41 | $(call PRINTS,OBJCOPY $(@F))$(OC) -O binary $< $@ | ||
42 | else | ||
43 | |||
44 | ifeq ($(SIMVER), x11) | ||
45 | ################################################### | ||
46 | # This is the X11 simulator version | ||
47 | |||
48 | $(OUTPUT): $(OBJS) | ||
49 | $(call PRINTS,LD $(@F))$(CC) $(CFLAGS) $(SHARED_FLAG) $(OBJS) -L$(BUILDDIR) -lplugin -o $@ | ||
50 | ifeq ($(findstring CYGWIN,$(UNAME)),CYGWIN) | ||
51 | # 'x' must be kept or you'll have "Win32 error 5" | ||
52 | # $ fgrep 5 /usr/include/w32api/winerror.h | head -1 | ||
53 | # #define ERROR_ACCESS_DENIED 5L | ||
54 | else | ||
55 | @chmod -x $@ | ||
56 | endif | ||
57 | |||
58 | else # end of x11-simulator | ||
59 | ifeq ($(SIMVER), sdl) | ||
60 | ################################################### | ||
61 | # This is the SDL simulator version | ||
62 | |||
63 | $(OUTPUT): $(OBJS) | ||
64 | $(call PRINTS,LD $(@F))$(CC) $(CFLAGS) $(SHARED_FLAG) $(OBJS) -L$(BUILDDIR) -lplugin -o $@ | ||
65 | ifeq ($(findstring CYGWIN,$(UNAME)),CYGWIN) | ||
66 | # 'x' must be kept or you'll have "Win32 error 5" | ||
67 | # $ fgrep 5 /usr/include/w32api/winerror.h | head -1 | ||
68 | # #define ERROR_ACCESS_DENIED 5L | ||
69 | else | ||
70 | @chmod -x $@ | ||
71 | endif | ||
72 | |||
73 | else # end of sdl-simulator | ||
74 | ################################################### | ||
75 | # This is the win32 simulator version | ||
76 | DLLTOOLFLAGS = --export-all | ||
77 | DLLWRAPFLAGS = -s --entry _DllMain@12 --target=i386-mingw32 -mno-cygwin | ||
78 | |||
79 | $(OUTPUT): $(OBJS) | ||
80 | $(call PRINTS,DLL $(@F))$(DLLTOOL) $(DLLTOOLFLAGS) -z $(OBJDIR)/$*.def $(OBJS) | ||
81 | $(SILENT)$(DLLWRAP) $(DLLWRAPFLAGS) --def $(OBJDIR)/$*.def $(OBJS) \ | ||
82 | $(BUILDDIR)/libplugin.a -o $@ | ||
83 | ifeq ($(findstring CYGWIN,$(UNAME)),CYGWIN) | ||
84 | # 'x' must be kept or you'll have "Win32 error 5" | ||
85 | # $ fgrep 5 /usr/include/w32api/winerror.h | head -1 | ||
86 | # #define ERROR_ACCESS_DENIED 5L | ||
87 | else | ||
88 | @chmod -x $@ | ||
89 | endif | ||
90 | endif # end of win32-simulator | ||
91 | endif | ||
92 | endif # end of simulator section | ||
93 | |||
94 | |||
95 | include $(TOOLSDIR)/make.inc | ||
96 | |||
97 | # MEMORYSIZE should be passed on to this makefile with the chosen memory size | ||
98 | # given in number of MB | ||
99 | $(LINKFILE): $(LDS) | ||
100 | $(call PRINTS,build $(@F))cat $< | $(CC) -DMEMORYSIZE=$(MEMORYSIZE) $(INCLUDES) $(TARGET) \ | ||
101 | $(DEFINES) -E -P - >$@ | ||
102 | |||
103 | clean: | ||
104 | $(call PRINTS,cleaning pacbox)rm -rf $(OBJDIR)/pacbox | ||
105 | $(SILENT)rm -f $(OBJDIR)/pacbox.* $(DEPFILE) | ||
106 | |||
107 | -include $(DEPFILE) | ||
108 | |||