- Status Closed
- Percent Complete
- Task Type Bugs
- Category Infrastructure → Build environment
- Assigned To No-one
- Operating System All players
- Severity Low
- Priority Very Low
- Reported Version Daily build (which?)
- Due in Version Undecided
-
Due Date
Undecided
- Votes
- Private
FS#9648 - makefile for new multifile plugins requires hackish extra code for unknown reason
I’m not even sure that this is a bug, it may be something I’m doing wrong or a misunderstanding on my part. But regardless, here it is:
This was tested from subversion revision r19442.
When making a new multi-file plugin, I can’t just copy the structure of the sudoku.make file from the sudoku plugin. These extra lines are needed at the end of the .make for some unknown reason:
$(call PRINTS,LD $(@F)) $(SILENT)$(CC) $(PLUGINFLAGS) -o $*.elf \ $(filter %.o, $^) \ $(filter %.a, $^) \ -lgcc $(PLUGINLDFLAGS)
ifdef SIMVER
$(SILENT)cp $*.elf $@
else
$(SILENT)$(OC) -O binary $*.elf $@
endif
If this blob is not present, then the plugin does not get linked or built into a .rock. (there is no error message, it just builds the object files for the plugin and fails to do anything else with them. No .rock file is made for the plugin.).
Attached is a patch containing an extremely simple plugin, named goban, that exhibits this behavior (it is basically a copy of the helloworld plugin made into a multi-file style plugin for demonstration). It appears to me that it should be doing everything necessary to be built as a plugin, but it doesn’t work. Notice that the goban.make has exactly the same structure as sudoku’s sudoku.make file, and yet sudoku correctly becomes a .rock plugin while this test plugin does not.
By the way, the extra blob above was found in reversi’s makefile.
Steps to reproduce:
1) Apply the attached patch
2) Build rockbox (I tested with e200 normal and simulator)
3) make zip and extract it
4) Notice that there exists no goban.rock file in .rockbox/rocks/games/
5) View apps/plugins/sudoku/sudoku.make and compare it with apps/plugins/goban/goban.make. Notice that the structure is identical and yet one works correctly while the other fails silently. This makes it very treacherous to start new multi-file plugins by copying the structure of existing plugins.
2009-08-20 22:32
Reason for closing: Wont Fix
Additional comments about closing: Warning: Undefined array key "typography" in /home/rockbox/flyspray/plugins/dokuwiki/inc/parserutils.php on line 371 Warning: Undefined array key "camelcase" in /home/rockbox/flyspray/plugins/dokuwiki/inc/parserutils.php on line 407
Not being allowed to call plugin sources
"main.c" is a bit annoying,
but something we can live with.
Loading...
Available keyboard shortcuts
- Alt + ⇧ Shift + l Login Dialog / Logout
- Alt + ⇧ Shift + a Add new task
- Alt + ⇧ Shift + m My searches
- Alt + ⇧ Shift + t focus taskid search
Tasklist
- o open selected task
- j move cursor down
- k move cursor up
Task Details
- n Next task
- p Previous task
- Alt + ⇧ Shift + e ↵ Enter Edit this task
- Alt + ⇧ Shift + w watch task
- Alt + ⇧ Shift + y Close Task
Task Editing
- Alt + ⇧ Shift + s save task
Just rename main.c to goban.c (in SOURCES too).
Wow, that’s annoying. I guess that works though, thanks.