public inbox for gentoo-catalyst@lists.gentoo.org
 help / color / mirror / Atom feed
* [gentoo-catalyst] [PATCH 1/3] Re-allow the use of mksquashfs to pack the livecd contents
@ 2020-10-23  9:18 Daniel Cordero
  2020-10-23  9:18 ` [gentoo-catalyst] [PATCH 2/3] Update requirements for amd64/x86 ISO creation Daniel Cordero
                   ` (2 more replies)
  0 siblings, 3 replies; 10+ messages in thread
From: Daniel Cordero @ 2020-10-23  9:18 UTC (permalink / raw
  To: gentoo-catalyst

From: Daniel Cordero <catalyst@0xdc.io>

sys-fs/squashfs-tools-ng is keyworded as unstable. Stable squashfs users
can still use mksquashfs to create the squashed image.

Fixes: 23e9ea10 "targets: Use gensquashfs instead of mksquashfs"

Signed-off-by: Daniel Cordero <catalyst@0xdc.io>
---

I have not fixed targets/embedded/fs-runscript.sh from the referenced
commit.


 targets/support/target_image_setup.sh | 9 +++++++--
 1 file changed, 7 insertions(+), 2 deletions(-)

diff --git a/targets/support/target_image_setup.sh b/targets/support/target_image_setup.sh
index fdc4a234..23150f13 100755
--- a/targets/support/target_image_setup.sh
+++ b/targets/support/target_image_setup.sh
@@ -7,8 +7,13 @@ mkdir -p "${1}"
 echo "Creating ${clst_fstype} filesystem"
 case ${clst_fstype} in
 	squashfs)
-		gensquashfs -D "${clst_destpath}" -q ${clst_fsops} "${1}/image.squashfs" \
-			|| die "Failed to create squashfs filesystem"
+		if command -v mksquashfs; then
+			mksquashfs "${clst_destpath}" "$1/image.squashfs" ${clst_fsops} -noappend \
+				|| die "mksquashfs failed"
+		else
+			gensquashfs -D "${clst_destpath}" -q ${clst_fsops} "${1}/image.squashfs" \
+				|| die "Failed to create squashfs filesystem"
+		fi
 	;;
 	jffs2)
 		mkfs.jffs2 --root="${clst_destpath}" --output="${1}/image.jffs" "${clst_fsops}" \
-- 
2.26.2



^ permalink raw reply related	[flat|nested] 10+ messages in thread

* [gentoo-catalyst] [PATCH 2/3] Update requirements for amd64/x86 ISO creation
  2020-10-23  9:18 [gentoo-catalyst] [PATCH 1/3] Re-allow the use of mksquashfs to pack the livecd contents Daniel Cordero
@ 2020-10-23  9:18 ` Daniel Cordero
  2020-10-23 16:24   ` Matt Turner
                     ` (2 more replies)
  2020-10-23  9:18 ` [gentoo-catalyst] [PATCH 3/3] Build ISO with Joliet directory information Daniel Cordero
  2020-10-23 16:22 ` [gentoo-catalyst] [PATCH 1/3] Re-allow the use of mksquashfs to pack the livecd contents Matt Turner
  2 siblings, 3 replies; 10+ messages in thread
From: Daniel Cordero @ 2020-10-23  9:18 UTC (permalink / raw
  To: gentoo-catalyst

From: Daniel Cordero <catalyst@0xdc.io>

xorriso uses mkisofs to create the ISO.

Signed-off-by: Daniel Cordero <catalyst@0xdc.io>
---
 targets/support/create-iso.sh | 8 ++++++--
 1 file changed, 6 insertions(+), 2 deletions(-)

diff --git a/targets/support/create-iso.sh b/targets/support/create-iso.sh
index ac97ef56..9b1c7185 100755
--- a/targets/support/create-iso.sh
+++ b/targets/support/create-iso.sh
@@ -18,9 +18,13 @@ case ${clst_hostarch} in
                 cdmaker="grub-mkrescue"
                 cdmakerpkg="dev-libs/libisoburn and sys-boot/grub:2"
                 ;;
-	ia64)
+	amd64|ia64|x86)
 		cdmaker="grub-mkrescue"
-		cdmakerpkg="sys-fs/mtools, dev-libs/libisoburn, and sys-boot/grub:2"
+		# grub-mkrescue requires:
+		#  xorriso from libisoburn
+		#  mkisofs from cdrtools
+		#  mformat from mtools
+		cdmakerpkg="sys-fs/mtools, dev-libs/libisoburn, sys-boot/grub:2, and virtual/cdrtools"
 		;;
 	*)
 		cdmaker="mkisofs"
-- 
2.26.2



^ permalink raw reply related	[flat|nested] 10+ messages in thread

* [gentoo-catalyst] [PATCH 3/3] Build ISO with Joliet directory information
  2020-10-23  9:18 [gentoo-catalyst] [PATCH 1/3] Re-allow the use of mksquashfs to pack the livecd contents Daniel Cordero
  2020-10-23  9:18 ` [gentoo-catalyst] [PATCH 2/3] Update requirements for amd64/x86 ISO creation Daniel Cordero
@ 2020-10-23  9:18 ` Daniel Cordero
  2020-10-23 16:25   ` Matt Turner
  2020-10-23 16:22 ` [gentoo-catalyst] [PATCH 1/3] Re-allow the use of mksquashfs to pack the livecd contents Matt Turner
  2 siblings, 1 reply; 10+ messages in thread
From: Daniel Cordero @ 2020-10-23  9:18 UTC (permalink / raw
  To: gentoo-catalyst

From: Daniel Cordero <catalyst@0xdc.io>

Previous syslinux based CDs had this information.
Necessary for direct kernel booting with virt-install --location.

Fixes: 0a27a7a39a "targets: Use GRUB for BIOS boot"

Signed-off-by: Daniel Cordero <catalyst@0xdc.io>
---
 targets/support/create-iso.sh | 1 +
 1 file changed, 1 insertion(+)

diff --git a/targets/support/create-iso.sh b/targets/support/create-iso.sh
index 9b1c7185..b11b046f 100755
--- a/targets/support/create-iso.sh
+++ b/targets/support/create-iso.sh
@@ -192,6 +192,7 @@ case ${clst_hostarch} in
 		isoroot_checksum
 
 		case ${clst_hostarch} in
+		amd64|x86) extra_opts="-joliet" ;;
 		sparc*) extra_opts="--sparc-boot" ;;
 		esac
 
-- 
2.26.2



^ permalink raw reply related	[flat|nested] 10+ messages in thread

* Re: [gentoo-catalyst] [PATCH 1/3] Re-allow the use of mksquashfs to pack the livecd contents
  2020-10-23  9:18 [gentoo-catalyst] [PATCH 1/3] Re-allow the use of mksquashfs to pack the livecd contents Daniel Cordero
  2020-10-23  9:18 ` [gentoo-catalyst] [PATCH 2/3] Update requirements for amd64/x86 ISO creation Daniel Cordero
  2020-10-23  9:18 ` [gentoo-catalyst] [PATCH 3/3] Build ISO with Joliet directory information Daniel Cordero
@ 2020-10-23 16:22 ` Matt Turner
  2 siblings, 0 replies; 10+ messages in thread
From: Matt Turner @ 2020-10-23 16:22 UTC (permalink / raw
  To: gentoo-catalyst

On Fri, Oct 23, 2020 at 2:19 AM Daniel Cordero <gentoo.catalyst@xxoo.ws> wrote:
>
> From: Daniel Cordero <catalyst@0xdc.io>
>
> sys-fs/squashfs-tools-ng is keyworded as unstable. Stable squashfs users
> can still use mksquashfs to create the squashed image.

I think it's perfectly appropriate for catalyst-9999 to have unstable
dependencies.


^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: [gentoo-catalyst] [PATCH 2/3] Update requirements for amd64/x86 ISO creation
  2020-10-23  9:18 ` [gentoo-catalyst] [PATCH 2/3] Update requirements for amd64/x86 ISO creation Daniel Cordero
@ 2020-10-23 16:24   ` Matt Turner
  2020-10-25 21:20   ` Daniel Cordero
  2020-10-26 13:25   ` Thomas Schmitt
  2 siblings, 0 replies; 10+ messages in thread
From: Matt Turner @ 2020-10-23 16:24 UTC (permalink / raw
  To: gentoo-catalyst

Thanks! Looks good to me.


^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: [gentoo-catalyst] [PATCH 3/3] Build ISO with Joliet directory information
  2020-10-23  9:18 ` [gentoo-catalyst] [PATCH 3/3] Build ISO with Joliet directory information Daniel Cordero
@ 2020-10-23 16:25   ` Matt Turner
  2020-10-23 17:00     ` Daniel Cordero
  0 siblings, 1 reply; 10+ messages in thread
From: Matt Turner @ 2020-10-23 16:25 UTC (permalink / raw
  To: gentoo-catalyst

On Fri, Oct 23, 2020 at 2:19 AM Daniel Cordero <gentoo.catalyst@xxoo.ws> wrote:
>
> From: Daniel Cordero <catalyst@0xdc.io>
>
> Previous syslinux based CDs had this information.
> Necessary for direct kernel booting with virt-install --location.
>
> Fixes: 0a27a7a39a "targets: Use GRUB for BIOS boot"
>
> Signed-off-by: Daniel Cordero <catalyst@0xdc.io>
> ---
>  targets/support/create-iso.sh | 1 +
>  1 file changed, 1 insertion(+)
>
> diff --git a/targets/support/create-iso.sh b/targets/support/create-iso.sh
> index 9b1c7185..b11b046f 100755
> --- a/targets/support/create-iso.sh
> +++ b/targets/support/create-iso.sh
> @@ -192,6 +192,7 @@ case ${clst_hostarch} in
>                 isoroot_checksum
>
>                 case ${clst_hostarch} in
> +               amd64|x86) extra_opts="-joliet" ;;

Is there any reason to limit this to amd64/x86?


^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: [gentoo-catalyst] [PATCH 3/3] Build ISO with Joliet directory information
  2020-10-23 16:25   ` Matt Turner
@ 2020-10-23 17:00     ` Daniel Cordero
  2020-10-23 17:16       ` Matt Turner
  0 siblings, 1 reply; 10+ messages in thread
From: Daniel Cordero @ 2020-10-23 17:00 UTC (permalink / raw
  To: gentoo-catalyst

On Fri, Oct 23, 2020 at 09:25:29AM -0700, Matt Turner wrote:
> On Fri, Oct 23, 2020 at 2:19 AM Daniel Cordero <gentoo.catalyst@xxoo.ws> wrote:
> >
> > From: Daniel Cordero <catalyst@0xdc.io>
> >
> > Previous syslinux based CDs had this information.
> > Necessary for direct kernel booting with virt-install --location.
> >
> > Fixes: 0a27a7a39a "targets: Use GRUB for BIOS boot"
> >
> > Signed-off-by: Daniel Cordero <catalyst@0xdc.io>
> > ---
> >  targets/support/create-iso.sh | 1 +
> >  1 file changed, 1 insertion(+)
> >
> > diff --git a/targets/support/create-iso.sh b/targets/support/create-iso.sh
> > index 9b1c7185..b11b046f 100755
> > --- a/targets/support/create-iso.sh
> > +++ b/targets/support/create-iso.sh
> > @@ -192,6 +192,7 @@ case ${clst_hostarch} in
> >                 isoroot_checksum
> >
> >                 case ${clst_hostarch} in
> > +               amd64|x86) extra_opts="-joliet" ;;
> 
> Is there any reason to limit this to amd64/x86?
> 

My concern is that the other arches may not have had this information on
their ISOs. I do not know if those arches might not like it.


^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: [gentoo-catalyst] [PATCH 3/3] Build ISO with Joliet directory information
  2020-10-23 17:00     ` Daniel Cordero
@ 2020-10-23 17:16       ` Matt Turner
  0 siblings, 0 replies; 10+ messages in thread
From: Matt Turner @ 2020-10-23 17:16 UTC (permalink / raw
  To: gentoo-catalyst

On Fri, Oct 23, 2020 at 10:01 AM Daniel Cordero <gentoo.catalyst@xxoo.ws> wrote:
>
> On Fri, Oct 23, 2020 at 09:25:29AM -0700, Matt Turner wrote:
> > On Fri, Oct 23, 2020 at 2:19 AM Daniel Cordero <gentoo.catalyst@xxoo.ws> wrote:
> > >
> > > From: Daniel Cordero <catalyst@0xdc.io>
> > >
> > > Previous syslinux based CDs had this information.
> > > Necessary for direct kernel booting with virt-install --location.
> > >
> > > Fixes: 0a27a7a39a "targets: Use GRUB for BIOS boot"
> > >
> > > Signed-off-by: Daniel Cordero <catalyst@0xdc.io>
> > > ---
> > >  targets/support/create-iso.sh | 1 +
> > >  1 file changed, 1 insertion(+)
> > >
> > > diff --git a/targets/support/create-iso.sh b/targets/support/create-iso.sh
> > > index 9b1c7185..b11b046f 100755
> > > --- a/targets/support/create-iso.sh
> > > +++ b/targets/support/create-iso.sh
> > > @@ -192,6 +192,7 @@ case ${clst_hostarch} in
> > >                 isoroot_checksum
> > >
> > >                 case ${clst_hostarch} in
> > > +               amd64|x86) extra_opts="-joliet" ;;
> >
> > Is there any reason to limit this to amd64/x86?
> >
>
> My concern is that the other arches may not have had this information on
> their ISOs. I do not know if those arches might not like it.

Oh, I see: this flag is passed through grub-mkrescue to mkisofs. I
guess this is an alias for the -J flag to mkisofs? Strange that I
don't see it documented in either mkisofs(8) or grub-mkrescue(1). It
looks like we're passing -J to mkisofs/xorriso on alpha and hppa, so
my feeling is that we should just use it on all platforms. I'm happy
to adjust the patch when I commit it.


^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: [gentoo-catalyst] [PATCH 2/3] Update requirements for amd64/x86 ISO creation
  2020-10-23  9:18 ` [gentoo-catalyst] [PATCH 2/3] Update requirements for amd64/x86 ISO creation Daniel Cordero
  2020-10-23 16:24   ` Matt Turner
@ 2020-10-25 21:20   ` Daniel Cordero
  2020-10-26 13:25   ` Thomas Schmitt
  2 siblings, 0 replies; 10+ messages in thread
From: Daniel Cordero @ 2020-10-25 21:20 UTC (permalink / raw
  To: gentoo-catalyst

On Fri, Oct 23, 2020 at 09:18:44AM +0000, Daniel Cordero wrote:
> xorriso uses mkisofs to create the ISO.

Apologies, this statement is incorrect.

xorisso does not depend on mkisofs from cdrtools.

However, pyDeComp requires isoinfo to create ISO CONTENTS.

---

>> Running grub-mkrescue to create iso image....
xorriso 1.5.2 : RockRidge filesystem manipulator, libburnia project.

Drive current: -outdev 'stdio:/run/media/system/dm-52/bindist/builds/amd64/systemd/20201024/roflmaOS-20201024.iso'
Media current: stdio file, overwriteable
Media status : is blank
Media summary: 0 sessions, 0 data blocks, 0 data, 24.3g free
Added to ISO image: directory '/'='/tmp/grub.LLGGAQ'
xorriso : UPDATE :     872 files added in 1 seconds
Added to ISO image: directory '/'='/run/media/system/dm-52/bindist/builds/amd64/systemd/20201024/livecd-stage2-amd64-systemd-20201024'
xorriso : UPDATE :     883 files added in 1 seconds
xorriso : NOTE : Copying to System Area: 512 bytes from file '/usr/lib/grub/i386-pc/boot_hybrid.img'
xorriso : UPDATE : Thank you for being patient. Working since 0 seconds.
xorriso : UPDATE :  50.74% done
xorriso : UPDATE :  51.38% done, estimate finish Sun Oct 25 21:06:57 2020
xorriso : UPDATE :  57.80% done, estimate finish Sun Oct 25 21:06:58 2020
xorriso : UPDATE :  68.13% done, estimate finish Sun Oct 25 21:06:58 2020
xorriso : UPDATE :  74.24% done, estimate finish Sun Oct 25 21:06:59 2020
xorriso : UPDATE :  76.69% done, estimate finish Sun Oct 25 21:07:00 2020
ISO image produced: 242256 sectors
Written to medium : 242256 sectors at LBA 0
Writing to 'stdio:/run/media/system/dm-52/bindist/builds/amd64/systemd/20201024/roflmaOS-20201024.iso' completed successfully.

25 Oct 2020 21:06:59 GMT: ERROR   : Exception running action sequence create_iso
Traceback (most recent call last):
  File "/run/media/system/dm-52/bindist/catalyst/catalyst/base/stagebase.py", line 1371, in run
    getattr(self, x)()
  File "/run/media/system/dm-52/bindist/catalyst/catalyst/base/stagebase.py", line 1443, in create_iso
    self.gen_contents_file(self.settings["iso"])
  File "/run/media/system/dm-52/bindist/catalyst/catalyst/base/genbase.py", line 33, in gen_contents_file
    file.write(c.contents(path, '', verbose=self.settings['VERBOSE']))
  File "/usr/lib/python3.8/site-packages/DeComp/contents.py", line 103, in contents
    if isinstance(self._map[mode].func, str):
KeyError: None
ERROR:catalyst:Exception running action sequence create_iso
Traceback (most recent call last):
  File "/run/media/system/dm-52/bindist/catalyst/catalyst/base/stagebase.py", line 1371, in run
    getattr(self, x)()
  File "/run/media/system/dm-52/bindist/catalyst/catalyst/base/stagebase.py", line 1443, in create_iso
    self.gen_contents_file(self.settings["iso"])
  File "/run/media/system/dm-52/bindist/catalyst/catalyst/base/genbase.py", line 33, in gen_contents_file
    file.write(c.contents(path, '', verbose=self.settings['VERBOSE']))
  File "/usr/lib/python3.8/site-packages/DeComp/contents.py", line 103, in contents
    if isinstance(self._map[mode].func, str):
KeyError: None
25 Oct 2020 21:06:59 GMT: NOTICE  : Cleaning up... Running unbind()
NOTICE:catalyst:Cleaning up... Running unbind()


^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: [gentoo-catalyst] [PATCH 2/3] Update requirements for amd64/x86 ISO creation
  2020-10-23  9:18 ` [gentoo-catalyst] [PATCH 2/3] Update requirements for amd64/x86 ISO creation Daniel Cordero
  2020-10-23 16:24   ` Matt Turner
  2020-10-25 21:20   ` Daniel Cordero
@ 2020-10-26 13:25   ` Thomas Schmitt
  2 siblings, 0 replies; 10+ messages in thread
From: Thomas Schmitt @ 2020-10-26 13:25 UTC (permalink / raw
  To: gentoo-catalyst

Hi,

thank you for flying xorriso.

I have two objections towards the commit message, code comments, and
the list in cdmakerpkg:

xorriso does not use mkisofs. It can emulate parts of the mkisofs command
line interface by help of its own code and its associated libraries.

grub-mkrescue of GRUB2 indeed depends on xorriso and mtools. But mkisofs
is not involved with grub-mkrescue since about 10 years.


Have a nice day :)

Thomas



^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2020-10-26 13:26 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2020-10-23  9:18 [gentoo-catalyst] [PATCH 1/3] Re-allow the use of mksquashfs to pack the livecd contents Daniel Cordero
2020-10-23  9:18 ` [gentoo-catalyst] [PATCH 2/3] Update requirements for amd64/x86 ISO creation Daniel Cordero
2020-10-23 16:24   ` Matt Turner
2020-10-25 21:20   ` Daniel Cordero
2020-10-26 13:25   ` Thomas Schmitt
2020-10-23  9:18 ` [gentoo-catalyst] [PATCH 3/3] Build ISO with Joliet directory information Daniel Cordero
2020-10-23 16:25   ` Matt Turner
2020-10-23 17:00     ` Daniel Cordero
2020-10-23 17:16       ` Matt Turner
2020-10-23 16:22 ` [gentoo-catalyst] [PATCH 1/3] Re-allow the use of mksquashfs to pack the livecd contents Matt Turner

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox