<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugzilla.yoctoproject.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.6"
          urlbase="https://bugzilla.yoctoproject.org/"
          
          maintainer="it-coreprojects-helpdesk@linuxfoundation.org"
>

    <bug>
          <bug_id>14864</bug_id>
          
          <creation_ts>2022-07-15 18:21:36 +0000</creation_ts>
          <short_desc>gpsd fails to include python utilities</short_desc>
          <delta_ts>2022-07-21 15:03:31 +0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>7</classification_id>
          <classification>Build System, Metadata &amp; Runtime</classification>
          <product>OE-Core</product>
          <component>oe-core other</component>
          <version>3.1.20</version>
          <rep_platform>x86</rep_platform>
          <op_sys>Multiple</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>INVALID</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>Undecided</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter name="Matt Woelfel">matthew.woelfel</reporter>
          <assigned_to name="Unassigned">unassigned</assigned_to>
          <cc>randy.macleod</cc>
    
    <cc>tim.orling</cc>
          
          
          <cf_os>---</cf_os>
          <cf_regression_type>---</cf_regression_type>
          
          <cf_docchange>No (bug/feature does not impact docs)</cf_docchange>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>93676</commentid>
    <comment_count>0</comment_count>
    <who name="Matt Woelfel">matthew.woelfel</who>
    <bug_when>2022-07-15 18:21:36 +0000</bug_when>
    <thetext>Preconditions/Environment
-------------------------
I&apos;m using Fedora 36. The build environment is crops/yocto.

Triggering Action/Cause
-----------------------
# checkout the dunfell branch of poky
git clone https://github.com/yoctoproject/poky.git -b dunfell
# enter a crops container
podman run --userns=keep-id --rm -it -v $HOME:$HOME -w $PWD/poky crops/yocto:centos-8-base /bin/bash
# setup the environment
source oe-init-build-env
bitbake-layers layerindex-fetch meta-oe
echo IMAGE_INSTALL_append += \&quot; gpsd\&quot; &gt;&gt; conf/local.conf
# build
bitbake gpsd -v

Expectation
-----------
gspfake, gpscat, and other utilities should be available.

Actual Result
-------------
Building gpsd seems to miss finding python and omits the python utilities from the build:

python = False (default True): build Python support and modules.

Adding a custom layer with a gpsd_3.19.bbappend that contains:

EXTRA_OESCONS += &quot; target_python=python3&quot;

enables python to be found, but the path in the include flag is messed up for gpsd to find Python.h:

Checking whether python3 program exists.../home/matt/poky/build/tmp/work/core2-64-poky-linux/gpsd/3.19-r0/recipe-sysroot-native/usr/bin/python3-native/python3
Obtaining Python exe path... 
yes

Obtaining Python lib dir... 
yes

Obtaining Python config vars... 
ok
...
gcc -pthread -o gpspacket-py_3_8_13_final_0.cpython-38-x86_64-linux-gnu.so -c -Wno-unused-result -Wsign-compare -fPIC -DNDEBUG -g -O3 -Wall -I/home/matt/poky/build/tmp/work/core2-64-poky-linux/gpsd/3.19-r0/recipe-sysroot/usr/include/home/matt/poky/build/tmp/work/core2-64-poky-linux/gpsd/3.19-r0/recipe-sysroot-native/usr/include/python3.8 gpspacket.c

gpspacket.c:20:10: fatal error: Python.h: No such file or directory
   20 | #include &lt;Python.h&gt;


Reproducibility
---------------
10/10

I tried a native host and several flavors of crops such as Ubuntu 18.04 and 20.04 with the same results each time.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>93685</commentid>
    <comment_count>1</comment_count>
    <who name="Randy MacLeod">randy.macleod</who>
    <bug_when>2022-07-21 14:36:38 +0000</bug_when>
    <thetext>gpsd is in meta-oe so it&apos;s not covered by this bugzilla:
   https://layers.openembedded.org/layerindex/recipe/1120/
but we hear that it works on kirkstone so take a look there and 
ask for help on the meta-oe email list if required. 

Thanks for the clear bug report anyhow -- YP Bug Review</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>93686</commentid>
    <comment_count>2</comment_count>
    <who name="Tim Orling">tim.orling</who>
    <bug_when>2022-07-21 14:40:26 +0000</bug_when>
    <thetext>Looks like the commit that fixed this on kirkstone was:
http://cgit.openembedded.org/meta-openembedded/commit/meta-oe/recipes-navigation/gpsd/gpsd_3.23.1.bb?h=kirkstone&amp;id=64156a6f8f3b4527c4732c91936aee0a167acb48

You can do something similar in a bbappend if you must use dunfell.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>93690</commentid>
    <comment_count>3</comment_count>
    <who name="Matt Woelfel">matthew.woelfel</who>
    <bug_when>2022-07-21 15:03:31 +0000</bug_when>
    <thetext>(In reply to comment #1)
&gt; gpsd is in meta-oe so it&apos;s not covered by this bugzilla:
&gt;    https://layers.openembedded.org/layerindex/recipe/1120/
&gt; but we hear that it works on kirkstone so take a look there and 
&gt; ask for help on the meta-oe email list if required. 
&gt; 
&gt; Thanks for the clear bug report anyhow -- YP Bug Review

Thanks for pointing me in the right direction. I&apos;ll ask on the mailing list.</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>