diff --git a/apps/Makefile b/apps/Makefile index 912b5ed143..12d4c85fd9 100644 --- a/apps/Makefile +++ b/apps/Makefile @@ -18,21 +18,19 @@ ifdef DEBUG CFLAGS += -g endif -SRC := $(wildcard *.c) +SRC := $(shell cat SOURCES | $(CC) -DMEMORYSIZE=$(MEMORYSIZE) $(INCLUDES) $(TARGET) $(DEFINES) -E -P -include "config.h" - ) DIRS = . # set the ROMTARGET here ROMTARGET := $(ARCHOSROM) ifdef APPEXTRA - SRC += $(wildcard $(APPEXTRA)/*.c) DIRS += $(APPEXTRA) INCLUDES += -I$(APPEXTRA) endif -CFLAGS = -O -W -Wall -m1 -nostdlib -ffreestanding -Wstrict-prototypes \ --fomit-frame-pointer -fschedule-insns $(INCLUDES) $(TARGET) $(DEFINES) \ --DAPPSVERSION=\"$(VERSION)\" $(EXTRA_DEFINES) -DMEM=${MEMORYSIZE} +CFLAGS = $(GCCOPTS) $(INCLUDES) $(TARGET) $(DEFINES) \ + -DAPPSVERSION=\"$(VERSION)\" $(EXTRA_DEFINES) -DMEM=${MEMORYSIZE} OBJS := $(OBJDIR)/lang.o $(SRC:%.c=$(OBJDIR)/%.o) SOURCES = $(SRC) diff --git a/apps/SOURCES b/apps/SOURCES new file mode 100644 index 0000000000..9cc336c4ef --- /dev/null +++ b/apps/SOURCES @@ -0,0 +1,42 @@ +alarm_menu.c +bookmark.c +credits.c +debug_menu.c +filetypes.c +language.c +main.c +main_menu.c +menu.c +misc.c +onplay.c +playlist.c +playlist_menu.c +playlist_viewer.c +plugin.c +screens.c +settings.c +settings_menu.c +sleeptimer.c +sound_menu.c +status.c +talk.c +tree.c +wps-display.c +wps.c +#ifdef HAVE_LCD_CHARCELLS +player/icons.c +player/keyboard.c +#endif +#ifdef HAVE_LCD_BITMAP +recorder/bmp.c +recorder/icons.c +recorder/keyboard.c +recorder/peakmeter.c +recorder/widgets.c +#endif +#ifdef CONFIG_TUNER +recorder/radio.c +#endif +#ifdef HAVE_RECORDING +recorder/recording.c +#endif diff --git a/apps/plugins/Makefile b/apps/plugins/Makefile index caa2775e12..5071f07668 100644 --- a/apps/plugins/Makefile +++ b/apps/plugins/Makefile @@ -8,9 +8,9 @@ # INCLUDES = -I$(FIRMDIR)/include -I$(FIRMDIR)/export -I$(FIRMDIR)/common \ --I$(FIRMDIR)/drivers -I$(APPSDIR) -Ilib -CFLAGS = -O -W -Wall -m1 -nostdlib -ffreestanding -Wstrict-prototypes \ -$(INCLUDES) $(TARGET) $(EXTRA_DEFINES) -DMEM=${MEMORYSIZE} -DPLUGIN + -I$(FIRMDIR)/drivers -I$(APPSDIR) -Ilib +CFLAGS = $(GCCOPTS) $(INCLUDES) $(TARGET) $(EXTRA_DEFINES) \ + -DMEM=${MEMORYSIZE} -DPLUGIN ifdef APPEXTRA INCLUDES += -I$(APPSDIR)/$(APPEXTRA) @@ -20,7 +20,8 @@ LDS := plugin.lds LINKFILE := $(OBJDIR)/pluginlink.lds DEPFILE = $(OBJDIR)/dep-plugins -SRC := $(wildcard *.c) +SRC := $(shell cat SOURCES | $(CC) -DMEMORYSIZE=$(MEMORYSIZE) \ + $(INCLUDES) $(TARGET) $(DEFINES) -E -P -include "config.h" - ) ROCKS := $(SRC:%.c=$(OBJDIR)/%.rock) SOURCES = $(SRC) ELFS := $(SRC:%.c=$(OBJDIR)/%.elf) diff --git a/apps/plugins/SOURCES b/apps/plugins/SOURCES new file mode 100644 index 0000000000..c5923ae843 --- /dev/null +++ b/apps/plugins/SOURCES @@ -0,0 +1,41 @@ +battery_test.c +bounce.c +calculator.c +calendar.c +chessclock.c +chip8.c +clock.c +cube.c +euroconverter.c +favorites.c +firmware_flash.c +flipit.c +grayscale.c +helloworld.c +jackpot.c +jpeg.c +mandelbrot.c +metronome.c +minesweeper.c +mosaique.c +nim.c +oscillograph.c +pong.c +rockblox.c +rockbox_flash.c +search.c +sliding_puzzle.c +snake.c +snake2.c +snow.c +sokoban.c +solitaire.c +sort.c +splitedit.c +star.c +stopwatch.c +vbrfix.c +video.c +viewer.c +vu_meter.c +wormlet.c diff --git a/apps/plugins/lib/Makefile b/apps/plugins/lib/Makefile index 2cc7974770..562d1fc931 100644 --- a/apps/plugins/lib/Makefile +++ b/apps/plugins/lib/Makefile @@ -17,7 +17,7 @@ ifdef APPEXTRA INCLUDES += -I$(APPSDIR)/$(APPEXTRA) endif -CFLAGS = -W -Wall -O -m1 -nostdlib -ffreestanding -Wstrict-prototypes \ +CFLAGS = $(GCCOPTS) \ $(INCLUDES) $(TARGET) $(EXTRA_DEFINES) -DMEM=${MEMORYSIZE} ifdef DEBUG @@ -26,7 +26,7 @@ else CFLAGS += -fomit-frame-pointer -fschedule-insns endif -SRC := $(wildcard *.c) +SRC := $(shell cat SOURCES | $(CC) -DMEMORYSIZE=$(MEMORYSIZE) $(INCLUDES) $(TARGET) $(DEFINES) -E -P -include "config.h" - ) SOURCES = $(SRC) OBJS := $(SRC:%.c=$(OBJDIR)/%.o) DEPFILE = $(OBJDIR)/dep-pluginlib diff --git a/apps/plugins/lib/SOURCES b/apps/plugins/lib/SOURCES new file mode 100644 index 0000000000..31467cca50 --- /dev/null +++ b/apps/plugins/lib/SOURCES @@ -0,0 +1,30 @@ +configfile.c +gray_black_display.c +gray_blockfuncs.c +gray_clear_display.c +gray_core.c +gray_deferred_update.c +gray_drawbitmap.c +gray_drawgraymap.c +gray_drawline.c +gray_drawpixel.c +gray_drawrect.c +gray_fillrect.c +gray_getstringsize.c +gray_horline.c +gray_pixelfuncs.c +gray_position_display.c +gray_putsxy.c +gray_screendump.c +gray_scroll_down.c +gray_scroll_down8.c +gray_scroll_left.c +gray_scroll_right.c +gray_scroll_up.c +gray_scroll_up8.c +gray_set_background.c +gray_set_drawinfo.c +gray_set_drawmode.c +gray_set_foreground.c +gray_setfont.c +gray_verline.c diff --git a/firmware/Makefile b/firmware/Makefile index bb4a30f101..e3364d4387 100644 --- a/firmware/Makefile +++ b/firmware/Makefile @@ -9,19 +9,12 @@ INCLUDES=-Iinclude -I$(FIRMDIR) -Iexport -Icommon -Idrivers -CFLAGS = -W -Wall -O -m1 -nostdlib -ffreestanding -Wstrict-prototypes \ -$(INCLUDES) $(TARGET) $(EXTRA_DEFINES) -DMEM=${MEMORYSIZE} +CFLAGS = $(GCCOPTS) $(INCLUDES) $(TARGET) $(EXTRA_DEFINES) -DMEM=${MEMORYSIZE} -ifdef DEBUG -CFLAGS += -g -DDEBUG -else -CFLAGS += -fomit-frame-pointer -fschedule-insns -endif - -SRC := $(wildcard drivers/*.c common/*.c *.c) -SRC_S := $(wildcard drivers/*.S common/*.S *.S) -SOURCES = $(SRC) $(SRC_S) -OBJS := $(SRC:%.c=$(OBJDIR)/%.o) $(SRC_S:%.S=$(OBJDIR)/%.o) $(OBJDIR)/sysfont.o +SRC := $(shell cat SOURCES | $(CC) -DMEMORYSIZE=$(MEMORYSIZE) $(INCLUDES) $(TARGET) $(DEFINES) -E -P -include "config.h" - ) +SOURCES = $(SRC) +OBJS2 := $(patsubst %.c, $(OBJDIR)/%.o, $(SRC)) $(OBJDIR)/sysfont.o +OBJS = $(patsubst %.S, $(OBJDIR)/%.o, $(OBJS2)) DIRS:=. drivers common OUTPUT = $(OBJDIR)/librockbox.a DEPFILE = $(OBJDIR)/dep-firmware diff --git a/firmware/SOURCES b/firmware/SOURCES new file mode 100644 index 0000000000..04fa25de34 --- /dev/null +++ b/firmware/SOURCES @@ -0,0 +1,59 @@ +backlight.c +buffer.c +common/atoi.c +common/ctype.c +common/dir.c +common/disk.c +common/errno.c +common/file.c +common/memcmp.c +common/qsort.c +common/random.c +common/sprintf.c +common/strcasecmp.c +common/strcat.c +common/strchr.c +common/strcmp.c +common/strcpy.c +common/strlen.c +common/strncmp.c +common/strncpy.c +common/strrchr.c +common/strtok.c +common/timefuncs.c +debug.c +drivers/adc.c +drivers/ata.c +drivers/ata_mmc.c +drivers/button.c +drivers/dac.c +drivers/fat.c +drivers/fmradio.c +drivers/i2c.c +drivers/lcd-player-charset.c +drivers/lcd-player.c +drivers/lcd-recorder.c +drivers/led.c +drivers/mas.c +drivers/power.c +drivers/rtc.c +drivers/serial.c +font.c +hwcompat.c +id3.c +kernel.c +mp3_playback.c +mp3data.c +mpeg.c +panic.c +powermgmt.c +rolo.c +system.c +thread.c +usb.c +bitswap.S +common/memcpy.S +common/memset.S +crt0.S +descramble.S +drivers/lcd.S