A modern Music Player Daemon based on Rockbox open source high quality audio player
libadwaita audio rust zig deno mpris rockbox mpd

Use full_path_subst on more places, to avoid replacing the wrong occurrences in paths.

If ROOTDIR=/rockbox and BUILDDIR=/rockbox/build-something, it is now possible to
successfully build both target binaries and simulators.

Change-Id: If12d1d5933c5a15feebf627a4f1636dc1e3a67fa

authored by

Vencislav Atanasov and committed by
Franklin Wei
7f9fc20a d8330c9c

+8 -7
+4 -3
apps/plugins/bitmaps/pluginbitmaps.make
··· 26 26 27 27 ifdef PBMP # does player use bitmaps? 28 28 29 - PLUGIN_BITMAPS := $(PBMP:$(ROOTDIR)/%.bmp=$(BUILDDIR)/%.o) 29 + PBMP_BUILD := $(call full_path_subst,$(ROOTDIR)/%,$(BUILDDIR)/%,$(PBMP)) 30 + 31 + PLUGIN_BITMAPS := $(PBMP_BUILD:%.bmp=%.o) 30 32 31 33 PLUGINBITMAPLIB := $(BUILDDIR)/apps/plugins/bitmaps/libpluginbitmaps.a 32 34 PLUGINBITMAPDIR := $(dir $(PLUGINBITMAPLIB)) 33 35 34 - PBMPHFILES := $(subst $(ROOTDIR),$(BUILDDIR),$(PBMP)) 35 - PBMPHFILES := $(shell echo $(PBMPHFILES) | sed -e 's/\.[0-9x]*\.bmp/.h/g' -e 's/\.bmp/.h/g' | awk "{ gsub(/apps\/plugins\/bitmaps\/(mono|native|remote_mono|remote_native)/, \"pluginbitmaps\"); print }" ) 36 + PBMPHFILES := $(shell echo $(PBMP_BUILD) | sed -e 's/\.[0-9x]*\.bmp/.h/g' -e 's/\.bmp/.h/g' | awk "{ gsub(/apps\/plugins\/bitmaps\/(mono|native|remote_mono|remote_native)/, \"pluginbitmaps\"); print }" ) 36 37 37 38 $(PBMPHFILES): $(PLUGIN_BITMAPS) 38 39
+2 -2
apps/plugins/plugins.make
··· 22 22 endif 23 23 OTHER_SRC += $(PLUGINS_SRC) 24 24 ROCKS1 := $(PLUGINS_SRC:.c=.rock) 25 - ROCKS1 := $(subst $(ROOTDIR),$(BUILDDIR),$(ROCKS1)) 25 + ROCKS1 := $(call full_path_subst,$(ROOTDIR)/%,$(BUILDDIR)/%,$(ROCKS1)) 26 26 27 27 ROCKS := $(ROCKS1) 28 28 ··· 35 35 36 36 PLUGINLIB_OBJ := $(PLUGINLIB_SRC:.c=.o) 37 37 PLUGINLIB_OBJ := $(PLUGINLIB_OBJ:.S=.o) 38 - PLUGINLIB_OBJ := $(subst $(ROOTDIR),$(BUILDDIR),$(PLUGINLIB_OBJ)) 38 + PLUGINLIB_OBJ := $(call full_path_subst,$(ROOTDIR)/%,$(BUILDDIR)/%,$(PLUGINLIB_OBJ)) 39 39 40 40 ### build data / rules 41 41 ifndef APP_TYPE
+1 -1
tools/database/database.make
··· 14 14 echo "\#endif" >> $(3); \ 15 15 echo $(3)) 16 16 17 - METADATAS := $(subst $(ROOTDIR), ../.., $(wildcard $(ROOTDIR)/lib/rbcodec/metadata/*.c)) 17 + METADATAS := $(call full_path_subst,$(ROOTDIR)/%,../../%,$(wildcard $(ROOTDIR)/lib/rbcodec/metadata/*.c)) 18 18 19 19 SRCFILE := $(call createsrc, $(TOOLSDIR)/database/SOURCES, \ 20 20 $(METADATAS), \
+1 -1
tools/functions.make
··· 24 24 asmdefs2file = $(SILENT)$(CC) $(PPCFLAGS) $(3) -S -x c -o - -include config.h $(1) | \ 25 25 perl -ne 'if(/^_?AD_(\w+):$$/){$$var=$$1}else{/^\W\.(?:word|long)\W(.*)$$/ && $$var && print "\#define $$var $$1\n";$$var=0}' > $(2) 26 26 27 - c2obj = $(addsuffix .o,$(basename $(subst $(ROOTDIR),$(BUILDDIR),$(1)))) 27 + c2obj = $(addsuffix .o,$(basename $(call full_path_subst,$(ROOTDIR)/%,$(BUILDDIR)/%,$(1)))) 28 28 29 29 a2lnk = $(patsubst lib%.a,-l%,$(notdir $(1))) 30 30