Error creating recipe for Perl DBI for postgresql in Kirkstone


Fernando Luiz Cola
 

Hello, I'm trying to write a recipe a Perl DBI for postgresql. I'm follwing the same recipe found in: 
https://layers.openembedded.org/layerindex/recipe/192563/  and https://layers.openembedded.org/layerindex/recipe/190989
Howover I'm having errors regarding db_config path, which cannot be found during the do_configure
here is my following recipe:  https://gist.github.com/ferlzc/9234ccd5c5a084f958ff52c7a08899a9 - I'm using Yocto Kirkstone

Any help is highly appreciated!
 


Tim Orling
 



On Tue, Dec 20, 2022 at 12:28 PM Fernando Luiz Cola <ferlzc@...> wrote:
Hello, I'm trying to write a recipe a Perl DBI for postgresql. I'm follwing the same recipe found in: 
https://layers.openembedded.org/layerindex/recipe/192563/  and https://layers.openembedded.org/layerindex/recipe/190989
Howover I'm having errors regarding db_config path, which cannot be found during the do_configure
here is my following recipe:  https://gist.github.com/ferlzc/9234ccd5c5a084f958ff52c7a08899a9 - I'm using Yocto Kirkstone

Any help is highly appreciated!

There are several layers of problems here.

export POSTGRES_INCLUDE="${STAGING_INCDIR}"
export POSTGERS_LIB="${STAGING_LIBDIR}"

But, even with that, do_config will fail to find the postgres version. It depends on https://metacpan.org/pod/App::Info::RDBMS::PostgreSQL to find it, and we do not have a recipe for that? (even if we did it is probably going to be wrong... not cross-compilation). There is another variable POSTGRES_DATA, but it is not clear what the structure/value of that should be.

Also, there is no native version/recipe of postgresql. In theory you could use that to be able to run /usr/bin/pg_config, but there are likely to be cross-compilation errors elsewhere.
(The lack of postgresql-native also means BBCLASSEXTEND = "native" in your libdbd-postgresql-perl recipe is a lie).

Short answer: this is not cross-compilation friendly