Bug 12768 - Please place them into pkg_postinst_ontarget_${PN} ()
Summary: Please place them into pkg_postinst_ontarget_${PN} ()
Status: RESOLVED FIXED
Alias: None
Product: OE-Core
Classification: Build System, Metadata & Runtime
Component: core (show other bugs)
Version: 2.5.1
Hardware: x86 Multiple
: Medium normal
Target Milestone: 2.6 M2
Assignee: Robert Berger
QA Contact:
URL:
Whiteboard:
Depends on:
Blocks:
 
Reported: 2018-06-03 16:57 UTC by Robert Berger
Modified: 2018-07-16 20:45 UTC (History)
4 users (show)

See Also:
OS type for building Yocto: ---
Type of Regression: ---
Verified:
Documentation change: Don't know


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Robert Berger 2018-06-03 16:57:40 UTC
I see this in my build logs:

WARNING: custom-packagegroup-image-1.0-r0 do_rootfs: sysvinit-inittab.postinst returned 1, marking as unpacked only, configuration required on target.
WARNING: custom-packagegroup-image-1.0-r0 do_rootfs: Intentionally failing postinstall scriptlets of ['sysvinit-inittab'] to defer them to first boot is deprecated. Please place them into pkg_postinst_ontarget_${PN} ().
If deferring to first boot wasn't the intent, then scriptlet failure may mean an issue in the recipe, or a regression elsewhere.
Details of the failure are in /tmp/yocto-autobuilder/yocto-autobuilder/yocto-worker/res-custom-sumo-multi-v7-core-image-minimal/build/build/tmp/work/multi_v7_ml-poky-linux-gnueabi/custom-packagegroup-image/1.0-r0/temp/log.do_rootfs.
WARNING: custom-packagegroup-image-1.0-r0 do_rootfs: sysvinit-inittab.postinst returned 1, marking as unpacked only, configuration required on target.
WARNING: custom-packagegroup-image-1.0-r0 do_rootfs: Intentionally failing postinstall scriptlets of ['sysvinit-inittab'] to defer them to first boot is deprecated. Please place them into pkg_postinst_ontarget_${PN} ().
If deferring to first boot wasn't the intent, then scriptlet failure may mean an issue in the recipe, or a regression elsewhere.
Details of the failure are in /tmp/yocto-autobuilder/yocto-autobuilder/yocto-worker/res-custom-sumo-multi-v7-core-image-minimal/build/build/tmp/work/multi_v7_ml-poky-linux-gnueabi/custom-packagegroup-image/1.0-r0/temp/log.do_rootfs.
WARNING: custom-packagegroup-image-1.0-r0 do_rootfs: [log_check] custom-packagegroup-image: found 2 warning messages in the logfile:
[log_check] WARNING: Intentionally failing postinstall scriptlets of ['sysvinit-inittab'] to defer them to first boot is deprecated. Please place them into pkg_postinst_ontarget_${PN} ().
[log_check] WARNING: Intentionally failing postinstall scriptlets of ['sysvinit-inittab'] to defer them to first boot is deprecated. Please place them into pkg_postinst_ontarget_${PN} ().

since I don't do anything special about sysvinit except for this bbappend

# use runlevel 3 instead of 5 and
# replace funny /bin/getty script with /sbin/getty
do_install_append() {
        sed -i 's/^id:5:initdefault/id:3:initdefault/' ${D}${sysconfdir}/inittab
}

I am not sure if it's me who caused this.
Comment 1 Robert Berger 2018-06-03 17:00:27 UTC
boot log on first boot:

Configuring packages on first boot....
 (This may take several minutes. Please do not power off the machine.)
Running postinst /etc/ipk-postinsts/000-sysvinit-inittab...
update-rc.d: /etc/init.d/run-postinsts exists during rc.d purge (continuing)
 Removing any system startup links for run-postinsts ...
  /etc/rcS.d/S99run-postinsts
INIT: Entering runlevel: 3
Comment 2 Alexander Kanavin 2018-06-08 09:39:55 UTC
I'm certain that this patch should simply be backported:

http://git.yoctoproject.org/cgit/cgit.cgi/poky/commit/?id=524e84028eccf8b2077f356efa96aba897e3e183

Robert, can you confirm that it fixes the issue and if so, send the backport to the oe-core list please?
Comment 3 Robert Berger 2018-06-20 05:54:38 UTC
It looks like the patch made it into oe-core sumo-next[1]

[1] http://cgit.openembedded.org/openembedded-core/commit/?h=sumo-next&id=f9f045ce9cbd441375f15911f3535cb1e304ba5b

So I am not sure where to backport it to.

I added it to my local copy of poky and will test it locally.
Comment 4 Robert Berger 2018-07-16 20:45:16 UTC
It looks like the patch made it into oe-core sumo-next[1]

[1] http://cgit.openembedded.org/openembedded-core/commit/?h=sumo-next&id=f9f045ce9cbd441375f15911f3535cb1e304ba5b

and my local tests look good