<?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>12612</bug_id>
          
          <creation_ts>2018-03-19 10:23:44 +0000</creation_ts>
          <short_desc>insane.bbclass: check for bashisms in packaged scripts</short_desc>
          <delta_ts>2026-08-13 15:13:46 +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>core</component>
          <version>unspecified</version>
          <rep_platform>All</rep_platform>
          <op_sys>Multiple</op_sys>
          <bug_status>UNCONFIRMED</bug_status>
          <resolution></resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard> </status_whiteboard>
          <keywords></keywords>
          <priority>Medium</priority>
          <bug_severity>enhancement</bug_severity>
          <target_milestone>6.99</target_milestone>
          
          
          <everconfirmed>0</everconfirmed>
          <reporter name="Joshua Watt">JPEWhacker</reporter>
          <assigned_to name="Joshua Watt">JPEWhacker</assigned_to>
          <cc>meta.mr.watcher</cc>
    
    <cc>meta.watcher</cc>
    
    <cc>randy.macleod</cc>
    
    <cc>ross.burton</cc>
    
    <cc>stephano</cc>
          
          
          <cf_os>---</cf_os>
          <cf_regression_type>---</cf_regression_type>
          
          <cf_docchange>Yes (doc changes required)</cf_docchange>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>79855</commentid>
    <comment_count>0</comment_count>
    <who name="Joshua Watt">JPEWhacker</who>
    <bug_when>2018-03-19 10:23:44 +0000</bug_when>
    <thetext>Add a QA check to verify that scripts do not contain bashisms. The Debian checkbashisms.pl script already covers this sufficiently, as it can distinguish between 3 cases:
 1) A script with #! /bin/sh that uses bashisms (BAD)
 2) A script with #! /bin/bash that uses bashisms (OK)
 3) A script with #! /bin/bash that doesn&apos;t use bashisms (OK)

At a minimum, an ERROR should be produced if #1 is encountered. We could also issue a WARNING for #3, but that is not as much of an issue.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>79856</commentid>
    <comment_count>1</comment_count>
    <who name="Ross Burton">ross.burton</who>
    <bug_when>2018-03-19 10:27:04 +0000</bug_when>
    <thetext>IMHO, far too invasive/slow to run on every parse.

oe-core has verify-bashisms which will run all shell bits in recipes through checkbashisms.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>79857</commentid>
    <comment_count>2</comment_count>
    <who name="Joshua Watt">JPEWhacker</who>
    <bug_when>2018-03-19 11:34:54 +0000</bug_when>
    <thetext>Sorry, maybe it wasn&apos;t clear, this was intended to be a QA check for on-target installed files, not bitbake metadata scripts (which is what verify-bashisms appears to be checking?). I found 

https://bugzilla.yoctoproject.org/show_bug.cgi?id=8851

did that also evaluate the performance impact of a QA check (I didn&apos;t find anything like that in the comments)? If not, I can do some evaluation to see what the impact would be on the do_package_qa step.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>79934</commentid>
    <comment_count>3</comment_count>
    <who name="Ross Burton">ross.burton</who>
    <bug_when>2018-03-22 10:25:44 +0000</bug_when>
    <thetext>Ah, right.  Reopening.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>96951</commentid>
    <comment_count>4</comment_count>
    <who name="Randy MacLeod">randy.macleod</who>
    <bug_when>2023-10-24 14:24:50 +0000</bug_when>
    <thetext>Bulk move from 4.99 or 0.00 to 5.99</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>106524</commentid>
    <comment_count>5</comment_count>
    <who name="Randy MacLeod">randy.macleod</who>
    <bug_when>2026-08-13 15:13:46 +0000</bug_when>
    <thetext>We could put the code in but leave it disabled by default for developers to use as needed.</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>