Skip to contentSkip to conversation

rootfs postprocess command

PATCH In review Chris Conroy 2 participants 2 messages Sep 16, 2009 – Sep 17, 2009

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 rootfs postprocess command

I ran into a problem yesterday where the ROOTFS_POSTPROCESS_COMMAND started failing after I turned off ONLINE_PACKAGE_MANAGEMENT. It seems the problem is that if package management is turned off, then the opkg directory gets deleted. Subsequent opkg commands in the ROOTFS_POSTPROCESS_COMMAND fail to open the lock file because the directory is gone.

This patch simply moves the postprocess command above the destruction of the opkg directory to allow any such commands to complete successfully.

classes/rootfs_ipk.bbclass +2 -2
index 16dd511..9231787 100644
@@ -81,6 +81,8 @@ fakeroot rootfs_ipk_do_rootfs () {
        install -d ${IMAGE_ROOTFS}/${sysconfdir}
        echo ${BUILDNAME} > ${IMAGE_ROOTFS}/${sysconfdir}/version
 
+       ${ROOTFS_POSTPROCESS_COMMAND}
+       
        if [ "${ONLINE_PACKAGE_MANAGEMENT}" != "none" ]; then
                if [ "${ONLINE_PACKAGE_MANAGEMENT}" == "add" ]; then
                        rm -f ${IMAGE_ROOTFS}${libdir}/opkg/status
@@ -97,8 +99,6 @@ fakeroot rootfs_ipk_do_rootfs () {
                rm -rf ${IMAGE_ROOTFS}/usr/lib/opkg
        fi
        
-       ${ROOTFS_POSTPROCESS_COMMAND}
-       
        log_check rootfs        
 }
 
#1 lore raw

+1

Quoted 38 lines · Chris Conroy

I ran into a problem yesterday where the ROOTFS_POSTPROCESS_COMMAND started failing after I turned off ONLINE_PACKAGE_MANAGEMENT. It seems the problem is that if package management is turned off, then the opkg directory gets deleted. Subsequent opkg commands in the ROOTFS_POSTPROCESS_COMMAND fail to open the lock file because the directory is gone.

This patch simply moves the postprocess command above the destruction of the opkg directory to allow any such commands to complete successfully.

classes/rootfs_ipk.bbclass +0 -0
index 16dd511..9231787 100644
@@ -81,6 +81,8 @@ fakeroot rootfs_ipk_do_rootfs () {
        install -d ${IMAGE_ROOTFS}/${sysconfdir}

       echo ${BUILDNAME} > ${IMAGE_ROOTFS}/${sysconfdir}/version

+       ${ROOTFS_POSTPROCESS_COMMAND}
+
       if [ "${ONLINE_PACKAGE_MANAGEMENT}" != "none" ]; then if [ "${ONLINE_PACKAGE_MANAGEMENT}" == "add" ]; then rm -f ${IMAGE_ROOTFS}${libdir}/opkg/status

classes/rootfs_ipk.bbclass +0 -0
@@ -97,8 +99,6 @@ fakeroot rootfs_ipk_do_rootfs () {

               rm -rf ${IMAGE_ROOTFS}/usr/lib/opkg fi

-       ${ROOTFS_POSTPROCESS_COMMAND}
-
       log_check rootfs
 }

_______________________________________________
Openembedded-devel mailing list
[email protected]
http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-devel

Signature · 3 lines
Otavio Salvador                  O.S. Systems
E-mail: [email protected]  http://www.ossystems.com.br
Mobile: +55 53 9981-7854         http://projetos.ossystems.com.br