forked from len0rd/rockbox
Make simulator compile on MacOS
Tested on MacOS Sequoia (Apple Silicon) with the latest Xcode command line tools, gcc 14 (Homebrew GCC 14.2.0_1) and sdl2 (Homebrew 2.30.9) Make sure 'gcc' (and 'gcc-ar') is in your PATH ahead of the Xcode-provided "gcc"(clang). E.g. by setting up symlinks in /usr/local/bin that point to gcc-14 and gcc-ar-14. Notes: - The appropriate bmp from uisimulator/bitmaps has to be manually copied to your build folder and renamed to UI256.bmp, if you want the sim background to be displayed Change-Id: I559f33d2165065f913f30c016b85906af380fb81
This commit is contained in:
parent
f9ae6d6524
commit
1745b74576
13 changed files with 75 additions and 8 deletions
|
|
@ -21,8 +21,12 @@ SIMLIB = $(BUILDDIR)/uisimulator/libuisimulator.a
|
|||
ifeq (yes,$(APPLICATION))
|
||||
UIBMP=
|
||||
else
|
||||
ifeq ($(UNAME), Darwin)
|
||||
UIBMP=
|
||||
else
|
||||
UIBMP=$(BUILDDIR)/UI256.bmp
|
||||
endif
|
||||
endif
|
||||
|
||||
.SECONDEXPANSION: # $$(OBJ) is not populated until after this
|
||||
|
||||
|
|
@ -31,8 +35,12 @@ $(SIMLIB): $$(SIMOBJ) $(UIBMP)
|
|||
$(call PRINTS,AR $(@F))$(AR) rcs $@ $^ >/dev/null
|
||||
|
||||
$(BUILDDIR)/$(BINARY): $$(OBJ) $(FIRMLIB) $(VOICESPEEXLIB) $(CORE_LIBS) $(SIMLIB)
|
||||
ifeq ($(UNAME), Darwin)
|
||||
$(call PRINTS,LD $(BINARY))$(CC) -o $@ $^ $(SIMLIB) $(LDOPTS) $(GLOBAL_LDOPTS) -Wl,-map,$(BUILDDIR)/rockbox.map
|
||||
else
|
||||
$(call PRINTS,LD $(BINARY))$(CC) -o $@ -Wl,--start-group $^ -Wl,--end-group $(LDOPTS) $(GLOBAL_LDOPTS) \
|
||||
-Wl,-Map,$(BUILDDIR)/rockbox.map
|
||||
endif
|
||||
$(SILENT)$(call objcopy,$@,$@)
|
||||
|
||||
$(BUILDDIR)/uisimulator/%.o: $(ROOTDIR)/uisimulator/%.c
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue