Introduce a genimage infra
cover Introduce a genimage infra
As suggested by Arnout here's a series introducing a genimage infra to remove all the duplicated genimage incantation (they are all identical!).
BTW, it seems this topic was brought on the 2014 Developer day at FOSDEM:
http://elinux.org/Buildroot:DeveloperDaysFOSDEM2014#Genimages
In addition to the infra stuff, I took the liberty of fixing all the boards currently using genimage, but I've tested just a couple:
Minnowboard Max and Olimex A20 Olinuxino Micro.
Comments? Feedback?
Ezequiel Garcia (15):
fs: add genimage infra
board/minnowboard-max: Leverage the new genimage infra board/olimex_a20_olinuxino: Leverage the new genimage infra board/wandboard: Leverage the new genimage infra board/firefly: Leverage the new genimage infra board/cubieboard2: Leverage the new genimage infra board/arietta-g25: Leverage the new genimage infra board/imx6ulevk: Leverage the new genimage infra board/galileo: Leverage the new genimage infra board/pandaboard: Leverage the new genimage infra board/boundarydevices: Leverage the new genimage infra board/imx233_olinuxino: Leverage the new genimage infra board/orangepipc: Leverage the new genimage infra board/raspberry*: Leverage the new genimage infra board/via_imx6_vab820: Leverage the new genimage infra
board/acmesystems/arietta-g25/post-image.sh | 16 ---------- board/boundarydevices/common/post-image.sh | 16 ---------- board/cubietech/cubieboard2/post-image.sh | 16 ---------- board/firefly/firefly-rk3288/post-build.sh | 4 +++ board/firefly/firefly-rk3288/post-image.sh | 20 ------------ board/freescale/imx6ulevk/post-image.sh | 15 --------- board/intel/galileo/post-image.sh | 13 -------- board/minnowboard-max/genimage.cfg | 34 +++++++++++++++++++++ board/minnowboard-max/readme.txt | 39 ++++++++---------------- board/olimex/a20_olinuxino/post-image.sh | 16 ---------- board/olimex/imx233_olinuxino/post-image.sh | 14 --------- board/orangepi/orangepipc/post-build.sh | 5 +++ board/orangepi/orangepipc/post-image.sh | 22 ------------- board/pandaboard/post-image.sh | 16 ---------- board/raspberrypi/post-build.sh | 8 +++++ board/raspberrypi/post-image.sh | 22 ------------- board/wandboard/post-image.sh | 16 ---------- configs/acmesystems_arietta_g25_128mb_defconfig | 4 +-- configs/acmesystems_arietta_g25_256mb_defconfig | 4 +-- configs/cubieboard2_defconfig | 5 +-- configs/firefly_rk3288_defconfig | 4 +-- configs/firefly_rk3288_demo_defconfig | 4 +-- configs/freescale_imx6ulevk_defconfig | 4 +-- configs/galileo_defconfig | 4 +-- configs/minnowboard_max_defconfig | 8 +++++ configs/nitrogen6sx_defconfig | 4 +-- configs/nitrogen6x_defconfig | 4 +-- configs/nitrogen7_defconfig | 4 +-- configs/olimex_a20_olinuxino_lime2_defconfig | 2 -- configs/olimex_a20_olinuxino_lime_defconfig | 4 +-- configs/olimex_a20_olinuxino_lime_mali_defconfig | 4 +-- configs/olimex_a20_olinuxino_micro_defconfig | 4 +-- configs/olimex_imx233_olinuxino_defconfig | 3 +- configs/orangepipc_defconfig | 4 +-- configs/pandaboard_defconfig | 4 +-- configs/raspberrypi2_defconfig | 5 +-- configs/raspberrypi_defconfig | 5 +-- configs/via_imx6_vab820_defconfig | 4 +-- configs/wandboard_defconfig | 5 +-- fs/Config.in | 1 + fs/genimage/Config.in | 20 ++++++++++++ fs/genimage/genimage.mk | 21 +++++++++++++ 42 files changed, 157 insertions(+), 270 deletions(-) delete mode 100755 board/acmesystems/arietta-g25/post-image.sh delete mode 100755 board/boundarydevices/common/post-image.sh delete mode 100755 board/cubietech/cubieboard2/post-image.sh delete mode 100755 board/firefly/firefly-rk3288/post-image.sh delete mode 100755 board/freescale/imx6ulevk/post-image.sh delete mode 100755 board/intel/galileo/post-image.sh create mode 100644 board/minnowboard-max/genimage.cfg delete mode 100755 board/olimex/a20_olinuxino/post-image.sh delete mode 100755 board/orangepi/orangepipc/post-image.sh delete mode 100755 board/pandaboard/post-image.sh create mode 100755 board/raspberrypi/post-build.sh delete mode 100755 board/raspberrypi/post-image.sh delete mode 100755 board/wandboard/post-image.sh create mode 100644 fs/genimage/Config.in create mode 100644 fs/genimage/genimage.mk
Signature · 1 line
2.7.0
PATCH 1/15 fs: add genimage infra
Currently, all the boards using genimage are using the same command incantation. Therefore, let's introduce a new filesystem infra to factorize them and allow easier genimage setup.
This commit adds a new genimage infra, by calling genimage with a user-provided config file. The user is still responsible of enabling the apropriate rootfs filesystem images.
--- fs/Config.in | 1 + fs/genimage/Config.in | 20 ++++++++++++++++++++ fs/genimage/genimage.mk | 21 +++++++++++++++++++++ 3 files changed, 42 insertions(+) create mode 100644 fs/genimage/Config.in create mode 100644 fs/genimage/genimage.mk
fs/Config.in +1 -0
@@ -5,6 +5,7 @@ source "fs/cloop/Config.in" source "fs/cpio/Config.in" source "fs/cramfs/Config.in" source "fs/ext2/Config.in" +source "fs/genimage/Config.in" source "fs/initramfs/Config.in" source "fs/iso9660/Config.in" source "fs/jffs2/Config.in"
fs/genimage/Config.in new file +20 -0
@@ -0,0 +1,20 @@ +config BR2_TARGET_ROOTFS_GENIMAGE + bool "full system image using genimage" + help + Generate a full system image using the genimage tool + and a user-provided configuration file. The image generated + will contain a partition table and will be ready to be copied + onto storage media, such as MMC, NAND or NOR devices. + + Keep in mind that you probably require to enable a rootfs + filesystem image, according to the genimage config file that you + provide. + +if BR2_TARGET_ROOTFS_GENIMAGE + +config BR2_TARGET_ROOTFS_GENIMAGE_CFG + string "genimage config file" + help + Genimage user configuration file. + +endif # BR2_TARGET_ROOTFS_GENIMAGE
fs/genimage/genimage.mk new file +21 -0
@@ -0,0 +1,21 @@ +################################################################################ +# +# Generate a system image using genimage +# +################################################################################ + +ROOTFS_GENIMAGE_DEPENDENCIES = host-genimage + +GENIMAGE_TMP="${BUILD_DIR}/genimage.tmp" + +define ROOTFS_GENIMAGE_CMD + $(RM) -rf ${GENIMAGE_TMP} && \ + $(HOST_DIR)/usr/bin/genimage \ + --rootpath ${TARGET_DIR} \ + --tmppath ${GENIMAGE_TMP} \ + --inputpath ${BINARIES_DIR} \ + --outputpath ${BINARIES_DIR} \ + --config ${BR2_TARGET_ROOTFS_GENIMAGE_CFG} +endef + +$(eval $(call ROOTFS_TARGET,genimage))
Signature · 1 line
2.7.0
PATCH 1/15 fs: add genimage infra
Hello,
Quoted 17 lines · Ezequiel Garcia
fs/genimage/genimage.mk new file +11
-0@@ -0,0 +1,21 @@ +################################################################################ +# +# Generate a system image using genimage +# +################################################################################ + +ROOTFS_GENIMAGE_DEPENDENCIES = host-genimage + +GENIMAGE_TMP="${BUILD_DIR}/genimage.tmp" + +define ROOTFS_GENIMAGE_CMD
fs/genimage/genimage.mk line 21
Quoted 10 lines
fs/genimage/genimage.mk new file +10
-0+ $(RM) -rf ${GENIMAGE_TMP} && \ + $(HOST_DIR)/usr/bin/genimage \ + --rootpath ${TARGET_DIR} \ + --tmppath ${GENIMAGE_TMP} \ + --inputpath ${BINARIES_DIR} \ + --outputpath ${BINARIES_DIR} \ + --config ${BR2_TARGET_ROOTFS_GENIMAGE_CFG} +endef + +$(eval $(call ROOTFS_TARGET,genimage))
A genimage.cfg file typically references some filesystem images like ext2/3/4 images. But I don't see anything in your implementation that ensures that the filesystem images that are used by the genimage.cfg file are produced *before* the genimage image is created. Am I missing something ?
Also, I think the infra should probably handle the dosfstools/mtools dependency that we need for many platforms to build a small FAT filesystem. So maybe a sub-option like BR2_TARGET_ROOTFS_GENIMAGE_BUILDS_FATFS or something like that, that would just select the appropriate packages.
Best regards,
Thomas
Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons Embedded Linux, Kernel and Android engineering http://free-electrons.com
PATCH 1/15 fs: add genimage infra
In reply to Ezequiel GarciaQuoted 7 lines · Ezequiel Garcia
Currently, all the boards using genimage are using the same command incantation. Therefore, let's introduce a new filesystem infra to factorize them and allow easier genimage setup.
This commit adds a new genimage infra, by calling genimage with a user-provided config file. The user is still responsible of enabling the apropriate rootfs filesystem images.
And for enabling dosfstools/mtools (as observed by Thomas).
Quoted 15 lines
Signed-off-by Ezequiel Garcia <[email protected]>--- fs/Config.in | 1 + fs/genimage/Config.in | 20 ++++++++++++++++++++ fs/genimage/genimage.mk | 21 +++++++++++++++++++++ 3 files changed, 42 insertions(+)create mode 100644
fs/genimage/Config.in
create mode 100644fs/genimage/genimage.mkfs/Config.in +0
-0
fs/Config.in source "fs/cloop/Config.in" · line 8
Quoted 4 lines
fs/Config.in +1
-0@@ -5,6 +5,7 @@ source "fs/cloop/Config.in" source "fs/cpio/Config.in" source "fs/cramfs/Config.in" source "fs/ext2/Config.in" +source "fs/genimage/Config.in"
I think this shouldn't be done alphabetically, but really at the end.
Quoted 10 lines
fs/Config.in +0
-0source "fs/initramfs/Config.in" source "fs/iso9660/Config.in" source "fs/jffs2/Config.in"fs/genimage/Config.in new file +1
-0@@ -0,0 +1,20 @@ +config BR2_TARGET_ROOTFS_GENIMAGE
fs/genimage/Config.in line 11
Quoted 10 lines
fs/genimage/Config.in new file +10
-0+ bool "full system image using genimage" + help + Generate a full system image using the genimage tool + and a user-provided configuration file. The image generated + will contain a partition table and will be ready to be copied + onto storage media, such as MMC, NAND or NOR devices. + + Keep in mind that you probably require to enable a rootfs + filesystem image, according to the genimage config file that you + provide.
And to select mtools/dosfstools. Thomas proposed to add an option for that.
For me, either an explicit genimage option or just adding the help text for it is OK.
Quoted 15 lines
fs/genimage/Config.in new file +9
-0+ +if BR2_TARGET_ROOTFS_GENIMAGE + +config BR2_TARGET_ROOTFS_GENIMAGE_CFG + string "genimage config file" + help + Genimage user configuration file. + +endif # BR2_TARGET_ROOTFS_GENIMAGEfs/genimage/genimage.mk new file +0
-0
fs/genimage/genimage.mk line 9
Quoted 9 lines
fs/genimage/genimage.mk new file +9
-0@@ -0,0 +1,21 @@ +################################################################################ +# +# Generate a system image using genimage +# +################################################################################ + +ROOTFS_GENIMAGE_DEPENDENCIES = host-genimage + +GENIMAGE_TMP="${BUILD_DIR}/genimage.tmp"
Variable name should be ROOTFS_GENIMAGE_TMP
fs/genimage/genimage.mk line 12
Quoted 3 lines
fs/genimage/genimage.mk new file +3
-0+ +define ROOTFS_GENIMAGE_CMD + $(RM) -rf ${GENIMAGE_TMP} && \
&& is not needed, treat it as two separate commands.
-f is not needed, it is already in $(RM).
All variables should use $(), not ${} (below as well).fs/genimage/genimage.mk line 13
Quoted 1 line
fs/genimage/genimage.mk new file +1
-0+ $(HOST_DIR)/usr/bin/genimage \
We don't generally align \ (annoying whitespace changes when you add a line).
fs/genimage/genimage.mk line 21
Quoted 8 lines
fs/genimage/genimage.mk new file +8
-0+ --rootpath ${TARGET_DIR} \ + --tmppath ${GENIMAGE_TMP} \ + --inputpath ${BINARIES_DIR} \ + --outputpath ${BINARIES_DIR} \ + --config ${BR2_TARGET_ROOTFS_GENIMAGE_CFG} +endef + +$(eval $(call ROOTFS_TARGET,genimage))
I think that, like for initramfs, the infra has little to offer here. And it
is in fact in the way, because (as observed by Thomas) you'll want to add
rootfs-genimage: $(TARGETS_ROOTFS)
which leads to a circular dependency.
So to make sure that it happens in the right order, I think you need something
like:
rootfs-genimage: $(TARGETS_ROOTFS) $(ROOTFS_GENIMAGE_DEPENDENCIES)
$(RM) -r $(ROOTFS_GENIMAGE_TMP) $(HOST_DIR)/usr/bin/genimage \ ...
ifeq ($(BR2_TARGET_ROOTFS_GENIMAGE),y)
target-post-image: rootfs-genimage
# Make sure the genimage dependencies appear in graph-depends show-targets:
@echo $(ROOTFS_GENIMAGE_DEPENDENCIES)
ifeq ($(wildcard $(BR2_TARGET_ROOTFS_GENIMAGE_CFG),)) $(error $(BR2_TARGET_ROOTFS_GENIMAGE_CFG) does not exist)
endif
However, I'm afraid that we're moving a bit too fast after all. There are
several open issues still:
- Do post-image scripts come before or after genimage?
- What with the dosfstools/mtools dependency?
- Should we support genimage.cfg files that are generated from a post-image script?
- Should we support several genimage.cfg files, producing several images (e.g. a NAND and a SD image)?
So, the current approach works well for the bundled defconfigs, but for real
use cases I think it's a bit too limited to be practical after all.
Therefore, at least as a first step, I guess it's better to just move the
script to a common place, e.g. to package/genimage/post-image.sh. Let it take a single argument for the genimage.cfg file, and add some documentation to the manual.
Regards,
Arnout
Signature · 6 lines
Arnout Vandecappelle arnout at mind be Senior Embedded Software Architect +32-16-286500 Essensium/Mind http://www.mind.be G.Geenslaan 9, 3001 Leuven, Belgium BE 872 984 063 RPR Leuven LinkedIn profile: http://www.linkedin.com/in/arnoutvandecappelle GPG fingerprint: 7493 020B C7E3 8618 8DEC 222C 82EB F404 F9AC 0DDF
PATCH 1/15 fs: add genimage infra
Hello,
Quoted 15 lines · Arnout Vandecappelle
I think that, like for initramfs, the infra has little to offer here. And it
is in fact in the way, because (as observed by Thomas) you'll want to addrootfs-genimage: $(TARGETS_ROOTFS)
which leads to a circular dependency.
So to make sure that it happens in the right order, I think you need something
like:rootfs-genimage: $(TARGETS_ROOTFS) $(ROOTFS_GENIMAGE_DEPENDENCIES)
$(RM) -r $(ROOTFS_GENIMAGE_TMP) $(HOST_DIR)/usr/bin/genimage \ ...
Quoted 7 lines
ifeq ($(BR2_TARGET_ROOTFS_GENIMAGE),y)
target-post-image: rootfs-genimage
# Make sure the genimage dependencies appear in graph-depends show-targets:
@echo $(ROOTFS_GENIMAGE_DEPENDENCIES)
But then is it really something that belongs to fs/ ? It really isn't a filesystem.
Quoted 11 lines
However, I'm afraid that we're moving a bit too fast after all. There are
several open issues still:- Do post-image scripts come before or after genimage?
- What with the dosfstools/mtools dependency?
- Should we support genimage.cfg files that are generated from a post-image script?
- Should we support several genimage.cfg files, producing several images (e.g. a NAND and a SD image)?So, the current approach works well for the bundled defconfigs, but for real
use cases I think it's a bit too limited to be practical after all.
Do we need to support all real use cases? I think we should support the common use cases, and the more complicated use cases can be handled via a special post-image script. That's really the general philosophy of Buildroot IMO: handle the most common cases nicely, and leave enough extension scripts/hooks to allow people to plug their scripts to handle the more complicated/specific cases.
Thanks,
Thomas
Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons Embedded Linux, Kernel and Android engineering http://free-electrons.com
PATCH 1/15 fs: add genimage infra
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
"Thomas" == Thomas Petazzoni <[email protected]> writes:
Hi,
Quoted 6 lines
Quoted 3 lines
# Make sure the genimage dependencies appear in graph-depends show-targets:
@echo $(ROOTFS_GENIMAGE_DEPENDENCIES)But then is it really something that belongs to
fs/? It really isn't a filesystem.
No, it is closer to the post-image script. Where do you suggest to move it? system/?
Quoted 12 lines
Quoted 11 lines
However, I'm afraid that we're moving a bit too fast after all. There are several open issues still:
- Do post-image scripts come before or after genimage?
- What with the dosfstools/mtools dependency?
- Should we support genimage.cfg files that are generated from a post-image script?
- Should we support several genimage.cfg files, producing several images (e.g. a NAND and a SD image)?So, the current approach works well for the bundled defconfigs, but for real use cases I think it's a bit too limited to be practical after all.
Quoted 6 lines
Do we need to support all real use cases? I think we should support the common use cases, and the more complicated use cases can be handled via a special post-image script. That's really the general philosophy of Buildroot IMO: handle the most common cases nicely, and leave enough extension
scripts/hooksto allow people to plug their scripts to handle the more complicated/specific cases.
Agreed, but it is good to think about the questions Arnout listed to think about what is really the common use case.
The definition of the post-image script was to run something at the very end, so I think we should do genimage before post-image (even though I could imagine use cases for the opposite as well).
For the dosfstools/mtools dependencies I think a simple sub option pulling them in is most sensible.
Supporting multiple genimage.cfg files (like we do for device_tables / post-build / post-image, ..) IMHO makes sense and looks simple to do.
Signature · 2 lines
Venlig hilsen, Peter Korsgaard
PATCH 1/15 fs: add genimage infra
Quoted 34 lines · Peter Korsgaard
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
"Thomas" == Thomas Petazzoni <[email protected]> writes:
Hi,
Quoted 6 lines
Quoted 3 lines
# Make sure the genimage dependencies appear in graph-depends show-targets:
@echo $(ROOTFS_GENIMAGE_DEPENDENCIES)But then is it really something that belongs to
fs/? It really isn't a filesystem.No, it is closer to the post-image script. Where do you suggest to move it? system/?
Quoted 12 lines
Quoted 11 lines
However, I'm afraid that we're moving a bit too fast after all. There are several open issues still:
- Do post-image scripts come before or after genimage?
- What with the dosfstools/mtools dependency?
- Should we support genimage.cfg files that are generated from a post-image script?
- Should we support several genimage.cfg files, producing several images (e.g. a NAND and a SD image)?So, the current approach works well for the bundled defconfigs, but for real use cases I think it's a bit too limited to be practical after all.
Quoted 6 lines
Do we need to support all real use cases? I think we should support the common use cases, and the more complicated use cases can be handled via a special post-image script. That's really the general philosophy of Buildroot IMO: handle the most common cases nicely, and leave enough extension
scripts/hooksto allow people to plug their scripts to handle the more complicated/specific cases.
Quoted 6 lines
Agreed, but it is good to think about the questions Arnout listed to think about what is really the common use case.
The definition of the post-image script was to run something at the very end, so I think we should do genimage before post-image (even though I could imagine use cases for the opposite as well).
Yes, so eventually we'll have a post-rootfs script...
Quoted 6 lines
For the dosfstools/mtools dependencies I think a simple sub option pulling them in is most sensible.
Supporting multiple genimage.cfg files (like we do for
device_tables/ post-build / post-image, ..) IMHO makes sense and looks simple to do.
Well, compared to the really simple solution that Ezequiel has now, I think
the code will look quite a bit more complicated when there are multiple genimage.cfg files.
Oh, and one more question: should we somehow make sure that the images
generated by the different scripts don't have the same name?
Regards,
Arnout
Signature · 6 lines
Arnout Vandecappelle arnout at mind be Senior Embedded Software Architect +32-16-286500 Essensium/Mind http://www.mind.be G.Geenslaan 9, 3001 Leuven, Belgium BE 872 984 063 RPR Leuven LinkedIn profile: http://www.linkedin.com/in/arnoutvandecappelle GPG fingerprint: 7493 020B C7E3 8618 8DEC 222C 82EB F404 F9AC 0DDF
PATCH 1/15 fs: add genimage infra
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
"Arnout" == Arnout Vandecappelle <[email protected]> writes:
Hi,
Quoted 7 lines · Peter Korsgaard
Quoted 4 lines
The definition of the post-image script was to run something at the very end, so I think we should do genimage before post-image (even though I could imagine use cases for the opposite as well).
Yes, so eventually we'll have a post-rootfs script...
Possibly, yes ;)
Quoted 9 lines
Quoted 5 lines
For the dosfstools/mtools dependencies I think a simple sub option pulling them in is most sensible.
Supporting multiple genimage.cfg files (like we do for
device_tables/ post-build / post-image, ..) IMHO makes sense and looks simple to do.Well, compared to the really simple solution that Ezequiel has now, I
think the code will look quite a bit more complicated when there are multiple genimage.cfg files.
Wouldn't it basically just sticking the logic in a loop over the words in BR2_TARGET_ROOTFS_GENIMAGE_CFG?
Quoted 2 lines
Oh, and one more question: should we somehow make sure that the
images generated by the different scripts don't have the same name?
No, I don't think we should do any parsing/verification of the .cfg files. If the user specifies files that aren't built or overwrites already existing files then they are themselves to blame.
Signature · 2 lines
Venlig hilsen, Peter Korsgaard
PATCH 1/15 fs: add genimage infra
All,
On 2016-04-14 23:37 +0200, Peter Korsgaard spake thusly:
Quoted 11 lines
Quoted 8 lines
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
"Arnout" == Arnout Vandecappelle <[email protected]> writes:
Quoted 2 lines · Peter Korsgaard
Supporting multiple genimage.cfg files (like we do for
device_tables/ post-build / post-image, ..) IMHO makes sense and looks simple to do.Well, compared to the really simple solution that Ezequiel has now, I
think the code will look quite a bit more complicated when there are multiple genimage.cfg files.Wouldn't it basically just sticking the logic in a loop over the words in
BR2_TARGET_ROOTFS_GENIMAGE_CFG?
It is already possible and perfectly legit to declare more than one image in a genimage config file, as far as I can see.
Regards,
Yann E. MORIN.
Signature · 6 lines
.-----------------.--------------------.------------------.--------------------. | Yann E. MORIN | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: | | +33 662 376 056 | Software Designer | \ / CAMPAIGN | ___ | | +33 223 225 172 `------------.-------: X AGAINST | \e/ There is no | | http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL | v conspiracy. | '------------------------------^-------^------------------^--------------------'
PATCH 1/15 fs: add genimage infra
Quoted 7 lines
Quoted 4 lines
Quoted 1 line
Quoted 1 line
Quoted 1 line
"Yann" == Yann E MORIN <[email protected]> writes:
Wouldn't it basically just sticking the logic in a loop over the words in
BR2_TARGET_ROOTFS_GENIMAGE_CFG?It is already possible and perfectly legit to declare more than one image in a genimage config file, as far as I can see.
Ahh, so we can then just concatenate all files specified and pass to genimage - Nice!
Signature · 2 lines
Venlig hilsen, Peter Korsgaard
PATCH 1/15 fs: add genimage infra
In reply to Arnout VandecappelleHello,
Quoted 3 lines · Arnout Vandecappelle
Therefore, at least as a first step, I guess it's better to just move the
script to a common place, e.g. topackage/genimage/post-image.sh. Let it take a single argument for the genimage.cfg file, and add some documentation to the manual.
As an after-thought, this seems like a good idea. This is really a very simple and minimal change, and is easy to do.
Thomas
Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons Embedded Linux, Kernel and Android engineering http://free-electrons.com
PATCH 1/15 fs: add genimage infra
Quoted 11 lines · Thomas Petazzoni
Hello,
Quoted 3 lines · Arnout Vandecappelle
Therefore, at least as a first step, I guess it's better to just move the
script to a common place, e.g. topackage/genimage/post-image.sh. Let it take a single argument for the genimage.cfg file, and add some documentation to the manual.As an after-thought, this seems like a good idea. This is really a very simple and minimal change, and is easy to do.
I realize this is a simple step forward, but I'm wondering if we can sort out the open
questions around a proper genimage infra, and just go for the big solution instead.
Signature · 2 lines
Ezequiel Garc?a, VanguardiaSur www.vanguardiasur.com.ar
PATCH 1/15 fs: add genimage infra
In reply to Thomas PetazzoniQuoted 11 lines
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
"Thomas" == Thomas Petazzoni <[email protected]> writes:
Hello,
Quoted 3 lines · Arnout Vandecappelle
Therefore, at least as a first step, I guess it's better to just move the script to a common place, e.g. to
package/genimage/post-image.sh. Let it take a single argument for the genimage.cfg file, and add some documentation to the manual.As an after-thought, this seems like a good idea. This is really a very simple and minimal change, and is easy to do.
The only complication is that you cannot directly pass arguments to post-image scripts, you have to use BR2_ROOTFS_POST_SCRIPT_ARGS (and it gets used for all scripts).
Signature · 1 line
Bye, Peter Korsgaard
PATCH 1/15 fs: add genimage infra
Quoted 9 lines · Peter Korsgaard
Quoted 8 lines
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
"Thomas" == Thomas Petazzoni <[email protected]> writes:
Hello,
Quoted 3 lines · Arnout Vandecappelle
Therefore, at least as a first step, I guess it's better to just move the script to a common place, e.g. to
package/genimage/post-image.sh. Let it take a single argument for the genimage.cfg file, and add some documentation to the manual.
Quoted 6 lines
Quoted 2 lines
As an after-thought, this seems like a good idea. This is really a very simple and minimal change, and is easy to do.
The only complication is that you cannot directly pass arguments to post-image scripts, you have to use
BR2_ROOTFS_POST_SCRIPT_ARGS(and it gets used for all scripts).
I really don't think that this is a limitation. Especially if you don't pass
the file, but the directory as the argument; that would be potentially useful for other post-image scripts as well.
So I tend to prefer the simple common-script-in-package/genimage solution.
That said, if Ezequiel posts a patch that takes into account all my concerns,
I'll be happy to Ack it.
Regards,
Arnout
Signature · 6 lines
Arnout Vandecappelle arnout at mind be Senior Embedded Software Architect +32-16-286500 Essensium/Mind http://www.mind.be G.Geenslaan 9, 3001 Leuven, Belgium BE 872 984 063 RPR Leuven LinkedIn profile: http://www.linkedin.com/in/arnoutvandecappelle GPG fingerprint: 7493 020B C7E3 8618 8DEC 222C 82EB F404 F9AC 0DDF
PATCH 2/15 board/minnowboard-max: Leverage the new genimage infra
In reply to Ezequiel GarciaLet's rework the board and config files to use the recently added genimage infra, which generates the SD card image directly.
--- board/minnowboard-max/genimage.cfg | 34 +++++++++++++++++++++++++++++++++ board/minnowboard-max/readme.txt | 39 ++++++++++++-------------------------- configs/minnowboard_max_defconfig | 8 ++++++++ 3 files changed, 54 insertions(+), 27 deletions(-) create mode 100644 board/minnowboard-max/genimage.cfg
board/minnowboard-max/genimage.cfg new file +34 -0
@@ -0,0 +1,34 @@ +# Create an image of the efi partition +image efi-part.vfat { + vfat { + file startup.nsh { + image = "efi-part/startup.nsh" + } + file EFI { + image = "efi-part/EFI" + } + file bzImage { + image = "bzImage" + } + } + size=10M +} + +# Create the sdcard image, pulling in +# * the image created by buildroot +# * the efi-partition created above +image sdcard.img { + hdimage { + } + + partition boot { + partition-type = 0xEF + image = "efi-part.vfat" + } + + partition rootfs { + partition-type = 0x83 + image = "rootfs.ext4" + size = 512M + } +}
board/minnowboard-max/readme.txt +12 -27
@@ -1,40 +1,25 @@ -Prepare the SD card for the Minnow Board MAX +How to get started with the Minnow Board MAX ============================================ - 1. Partition the SD card with a GPT partition table +1. Build - sudo cgdisk /dev/mmcblk0 + Apply the defconfig: - Create two partitions: + $ make minnowboard_max_defconfig - a) First partition of a few dozens of megabytes, which will be - used to store the bootloader and the kernel image. Type must - be EF00 (EFI partition). + Add any additional packages required and build: - b) Second partition of any size, which will be used to store the - root filesystem. Type must be 8300 (Linux filesystem) + $ make - 2. Prepare the boot partition +2. Write the SD card - We will format it, mount it, copy the EFI data generated by - Buildroot, and the kernel image. + The build process will create a SD card image in output/images. + Write the image to an mSD card, insert into the Minnowboard MAX + and power the board on. - sudo mkfs.vfat -F 32 -n boot /dev/mmcblk0p1 - sudo mount /dev/mmcblk0p1 /mnt - sudo cp -a output/images/efi-part/* /mnt/ - sudo cp output/images/bzImage /mnt/ - sudo umount /mnt + $ dd if=output/images/sdcard.img of=/dev/mmcblk0; sync - 3. Prepare the root partition - - We will format it, mount it, and extract the root filesystem. - - sudo mkfs.ext4 -L root /dev/mmcblk0p2 - sudo mount /dev/mmcblk0p2 /mnt - sudo tar -C /mnt -xf output/images/rootfs.tar - sudo umount /mnt - - 4. Enjoy +3. Enjoy Additional information about this board can be found at http://www.minnowboard.org/ or http://wiki.minnowboard.org/MinnowBoard_MAX
configs/minnowboard_max_defconfig +8 -0
@@ -8,6 +8,7 @@ BR2_ROOTFS_POST_BUILD_SCRIPT="board/minnowboard-max/post-build.sh" # Linux headers same as kernel, a 4.4 series BR2_PACKAGE_HOST_LINUX_HEADERS_CUSTOM_4_4=y +BR2_PACKAGE_HOST_DOSFSTOOLS=y # Needed for ethernet BR2_PACKAGE_LINUX_FIRMWARE=y
@@ -23,3 +24,10 @@ BR2_LINUX_KERNEL_CUSTOM_CONFIG_FILE="board/minnowboard-max/linux.config" # Bootloader BR2_TARGET_GRUB2=y BR2_TARGET_GRUB2_X86_64_EFI=y + +# Filesystem image +BR2_TARGET_ROOTFS_EXT2=y +BR2_TARGET_ROOTFS_EXT2_4=y +BR2_TARGET_ROOTFS_GENIMAGE=y +BR2_TARGET_ROOTFS_GENIMAGE_CFG="board/minnowboard-max/genimage.cfg" +# BR2_TARGET_ROOTFS_TAR is not set
Signature · 1 line
2.7.0
PATCH 3/15 board/olimex_a20_olinuxino: Leverage the new genimage infra
In reply to Ezequiel GarciaLet's rework the board and config files to use the recently added genimage infra, which generates the SD card image directly.
--- board/olimex/a20_olinuxino/post-image.sh | 16 ---------------- configs/olimex_a20_olinuxino_lime2_defconfig | 2 -- configs/olimex_a20_olinuxino_lime_defconfig | 4 ++-- configs/olimex_a20_olinuxino_lime_mali_defconfig | 4 ++-- configs/olimex_a20_olinuxino_micro_defconfig | 4 ++-- 5 files changed, 6 insertions(+), 24 deletions(-) delete mode 100755 board/olimex/a20_olinuxino/post-image.sh
board/olimex/a20_olinuxino/post-image.sh deleted +0 -16
@@ -1,16 +0,0 @@ -#!/bin/sh - -BOARD_DIR="$(dirname $0)" -GENIMAGE_CFG="${BOARD_DIR}/genimage.cfg" -GENIMAGE_TMP="${BUILD_DIR}/genimage.tmp" - -rm -rf "${GENIMAGE_TMP}" - -genimage \ - --rootpath "${TARGET_DIR}" \ - --tmppath "${GENIMAGE_TMP}" \ - --inputpath "${BINARIES_DIR}" \ - --outputpath "${BINARIES_DIR}" \ - --config "${GENIMAGE_CFG}" - -exit $?
configs/olimex_a20_olinuxino_lime2_defconfig +0 -2
@@ -7,7 +7,6 @@ BR2_TARGET_GENERIC_HOSTNAME="a20-olinuxino" BR2_TARGET_GENERIC_ISSUE="Welcome to OLinuXino!" BR2_TARGET_GENERIC_GETTY_PORT="ttyS0" BR2_ROOTFS_POST_BUILD_SCRIPT="board/olimex/a20_olinuxino/post-build.sh" -BR2_ROOTFS_POST_IMAGE_SCRIPT="board/olimex/a20_olinuxino/post-image.sh" BR2_ROOTFS_POST_SCRIPT_ARGS="board/olimex/a20_olinuxino/boot.cmd $(TARGET_DIR)/boot" BR2_LINUX_KERNEL=y BR2_LINUX_KERNEL_CUSTOM_VERSION=y
@@ -28,5 +27,4 @@ BR2_TARGET_UBOOT_CUSTOM_VERSION=y BR2_TARGET_UBOOT_CUSTOM_VERSION_VALUE="2015.01" BR2_TARGET_UBOOT_SPL=y BR2_TARGET_UBOOT_SPL_NAME="u-boot-sunxi-with-spl.bin" -BR2_PACKAGE_HOST_GENIMAGE=y BR2_PACKAGE_HOST_UBOOT_TOOLS=y
configs/olimex_a20_olinuxino_lime_defconfig +2 -2
@@ -12,7 +12,6 @@ BR2_TARGET_GENERIC_ISSUE="Welcome to OLinuXino!" BR2_TARGET_GENERIC_GETTY=y BR2_TARGET_GENERIC_GETTY_PORT="ttyS0" BR2_ROOTFS_POST_BUILD_SCRIPT="board/olimex/a20_olinuxino/post-build.sh" -BR2_ROOTFS_POST_IMAGE_SCRIPT="board/olimex/a20_olinuxino/post-image.sh" BR2_ROOTFS_POST_SCRIPT_ARGS="board/olimex/a20_olinuxino/boot.cmd $(TARGET_DIR)/boot" # Kernel
@@ -28,6 +27,8 @@ BR2_LINUX_KERNEL_INSTALL_TARGET=y # Filesystem BR2_TARGET_ROOTFS_EXT2=y BR2_TARGET_ROOTFS_EXT2_4=y +BR2_TARGET_ROOTFS_GENIMAGE=y +BR2_TARGET_ROOTFS_GENIMAGE_CFG="board/olimex/a20_olinuxino/genimage.cfg" # BR2_TARGET_ROOTFS_TAR is not set # Bootloaders
@@ -41,5 +42,4 @@ BR2_TARGET_UBOOT_SPL=y BR2_TARGET_UBOOT_SPL_NAME="u-boot-sunxi-with-spl.bin" # Additional tools -BR2_PACKAGE_HOST_GENIMAGE=y BR2_PACKAGE_HOST_UBOOT_TOOLS=y
configs/olimex_a20_olinuxino_lime_mali_defconfig +2 -2
@@ -12,7 +12,6 @@ BR2_TARGET_GENERIC_ISSUE="Welcome to OLinuXino!" BR2_TARGET_GENERIC_GETTY=y BR2_TARGET_GENERIC_GETTY_PORT="ttyS0" BR2_ROOTFS_POST_BUILD_SCRIPT="board/olimex/a20_olinuxino/post-build.sh" -BR2_ROOTFS_POST_IMAGE_SCRIPT="board/olimex/a20_olinuxino/post-image.sh" BR2_ROOTFS_POST_SCRIPT_ARGS="board/olimex/a20_olinuxino/boot-mali.cmd $(TARGET_DIR)/boot" # Kernel
@@ -33,6 +32,8 @@ BR2_PACKAGE_SUNXI_MALI_DBG=y # Filesystem BR2_TARGET_ROOTFS_EXT2=y BR2_TARGET_ROOTFS_EXT2_4=y +BR2_TARGET_ROOTFS_GENIMAGE=y +BR2_TARGET_ROOTFS_GENIMAGE_CFG="board/olimex/a20_olinuxino/genimage.cfg" # BR2_TARGET_ROOTFS_TAR is not set # Bootloaders
@@ -45,5 +46,4 @@ BR2_TARGET_UBOOT_SPL=y BR2_TARGET_UBOOT_SPL_NAME="u-boot-sunxi-with-spl.bin" # Additional tools -BR2_PACKAGE_HOST_GENIMAGE=y BR2_PACKAGE_HOST_UBOOT_TOOLS=y
configs/olimex_a20_olinuxino_micro_defconfig +2 -2
@@ -12,7 +12,6 @@ BR2_TARGET_GENERIC_ISSUE="Welcome to OLinuXino!" BR2_TARGET_GENERIC_GETTY_PORT="ttyS0" BR2_SYSTEM_DHCP="eth0" BR2_ROOTFS_POST_BUILD_SCRIPT="board/olimex/a20_olinuxino/post-build.sh" -BR2_ROOTFS_POST_IMAGE_SCRIPT="board/olimex/a20_olinuxino/post-image.sh" BR2_ROOTFS_POST_SCRIPT_ARGS="board/olimex/a20_olinuxino/boot.cmd $(TARGET_DIR)/boot" # Kernel
@@ -27,6 +26,8 @@ BR2_LINUX_KERNEL_INSTALL_TARGET=y # Filesystem BR2_TARGET_ROOTFS_EXT2=y BR2_TARGET_ROOTFS_EXT2_4=y +BR2_TARGET_ROOTFS_GENIMAGE=y +BR2_TARGET_ROOTFS_GENIMAGE_CFG="board/olimex/a20_olinuxino/genimage.cfg" # BR2_TARGET_ROOTFS_TAR is not set # Bootloaders
@@ -39,5 +40,4 @@ BR2_TARGET_UBOOT_SPL=y BR2_TARGET_UBOOT_SPL_NAME="u-boot-sunxi-with-spl.bin" # Additional tools -BR2_PACKAGE_HOST_GENIMAGE=y BR2_PACKAGE_HOST_UBOOT_TOOLS=y
Signature · 1 line
2.7.0
PATCH 4/15 board/wandboard: Leverage the new genimage infra
In reply to Ezequiel GarciaLet's rework the board and config files to use the recently added genimage infra, which generates the SD card image directly.
--- board/wandboard/post-image.sh | 16 ---------------- configs/wandboard_defconfig | 5 +++-- 2 files changed, 3 insertions(+), 18 deletions(-) delete mode 100755 board/wandboard/post-image.sh
board/wandboard/post-image.sh deleted +0 -16
@@ -1,16 +0,0 @@ -#!/usr/bin/env bash - -GENIMAGE_CFG="board/wandboard/genimage.cfg" -GENIMAGE_TMP="${BUILD_DIR}/genimage.tmp" - -rm -rf "${GENIMAGE_TMP}" - -genimage \ - --rootpath "${TARGET_DIR}" \ - --tmppath "${GENIMAGE_TMP}" \ - --inputpath "${BINARIES_DIR}" \ - --outputpath "${BINARIES_DIR}" \ - --config "${GENIMAGE_CFG}" - -RET=${?} -exit ${RET}
configs/wandboard_defconfig +3 -2
@@ -3,10 +3,11 @@ BR2_cortex_a9=y # Linux headers same as kernel, a 3.14 series BR2_PACKAGE_HOST_LINUX_HEADERS_CUSTOM_3_14=y BR2_TARGET_GENERIC_GETTY_PORT="ttymxc0" -BR2_PACKAGE_HOST_GENIMAGE=y -BR2_ROOTFS_POST_IMAGE_SCRIPT="board/wandboard/post-image.sh" +BR2_ROOTFS_POST_IMAGE_SCRIPT= BR2_TARGET_ROOTFS_EXT2=y BR2_TARGET_ROOTFS_EXT2_4=y +BR2_TARGET_ROOTFS_GENIMAGE=y +BR2_TARGET_ROOTFS_GENIMAGE_CFG="board/wandboard/genimage.cfg" BR2_TARGET_UBOOT=y BR2_TARGET_UBOOT_BUILD_SYSTEM_KCONFIG=y BR2_TARGET_UBOOT_USE_DEFCONFIG=y
Signature · 1 line
2.7.0
PATCH 4/15 board/wandboard: Leverage the new genimage infra
Hello,
configs/wandboard_defconfig BR2_cortex_a9=y · line 6
Quoted 2 lines · Ezequiel Garcia
configs/wandboard_defconfig +1
-1-BR2_ROOTFS_POST_IMAGE_SCRIPT="board/wandboard/post-image.sh" +BR2_ROOTFS_POST_IMAGE_SCRIPT=
Not good :)
Thomas
Signature · 3 lines
Thomas Petazzoni, CTO, Free Electrons Embedded Linux, Kernel and Android engineering http://free-electrons.com
PATCH 4/15 board/wandboard: Leverage the new genimage infra
Quoted 9 lines · Thomas Petazzoni
Hello,
configs/wandboard_defconfig BR2_cortex_a9=y · line 6
Quoted 2 lines · Ezequiel Garcia
configs/wandboard_defconfig +1
-1-BR2_ROOTFS_POST_IMAGE_SCRIPT="board/wandboard/post-image.sh" +BR2_ROOTFS_POST_IMAGE_SCRIPT=Not good :)
Ouch, bad commit fixup.
Signature · 2 lines
Ezequiel Garc?a, VanguardiaSur www.vanguardiasur.com.ar
PATCH 5/15 board/firefly: Leverage the new genimage infra
In reply to Ezequiel GarciaLet's rework the board and config files to use the recently added genimage infra, which generates the SD card image directly.
--- board/firefly/firefly-rk3288/post-build.sh | 4 ++++ board/firefly/firefly-rk3288/post-image.sh | 20 -------------------- configs/firefly_rk3288_defconfig | 4 ++-- configs/firefly_rk3288_demo_defconfig | 4 ++-- 4 files changed, 8 insertions(+), 24 deletions(-) delete mode 100755 board/firefly/firefly-rk3288/post-image.sh
board/firefly/firefly-rk3288/post-build.sh +4 -0
@@ -1,3 +1,7 @@ BOARD_DIR="$(dirname $0)" install -m 0644 -D $BOARD_DIR/extlinux.conf $TARGET_DIR/boot/extlinux/extlinux.conf + +$HOST_DIR/usr/bin/mkimage -n rk3288 -T rksd \ + -d $BINARIES_DIR/u-boot-spl-dtb.bin \ + $BINARIES_DIR/u-boot-spl-dtb.img
board/firefly/firefly-rk3288/post-image.sh deleted +0 -20
@@ -1,20 +0,0 @@ -#!/bin/sh - -MKIMAGE=$HOST_DIR/usr/bin/mkimage - -BOARD_DIR="$(dirname $0)" -GENIMAGE_CFG="${BOARD_DIR}/sd-image.cfg" -GENIMAGE_TMP="${BUILD_DIR}/genimage.tmp" - -$MKIMAGE -n rk3288 -T rksd -d $BINARIES_DIR/u-boot-spl-dtb.bin $BINARIES_DIR/u-boot-spl-dtb.img - -rm -rf "${GENIMAGE_TMP}" - -genimage \ - --rootpath "${TARGET_DIR}" \ - --tmppath "${GENIMAGE_TMP}" \ - --inputpath "${BINARIES_DIR}" \ - --outputpath "${BINARIES_DIR}" \ - --config "${GENIMAGE_CFG}" - -exit $?
configs/firefly_rk3288_defconfig +2 -2
@@ -5,7 +5,6 @@ BR2_PACKAGE_HOST_LINUX_HEADERS_CUSTOM_4_4=y BR2_TARGET_GENERIC_HOSTNAME="firefly-rk3288" BR2_TARGET_GENERIC_ISSUE="Welcome to FIREFLY RK3288!" BR2_ROOTFS_POST_BUILD_SCRIPT="board/firefly/firefly-rk3288/post-build.sh" -BR2_ROOTFS_POST_IMAGE_SCRIPT="board/firefly/firefly-rk3288/post-image.sh" BR2_LINUX_KERNEL=y BR2_LINUX_KERNEL_CUSTOM_GIT=y BR2_LINUX_KERNEL_CUSTOM_REPO_URL="https://github.com/mmind/linux-rockchip.git"
@@ -18,6 +17,8 @@ BR2_LINUX_KERNEL_INTREE_DTS_NAME="rk3288-firefly" BR2_LINUX_KERNEL_INSTALL_TARGET=y BR2_TARGET_ROOTFS_EXT2=y BR2_TARGET_ROOTFS_EXT2_4=y +BR2_TARGET_ROOTFS_GENIMAGE=y +BR2_TARGET_ROOTFS_GENIMAGE_CFG="board/firefly/firefly-rk3288/sd-image.cfg" # BR2_TARGET_ROOTFS_TAR is not set BR2_TARGET_UBOOT=y BR2_TARGET_UBOOT_BUILD_SYSTEM_KCONFIG=y
@@ -28,5 +29,4 @@ BR2_TARGET_UBOOT_NEEDS_DTC=y BR2_TARGET_UBOOT_FORMAT_DTB_IMG=y BR2_TARGET_UBOOT_SPL=y BR2_TARGET_UBOOT_SPL_NAME="spl/u-boot-spl-dtb.bin" -BR2_PACKAGE_HOST_GENIMAGE=y BR2_PACKAGE_HOST_UBOOT_TOOLS=y
configs/firefly_rk3288_demo_defconfig +2 -2
@@ -7,7 +7,6 @@ BR2_TOOLCHAIN_BUILDROOT_CXX=y BR2_TARGET_GENERIC_HOSTNAME="firefly-rk3288" BR2_TARGET_GENERIC_ISSUE="Welcome to FIREFLY RK3288!" BR2_ROOTFS_POST_BUILD_SCRIPT="board/firefly/firefly-rk3288/post-build.sh" -BR2_ROOTFS_POST_IMAGE_SCRIPT="board/firefly/firefly-rk3288/post-image.sh" BR2_LINUX_KERNEL=y BR2_LINUX_KERNEL_CUSTOM_GIT=y BR2_LINUX_KERNEL_CUSTOM_REPO_URL="https://github.com/mmind/linux-rockchip.git"
@@ -26,6 +25,8 @@ BR2_PACKAGE_QT5BASE_EGLFS=y BR2_PACKAGE_MALI_T76X=y BR2_TARGET_ROOTFS_EXT2=y BR2_TARGET_ROOTFS_EXT2_4=y +BR2_TARGET_ROOTFS_GENIMAGE=y +BR2_TARGET_ROOTFS_GENIMAGE_CFG="board/firefly/firefly-rk3288/sd-image.cfg" # BR2_TARGET_ROOTFS_TAR is not set BR2_TARGET_UBOOT=y BR2_TARGET_UBOOT_BUILD_SYSTEM_KCONFIG=y
@@ -36,5 +37,4 @@ BR2_TARGET_UBOOT_NEEDS_DTC=y BR2_TARGET_UBOOT_FORMAT_DTB_IMG=y BR2_TARGET_UBOOT_SPL=y BR2_TARGET_UBOOT_SPL_NAME="spl/u-boot-spl-dtb.bin" -BR2_PACKAGE_HOST_GENIMAGE=y BR2_PACKAGE_HOST_UBOOT_TOOLS=y
Signature · 1 line
2.7.0
PATCH 6/15 board/cubieboard2: Leverage the new genimage infra
In reply to Ezequiel GarciaLet's rework the board and config files to use the recently added genimage infra, which generates the SD card image directly.
While here, let's remove the tar'ed rootfs, which
is not used.
--- board/cubietech/cubieboard2/post-image.sh | 16 ---------------- configs/cubieboard2_defconfig | 5 +++-- 2 files changed, 3 insertions(+), 18 deletions(-) delete mode 100755 board/cubietech/cubieboard2/post-image.sh
board/cubietech/cubieboard2/post-image.sh deleted +0 -16
@@ -1,16 +0,0 @@ -#!/bin/sh - -BOARD_DIR="$(dirname $0)" -GENIMAGE_CFG="${BOARD_DIR}/genimage.cfg" -GENIMAGE_TMP="${BUILD_DIR}/genimage.tmp" - -rm -rf "${GENIMAGE_TMP}" - -genimage \ - --rootpath "${TARGET_DIR}" \ - --tmppath "${GENIMAGE_TMP}" \ - --inputpath "${BINARIES_DIR}" \ - --outputpath "${BINARIES_DIR}" \ - --config "${GENIMAGE_CFG}" - -exit $?
configs/cubieboard2_defconfig +3 -2
@@ -7,7 +7,6 @@ BR2_TARGET_GENERIC_HOSTNAME="Cubieboard2" BR2_TARGET_GENERIC_ISSUE="Welcome to Cubieboard2!" BR2_TARGET_GENERIC_GETTY_PORT="ttyS0" BR2_ROOTFS_POST_BUILD_SCRIPT="board/cubietech/cubieboard2/post-build.sh" -BR2_ROOTFS_POST_IMAGE_SCRIPT="board/cubietech/cubieboard2/post-image.sh" BR2_LINUX_KERNEL=y BR2_LINUX_KERNEL_CUSTOM_VERSION=y BR2_LINUX_KERNEL_CUSTOM_VERSION_VALUE="4.3.3"
@@ -16,6 +15,9 @@ BR2_LINUX_KERNEL_DTS_SUPPORT=y BR2_LINUX_KERNEL_INTREE_DTS_NAME="sun7i-a20-cubieboard2" BR2_TARGET_ROOTFS_EXT2=y BR2_TARGET_ROOTFS_EXT2_4=y +BR2_TARGET_ROOTFS_GENIMAGE=y +BR2_TARGET_ROOTFS_GENIMAGE_CFG="board/cubietech/cubieboard2/genimage.cfg" +# BR2_TARGET_ROOTFS_TAR is not set BR2_TARGET_UBOOT=y BR2_TARGET_UBOOT_BUILD_SYSTEM_KCONFIG=y BR2_TARGET_UBOOT_CUSTOM_VERSION=y
@@ -25,6 +27,5 @@ BR2_TARGET_UBOOT_NEEDS_DTC=y BR2_TARGET_UBOOT_SPL=y BR2_TARGET_UBOOT_SPL_NAME="u-boot-sunxi-with-spl.bin" BR2_PACKAGE_HOST_DOSFSTOOLS=y -BR2_PACKAGE_HOST_GENIMAGE=y BR2_PACKAGE_HOST_MTOOLS=y BR2_PACKAGE_HOST_UBOOT_TOOLS=y
Signature · 1 line
2.7.0
PATCH 7/15 board/arietta-g25: Leverage the new genimage infra
In reply to Ezequiel GarciaLet's rework the board and config files to use the recently added genimage infra, which generates the SD card image directly.
--- board/acmesystems/arietta-g25/post-image.sh | 16 ---------------- configs/acmesystems_arietta_g25_128mb_defconfig | 4 ++-- configs/acmesystems_arietta_g25_256mb_defconfig | 4 ++-- 3 files changed, 4 insertions(+), 20 deletions(-) delete mode 100755 board/acmesystems/arietta-g25/post-image.sh
board/acmesystems/arietta-g25/post-image.sh deleted +0 -16
@@ -1,16 +0,0 @@ -#!/bin/sh - -BOARD_DIR="$(dirname $0)" -GENIMAGE_CFG="${BOARD_DIR}/genimage.cfg" -GENIMAGE_TMP="${BUILD_DIR}/genimage.tmp" - -rm -rf "${GENIMAGE_TMP}" - -genimage \ - --rootpath "${TARGET_DIR}" \ - --tmppath "${GENIMAGE_TMP}" \ - --inputpath "${BINARIES_DIR}" \ - --outputpath "${BINARIES_DIR}" \ - --config "${GENIMAGE_CFG}" - -exit $?
configs/acmesystems_arietta_g25_128mb_defconfig +2 -2
@@ -21,10 +21,10 @@ BR2_TARGET_AT91BOOTSTRAP3_CUSTOM_REPO_VERSION="cedbde4b36695b715f469f4872f47e5cc BR2_TARGET_AT91BOOTSTRAP3_DEFCONFIG="arietta-128m" # Image -BR2_ROOTFS_POST_IMAGE_SCRIPT="board/acmesystems/arietta-g25/post-image.sh" BR2_TARGET_ROOTFS_EXT2=y BR2_TARGET_ROOTFS_EXT2_4=y +BR2_TARGET_ROOTFS_GENIMAGE=y +BR2_TARGET_ROOTFS_GENIMAGE_CFG="board/acmesystems/arietta-g25/genimage.cfg" # BR2_TARGET_ROOTFS_TAR is not set -BR2_PACKAGE_HOST_GENIMAGE=y BR2_PACKAGE_HOST_DOSFSTOOLS=y BR2_PACKAGE_HOST_MTOOLS=y
configs/acmesystems_arietta_g25_256mb_defconfig +2 -2
@@ -21,10 +21,10 @@ BR2_TARGET_AT91BOOTSTRAP3_CUSTOM_REPO_VERSION="cedbde4b36695b715f469f4872f47e5cc BR2_TARGET_AT91BOOTSTRAP3_DEFCONFIG="arietta-256m" # Image -BR2_ROOTFS_POST_IMAGE_SCRIPT="board/acmesystems/arietta-g25/post-image.sh" BR2_TARGET_ROOTFS_EXT2=y BR2_TARGET_ROOTFS_EXT2_4=y +BR2_TARGET_ROOTFS_GENIMAGE=y +BR2_TARGET_ROOTFS_GENIMAGE_CFG="board/acmesystems/arietta-g25/genimage.cfg" # BR2_TARGET_ROOTFS_TAR is not set -BR2_PACKAGE_HOST_GENIMAGE=y BR2_PACKAGE_HOST_DOSFSTOOLS=y BR2_PACKAGE_HOST_MTOOLS=y
Signature · 1 line
2.7.0
PATCH 8/15 board/imx6ulevk: Leverage the new genimage infra
In reply to Ezequiel GarciaLet's rework the board and config files to use the recently added genimage infra, which generates the SD card image directly.
--- board/freescale/imx6ulevk/post-image.sh | 15 --------------- configs/freescale_imx6ulevk_defconfig | 4 ++-- 2 files changed, 2 insertions(+), 17 deletions(-) delete mode 100755 board/freescale/imx6ulevk/post-image.sh
board/freescale/imx6ulevk/post-image.sh deleted +0 -15
@@ -1,15 +0,0 @@ -#!/usr/bin/env bash - -GENIMAGE_CFG="board/freescale/imx6ulevk/genimage.cfg" -GENIMAGE_TMP="${BUILD_DIR}/genimage.tmp" - -rm -rf "${GENIMAGE_TMP}" - -genimage \ - --rootpath "${TARGET_DIR}" \ - --tmppath "${GENIMAGE_TMP}" \ - --inputpath "${BINARIES_DIR}" \ - --outputpath "${BINARIES_DIR}" \ - --config "${GENIMAGE_CFG}" - -exit $?
configs/freescale_imx6ulevk_defconfig +2 -2
@@ -27,9 +27,9 @@ BR2_TARGET_UBOOT_FORMAT_IMX=y # required tools to create the microSD image BR2_PACKAGE_HOST_DOSFSTOOLS=y -BR2_PACKAGE_HOST_GENIMAGE=y BR2_PACKAGE_HOST_MTOOLS=y # filesystem / image -BR2_ROOTFS_POST_IMAGE_SCRIPT="board/freescale/imx6ulevk/post-image.sh" BR2_TARGET_ROOTFS_EXT2=y +BR2_TARGET_ROOTFS_GENIMAGE=y +BR2_TARGET_ROOTFS_GENIMAGE_CFG="board/freescale/imx6ulevk/genimage.cfg"
Signature · 1 line
2.7.0
PATCH 9/15 board/galileo: Leverage the new genimage infra
In reply to Ezequiel GarciaLet's rework the board and config files to use the recently added genimage infra, which generates the SD card image directly.
--- board/intel/galileo/post-image.sh | 13 ------------- configs/galileo_defconfig | 4 ++-- 2 files changed, 2 insertions(+), 15 deletions(-) delete mode 100755 board/intel/galileo/post-image.sh
board/intel/galileo/post-image.sh deleted +0 -13
@@ -1,13 +0,0 @@ -#!/bin/sh -e - -GENIMAGE_CFG="board/intel/galileo/genimage.cfg" -GENIMAGE_TMP="${BUILD_DIR}/genimage.tmp" - -rm -rf "${GENIMAGE_TMP}" - -genimage \ - --rootpath "${TARGET_DIR}" \ - --tmppath "${GENIMAGE_TMP}" \ - --inputpath "${BINARIES_DIR}" \ - --outputpath "${BINARIES_DIR}" \ - --config "${GENIMAGE_CFG}"
configs/galileo_defconfig +2 -2
@@ -8,7 +8,6 @@ BR2_TARGET_GENERIC_GETTY_PORT="ttyS1" BR2_TARGET_GENERIC_GETTY_BAUDRATE_115200=y BR2_ROOTFS_OVERLAY="board/intel/galileo/rootfs_overlay" BR2_ROOTFS_POST_BUILD_SCRIPT="board/intel/galileo/post-build.sh" -BR2_ROOTFS_POST_IMAGE_SCRIPT="board/intel/galileo/post-image.sh" BR2_LINUX_KERNEL=y BR2_LINUX_KERNEL_CUSTOM_GIT=y BR2_LINUX_KERNEL_CUSTOM_REPO_URL="https://github.com/mdr78/Linux-x1000.git"
@@ -18,8 +17,9 @@ BR2_LINUX_KERNEL_CUSTOM_CONFIG_FILE="board/intel/galileo/linux-3.8.config" BR2_LINUX_KERNEL_INSTALL_TARGET=y BR2_TARGET_ROOTFS_EXT2=y BR2_TARGET_ROOTFS_EXT2_4=y +BR2_TARGET_ROOTFS_GENIMAGE=y +BR2_TARGET_ROOTFS_GENIMAGE_CFG="board/intel/galileo/genimage.cfg" BR2_TARGET_GRUB2=y BR2_TARGET_GRUB2_I386_EFI=y BR2_PACKAGE_HOST_DOSFSTOOLS=y -BR2_PACKAGE_HOST_GENIMAGE=y BR2_PACKAGE_HOST_MTOOLS=y
Signature · 1 line
2.7.0
PATCH 10/15 board/pandaboard: Leverage the new genimage infra
In reply to Ezequiel GarciaLet's rework the board and config files to use the recently added genimage infra, which generates the SD card image directly.
--- board/pandaboard/post-image.sh | 16 ---------------- configs/pandaboard_defconfig | 4 ++-- 2 files changed, 2 insertions(+), 18 deletions(-) delete mode 100755 board/pandaboard/post-image.sh
board/pandaboard/post-image.sh deleted +0 -16
@@ -1,16 +0,0 @@ -#!/bin/sh - -BOARD_DIR="$(dirname $0)" -GENIMAGE_CFG="${BOARD_DIR}/genimage.cfg" -GENIMAGE_TMP="${BUILD_DIR}/genimage.tmp" - -rm -rf "${GENIMAGE_TMP}" - -genimage \ - --rootpath "${TARGET_DIR}" \ - --tmppath "${GENIMAGE_TMP}" \ - --inputpath "${BINARIES_DIR}" \ - --outputpath "${BINARIES_DIR}" \ - --config "${GENIMAGE_CFG}" - -exit $?
configs/pandaboard_defconfig +2 -2
@@ -6,7 +6,6 @@ BR2_PACKAGE_HOST_LINUX_HEADERS_CUSTOM_4_5=y BR2_ROOTFS_DEVICE_CREATION_DYNAMIC_MDEV=y BR2_TARGET_GENERIC_GETTY_PORT="ttyO2" BR2_SYSTEM_DHCP="eth0" -BR2_ROOTFS_POST_IMAGE_SCRIPT="board/pandaboard/post-image.sh" BR2_LINUX_KERNEL=y BR2_LINUX_KERNEL_CUSTOM_VERSION=y BR2_LINUX_KERNEL_CUSTOM_VERSION_VALUE="4.5"
@@ -16,6 +15,8 @@ BR2_LINUX_KERNEL_INTREE_DTS_NAME="omap4-panda-es omap4-panda omap4-panda-a4" BR2_LINUX_KERNEL_INSTALL_TARGET=y BR2_TARGET_ROOTFS_EXT2=y BR2_TARGET_ROOTFS_EXT2_4=y +BR2_TARGET_ROOTFS_GENIMAGE=y +BR2_TARGET_ROOTFS_GENIMAGE_CFG="board/pandaboard/genimage.cfg" # BR2_TARGET_ROOTFS_TAR is not set BR2_TARGET_UBOOT=y BR2_TARGET_UBOOT_BUILD_SYSTEM_KCONFIG=y
@@ -26,5 +27,4 @@ BR2_TARGET_UBOOT_FORMAT_IMG=y BR2_TARGET_UBOOT_SPL=y BR2_TARGET_UBOOT_SPL_NAME="MLO" BR2_PACKAGE_HOST_DOSFSTOOLS=y -BR2_PACKAGE_HOST_GENIMAGE=y BR2_PACKAGE_HOST_MTOOLS=y
Signature · 1 line
2.7.0
PATCH 11/15 board/boundarydevices: Leverage the new genimage infra
In reply to Ezequiel GarciaLet's rework the board and config files to use the recently added genimage infra, which generates the SD card image directly.
--- board/boundarydevices/common/post-image.sh | 16 ---------------- configs/nitrogen6sx_defconfig | 4 ++-- configs/nitrogen6x_defconfig | 4 ++-- configs/nitrogen7_defconfig | 4 ++-- 4 files changed, 6 insertions(+), 22 deletions(-) delete mode 100755 board/boundarydevices/common/post-image.sh
board/boundarydevices/common/post-image.sh deleted +0 -16
@@ -1,16 +0,0 @@ -#!/bin/sh - -BOARD_DIR="$(dirname $0)" -GENIMAGE_CFG="${BOARD_DIR}/genimage.cfg" -GENIMAGE_TMP="${BUILD_DIR}/genimage.tmp" - -rm -rf "${GENIMAGE_TMP}" - -genimage \ - --rootpath "${TARGET_DIR}" \ - --tmppath "${GENIMAGE_TMP}" \ - --inputpath "${BINARIES_DIR}" \ - --outputpath "${BINARIES_DIR}" \ - --config "${GENIMAGE_CFG}" - -exit $?
configs/nitrogen6sx_defconfig +2 -2
@@ -6,13 +6,13 @@ BR2_cortex_a9=y BR2_TARGET_GENERIC_GETTY=y BR2_TARGET_GENERIC_GETTY_PORT="ttymxc0" BR2_ROOTFS_POST_BUILD_SCRIPT="board/boundarydevices/common/post-build.sh" -BR2_ROOTFS_POST_IMAGE_SCRIPT="board/boundarydevices/common/post-image.sh" -BR2_PACKAGE_HOST_GENIMAGE=y BR2_PACKAGE_HOST_UBOOT_TOOLS=y # filesystem BR2_TARGET_ROOTFS_EXT2=y BR2_TARGET_ROOTFS_EXT2_4=y +BR2_TARGET_ROOTFS_GENIMAGE=y +BR2_TARGET_ROOTFS_GENIMAGE_CFG="board/boundarydevices/common/genimage.cfg" # Linux headers same as kernel, a 3.14 series BR2_PACKAGE_HOST_LINUX_HEADERS_CUSTOM_3_14=y
configs/nitrogen6x_defconfig +2 -2
@@ -6,13 +6,13 @@ BR2_cortex_a9=y BR2_TARGET_GENERIC_GETTY=y BR2_TARGET_GENERIC_GETTY_PORT="ttymxc1" BR2_ROOTFS_POST_BUILD_SCRIPT="board/boundarydevices/common/post-build.sh" -BR2_ROOTFS_POST_IMAGE_SCRIPT="board/boundarydevices/common/post-image.sh" -BR2_PACKAGE_HOST_GENIMAGE=y BR2_PACKAGE_HOST_UBOOT_TOOLS=y # filesystem BR2_TARGET_ROOTFS_EXT2=y BR2_TARGET_ROOTFS_EXT2_4=y +BR2_TARGET_ROOTFS_GENIMAGE=y +BR2_TARGET_ROOTFS_GENIMAGE_CFG="board/boundarydevices/common/genimage.cfg" # Linux headers same as kernel, a 3.14 series BR2_PACKAGE_HOST_LINUX_HEADERS_CUSTOM_3_14=y
configs/nitrogen7_defconfig +2 -2
@@ -6,14 +6,14 @@ BR2_cortex_a7=y BR2_TARGET_GENERIC_GETTY=y BR2_TARGET_GENERIC_GETTY_PORT="ttymxc0" BR2_ROOTFS_POST_BUILD_SCRIPT="board/boundarydevices/common/post-build.sh" -BR2_ROOTFS_POST_IMAGE_SCRIPT="board/boundarydevices/common/post-image.sh" -BR2_PACKAGE_HOST_GENIMAGE=y BR2_PACKAGE_HOST_UBOOT_TOOLS=y # filesystem # BR2_TARGET_ROOTFS_TAR is not set BR2_TARGET_ROOTFS_EXT2=y BR2_TARGET_ROOTFS_EXT2_4=y +BR2_TARGET_ROOTFS_GENIMAGE=y +BR2_TARGET_ROOTFS_GENIMAGE_CFG="board/boundarydevices/common/genimage.cfg" # Linux headers same as kernel, a 3.14 series BR2_PACKAGE_HOST_LINUX_HEADERS_CUSTOM_3_14=y
Signature · 1 line
2.7.0
PATCH 12/15 board/imx233_olinuxino: Leverage the new genimage infra
In reply to Ezequiel GarciaLet's rework the board and config files to use the recently added genimage infra, which generates the SD card image directly.
--- board/olimex/imx233_olinuxino/post-image.sh | 14 -------------- configs/olimex_imx233_olinuxino_defconfig | 3 ++- 2 files changed, 2 insertions(+), 15 deletions(-)
board/olimex/imx233_olinuxino/post-image.sh +0 -14
@@ -1,20 +1,6 @@ #!/bin/sh -BOARD_DIR="$(dirname $0)" -BOARD_NAME="$(basename ${BOARD_DIR})" -GENIMAGE_CFG="${BOARD_DIR}/genimage-${BOARD_NAME}.cfg" -GENIMAGE_TMP="${BUILD_DIR}/genimage.tmp" - # Create symlink to "rename" kernel image ln -sf uImage.imx23-olinuxino ${BINARIES_DIR}/uImage -rm -rf "${GENIMAGE_TMP}" - -genimage \ - --rootpath "${TARGET_DIR}" \ - --tmppath "${GENIMAGE_TMP}" \ - --inputpath "${BINARIES_DIR}" \ - --outputpath "${BINARIES_DIR}" \ - --config "${GENIMAGE_CFG}" - exit $?
configs/olimex_imx233_olinuxino_defconfig +2 -1
@@ -30,6 +30,8 @@ BR2_PACKAGE_ZD1211_FIRMWARE=y # Filesystem BR2_TARGET_ROOTFS_EXT2=y +BR2_TARGET_ROOTFS_GENIMAGE=y +BR2_TARGET_ROOTFS_GENIMAGE_CFG="board/olimex/imx233_olinuxino/post-image.sh" # BR2_TARGET_ROOTFS_TAR is not set # U-Boot
@@ -42,7 +44,6 @@ BR2_TARGET_UBOOT_FORMAT_SD=y # To generate SD Image BR2_PACKAGE_HOST_DOSFSTOOLS=y -BR2_PACKAGE_HOST_GENIMAGE=y BR2_PACKAGE_HOST_MTOOLS=y BR2_ROOTFS_POST_IMAGE_SCRIPT="board/olimex/imx233_olinuxino/post-image.sh"
Signature · 1 line
2.7.0
PATCH 13/15 board/orangepipc: Leverage the new genimage infra
In reply to Ezequiel GarciaLet's rework the board and config files to use the recently added genimage infra, which generates the SD card image directly.
--- board/orangepi/orangepipc/post-build.sh | 5 +++++ board/orangepi/orangepipc/post-image.sh | 22 ---------------------- configs/orangepipc_defconfig | 4 ++-- 3 files changed, 7 insertions(+), 24 deletions(-) delete mode 100755 board/orangepi/orangepipc/post-image.sh
board/orangepi/orangepipc/post-build.sh +5 -0
@@ -9,3 +9,8 @@ BOOT_CMD_H=$BINARIES_DIR/boot.scr # U-Boot script $MKIMAGE -C none -A arm -T script -d $BOOT_CMD $BOOT_CMD_H + +# As we now use the Linux v4.5-RC1 kernel no orangepi-pc dtb exists yet. +# However the orangepi-plus dtb has not much content, only mmc0 and uart +# which are equal to the pc version of the board, so we use it here. +mv ${BINARIES_DIR}/sun8i-h3-orangepi-plus.dtb ${BINARIES_DIR}/sun8i-h3-orangepi-pc.dtb
board/orangepi/orangepipc/post-image.sh deleted +0 -22
@@ -1,22 +0,0 @@ -#!/bin/sh - -BOARD_DIR="$(dirname $0)" -GENIMAGE_CFG="${BOARD_DIR}/genimage.cfg" -GENIMAGE_TMP="${BUILD_DIR}/genimage.tmp" - -rm -rf "${GENIMAGE_TMP}" - -# As we now use the Linux v4.5-RC1 kernel no orangepi-pc dtb exists yet. -# However the orangepi-plus dtb has not much content, only mmc0 and uart -# which are equal to the pc version of the board, so we use it here. -mv ${BINARIES_DIR}/sun8i-h3-orangepi-plus.dtb ${BINARIES_DIR}/sun8i-h3-orangepi-pc.dtb - - -genimage \ - --rootpath "${TARGET_DIR}" \ - --tmppath "${GENIMAGE_TMP}" \ - --inputpath "${BINARIES_DIR}" \ - --outputpath "${BINARIES_DIR}" \ - --config "${GENIMAGE_CFG}" - -exit $?
configs/orangepipc_defconfig +2 -2
@@ -5,7 +5,6 @@ BR2_PACKAGE_HOST_LINUX_HEADERS_CUSTOM_4_5=y BR2_TARGET_GENERIC_HOSTNAME="OrangePi_PC" BR2_TARGET_GENERIC_ISSUE="Welcome to Buildroot for the Orange Pi PC" BR2_ROOTFS_POST_BUILD_SCRIPT="board/orangepi/orangepipc/post-build.sh" -BR2_ROOTFS_POST_IMAGE_SCRIPT="board/orangepi/orangepipc/post-image.sh" BR2_LINUX_KERNEL=y BR2_LINUX_KERNEL_CUSTOM_VERSION=y BR2_LINUX_KERNEL_CUSTOM_VERSION_VALUE="4.5"
@@ -14,6 +13,8 @@ BR2_LINUX_KERNEL_DTS_SUPPORT=y BR2_LINUX_KERNEL_INTREE_DTS_NAME="sun8i-h3-orangepi-plus" BR2_TARGET_ROOTFS_EXT2=y BR2_TARGET_ROOTFS_EXT2_4=y +BR2_TARGET_ROOTFS_GENIMAGE=y +BR2_TARGET_ROOTFS_GENIMAGE_CFG="board/orangepi/orangepipc/genimage.cfg" # BR2_TARGET_ROOTFS_TAR is not set BR2_TARGET_UBOOT=y BR2_TARGET_UBOOT_BUILD_SYSTEM_KCONFIG=y
@@ -24,6 +25,5 @@ BR2_TARGET_UBOOT_NEEDS_DTC=y BR2_TARGET_UBOOT_FORMAT_CUSTOM=y BR2_TARGET_UBOOT_FORMAT_CUSTOM_NAME="u-boot-sunxi-with-spl.bin" BR2_PACKAGE_HOST_DOSFSTOOLS=y -BR2_PACKAGE_HOST_GENIMAGE=y BR2_PACKAGE_HOST_MTOOLS=y BR2_PACKAGE_HOST_UBOOT_TOOLS=y
Signature · 1 line
2.7.0
PATCH 14/15 board/raspberry*: Leverage the new genimage infra
In reply to Ezequiel GarciaLet's rework the board and config files to use the recently added genimage infra, which generates the SD card image directly.
--- board/raspberrypi/post-build.sh | 8 ++++++++ board/raspberrypi/post-image.sh | 22 ---------------------- configs/raspberrypi2_defconfig | 5 +++-- configs/raspberrypi_defconfig | 5 +++-- 4 files changed, 14 insertions(+), 26 deletions(-) create mode 100755 board/raspberrypi/post-build.sh delete mode 100755 board/raspberrypi/post-image.sh
board/raspberrypi/post-build.sh new file +8 -0
@@ -0,0 +1,8 @@ +#!/bin/sh + +# Mark the kernel as DT-enabled +mkdir -p "${BINARIES_DIR}/kernel-marked" +${HOST_DIR}/usr/bin/mkknlimg "${BINARIES_DIR}/zImage" \ + "${BINARIES_DIR}/kernel-marked/zImage" + +exit $?
board/raspberrypi/post-image.sh deleted +0 -22
@@ -1,22 +0,0 @@ -#!/bin/sh - -BOARD_DIR="$(dirname $0)" -BOARD_NAME="$(basename ${BOARD_DIR})" -GENIMAGE_CFG="${BOARD_DIR}/genimage-${BOARD_NAME}.cfg" -GENIMAGE_TMP="${BUILD_DIR}/genimage.tmp" - -# Mark the kernel as DT-enabled -mkdir -p "${BINARIES_DIR}/kernel-marked" -${HOST_DIR}/usr/bin/mkknlimg "${BINARIES_DIR}/zImage" \ - "${BINARIES_DIR}/kernel-marked/zImage" - -rm -rf "${GENIMAGE_TMP}" - -genimage \ - --rootpath "${TARGET_DIR}" \ - --tmppath "${GENIMAGE_TMP}" \ - --inputpath "${BINARIES_DIR}" \ - --outputpath "${BINARIES_DIR}" \ - --config "${GENIMAGE_CFG}" - -exit $?
configs/raspberrypi2_defconfig +3 -2
@@ -25,11 +25,12 @@ BR2_PACKAGE_RPI_FIRMWARE=y # Required tools to create the SD image BR2_PACKAGE_HOST_DOSFSTOOLS=y -BR2_PACKAGE_HOST_GENIMAGE=y BR2_PACKAGE_HOST_MTOOLS=y # Filesystem / image BR2_TARGET_ROOTFS_EXT2=y BR2_TARGET_ROOTFS_EXT2_4=y +BR2_TARGET_ROOTFS_GENIMAGE=y +BR2_TARGET_ROOTFS_GENIMAGE_CFG="board/raspberrypi2/genimage-raspberrypi2.cfg" # BR2_TARGET_ROOTFS_TAR is not set -BR2_ROOTFS_POST_IMAGE_SCRIPT="board/raspberrypi2/post-image.sh" +BR2_ROOTFS_POST_BUILD_SCRIPT="board/raspberrypi2/post-build.sh"
configs/raspberrypi_defconfig +3 -2
@@ -24,11 +24,12 @@ BR2_PACKAGE_RPI_FIRMWARE=y # Required tools to create the SD image BR2_PACKAGE_HOST_DOSFSTOOLS=y -BR2_PACKAGE_HOST_GENIMAGE=y BR2_PACKAGE_HOST_MTOOLS=y # Filesystem / image BR2_TARGET_ROOTFS_EXT2=y BR2_TARGET_ROOTFS_EXT2_4=y +BR2_TARGET_ROOTFS_GENIMAGE=y +BR2_TARGET_ROOTFS_GENIMAGE_CFG="board/raspberrypi/genimage-raspberrypi.cfg" # BR2_TARGET_ROOTFS_TAR is not set -BR2_ROOTFS_POST_IMAGE_SCRIPT="board/raspberrypi/post-image.sh" +BR2_ROOTFS_POST_BUILD_SCRIPT="board/raspberrypi/post-build.sh"
Signature · 1 line
2.7.0
PATCH 15/15 board/via_imx6_vab820: Leverage the new genimage infra
In reply to Ezequiel GarciaLet's rework the board and config files to use the recently added genimage infra, which generates the SD card image directly.
--- configs/via_imx6_vab820_defconfig | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
configs/via_imx6_vab820_defconfig +2 -2
@@ -28,7 +28,7 @@ BR2_TARGET_UBOOT_FORMAT_IMX=y # Filesystem BR2_TARGET_ROOTFS_EXT2=y BR2_TARGET_ROOTFS_EXT2_4=y +BR2_TARGET_ROOTFS_GENIMAGE=y +BR2_TARGET_ROOTFS_GENIMAGE_CFG="board/via/imx6_vab820/genimage.cfg" BR2_PACKAGE_HOST_DOSFSTOOLS=y -BR2_PACKAGE_HOST_GENIMAGE=y BR2_PACKAGE_HOST_MTOOLS=y -BR2_ROOTFS_POST_IMAGE_SCRIPT="board/via/imx6_vab820/post-image.sh"
Signature · 1 line
2.7.0