-
Notifications
You must be signed in to change notification settings - Fork 221
Commit
This helps avoid picking up the wrong files when msd files have already been installed as a debian package
- Loading branch information
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,12 @@ | ||
rpiboot: main.c | ||
rpiboot: main.c msd/bootcode.h msd/start.h | ||
$(CC) -Wall -Wextra -g -o $@ $< -lusb-1.0 | ||
|
||
%.h: %.bin | ||
xxd -i $< > $@ | ||
This comment has been minimized.
Sorry, something went wrong.
This comment has been minimized.
Sorry, something went wrong.
ghollingworth
via email
Author
Contributor
|
||
|
||
%.h: %.elf | ||
xxd -i $< > $@ | ||
|
||
uninstall: | ||
rm -f /usr/bin/rpiboot | ||
rm -f /usr/share/rpiboot/usbbootcode.bin | ||
|
4 comments
on commit 1bb4c2d
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think you might have forgotten to "git add msd/bootcode.h msd/start.h", as these appear to be missing.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No, the makefile has a rule to generate them from the binary files
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry yes, I worked that out too late. - very useful trick
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, realised that you could use xxd to convert a binary to an include file and use fmemopen to create a file pointer from an array...
@ghollingworth Small question: this change makes building rpiboot depend on vim, since
xxd
is part of vim.Is there no other way to do this?