Skip to contentSkip to conversation

do_install() is not getting called

DISCUSSION hari kumar 2 participants 3 messages Nov 8, 2014 – Nov 10, 2014

lore
Share & tools
lore

hari kumar

author
#0 lore raw

Hi All,

I am creating a new recipe in bsp layer. So I created a bb file inside the recipe.
Then from the build directory, I am able to successfully compile the source files and was able to create the library ( bitbake -c compile -f <package_name> ). This is a makefile based package and I don't have an install target in my Makefile. So I am writing a do_install in my bb file and I am doing install there. I can see that do_compile task is getting called. But do_install ( which was overridden in my bb file ) task is not called and the images and libraries are not installed in the sysroots directory.

Bitbake Snippet :

SRC_URI = "file://src/"

PV = "1.0"

S = "${WORKDIR}/src/"

EXTRA_OEMAKE = "CFLAGS=--sysroot=${PKG_CONFIG_SYSROOT_DIR} 'LDFLAGS=-lpthread -lrt ${LDFLAGS}'"

do_install () {
oe_runmake install DESTDIR=${D} SBINDIR=${sbindir} MANDIR=${mandir} INCLUDEDIR=${includedir}

       install -d ${D}${includedir}/

for f in ${S}/*.h; do install -m 0644 $f ${D}${includedir}/ done }
PARALLEL_MAKE = ""
#BBCLASSEXTEND = "native"

Could you please suggest why do_install is not getting called for this Makefile based system ?

#1 lore raw

Am 08.11.2014 13:10 schrieb "hari kumar" <[email protected]>:

Quoted 4 lines

Hi All,

I am creating a new recipe in bsp layer. So I created a bb file inside

the recipe.

Quoted 1 line

Then from the build directory, I am able to successfully compile the

source files and was able to create the library ( bitbake -c compile -f <package_name> ). This is a makefile based package and I don't have an install target in my Makefile. So I am writing a do_install in my bb file and I am doing install there. I can see that do_compile task is getting called. But do_install ( which was overridden in my bb file ) task is not called and the images and libraries are not installed in the sysroots directory.

Quoted 1 line

By running bitbake -f -c compile the do_install is not called. Either you call bitbacke package_name or to force install butbake -c install.

Sometime a clean or cleanall before a compile also helps. This is needed if you already had a successfull run.

Regards
Christian

Quoted 9 lines

Bitbake Snippet :

SRC_URI = "file://src/"

PV = "1.0"

S = "${WORKDIR}/src/"

EXTRA_OEMAKE = "CFLAGS=--sysroot=${PKG_CONFIG_SYSROOT_DIR}

'LDFLAGS=-lpthread -lrt ${LDFLAGS}'"

Quoted 3 lines

do_install () {
oe_runmake install DESTDIR=${D} SBINDIR=${sbindir} MANDIR=${mandir}

INCLUDEDIR=${includedir}

Quoted 11 lines
       install -d ${D}${includedir}/

       for f in ${S}/*.h; do
           install -m 0644 $f ${D}${includedir}/
       done

}
PARALLEL_MAKE = ""
#BBCLASSEXTEND = "native"

Could you please suggest why do_install is not getting called for this

Makefile based system ?

Quoted 7 lines

--
_______________________________________________
yocto mailing list
[email protected]
https://lists.yoctoproject.org/listinfo/yocto

author
#2 lore raw

Thanks Christian. It worked. I gave bitbake -c install to install it.

Regards
Hari

On Saturday, 8 November 2014 6:00 PM, Christian Ege <[email protected]> wrote:

Am 08.11.2014 13:10 schrieb "hari kumar" <[email protected]>:

Quoted 6 lines

Hi All,

I am creating a new recipe in bsp layer. So I created a bb file inside the recipe.
Then from the build directory, I am able to successfully compile the source files and was able to create the library ( bitbake -c compile -f <package_name> ). This is a makefile based package and I don't have an install target in my Makefile. So I am writing a do_install in my bb file and I am doing install there. I can see that do_compile task is getting called. But do_install ( which was overridden in my bb file ) task is not called and the images and libraries are not installed in the sysroots directory.

By running bitbake -f -c compile the do_install is not called. Either you call bitbacke package_name or to force install butbake -c install. Sometime a clean or cleanall before a compile also helps. This is needed if you already had a successfull run. Regards
Christian

Quoted 30 lines

Bitbake Snippet :

SRC_URI = "file://src/"

PV = "1.0"

S = "${WORKDIR}/src/"

EXTRA_OEMAKE = "CFLAGS=--sysroot=${PKG_CONFIG_SYSROOT_DIR} 'LDFLAGS=-lpthread -lrt ${LDFLAGS}'"

do_install () {
oe_runmake install DESTDIR=${D} SBINDIR=${sbindir} MANDIR=${mandir} INCLUDEDIR=${includedir}

       install -d ${D}${includedir}/

	       for f in ${S}/*.h; do
	     	      install -m 0644 $f ${D}${includedir}/
	       done

}
PARALLEL_MAKE = ""
#BBCLASSEXTEND = "native"

Could you please suggest why do_install is not getting called for this Makefile based system ?

--
_______________________________________________
yocto mailing list
[email protected]
https://lists.yoctoproject.org/listinfo/yocto

Signature · 4 lines
_______________________________________________
yocto mailing list
[email protected]
https://lists.yoctoproject.org/listinfo/yocto