Skip to contentSkip to conversation

man/info: fix not support xz/bz2 compression

PATCH Superseded Hongxu Jia 2 participants 10 messages Sep 24, 2014 – Sep 25, 2014

v3 of 5 Superseded Latest is v5 →

lore
Share & tools
lore

Hongxu Jia

author
#0 lore raw

v3 cover man/info: fix not support xz/bz2 compression

Changed in V3:
- Remove Debian-specific code
- split() the INHERIT variable

Changed in V2:
- Conditionally add 'gzip/bzip2/xz' to man/info's RDEPENDS rather than modify busybox's defconfig.

- Refer Ubuntu to add a script to postinst_intercept to run it after all packages have been installed at build time.

Test Case:

vim local.conf
..
IMAGE_INSTALL_append = " man man-doc texinfo texinfo-doc info info-doc" INHERIT += "compress_doc"
DOC_COMPRESS = "xz" or DOC_COMPRESS = "bz2"
..

bitbake core-image-minimal

runqemu qemux86

On target,
...

root@qemux86:~# man man
root@qemux86:~# info info
...

//Hongxu

The following changes since commit 8ac8eca2e3bd8c78e2b31ea974930ed0243258a3:

build-appliance-image: Update to dizzy head revision (2014-09-23 22:10:26 +0100)

are available in the git repository at:

git://git.pokylinux.org/poky-contrib hongxu/fix-doc
http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=hongxu/fix-doc

Hongxu Jia (4):
scripts/postinst-intercepts: add update_info_dir
texinfo: fix QA Error while doc compress enabled
texinfo: fix info not work
man/texinfo: conditionally add gzip/bzip2/xz to RDEPENDS

 meta/recipes-extended/man/man_1.6g.bb        | 13 +++++
 meta/recipes-extended/texinfo/texinfo_5.2.bb | 68 +++++++++++++++++++++++-
 scripts/postinst-intercepts/update_info_dir  | 77 ++++++++++++++++++++++++++++
 3 files changed, 157 insertions(+), 1 deletion(-)
 create mode 100755 scripts/postinst-intercepts/update_info_dir
Signature · 1 line
1.9.1
author
#1 lore raw

PATCH v3 1/4 scripts/postinst-intercepts: add update_info_dir

We need to run it after all packages have been installed. Here is details:

NAME
update_info_dir - update or create index file from all installed info files in directory

SYNOPSIS
update_info_dir [options] [directory]

DESCRIPTION
Update, or create, the index file dir of available documentation in $D/${infodir} (the default) or in given DIRECTORY. The index file info is the directory is usually presented by info browsers on startup.

OPTIONS
-h,--help
Display help and exit.

SEE ALSO
emacs(1) info(1) install-info(1)

AUTHOR
This manual page was written by Norbert Preining <[email protected]>, for the Debian GNU/Linux system (but may be used by others). This manual page was written for the Debian GNU/Linux distribution because the original script was designed for Debian packaging system.

Backport update-info-dir from ubuntu 1404, and add xz/bz2 compression support

[YOCTO #6751]

---
 scripts/postinst-intercepts/update_info_dir | 77 +++++++++++++++++++++++++++++
 1 file changed, 77 insertions(+)
 create mode 100755 scripts/postinst-intercepts/update_info_dir
scripts/postinst-intercepts/update_info_dir new file +77 -0
new file mode 100755
index 0000000..7b80d28
@@ -0,0 +1,77 @@
+#!/bin/bash
+# update-info-dir
+# create a dir file from all installed info files
+# Copyright 2009 Norbert Preining
+# GPLv2
+
+INFODIR=$D${infodir}
+
+set -e
+
+#
+# since user's environment is taken over into root account when sudo-ing
+# we don't want that one's user LANGUAGE setting changes the messages in
+# the dir file. Force it to C. See bug #536476
+LANGUAGE="C"
+LANG="C"
+
+Help ()
+{
+    echo "\
+SYNOPSIS: update-info-dir [-h,--help] [info-directory]
+
+(re-)creates the index of available documentation in info format
+(the file /usr/share/info/dir) which is usually presented by info browsers
+on startup."
+
+    exit 0
+}
+
+
+if [ "$1" = "-h" ] || [ "$1" == "--help" ]; then
+    Help
+fi
+
+if [ -n "$1" ] ; then
+  INFODIR="$1"
+fi
+
+if [ ! -d "$INFODIR" ] ; then
+  echo "Not a directory: $INFODIR." >&2
+  exit 1
+fi
+
+if [ -r "$INFODIR/dir" ] ; then
+  rm -f "$INFODIR/dir.old"
+  cp $INFODIR/dir $INFODIR/dir.old
+fi
+
+# we have to remove the dir file not make ginstall-info being surprised
+rm -f "$INFODIR/dir"
+
+errors=0
+find "$INFODIR" -type f | while read file ; do
+  case $file in
+    */dir|*/dir.old| \
+    *-[0-9]|*-[0-9].gz|*-[0-9].xz|*-[0-9].bz2| \
+    *-[1-9][0-9]|*-[1-9][0-9].gz|*-[1-9][0-9].xz|*-[1-9][0-9].bz2| \
+    *.png)
+      # these files are ignored
+      continue
+      ;;
+    *)
+      ${STAGING_BINDIR_NATIVE}/install-info "$file" "$INFODIR/dir" || {
+        errors=$[errors+1]
+      }
+      ;;
+  esac
+done
+
+if [ $errors -gt 0 ] ; then
+  echo "Updating the index of info documentation produced $errors errors."
+  exit 1
+fi
+
+exit 0
+
+# vim:set expandtab tabstop=2: #
Signature · 1 line
1.9.1
author
#2 lore raw

PATCH v3 2/4 texinfo: fix QA Error while doc compress enabled

In reply to Hongxu Jia

While doc compress enabled, ther is a QA issue:
...
ERROR: QA Issue: texinfo: Files/directories were installed but not shipped
/usr/share/info/info.info.bz2 /usr/share/info/info-stnd.info.bz2 [installed-vs-shipped]
...

---
 meta/recipes-extended/texinfo/texinfo_5.2.bb | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
meta/recipes-extended/texinfo/texinfo_5.2.bb +1 -1
index be90aba..7b5a11a 100644
@@ -51,7 +51,7 @@ do_install_append_class-native() {
 PACKAGES += "info info-doc"
 
 FILES_info = "${bindir}/info ${bindir}/infokey ${bindir}/install-info"
-FILES_info-doc = "${infodir}/info.info ${infodir}/dir ${infodir}/info-*.info \
+FILES_info-doc = "${infodir}/info.info* ${infodir}/dir ${infodir}/info-*.info* \
                   ${mandir}/man1/info.1* ${mandir}/man5/info.5* \
                   ${mandir}/man1/infokey.1* ${mandir}/man1/install-info.1*"
 
Signature · 1 line
1.9.1
author
#3 lore raw

PATCH v3 3/4 texinfo: fix info not work

In reply to Hongxu Jia

In texinfo, we didn't have info/dir entries, which caused info not work.
...

root@qemux86:~# info info
info: dir: No such file or directory
...

Refer ubuntu/debian to invoke install-info to create info/dir entries in pkg_postinst_info.

[YOCTO #6751]

---
 meta/recipes-extended/texinfo/texinfo_5.2.bb | 53 ++++++++++++++++++++++++++++
 1 file changed, 53 insertions(+)
meta/recipes-extended/texinfo/texinfo_5.2.bb +53 -0
index 7b5a11a..cdcb37b 100644
@@ -61,4 +61,57 @@ FILES_${PN}-doc = "${infodir}/texinfo* \
                    ${datadir}/${tex_texinfo} \
                    ${mandir}/man1 ${mandir}/man5"
 
+pkg_postinst_info () {
+if [ "x$D" != "x" ]; then
+    $INTERCEPT_DIR/postinst_intercept update_info_dir ${PKG} \
+        mlprefix=${MLPREFIX} infodir=${infodir} STAGING_BINDIR_NATIVE=${STAGING_BINDIR_NATIVE}
+else
+    errors=0
+    find "${infodir}" -type f | while read file ; do
+        case $file in
+        */dir| */dir.old| \
+        *-[0-9]|*-[0-9].gz|*-[0-9].xz|*-[0-9].bz2| \
+        *-[1-9][0-9]|*-[1-9][0-9].gz|*-[1-9][0-9].xz|*-[1-9][0-9].bz2| \
+        *.png)
+            # these files are ignored
+            continue
+            ;;
+        *)
+            install-info "$file" "${infodir}/dir" || {
+                errors=$[errors+1]
+            }
+            ;;
+        esac
+    done
+    if [ $errors -gt 0 ] ; then
+        echo "Updating the index of info documentation produced $errors errors."
+        exit 1
+    fi
+fi
+}
+
+pkg_prerm_info () {
+errors=0
+find "$D${infodir}" -type f | while read file ; do
+    case $file in
+    */dir|*/dir.old| \
+    *-[0-9]|*-[0-9].gz|*-[0-9].xz|*-[0-9].bz2| \
+    *-[1-9][0-9]|*-[1-9][0-9].gz|*-[1-9][0-9].xz|*-[1-9][0-9].bz2| \
+    *.png)
+        # these files are ignored
+        continue
+        ;;
+    *)
+        install-info --delete "$file" "$D${infodir}/dir" || {
+            errors=$[errors+1]
+        }
+        ;;
+    esac
+done
+
+if [ $errors -gt 0 ] ; then
+    echo "Cleaning the index of info documentation produced $errors errors."
+fi
+}
+
 BBCLASSEXTEND = "native"
Signature · 1 line
1.9.1
author
#4 lore raw

PATCH v3 4/4 man/texinfo: conditionally add gzip/bzip2/xz to RDEPENDS

In reply to Hongxu Jia

Conditionally add 'xz/bz2/gzip' to info/man's RDEPENDS according to DOC_COMPRESS.

[YOCTO #6750]
[YOCTO #6751]

---
 meta/recipes-extended/man/man_1.6g.bb        | 13 +++++++++++++
 meta/recipes-extended/texinfo/texinfo_5.2.bb | 13 +++++++++++++
 2 files changed, 26 insertions(+)
meta/recipes-extended/man/man_1.6g.bb +13 -0
index a66e01c..03fffd6 100644
@@ -9,6 +9,19 @@ PR = "r1"
 
 DEPENDS = "groff less"
 
+def compress_pkg(d):
+    if "compress_doc" in (d.getVar("INHERIT", True) or "").split():
+         compress = d.getVar("DOC_COMPRESS", True)
+         if compress == "gz":
+             return "gzip"
+         elif compress == "bz2":
+             return "bzip2"
+         elif compress == "xz":
+             return "xz"
+    return ""
+
+RDEPENDS_${PN} += "${@compress_pkg(d)}"
+
 SRC_URI = "http://primates.ximian.com/~flucifredi/${BPN}/${BPN}-${PV}.tar.gz \
            file://man-1.5k-confpath.patch;striplevel=0 \
            file://man-1.5h1-make.patch \
meta/recipes-extended/texinfo/texinfo_5.2.bb +13 -0
index cdcb37b..59480e3 100644
@@ -9,6 +9,19 @@ LIC_FILES_CHKSUM = "file://COPYING;md5=d32239bcb673463ab874e80d47fae504"
 
 PROVIDES_append_class-native = " texinfo-replacement-native"
 
+def compress_pkg(d):
+    if "compress_doc" in (d.getVar("INHERIT", True) or "").split():
+         compress = d.getVar("DOC_COMPRESS", True)
+         if compress == "gz":
+             return "gzip"
+         elif compress == "bz2":
+             return "bzip2"
+         elif compress == "xz":
+             return "xz"
+    return ""
+
+RDEPENDS_info += "${@compress_pkg(d)}"
+
 DEPENDS = "zlib ncurses texinfo-replacement-native"
 DEPENDS_class-native = "zlib-native ncurses-native"
 
Signature · 1 line
1.9.1
#5 lore raw
In reply to Hongxu Jia

Hi Hongxu,

This is failing for me, core-image-minimal for NUC with doc-pkgs:

Collected errors:
* check_data_file_clashes: Package util-linux-doc wants to install
file /data/poky-master/tmp/work/nuc-poky-linux/cor e-image-minimal/1.0-r0/rootfs/usr/share/man/man3/libblkid.3.xz
But that file is already provided by package * e2fsprogs-doc
* check_data_file_clashes: Package util-linux-doc wants to install
file /data/poky-master/tmp/work/nuc-poky-linux/cor e-image-minimal/1.0-r0/rootfs/usr/share/man/man8/findfs.8.xz
But that file is already provided by package * e2fsprogs-doc
* check_data_file_clashes: Package util-linux-doc wants to install
file /data/poky-master/tmp/work/nuc-poky-linux/cor e-image-minimal/1.0-r0/rootfs/usr/share/man/man8/fsck.8.xz
But that file is already provided by package * e2fsprogs-doc
* check_data_file_clashes: Package util-linux-doc wants to install
file /data/poky-master/tmp/work/nuc-poky-linux/cor e-image-minimal/1.0-r0/rootfs/usr/share/man/man8/blkid.8.xz
But that file is already provided by package * e2fsprogs-doc
* opkg_install_cmd: Cannot install package util-linux-doc.

NOTE: Running intercept scripts:
NOTE: > Executing update_info_dir intercept ... /data/poky-master/tmp/work/nuc-poky-linux/core-image-minimal/1.0-r0/intercept_scripts/update_info_dir:
line 63: /insta
ll-info: No such file or directory /data/poky-master/tmp/work/nuc-poky-linux/core-image-minimal/1.0-r0/intercept_scripts/update_info_dir:
line 63: /insta
ll-info: No such file or directory

Ross

Quoted 58 lines · Hongxu Jia

Changed in V3:
- Remove Debian-specific code
- split() the INHERIT variable

Changed in V2:
- Conditionally add 'gzip/bzip2/xz' to man/info's RDEPENDS rather than modify busybox's defconfig.

- Refer Ubuntu to add a script to postinst_intercept to run it after all packages have been installed at build time.

Test Case:

vim local.conf
..
IMAGE_INSTALL_append = " man man-doc texinfo texinfo-doc info info-doc" INHERIT += "compress_doc"
DOC_COMPRESS = "xz" or DOC_COMPRESS = "bz2"
..

bitbake core-image-minimal

runqemu qemux86

On target,
...

root@qemux86:~# man man
root@qemux86:~# info info
...

//Hongxu

The following changes since commit 8ac8eca2e3bd8c78e2b31ea974930ed0243258a3:

build-appliance-image: Update to dizzy head revision (2014-09-23 22:10:26 +0100)

are available in the git repository at:

git://git.pokylinux.org/poky-contrib hongxu/fix-doc
http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=hongxu/fix-doc

Hongxu Jia (4):
scripts/postinst-intercepts: add update_info_dir
texinfo: fix QA Error while doc compress enabled
texinfo: fix info not work
man/texinfo: conditionally add gzip/bzip2/xz to RDEPENDS

 meta/recipes-extended/man/man_1.6g.bb        | 13 +++++
 meta/recipes-extended/texinfo/texinfo_5.2.bb | 68 +++++++++++++++++++++++-
 scripts/postinst-intercepts/update_info_dir  | 77 ++++++++++++++++++++++++++++
 3 files changed, 157 insertions(+), 1 deletion(-)
 create mode 100755 scripts/postinst-intercepts/update_info_dir

--
1.9.1

author
#6 lore raw
Quoted 23 lines · Ross

Hi Hongxu,

This is failing for me, core-image-minimal for NUC with doc-pkgs:

Collected errors:
* check_data_file_clashes: Package util-linux-doc wants to install
file /data/poky-master/tmp/work/nuc-poky-linux/cor e-image-minimal/1.0-r0/rootfs/usr/share/man/man3/libblkid.3.xz
But that file is already provided by package * e2fsprogs-doc
* check_data_file_clashes: Package util-linux-doc wants to install
file /data/poky-master/tmp/work/nuc-poky-linux/cor e-image-minimal/1.0-r0/rootfs/usr/share/man/man8/findfs.8.xz
But that file is already provided by package * e2fsprogs-doc
* check_data_file_clashes: Package util-linux-doc wants to install
file /data/poky-master/tmp/work/nuc-poky-linux/cor e-image-minimal/1.0-r0/rootfs/usr/share/man/man8/fsck.8.xz
But that file is already provided by package * e2fsprogs-doc
* check_data_file_clashes: Package util-linux-doc wants to install
file /data/poky-master/tmp/work/nuc-poky-linux/cor e-image-minimal/1.0-r0/rootfs/usr/share/man/man8/blkid.8.xz
But that file is already provided by package * e2fsprogs-doc
* opkg_install_cmd: Cannot install package util-linux-doc.

Quoted 8 lines

NOTE: Running intercept scripts:
NOTE: > Executing update_info_dir intercept ... /data/poky-master/tmp/work/nuc-poky-linux/core-image-minimal/1.0-r0/intercept_scripts/update_info_dir:
line 63: /insta
ll-info: No such file or directory /data/poky-master/tmp/work/nuc-poky-linux/core-image-minimal/1.0-r0/intercept_scripts/update_info_dir:
line 63: /insta
ll-info: No such file or directory

Thanks for testing, the error log shows STAGING_BINDIR_NATIVE is unset, but I could not reproduce it, could you paste more details about the config, such as
...
PACKAGE_CLASSES ?= "package_ipk"
EXTRA_IMAGE_FEATURES = "debug-tweaks doc-pkgs"
USER_CLASSES += "compress_doc"
DOC_COMPRESS = "xz"
...

bitbake core-image-minimal

//Hongxu

Quoted 61 lines

Ross

Quoted 58 lines · Hongxu Jia

Changed in V3:
- Remove Debian-specific code
- split() the INHERIT variable

Changed in V2:
- Conditionally add 'gzip/bzip2/xz' to man/info's RDEPENDS rather than modify busybox's defconfig.

- Refer Ubuntu to add a script to postinst_intercept to run it after all packages have been installed at build time.

Test Case:

vim local.conf
..
IMAGE_INSTALL_append = " man man-doc texinfo texinfo-doc info info-doc" INHERIT += "compress_doc"
DOC_COMPRESS = "xz" or DOC_COMPRESS = "bz2"
..

bitbake core-image-minimal

runqemu qemux86

On target,
...

root@qemux86:~# man man
root@qemux86:~# info info
...

//Hongxu

The following changes since commit 8ac8eca2e3bd8c78e2b31ea974930ed0243258a3:

   build-appliance-image: Update to dizzy head revision (2014-09-23 22:10:26 +0100)

are available in the git repository at:

git://git.pokylinux.org/poky-contrib hongxu/fix-doc
http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=hongxu/fix-doc

Hongxu Jia (4):
scripts/postinst-intercepts: add update_info_dir
texinfo: fix QA Error while doc compress enabled
texinfo: fix info not work
man/texinfo: conditionally add gzip/bzip2/xz to RDEPENDS

  meta/recipes-extended/man/man_1.6g.bb        | 13 +++++
  meta/recipes-extended/texinfo/texinfo_5.2.bb | 68 +++++++++++++++++++++++-
  scripts/postinst-intercepts/update_info_dir  | 77 ++++++++++++++++++++++++++++
  3 files changed, 157 insertions(+), 1 deletion(-)

create mode 100755 scripts/postinst-intercepts/update_info_dir

--
1.9.1

author
#7 lore raw
Quoted 5 lines · Hongxu Jia
Quoted 4 lines · Ross

Hi Hongxu,

This is failing for me, core-image-minimal for NUC with doc-pkgs:

And what NUC means? I am not familiar with is.

//Hongxu

Quoted 109 lines
Quoted 23 lines

Collected errors:
* check_data_file_clashes: Package util-linux-doc wants to install
file /data/poky-master/tmp/work/nuc-poky-linux/cor e-image-minimal/1.0-r0/rootfs/usr/share/man/man3/libblkid.3.xz
But that file is already provided by package * e2fsprogs-doc
* check_data_file_clashes: Package util-linux-doc wants to install
file /data/poky-master/tmp/work/nuc-poky-linux/cor e-image-minimal/1.0-r0/rootfs/usr/share/man/man8/findfs.8.xz
But that file is already provided by package * e2fsprogs-doc
* check_data_file_clashes: Package util-linux-doc wants to install
file /data/poky-master/tmp/work/nuc-poky-linux/cor e-image-minimal/1.0-r0/rootfs/usr/share/man/man8/fsck.8.xz
But that file is already provided by package * e2fsprogs-doc
* check_data_file_clashes: Package util-linux-doc wants to install
file /data/poky-master/tmp/work/nuc-poky-linux/cor e-image-minimal/1.0-r0/rootfs/usr/share/man/man8/blkid.8.xz
But that file is already provided by package * e2fsprogs-doc
* opkg_install_cmd: Cannot install package util-linux-doc.

NOTE: Running intercept scripts:
NOTE: > Executing update_info_dir intercept ... /data/poky-master/tmp/work/nuc-poky-linux/core-image-minimal/1.0-r0/intercept_scripts/update_info_dir:

Quoted 6 lines

line 63: /insta
ll-info: No such file or directory /data/poky-master/tmp/work/nuc-poky-linux/core-image-minimal/1.0-r0/intercept_scripts/update_info_dir:

line 63: /insta
ll-info: No such file or directory

Thanks for testing, the error log shows STAGING_BINDIR_NATIVE is unset, but I could not reproduce it, could you paste more details about the config, such as
...
PACKAGE_CLASSES ?= "package_ipk"
EXTRA_IMAGE_FEATURES = "debug-tweaks doc-pkgs"
USER_CLASSES += "compress_doc"
DOC_COMPRESS = "xz"
...

bitbake core-image-minimal

//Hongxu

Quoted 64 lines

Ross

Quoted 61 lines · Hongxu Jia

Changed in V3:
- Remove Debian-specific code
- split() the INHERIT variable

Changed in V2:
- Conditionally add 'gzip/bzip2/xz' to man/info's RDEPENDS rather than modify busybox's defconfig.

- Refer Ubuntu to add a script to postinst_intercept to run it after all packages have been installed at build time.

Test Case:

vim local.conf
..
IMAGE_INSTALL_append = " man man-doc texinfo texinfo-doc info info-doc" INHERIT += "compress_doc"
DOC_COMPRESS = "xz" or DOC_COMPRESS = "bz2"
..

bitbake core-image-minimal

runqemu qemux86

On target,
...

root@qemux86:~# man man
root@qemux86:~# info info
...

//Hongxu

The following changes since commit 8ac8eca2e3bd8c78e2b31ea974930ed0243258a3:

build-appliance-image: Update to dizzy head revision (2014-09-23
22:10:26 +0100)

are available in the git repository at:

git://git.pokylinux.org/poky-contrib hongxu/fix-doc
http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=hongxu/fix-doc

Hongxu Jia (4):
scripts/postinst-intercepts: add update_info_dir
texinfo: fix QA Error while doc compress enabled
texinfo: fix info not work
man/texinfo: conditionally add gzip/bzip2/xz to RDEPENDS

  meta/recipes-extended/man/man_1.6g.bb        | 13 +++++
  meta/recipes-extended/texinfo/texinfo_5.2.bb | 68 
+++++++++++++++++++++++-
  scripts/postinst-intercepts/update_info_dir  | 77 
++++++++++++++++++++++++++++
  3 files changed, 157 insertions(+), 1 deletion(-)

create mode 100755 scripts/postinst-intercepts/update_info_dir

Signature · 1 line
1.9.1
author
#8 lore raw
Quoted 9 lines · Hongxu Jia
Quoted 5 lines · Hongxu Jia
Quoted 4 lines · Ross

Hi Hongxu,

This is failing for me, core-image-minimal for NUC with doc-pkgs:

And what NUC means? I am not familiar with is.

Oh, it is a intel BSP located in yocto/meta-intel/meta-nuc.

//Hongxu

Quoted 112 lines

//Hongxu

Quoted 109 lines
Quoted 23 lines

Collected errors:
* check_data_file_clashes: Package util-linux-doc wants to install
file /data/poky-master/tmp/work/nuc-poky-linux/cor e-image-minimal/1.0-r0/rootfs/usr/share/man/man3/libblkid.3.xz
But that file is already provided by package * e2fsprogs-doc
* check_data_file_clashes: Package util-linux-doc wants to install
file /data/poky-master/tmp/work/nuc-poky-linux/cor e-image-minimal/1.0-r0/rootfs/usr/share/man/man8/findfs.8.xz
But that file is already provided by package * e2fsprogs-doc
* check_data_file_clashes: Package util-linux-doc wants to install
file /data/poky-master/tmp/work/nuc-poky-linux/cor e-image-minimal/1.0-r0/rootfs/usr/share/man/man8/fsck.8.xz
But that file is already provided by package * e2fsprogs-doc
* check_data_file_clashes: Package util-linux-doc wants to install
file /data/poky-master/tmp/work/nuc-poky-linux/cor e-image-minimal/1.0-r0/rootfs/usr/share/man/man8/blkid.8.xz
But that file is already provided by package * e2fsprogs-doc
* opkg_install_cmd: Cannot install package util-linux-doc.

NOTE: Running intercept scripts:
NOTE: > Executing update_info_dir intercept ... /data/poky-master/tmp/work/nuc-poky-linux/core-image-minimal/1.0-r0/intercept_scripts/update_info_dir:

Quoted 6 lines

line 63: /insta
ll-info: No such file or directory /data/poky-master/tmp/work/nuc-poky-linux/core-image-minimal/1.0-r0/intercept_scripts/update_info_dir:

line 63: /insta
ll-info: No such file or directory

Thanks for testing, the error log shows STAGING_BINDIR_NATIVE is unset, but I could not reproduce it, could you paste more details about the config, such as
...
PACKAGE_CLASSES ?= "package_ipk"
EXTRA_IMAGE_FEATURES = "debug-tweaks doc-pkgs"
USER_CLASSES += "compress_doc"
DOC_COMPRESS = "xz"
...

bitbake core-image-minimal

//Hongxu

Quoted 64 lines

Ross

Quoted 61 lines · Hongxu Jia

Changed in V3:
- Remove Debian-specific code
- split() the INHERIT variable

Changed in V2:
- Conditionally add 'gzip/bzip2/xz' to man/info's RDEPENDS rather than modify busybox's defconfig.

- Refer Ubuntu to add a script to postinst_intercept to run it after all packages have been installed at build time.

Test Case:

vim local.conf
..
IMAGE_INSTALL_append = " man man-doc texinfo texinfo-doc info info-doc" INHERIT += "compress_doc"
DOC_COMPRESS = "xz" or DOC_COMPRESS = "bz2"
..

bitbake core-image-minimal

runqemu qemux86

On target,
...

root@qemux86:~# man man
root@qemux86:~# info info
...

//Hongxu

The following changes since commit 8ac8eca2e3bd8c78e2b31ea974930ed0243258a3:

build-appliance-image: Update to dizzy head revision (2014-09-23
22:10:26 +0100)

are available in the git repository at:

git://git.pokylinux.org/poky-contrib hongxu/fix-doc
http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=hongxu/fix-doc

Hongxu Jia (4):
scripts/postinst-intercepts: add update_info_dir
texinfo: fix QA Error while doc compress enabled
texinfo: fix info not work
man/texinfo: conditionally add gzip/bzip2/xz to RDEPENDS

  meta/recipes-extended/man/man_1.6g.bb        | 13 +++++
  meta/recipes-extended/texinfo/texinfo_5.2.bb | 68 
+++++++++++++++++++++++-
  scripts/postinst-intercepts/update_info_dir  | 77 
++++++++++++++++++++++++++++
  3 files changed, 157 insertions(+), 1 deletion(-)

create mode 100755 scripts/postinst-intercepts/update_info_dir

Signature · 1 line
1.9.1
author
#9 lore raw
In reply to Burton, Ross

I could reproduce it now, and am working on it, v4 incoming

//Hongxu

Quoted 93 lines · Ross

Hi Hongxu,

This is failing for me, core-image-minimal for NUC with doc-pkgs:

Collected errors:
* check_data_file_clashes: Package util-linux-doc wants to install
file /data/poky-master/tmp/work/nuc-poky-linux/cor e-image-minimal/1.0-r0/rootfs/usr/share/man/man3/libblkid.3.xz
But that file is already provided by package * e2fsprogs-doc
* check_data_file_clashes: Package util-linux-doc wants to install
file /data/poky-master/tmp/work/nuc-poky-linux/cor e-image-minimal/1.0-r0/rootfs/usr/share/man/man8/findfs.8.xz
But that file is already provided by package * e2fsprogs-doc
* check_data_file_clashes: Package util-linux-doc wants to install
file /data/poky-master/tmp/work/nuc-poky-linux/cor e-image-minimal/1.0-r0/rootfs/usr/share/man/man8/fsck.8.xz
But that file is already provided by package * e2fsprogs-doc
* check_data_file_clashes: Package util-linux-doc wants to install
file /data/poky-master/tmp/work/nuc-poky-linux/cor e-image-minimal/1.0-r0/rootfs/usr/share/man/man8/blkid.8.xz
But that file is already provided by package * e2fsprogs-doc
* opkg_install_cmd: Cannot install package util-linux-doc.

NOTE: Running intercept scripts:
NOTE: > Executing update_info_dir intercept ... /data/poky-master/tmp/work/nuc-poky-linux/core-image-minimal/1.0-r0/intercept_scripts/update_info_dir:
line 63: /insta
ll-info: No such file or directory /data/poky-master/tmp/work/nuc-poky-linux/core-image-minimal/1.0-r0/intercept_scripts/update_info_dir:
line 63: /insta
ll-info: No such file or directory

Ross

Quoted 58 lines · Hongxu Jia

Changed in V3:
- Remove Debian-specific code
- split() the INHERIT variable

Changed in V2:
- Conditionally add 'gzip/bzip2/xz' to man/info's RDEPENDS rather than modify busybox's defconfig.

- Refer Ubuntu to add a script to postinst_intercept to run it after all packages have been installed at build time.

Test Case:

vim local.conf
..
IMAGE_INSTALL_append = " man man-doc texinfo texinfo-doc info info-doc" INHERIT += "compress_doc"
DOC_COMPRESS = "xz" or DOC_COMPRESS = "bz2"
..

bitbake core-image-minimal

runqemu qemux86

On target,
...

root@qemux86:~# man man
root@qemux86:~# info info
...

//Hongxu

The following changes since commit 8ac8eca2e3bd8c78e2b31ea974930ed0243258a3:

   build-appliance-image: Update to dizzy head revision (2014-09-23 22:10:26 +0100)

are available in the git repository at:

git://git.pokylinux.org/poky-contrib hongxu/fix-doc
http://git.pokylinux.org/cgit.cgi/poky-contrib/log/?h=hongxu/fix-doc

Hongxu Jia (4):
scripts/postinst-intercepts: add update_info_dir
texinfo: fix QA Error while doc compress enabled
texinfo: fix info not work
man/texinfo: conditionally add gzip/bzip2/xz to RDEPENDS

  meta/recipes-extended/man/man_1.6g.bb        | 13 +++++
  meta/recipes-extended/texinfo/texinfo_5.2.bb | 68 +++++++++++++++++++++++-
  scripts/postinst-intercepts/update_info_dir  | 77 ++++++++++++++++++++++++++++
  3 files changed, 157 insertions(+), 1 deletion(-)

create mode 100755 scripts/postinst-intercepts/update_info_dir

--
1.9.1