Rockbox open source high quality audio player as a Music Player Daemon
mpris rockbox mpd libadwaita audio rust zig deno
2
fork

Configure Feed

Select the types of activity you want to include in your feed.

make: allow building flat binary plugins on USE_ELF targets (attempt 2)

Looks like I forgot to test the hosted builds and for some
reason thought that make would expand objcopy recursively...

Change-Id: I61264eadcb1235660566f6a9f19f8718ebe14583

+20 -13
+1 -1
apps/plugins/chessbox/chessbox.make
··· 39 39 $(filter %.o, $^) \ 40 40 $(filter %.a, $+) \ 41 41 -lgcc $(CHESSBOX_OVLFLAGS) 42 - $(call PRINTS,LD $(@F))$(call objcopy,$(basename $@).elf,$@) 42 + $(call PRINTS,LD $(@F))$(call objcopy_plugin,$(basename $@).elf,$@) 43 43 44 44 # special pattern rule for compiling chessbox with extra flags 45 45 $(CHESSBOX_OBJDIR)/%.o: $(CHESSBOX_SRCDIR)/%.c $(CHESSBOX_SRCDIR)/chessbox.make
+1 -1
apps/plugins/goban/goban.make
··· 36 36 $(filter %.o, $^) \ 37 37 $(filter %.a, $+) \ 38 38 -lgcc $(GOBAN_OVLFLAGS) 39 - $(call PRINTS,LD $(@F))$(call objcopy,$(basename $@).elf,$@) 39 + $(call PRINTS,LD $(@F))$(call objcopy_plugin,$(basename $@).elf,$@)
+1 -1
apps/plugins/imageviewer/imageviewer.make
··· 40 40 $(filter-out $(PLUGIN_CRT0),$(filter %.o, $^)) \ 41 41 $(filter %.a, $+) \ 42 42 -lgcc $(IMGDEC_OVLFLAGS) 43 - $(SILENT)$(call objcopy,$(IMGVBUILDDIR)/$*.elf,$@) 43 + $(SILENT)$(call objcopy_plugin,$(IMGVBUILDDIR)/$*.elf,$@) 44 44 45 45 # rule to create reference map for image decoder 46 46 $(IMGVBUILDDIR)/%.refmap: $(APPSDIR)/plugin.h $(IMGVSRCDIR)/imageviewer.h $(PLUGINLINK_LDS) $(PLUGIN_LIBS)
+1 -1
apps/plugins/lua/lua.make
··· 73 73 $(filter %.o, $^) \ 74 74 $(filter %.a, $+) \ 75 75 -lgcc $(LUA_OVLFLAGS) 76 - $(call PRINTS,LD $(@F))$(call objcopy,$(basename $@).elf,$@) 76 + $(call PRINTS,LD $(@F))$(call objcopy_plugin,$(basename $@).elf,$@) 77 77 78 78 $(LUA_BUILDDIR): 79 79 $(call PRINTS,MKDIR $@)mkdir -p $(LUA_BUILDDIR)/
+1 -1
apps/plugins/pictureflow/pictureflow.make
··· 37 37 $(filter %.o, $^) \ 38 38 $(filter %.a, $+) \ 39 39 -lgcc $(PICTUREFLOW_OVLFLAGS) 40 - $(call PRINTS,LD $(@F))$(call objcopy,$(basename $@).elf,$@) 40 + $(call PRINTS,LD $(@F))$(call objcopy_plugin,$(basename $@).elf,$@) 41 41 42 42 # special pattern rule for compiling pictureflow with extra flags 43 43 $(PICTUREFLOW_OBJDIR)/%.o: $(PICTUREFLOW_SRCDIR)/%.c $(PICTUREFLOW_SRCDIR)/pictureflow.make
+1 -1
apps/plugins/plugins.make
··· 169 169 $(filter %.o, $^) \ 170 170 $(filter %.a, $+) \ 171 171 -lgcc $(PLUGINLDFLAGS) 172 - $(SILENT)$(call objcopy,$(BUILDDIR)/$*.elf,$@) 172 + $(SILENT)$(call objcopy_plugin,$(BUILDDIR)/$*.elf,$@) 173 173 174 174 $(BUILDDIR)/apps/plugins/%.lua: $(ROOTDIR)/apps/plugins/%.lua 175 175 $(call PRINTS,CP $(subst $(ROOTDIR)/,,$<))cp $< $(BUILDDIR)/apps/plugins/
+2 -2
apps/plugins/puzzles/puzzles.make
··· 49 49 $(filter %.o, $^) \ 50 50 $(filter %.a, $+) \ 51 51 -lgcc $(filter-out -Wl%.map, $(PLUGINLDFLAGS)) -Wl,$(LDMAP_OPT),$(PUZZLES_OBJDIR)/src/$*.map 52 - $(SILENT)$(call objcopy,$(PUZZLES_OBJDIR)/$*.elf,$@) 52 + $(SILENT)$(call objcopy_plugin,$(PUZZLES_OBJDIR)/$*.elf,$@) 53 53 54 54 $(PUZZLES_OBJDIR)/sgt-%.rock: $(PUZZLES_OBJDIR)/src/unfinished/%.o $(PUZZLES_OBJDIR)/help/%.o $(PUZZLES_SHARED_OBJ) $(TLSFLIB) 55 55 $(call PRINTS,LD $(@F))$(CC) $(PLUGINFLAGS) -o $(PUZZLES_OBJDIR)/$*.elf \ 56 56 $(filter %.o, $^) \ 57 57 $(filter %.a, $+) \ 58 58 -lgcc $(filter-out -Wl%.map, $(PLUGINLDFLAGS)) -Wl,$(LDMAP_OPT),$(PUZZLES_OBJDIR)/src/$*.map 59 - $(SILENT)$(call objcopy,$(PUZZLES_OBJDIR)/$*.elf,$@) 59 + $(SILENT)$(call objcopy_plugin,$(PUZZLES_OBJDIR)/$*.elf,$@) 60 60 61 61 $(PUZZLES_SRCDIR)/rbcompat.h: $(APPSDIR)/plugin.h \ 62 62 $(APPSDIR)/plugins/lib/pluginlib_exit.h \
+1 -1
apps/plugins/rockboy/rockboy.make
··· 37 37 $(filter %.o, $^) \ 38 38 $(filter %.a, $+) \ 39 39 -lgcc $(ROCKBOY_OVLFLAGS) 40 - $(call PRINTS,LD $(@F))$(call objcopy,$(basename $@).elf,$@) 40 + $(call PRINTS,LD $(@F))$(call objcopy_plugin,$(basename $@).elf,$@) 41 41 42 42 # special rule to build with devkitarm gcc 43 43 ifeq ($(APP_TYPE),ctru-app)
+2 -2
apps/plugins/sdl/sdl.make
··· 95 95 $(filter %.o, $^) \ 96 96 $(filter %.a, $+) \ 97 97 -lgcc -T$(WOLF3D_OUTLDS) $(SDL_OVLFLAGS) 98 - $(call PRINTS,LD $(@F))$(call objcopy,$(basename $@).elf,$@) 98 + $(call PRINTS,LD $(@F))$(call objcopy_plugin,$(basename $@).elf,$@) 99 99 100 100 # Quake 101 101 ### ··· 113 113 $(filter %.o, $^) \ 114 114 $(filter %.a, $+) \ 115 115 -lgcc -T$(QUAKE_OUTLDS) $(SDL_OVLFLAGS) 116 - $(call PRINTS,LD $(@F))$(call objcopy,$(basename $@).elf,$@) 116 + $(call PRINTS,LD $(@F))$(call objcopy_plugin,$(basename $@).elf,$@) 117 117 118 118 ### 119 119
+1 -1
apps/plugins/zxbox/zxbox.make
··· 45 45 $(filter %.o, $^) \ 46 46 $(filter %.a, $+) \ 47 47 -lgcc $(ZXBOX_LDFLAGS) 48 - $(call PRINTS,LD $(@F))$(call objcopy,$(basename $@).elf,$@) 48 + $(call PRINTS,LD $(@F))$(call objcopy_plugin,$(basename $@).elf,$@) 49 49 50 50 # special pattern rule for compiling zxbox with extra flags 51 51 $(ZXBOX_OBJDIR)/%.o: $(ZXBOX_SRCDIR)/%.c $(ZXBOX_SRCDIR)/zxbox.make
+1 -1
lib/rbcodec/codecs/codecs.make
··· 245 245 $(filter %.o, $^) \ 246 246 $(filter %.a, $+) \ 247 247 -lgcc $(CODECLDFLAGS) 248 - $(SILENT)$(call objcopy,$(CODECDIR)/$*.elf,$@) 248 + $(SILENT)$(call objcopy_plugin,$(CODECDIR)/$*.elf,$@)
+2
tools/configure
··· 1755 1755 x1000tools="$genericbitmaptools scramble mkspl-x1000 uclpack" 1756 1756 # default to not generating ELF files 1757 1757 USE_ELF="no" 1758 + PLUGIN_USE_ELF="no" 1758 1759 1759 1760 # ---- For each target ---- 1760 1761 # ··· 4964 4965 export ENC_OPTS=${ENC_OPTS} 4965 4966 export ENCODER=${ENCODER} 4966 4967 export USE_ELF=${USE_ELF} 4968 + export PLUGIN_USE_ELF=${PLUGIN_USE_ELF} 4967 4969 export RBDIR=${rbdir} 4968 4970 export ROCKBOX_SHARE_PATH=${sharedir} 4969 4971 export ROCKBOX_BINARY_PATH=${bindir}
+5
tools/functions.make
··· 38 38 # handles the $(1) == $(2) case too 39 39 ifndef APP_TYPE 40 40 objcopy = $(OC) $(if $(filter yes, $(USE_ELF)), -S -x, -O binary) $(1) $(2) # objcopy native 41 + objcopy_plugin = $(OC) $(if $(filter yes, $(PLUGIN_USE_ELF)), -S -x, -O binary) $(1) $(2) 41 42 else ifneq (,$(findstring sdl-sim,$(APP_TYPE))) 42 43 objcopy = cp $(1) $(1).tmp;mv -f $(1).tmp $(2) # objcopy simulator 44 + objcopy_plugin = $(objcopy) 43 45 else ifneq (,$(findstring ctru,$(MODELNAME))) # 3dsxtool requires symbols 44 46 objcopy = cp $(1) $(1).tmp;mv -f $(1).tmp $(2) 47 + objcopy_plugin = $(objcopy) 45 48 else 46 49 ifdef DEBUG 47 50 objcopy = cp $(1) $(1).tmp;mv -f $(1).tmp $(2) # objcopy hosted (DEBUG) 51 + objcopy_plugin = $(objcopy) 48 52 else 49 53 objcopy = $(OC) -S -x $(1) $(2) # objcopy hosted (!DEBUG) 54 + objcopy_plugin = $(objcopy) 50 55 endif 51 56 endif 52 57