* [ptxdist] How to create multiple packages, which contain same filename ?
@ 2018-12-06 11:49 Andreas Friesen
2018-12-11 7:29 ` Michael Olbrich
2018-12-11 8:58 ` Baeuerle, Florian
0 siblings, 2 replies; 7+ messages in thread
From: Andreas Friesen @ 2018-12-06 11:49 UTC (permalink / raw)
To: ptxdist
[-- Attachment #1.1: Type: text/plain, Size: 656 bytes --]
Hello everyone,
we've got many module types, each module type builds on same platform. I
would like create a generic barebox environment for all module types.
My problem is, that ptxdist don't like packages, which contain same
filename. My plan was to create several packages :
- firmware-Type-A.ipkg (contains /boot/{fpga.bin,platform.dtb)
- firmware-Type-B.ipkg (contains /boot/{fpga.bin,platform.dtb)
- firmware-Type-C.ipkg (contains /boot/{fpga.bin,platform.dtb)
And each module install via" collection" the respective package.
What can I do ? I would like to avoid having foreign components in the
firmware package.
Regards,
Andreas Friesen
[-- Attachment #1.2: Type: text/html, Size: 951 bytes --]
[-- Attachment #2: Type: text/plain, Size: 91 bytes --]
_______________________________________________
ptxdist mailing list
ptxdist@pengutronix.de
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [ptxdist] How to create multiple packages, which contain same filename ?
2018-12-06 11:49 [ptxdist] How to create multiple packages, which contain same filename ? Andreas Friesen
@ 2018-12-11 7:29 ` Michael Olbrich
2018-12-11 8:58 ` Baeuerle, Florian
1 sibling, 0 replies; 7+ messages in thread
From: Michael Olbrich @ 2018-12-11 7:29 UTC (permalink / raw)
To: ptxdist
Hi,
On Thu, Dec 06, 2018 at 12:49:58PM +0100, Andreas Friesen wrote:
> we've got many module types, each module type builds on same platform. I
> would like create a generic barebox environment for all module types.
>
> My problem is, that ptxdist don't like packages, which contain same
> filename. My plan was to create several packages :
>
> - firmware-Type-A.ipkg (contains /boot/{fpga.bin,platform.dtb)
> - firmware-Type-B.ipkg (contains /boot/{fpga.bin,platform.dtb)
> - firmware-Type-C.ipkg (contains /boot/{fpga.bin,platform.dtb)
>
> And each module install via" collection" the respective package.
>
> What can I do ? I would like to avoid having foreign components in the
> firmware package.
The documentation has a section about stuff like that[1]. Start with that
and come back if you have more questions.
Michael
[1] https://www.ptxdist.org/doc/daily_work_section.html#supporting-multiple-device-variants-in-one-platform
--
Pengutronix e.K. | |
Industrial Linux Solutions | http://www.pengutronix.de/ |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 |
Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |
_______________________________________________
ptxdist mailing list
ptxdist@pengutronix.de
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [ptxdist] How to create multiple packages, which contain same filename ?
2018-12-06 11:49 [ptxdist] How to create multiple packages, which contain same filename ? Andreas Friesen
2018-12-11 7:29 ` Michael Olbrich
@ 2018-12-11 8:58 ` Baeuerle, Florian
2018-12-11 10:59 ` Andreas Friesen
1 sibling, 1 reply; 7+ messages in thread
From: Baeuerle, Florian @ 2018-12-11 8:58 UTC (permalink / raw)
To: ptxdist
Hi Andreas,
this use case is supported by ptxdist, actually quite exactly as you planned it.
You will eventually run into this issue:
https://www.mail-archive.com/ptxdist@pengutronix.de/msg13611.html
But probably only if you use image packages for creating your three rootfses at
the same time (saves a lot of build time btw).
Best Regards
Florian
Am Donnerstag, den 06.12.2018, 12:49 +0100 schrieb Andreas Friesen:
> Hello everyone,
>
> we've got many module types, each module type builds on same platform. I
> would like create a generic barebox environment for all module types.
>
> My problem is, that ptxdist don't like packages, which contain same filename.
> My plan was to create several packages :
>
> - firmware-Type-A.ipkg (contains /boot/{fpga.bin,platform.dtb)
> - firmware-Type-B.ipkg (contains /boot/{fpga.bin,platform.dtb)
> - firmware-Type-C.ipkg (contains /boot/{fpga.bin,platform.dtb)
>
> And each module install via" collection" the respective package.
>
> What can I do ? I would like to avoid having foreign components in the
> firmware package.
>
> Regards,
> Andreas Friesen
> _______________________________________________
> ptxdist mailing list
> ptxdist@pengutronix.de
_______________________________________________
ptxdist mailing list
ptxdist@pengutronix.de
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [ptxdist] How to create multiple packages, which contain same filename ?
2018-12-11 8:58 ` Baeuerle, Florian
@ 2018-12-11 10:59 ` Andreas Friesen
2018-12-11 11:13 ` Baeuerle, Florian
0 siblings, 1 reply; 7+ messages in thread
From: Andreas Friesen @ 2018-12-11 10:59 UTC (permalink / raw)
To: ptxdist
[-- Attachment #1.1: Type: text/plain, Size: 2788 bytes --]
Hi Florian,
ptxdist reports me after workspace clean this error (see below). This is
always first targetinstall one of the above mentioned packages. The build
order seems to be random.
After repetition of "ptxdist go -j -q " is the build OK. Who create /boot
in root ? Or witch /boot is meant ? What is wrong ?
-------------------------------------
target: fpgaimage-cx27c.targetinstall
-------------------------------------
install_init: preparing for image creation of 'fpgaimage-cx27c'...
....
xpkg_finish: creating opkg package ...
install file:
src=ptx-multi/projectroot/lib/firmware/fpga_complete/soc_system_cx27c.rbf
dst=/boot/fpgaimage.rbf
owner=0
group=0
permissions=0755
chmod: cannot access
'/home/friesen/quantumx/projects/ppc/ptx-multi/platform-soc/root/boot/fpgaimage.rbf':
No such file or directory
Error: install_file failed!
xpkg_finish: failed.
/home/friesen/quantumx/projects/ppc/ptx-multi/rules/fpgaimage-cx27c.make:12:
recipe for target
'/home/friesen/quantumx/projects/ppc/ptx-multi/platform-soc/state/fpgaimage-cx27c.targetinstall'
failed
make: ***
[/home/friesen/quantumx/projects/ppc/ptx-multi/platform-soc/state/fpgaimage-cx27c.targetinstall]
Error 1
make: *** Waiting for unfinished jobs....
Am Di., 11. Dez. 2018 um 09:58 Uhr schrieb Baeuerle, Florian <
Florian.Baeuerle@allegion.com>:
> Hi Andreas,
>
> this use case is supported by ptxdist, actually quite exactly as you
> planned it.
>
> You will eventually run into this issue:
>
> https://www.mail-archive.com/ptxdist@pengutronix.de/msg13611.html
>
> But probably only if you use image packages for creating your three
> rootfses at
> the same time (saves a lot of build time btw).
>
>
> Best Regards
> Florian
>
> Am Donnerstag, den 06.12.2018, 12:49 +0100 schrieb Andreas Friesen:
> > Hello everyone,
> >
> > we've got many module types, each module type builds on same platform. I
> > would like create a generic barebox environment for all module types.
> >
> > My problem is, that ptxdist don't like packages, which contain same
> filename.
> > My plan was to create several packages :
> >
> > - firmware-Type-A.ipkg (contains /boot/{fpga.bin,platform.dtb)
> > - firmware-Type-B.ipkg (contains /boot/{fpga.bin,platform.dtb)
> > - firmware-Type-C.ipkg (contains /boot/{fpga.bin,platform.dtb)
> >
> > And each module install via" collection" the respective package.
> >
> > What can I do ? I would like to avoid having foreign components in the
> > firmware package.
> >
> > Regards,
> > Andreas Friesen
> > _______________________________________________
> > ptxdist mailing list
> > ptxdist@pengutronix.de
> _______________________________________________
> ptxdist mailing list
> ptxdist@pengutronix.de
[-- Attachment #1.2: Type: text/html, Size: 9778 bytes --]
[-- Attachment #2: fpgaimage-cx27c.make --]
[-- Type: application/octet-stream, Size: 990 bytes --]
PACKAGES-$(PTXCONF_FPGAIMAGE_CX27C) += fpgaimage-cx27c
FPGAIMAGE_CX27C_VERSION := 0.0.1
FPGAIMAGE_CX27C_LICENSE := Copyright (C) 2007 Hottinger Baldwin Messtechnik GmbH
$(STATEDIR)/fpgaimage-cx27c.install:
@$(call targetinfo)
@install -D -m 0755 $(PTXDIST_WORKSPACE)/projectroot/lib/firmware/fpga_complete/$(PTXCONF_QUANTUMX_RBF_CX27C) $(IMAGEDIR)/$(PTXCONF_QUANTUMX_RBF_CX27C)
@$(call touch)
$(STATEDIR)/fpgaimage-cx27c.targetinstall:
@$(call targetinfo)
@$(call install_init, fpgaimage-cx27c)
@$(call install_fixup,fpgaimage-cx27c,PRIORITY,optional)
@$(call install_fixup,fpgaimage-cx27c,SECTION,base)
@$(call install_fixup,fpgaimage-cx27c,AUTHOR,"Andreas Friesen <andreas.friesen@hbm.com>")
@$(call install_fixup,fpgaimage-cx27c,DESCRIPTION,missing)
@$(call install_copy, fpgaimage-cx27c, 0, 0, 0755, $(PTXDIST_WORKSPACE)/projectroot/lib/firmware/fpga_complete/$(PTXCONF_QUANTUMX_RBF_CX27C), /boot/fpgaimage.rbf)
@$(call install_finish,fpgaimage-cx27c)
@$(call touch)
[-- Attachment #3: collectionconfig.cx27c --]
[-- Type: application/octet-stream, Size: 1436 bytes --]
#
# Automatically generated file; DO NOT EDIT.
# PTXdist 2018.11.0
#
PTXCONF__collectionconfig_MAGIC__=y
# PTXCONF_COLLECTION_NONE is not set
PTXCONF_COLLECTION_MANUAL=y
# PTXCONF_COLLECTION_ALL is not set
PTXCONF_BAREBOX_MINI_NOR_CX27C=y
# PTXCONF_BAREBOX_MINI_NOR_MX471C is not set
# PTXCONF_BAREBOX_MINI_NOR_MXFS4 is not set
PTXCONF_BAREBOX_NOR_CX27C=y
# PTXCONF_BAREBOX_NOR_MX471C is not set
# PTXCONF_BAREBOX_NOR_MXFS4 is not set
PTXCONF_BAREBOX_XLOAD_NOR_CX27C=y
# PTXCONF_BAREBOX_XLOAD_NOR_MX471C is not set
# PTXCONF_BAREBOX_XLOAD_NOR_MXFS4 is not set
PTXCONF_BAREBOX_XLOAD_SD_CX27C=y
# PTXCONF_BAREBOX_XLOAD_SD_MX471C is not set
# PTXCONF_BAREBOX_XLOAD_SD_MXFS4 is not set
# PTXCONF_CAN_STATIC_TRANSMIT is not set
PTXCONF_DTBIMAGE_CX27C=y
# PTXCONF_DTBIMAGE_MX471C is not set
# PTXCONF_DTBIMAGE_MXFS4 is not set
# PTXCONF_FB_CANFD_DECODER is not set
# PTXCONF_FB_FIBER is not set
# PTXCONF_FB_FIBER_OSA is not set
# PTXCONF_FB_PROFINET is not set
# PTXCONF_FB_SIGGEN is not set
# PTXCONF_FIELDBUS is not set
PTXCONF_FPGAIMAGE_CX27C=y
# PTXCONF_FPGAIMAGE_MX471C is not set
# PTXCONF_FPGAIMAGE_MXFS4 is not set
# PTXCONF_FSAPPL is not set
# PTXCONF_HOST_GENEXT2FS is not set
# PTXCONF_HOST_GENIMAGE is not set
# PTXCONF_HOST_LIBCONFUSE is not set
# PTXCONF_HOST_LIBLZO is not set
# PTXCONF_HOST_MTD_UTILS is not set
# PTXCONF_HOST_MTOOLS is not set
# PTXCONF_HOST_UTIL_LINUX_NG is not set
# PTXCONF_SDC_UPDATE_SCRIPTS is not set
[-- Attachment #4: quantumx-cx27c.in --]
[-- Type: application/octet-stream, Size: 2064 bytes --]
##SECTION=quantumx_images
menuconfig QUANTUMX_CX27C
bool "QuantumX CX27C"
default y
if QUANTUMX_CX27C
config IMAGE_UBIFS_CX27C
tristate
select HOST_GENIMAGE
select HOST_MTD_UTILS
prompt "images/root-cx27c.ubifs"
default m
config IMAGE_SD_CX27C
tristate
select HOST_GENIMAGE
select HOST_MTOOLS
prompt "images/sd-cx27c.img"
default m
config IMAGE_CX27C_TGZ
tristate
prompt "images/root-cx27c.tgz"
default m
config BAREBOX_NOR_CX27C
tristate
prompt "Barebox (nor-cx27c)"
default m
config BAREBOX_MINI_NOR_CX27C
tristate
prompt "Barebox (xload-mini-nor-cx27c)"
default m
config BAREBOX_XLOAD_SD_CX27C
tristate
prompt "Barebox (xload-sd-cx27c)"
default m
config BAREBOX_XLOAD_NOR_CX27C
tristate
prompt "Barebox (xload-nor-cx27c)"
default m
if BAREBOX_XLOAD_SD_CX27C
config IMAGE_CX27C_VFAT
tristate
select HOST_MTOOLS
prompt "vfat (boot-cx27c.vfat)"
default m
config IMAGE_CX27C_EXT2
tristate
select HOST_GENEXT2FS
prompt "ext2 (root-cx27c.ext2)"
default m
endif
config DTBIMAGE_CX27C
tristate
# prompt "DeviceTree Image (CX27C)"
depends on IMAGE_UBIFS_CX27C
default m
if DTBIMAGE_CX27C
config QUANTUMX_DTS_CX27C
string "device tree file (dts)"
default "socfpga_cyclone5_cx27c.dts"
endif
config FPGAIMAGE_CX27C
tristate
# prompt "FPGA Image (CX27C)"
depends on IMAGE_UBIFS_CX27C
default m
if FPGAIMAGE_CX27C
config QUANTUMX_RBF_CX27C
string "fpga image (rbf)"
default "soc_system_cx27c.rbf"
endif
config QUANTUMX_REVISION_CX27C
string "Revision strings"
default "101"
config QUANTUMX_CONFIGSTRING_CX27C
string "Configstring"
default "^^"
config IMAGE_CONFIGSTRING_CX27C
bool
default y
config BLSPEC_CX27C
tristate
# prompt "/loader/entries/cx27c.conf"
default y
endif
[-- Attachment #5: Type: text/plain, Size: 91 bytes --]
_______________________________________________
ptxdist mailing list
ptxdist@pengutronix.de
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [ptxdist] How to create multiple packages, which contain same filename ?
2018-12-11 10:59 ` Andreas Friesen
@ 2018-12-11 11:13 ` Baeuerle, Florian
2018-12-14 10:57 ` Andreas Friesen
0 siblings, 1 reply; 7+ messages in thread
From: Baeuerle, Florian @ 2018-12-11 11:13 UTC (permalink / raw)
To: ptxdist
Hi Andreas,
maybe you can confirm if this assumption is correct:
You are using image packages with your collections to create rootfs images for
your three different variants.
If so, then this probably the root cause:
ptxdist has this "nfsroot" feature. By default, it installs everything into
$build/root. This is a bit problematic when using image packages, because it
will install all your variant packages in parallel. This leads to races where
variant-1 wants to install and chmod a file, but shortly before variant-1's
targetinstall wants to chmod the file, variant-2 replaces it.
Additionally, the content of the nfsroot are not really predictable.
There is currently no option to disable nfsroot (wouldn't be a problem anyway,
because for image packages you can have an nfsroot for each root image you
create). I want to submit a patch (well, at some point...).
If you just need a short workaround, you can place sleeps into your image
packages .targetinstall stages (That's what I do).
variant-1: no sleeping
variant-2: sleep 1
variant-3: sleep 2
It's just an ugly workaround and it can still fail.
Feel free to go ahead and submit a patch, proposal #1 or #2 to fix the issue
probably have chance to get accepted:
https://www.mail-archive.com/ptxdist@pengutronix.de/msg13614.html
Best Regards
Florian
Am Dienstag, den 11.12.2018, 11:59 +0100 schrieb Andreas Friesen:
> Hi Florian,
>
> ptxdist reports me after workspace clean this error (see below). This is
> always first targetinstall one of the above mentioned packages. The build
> order seems to be random.
> After repetition of "ptxdist go -j -q " is the build OK. Who create /boot in
> root ? Or witch /boot is meant ? What is wrong ?
>
> -------------------------------------
>
>
> target: fpgaimage-cx27c.targetinstall
>
>
> -------------------------------------
>
>
>
>
>
> install_init: preparing for image creation of 'fpgaimage-cx27c'...
>
>
> ....
>
> xpkg_finish: creating opkg package ...
>
>
>
>
>
> install file:
>
>
> src=ptx-multi/projectroot/lib/firmware/fpga_complete/soc_system_cx27c.rbf
>
>
> dst=/boot/fpgaimage.rbf
>
>
> owner=0
>
>
> group=0
>
>
> permissions=0755
>
>
>
>
>
> chmod: cannot access '/home/friesen/quantumx/projects/ppc/ptx-multi/platform-
> soc/root/boot/fpgaimage.rbf': No such file or directory
>
> Error: install_file failed!
>
>
>
>
>
> xpkg_finish: failed.
>
>
>
>
>
> /home/friesen/quantumx/projects/ppc/ptx-multi/rules/fpgaimage-cx27c.make:12:
> recipe for target '/home/friesen/quantumx/projects/ppc/ptx-multi/platform-
> soc/state/fpgaimage-cx27c.targetinstall' failed
> make: *** [/home/friesen/quantumx/projects/ppc/ptx-multi/platform-
> soc/state/fpgaimage-cx27c.targetinstall] Error 1
>
> make: *** Waiting for unfinished jobs....
>
>
>
>
>
> Am Di., 11. Dez. 2018 um 09:58 Uhr schrieb Baeuerle, Florian <
> Florian.Baeuerle@allegion.com>:
> > Hi Andreas,
> >
> > this use case is supported by ptxdist, actually quite exactly as you planned
> > it.
> >
> > You will eventually run into this issue:
> >
> > https://www.mail-archive.com/ptxdist@pengutronix.de/msg13611.html
> >
> > But probably only if you use image packages for creating your three rootfses
> > at
> > the same time (saves a lot of build time btw).
> >
> >
> > Best Regards
> > Florian
> >
> > Am Donnerstag, den 06.12.2018, 12:49 +0100 schrieb Andreas Friesen:
> > > Hello everyone,
> > >
> > > we've got many module types, each module type builds on same platform. I
> > > would like create a generic barebox environment for all module types.
> > >
> > > My problem is, that ptxdist don't like packages, which contain same
> > filename.
> > > My plan was to create several packages :
> > >
> > > - firmware-Type-A.ipkg (contains /boot/{fpga.bin,platform.dtb)
> > > - firmware-Type-B.ipkg (contains /boot/{fpga.bin,platform.dtb)
> > > - firmware-Type-C.ipkg (contains /boot/{fpga.bin,platform.dtb)
> > >
> > > And each module install via" collection" the respective package.
> > >
> > > What can I do ? I would like to avoid having foreign components in the
> > > firmware package.
> > >
> > > Regards,
> > > Andreas Friesen
> > > _______________________________________________
> > > ptxdist mailing list
> > > ptxdist@pengutronix.de
> > _______________________________________________
> > ptxdist mailing list
> > ptxdist@pengutronix.de
>
> _______________________________________________
> ptxdist mailing list
> ptxdist@pengutronix.de
_______________________________________________
ptxdist mailing list
ptxdist@pengutronix.de
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [ptxdist] How to create multiple packages, which contain same filename ?
2018-12-11 11:13 ` Baeuerle, Florian
@ 2018-12-14 10:57 ` Andreas Friesen
2018-12-14 11:51 ` Baeuerle, Florian
0 siblings, 1 reply; 7+ messages in thread
From: Andreas Friesen @ 2018-12-14 10:57 UTC (permalink / raw)
To: ptxdist
[-- Attachment #1.1: Type: text/plain, Size: 5236 bytes --]
Hi Florian,
I added some randomized sleeps to *.install rules. It works for now, but
its realy ugly.
Best Regards,
Andreas.
Am Di., 11. Dez. 2018 um 12:14 Uhr schrieb Baeuerle, Florian <
Florian.Baeuerle@allegion.com>:
> Hi Andreas,
>
> maybe you can confirm if this assumption is correct:
>
> You are using image packages with your collections to create rootfs images
> for
> your three different variants.
>
> If so, then this probably the root cause:
>
> ptxdist has this "nfsroot" feature. By default, it installs everything into
> $build/root. This is a bit problematic when using image packages, because
> it
> will install all your variant packages in parallel. This leads to races
> where
> variant-1 wants to install and chmod a file, but shortly before variant-1's
> targetinstall wants to chmod the file, variant-2 replaces it.
>
> Additionally, the content of the nfsroot are not really predictable.
>
> There is currently no option to disable nfsroot (wouldn't be a problem
> anyway,
> because for image packages you can have an nfsroot for each root image you
> create). I want to submit a patch (well, at some point...).
>
> If you just need a short workaround, you can place sleeps into your image
> packages .targetinstall stages (That's what I do).
>
> variant-1: no sleeping
> variant-2: sleep 1
> variant-3: sleep 2
>
> It's just an ugly workaround and it can still fail.
>
> Feel free to go ahead and submit a patch, proposal #1 or #2 to fix the
> issue
> probably have chance to get accepted:
> https://www.mail-archive.com/ptxdist@pengutronix.de/msg13614.html
>
>
> Best Regards
> Florian
>
> Am Dienstag, den 11.12.2018, 11:59 +0100 schrieb Andreas Friesen:
> > Hi Florian,
> >
> > ptxdist reports me after workspace clean this error (see below). This is
> > always first targetinstall one of the above mentioned packages. The
> build
> > order seems to be random.
> > After repetition of "ptxdist go -j -q " is the build OK. Who create
> /boot in
> > root ? Or witch /boot is meant ? What is wrong ?
> >
> > -------------------------------------
>
> >
>
> >
> > target: fpgaimage-cx27c.targetinstall
>
> >
>
> >
> > -------------------------------------
>
> >
>
> >
> >
>
> >
>
> >
> > install_init: preparing for image creation of 'fpgaimage-cx27c'...
>
> >
>
> >
> > ....
>
> >
> > xpkg_finish: creating opkg package ...
>
> >
>
> >
> >
>
> >
>
> >
> > install file:
>
> >
>
> >
> >
> src=ptx-multi/projectroot/lib/firmware/fpga_complete/soc_system_cx27c.rbf
>
> >
>
> >
> > dst=/boot/fpgaimage.rbf
>
> >
>
> >
> > owner=0
>
> >
>
> >
> > group=0
>
> >
>
> >
> > permissions=0755
>
> >
>
> >
> >
>
> >
>
> >
> > chmod: cannot access
> '/home/friesen/quantumx/projects/ppc/ptx-multi/platform-
> > soc/root/boot/fpgaimage.rbf': No such file or directory
>
> >
> > Error: install_file failed!
>
> >
>
> >
> >
>
> >
>
> >
> > xpkg_finish: failed.
>
> >
>
> >
> >
>
> >
>
> >
> >
> /home/friesen/quantumx/projects/ppc/ptx-multi/rules/fpgaimage-cx27c.make:12:
> > recipe for target
> '/home/friesen/quantumx/projects/ppc/ptx-multi/platform-
> > soc/state/fpgaimage-cx27c.targetinstall' failed
> > make: *** [/home/friesen/quantumx/projects/ppc/ptx-multi/platform-
> > soc/state/fpgaimage-cx27c.targetinstall] Error 1
>
> >
> > make: *** Waiting for unfinished jobs....
>
> >
>
> >
> >
>
> >
> >
> > Am Di., 11. Dez. 2018 um 09:58 Uhr schrieb Baeuerle, Florian <
> > Florian.Baeuerle@allegion.com>:
> > > Hi Andreas,
> > >
> > > this use case is supported by ptxdist, actually quite exactly as you
> planned
> > > it.
> > >
> > > You will eventually run into this issue:
> > >
> > > https://www.mail-archive.com/ptxdist@pengutronix.de/msg13611.html
> > >
> > > But probably only if you use image packages for creating your three
> rootfses
> > > at
> > > the same time (saves a lot of build time btw).
> > >
> > >
> > > Best Regards
> > > Florian
> > >
> > > Am Donnerstag, den 06.12.2018, 12:49 +0100 schrieb Andreas Friesen:
> > > > Hello everyone,
> > > >
> > > > we've got many module types, each module type builds on same
> platform. I
> > > > would like create a generic barebox environment for all module types.
> > > >
> > > > My problem is, that ptxdist don't like packages, which contain same
> > > filename.
> > > > My plan was to create several packages :
> > > >
> > > > - firmware-Type-A.ipkg (contains /boot/{fpga.bin,platform.dtb)
> > > > - firmware-Type-B.ipkg (contains /boot/{fpga.bin,platform.dtb)
> > > > - firmware-Type-C.ipkg (contains /boot/{fpga.bin,platform.dtb)
> > > >
> > > > And each module install via" collection" the respective package.
> > > >
> > > > What can I do ? I would like to avoid having foreign components in
> the
> > > > firmware package.
> > > >
> > > > Regards,
> > > > Andreas Friesen
> > > > _______________________________________________
> > > > ptxdist mailing list
> > > > ptxdist@pengutronix.de
> > > _______________________________________________
> > > ptxdist mailing list
> > > ptxdist@pengutronix.de
> >
> > _______________________________________________
> > ptxdist mailing list
> > ptxdist@pengutronix.de
> _______________________________________________
> ptxdist mailing list
> ptxdist@pengutronix.de
[-- Attachment #1.2: Type: text/html, Size: 13079 bytes --]
[-- Attachment #2: Type: text/plain, Size: 91 bytes --]
_______________________________________________
ptxdist mailing list
ptxdist@pengutronix.de
^ permalink raw reply [flat|nested] 7+ messages in thread
* Re: [ptxdist] How to create multiple packages, which contain same filename ?
2018-12-14 10:57 ` Andreas Friesen
@ 2018-12-14 11:51 ` Baeuerle, Florian
0 siblings, 0 replies; 7+ messages in thread
From: Baeuerle, Florian @ 2018-12-14 11:51 UTC (permalink / raw)
To: ptxdist
Hi Andreas,
Am Freitag, den 14.12.2018, 11:57 +0100 schrieb Andreas Friesen:
> Hi Florian,
>
> I added some randomized sleeps to *.install rules. It works for now, but its
> realy ugly.
Yes it is. The fix is either adding an option to disable ROOTDIR or locking
ROOTDIR while installing stuff there.
>
> Best Regards,
> Andreas.
>
> Am Di., 11. Dez. 2018 um 12:14 Uhr schrieb Baeuerle, Florian <
> Florian.Baeuerle@allegion.com>:
> > Hi Andreas,
> >
> > maybe you can confirm if this assumption is correct:
> >
> > You are using image packages with your collections to create rootfs images
> > for
> > your three different variants.
> >
> > If so, then this probably the root cause:
> >
> > ptxdist has this "nfsroot" feature. By default, it installs everything into
> > $build/root. This is a bit problematic when using image packages, because it
> > will install all your variant packages in parallel. This leads to races
> > where
> > variant-1 wants to install and chmod a file, but shortly before variant-1's
> > targetinstall wants to chmod the file, variant-2 replaces it.
> >
> > Additionally, the content of the nfsroot are not really predictable.
> >
> > There is currently no option to disable nfsroot (wouldn't be a problem
> > anyway,
> > because for image packages you can have an nfsroot for each root image you
> > create). I want to submit a patch (well, at some point...).
> >
> > If you just need a short workaround, you can place sleeps into your image
> > packages .targetinstall stages (That's what I do).
> >
> > variant-1: no sleeping
> > variant-2: sleep 1
> > variant-3: sleep 2
> >
> > It's just an ugly workaround and it can still fail.
> >
> > Feel free to go ahead and submit a patch, proposal #1 or #2 to fix the issue
> > probably have chance to get accepted:
> > https://www.mail-archive.com/ptxdist@pengutronix.de/msg13614.html
> >
> >
> > Best Regards
> > Florian
> >
> > Am Dienstag, den 11.12.2018, 11:59 +0100 schrieb Andreas Friesen:
> > > Hi Florian,
> > >
> > > ptxdist reports me after workspace clean this error (see below). This is
> > > always first targetinstall one of the above mentioned packages. The build
> > > order seems to be random.
> > > After repetition of "ptxdist go -j -q " is the build OK. Who create /boot
> > in
> > > root ? Or witch /boot is meant ? What is wrong ?
> > >
> > > -------------------------------------
> >
> > >
> >
> > >
> > > target: fpgaimage-cx27c.targetinstall
> >
> > >
> >
> > >
> > > -------------------------------------
> >
> > >
> >
> > >
> > >
> >
> > >
> >
> > >
> > > install_init: preparing for image creation of 'fpgaimage-cx27c'...
> >
> > >
> >
> > >
> > > ....
> >
> > >
> > > xpkg_finish: creating opkg package ...
> >
> > >
> >
> > >
> > >
> >
> > >
> >
> > >
> > > install file:
> >
> > >
> >
> > >
> > > src=ptx-
> > multi/projectroot/lib/firmware/fpga_complete/soc_system_cx27c.rbf
> > >
> >
> > >
> > > dst=/boot/fpgaimage.rbf
> >
> > >
> >
> > >
> > > owner=0
> >
> > >
> >
> > >
> > > group=0
> >
> > >
> >
> > >
> > > permissions=0755
> >
> > >
> >
> > >
> > >
> >
> > >
> >
> > >
> > > chmod: cannot access '/home/friesen/quantumx/projects/ppc/ptx-
> > multi/platform-
> > > soc/root/boot/fpgaimage.rbf': No such file or directory
> >
> > >
> > > Error: install_file failed!
> >
> > >
> >
> > >
> > >
> >
> > >
> >
> > >
> > > xpkg_finish: failed.
> >
> > >
> >
> > >
> > >
> >
> > >
> >
> > >
> > > /home/friesen/quantumx/projects/ppc/ptx-multi/rules/fpgaimage-
> > cx27c.make:12:
> > > recipe for target '/home/friesen/quantumx/projects/ppc/ptx-multi/platform-
> > > soc/state/fpgaimage-cx27c.targetinstall' failed
> > > make: *** [/home/friesen/quantumx/projects/ppc/ptx-multi/platform-
> > > soc/state/fpgaimage-cx27c.targetinstall] Error 1
> >
> > >
> > > make: *** Waiting for unfinished jobs....
> >
> > >
> >
> > >
> > >
> >
> > >
> > >
> > > Am Di., 11. Dez. 2018 um 09:58 Uhr schrieb Baeuerle, Florian <
> > > Florian.Baeuerle@allegion.com>:
> > > > Hi Andreas,
> > > >
> > > > this use case is supported by ptxdist, actually quite exactly as you
> > planned
> > > > it.
> > > >
> > > > You will eventually run into this issue:
> > > >
> > > > https://www.mail-archive.com/ptxdist@pengutronix.de/msg13611.html
> > > >
> > > > But probably only if you use image packages for creating your three
> > rootfses
> > > > at
> > > > the same time (saves a lot of build time btw).
> > > >
> > > >
> > > > Best Regards
> > > > Florian
> > > >
> > > > Am Donnerstag, den 06.12.2018, 12:49 +0100 schrieb Andreas Friesen:
> > > > > Hello everyone,
> > > > >
> > > > > we've got many module types, each module type builds on same
> > platform. I
> > > > > would like create a generic barebox environment for all module types.
> > > > >
> > > > > My problem is, that ptxdist don't like packages, which contain same
> > > > filename.
> > > > > My plan was to create several packages :
> > > > >
> > > > > - firmware-Type-A.ipkg (contains /boot/{fpga.bin,platform.dtb)
> > > > > - firmware-Type-B.ipkg (contains /boot/{fpga.bin,platform.dtb)
> > > > > - firmware-Type-C.ipkg (contains /boot/{fpga.bin,platform.dtb)
> > > > >
> > > > > And each module install via" collection" the respective package.
> > > > >
> > > > > What can I do ? I would like to avoid having foreign components in the
> > > > > firmware package.
> > > > >
> > > > > Regards,
> > > > > Andreas Friesen
> > > > > _______________________________________________
> > > > > ptxdist mailing list
> > > > > ptxdist@pengutronix.de
> > > > _______________________________________________
> > > > ptxdist mailing list
> > > > ptxdist@pengutronix.de
> > >
> > > _______________________________________________
> > > ptxdist mailing list
> > > ptxdist@pengutronix.de
> > _______________________________________________
> > ptxdist mailing list
> > ptxdist@pengutronix.de
>
> _______________________________________________
> ptxdist mailing list
> ptxdist@pengutronix.de
_______________________________________________
ptxdist mailing list
ptxdist@pengutronix.de
^ permalink raw reply [flat|nested] 7+ messages in thread
end of thread, other threads:[~2018-12-14 11:51 UTC | newest]
Thread overview: 7+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-12-06 11:49 [ptxdist] How to create multiple packages, which contain same filename ? Andreas Friesen
2018-12-11 7:29 ` Michael Olbrich
2018-12-11 8:58 ` Baeuerle, Florian
2018-12-11 10:59 ` Andreas Friesen
2018-12-11 11:13 ` Baeuerle, Florian
2018-12-14 10:57 ` Andreas Friesen
2018-12-14 11:51 ` Baeuerle, Florian
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox