<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "http://bugs.gentoo.org/bugzilla.dtd">

<bugzilla version="2.22.7"
          urlbase="http://bugs.gentoo.org/"
          maintainer="bugzilla@gentoo.org"
>

    <bug>
          <bug_id>158540</bug_id>
          
          <creation_ts>2006-12-19 05:56 0000</creation_ts>
          <short_desc>net-misc/dhcp-3.0.5 - dhclient-script requires /bin/bash</short_desc>
          <delta_ts>2006-12-20 04:36:17 0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>1</classification_id>
          <classification>Unclassified</classification>
          <product>Gentoo Linux</product>
          <component>Core system</component>
          <version>unspecified</version>
          <rep_platform>All</rep_platform>
          <op_sys>Linux</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          
          
          <priority>P2</priority>
          <bug_severity>minor</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          
          <everconfirmed>1</everconfirmed>
          <reporter>qb4w0p7r02@sneakemail.com</reporter>
          <assigned_to>uberlord@gentoo.org</assigned_to>
          

      

      
          <long_desc isprivate="0">
            <who>qb4w0p7r02@sneakemail.com</who>
            <bug_when>2006-12-19 05:56:35 0000</bug_when>
            <thetext>The script shebang is 

#!/bin/bash

and should be  

#!/bin/sh

Otherwise, if bash isn&apos;t installed (as is generally the case on embedded builds) dhclient fails with &quot;file not found&quot;

Not a biggie, but I thought you might like it logged.</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>jakub@gentoo.org</who>
            <bug_when>2006-12-19 07:03:42 0000</bug_when>
            <thetext>Reopen with exact ebuild name and version; assuming that everyone uses some weirdo busybox stuff plain doesn&apos;t work... No idea what&apos;s this about.</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>qb4w0p7r02@sneakemail.com</who>
            <bug_when>2006-12-19 08:41:23 0000</bug_when>
            <thetext>sorry. package is net-misc/dhcp-3.0.5

file is /sbin/dhclient-script

&gt; assuming that everyone uses some weirdo busybox stuff plain doesn&apos;t work...

Charmed, I&apos;m sure.

The script starts with &quot;#!/bin/bash&quot; which will break on any system that doesn&apos;t have bash installed. On the other hand &quot;#!/bin/sh&quot; should work for anything that&apos;s Bourne shell based.
</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>uberlord@gentoo.org</who>
            <bug_when>2006-12-19 09:05:33 0000</bug_when>
            <thetext>(In reply to comment #0)
&gt; Otherwise, if bash isn&apos;t installed (as is generally the case on embedded
&gt; builds) dhclient fails with &quot;file not found&quot;

That&apos;s a fair point, but on on embedded systems then udhcpc or dhcpcd would be used as ISC&apos;s dhcp is very bloated :)

# ls -l /sbin/{dhcpcd,dhclient,pump,udhcp*}
-rwxr-xr-x 1 root root 358640 2006-11-06 09:29 /sbin/dhclient
-rwxr-xr-x 1 root root  38312 2006-12-19 12:01 /sbin/dhcpcd
-rwxr-xr-x 1 root root  60216 2006-06-16 16:39 /sbin/pump
lrwxrwxrwx 1 root root      6 2006-07-25 21:49 /sbin/udhcpc -&gt; udhcpd
-rwxr-xr-x 1 root root  27672 2006-07-25 21:49 /sbin/udhcpd
</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>uberlord@gentoo.org</who>
            <bug_when>2006-12-19 09:07:56 0000</bug_when>
            <thetext>(In reply to comment #2)
&gt; The script starts with &quot;#!/bin/bash&quot; which will break on any system that
&gt; doesn&apos;t have bash installed. On the other hand &quot;#!/bin/sh&quot; should work for
&gt; anything that&apos;s Bourne shell based.

Not entirely accurate - if bash is invoked by #!/bin/sh then it turns off all non POSIX functions, which is a fair bit. Luckily dhclient-script doesn&apos;t use any of that, so I&apos;ll update it in one of the ~ARCH versions.</thetext>
          </long_desc>
          <long_desc isprivate="0">
            <who>uberlord@gentoo.org</who>
            <bug_when>2006-12-20 04:36:17 0000</bug_when>
            <thetext>Fixed in dhcp-3.0.5 and 3.1.0_alpha2</thetext>
          </long_desc>
      
    </bug>

</bugzilla>