Bug List: (This bug is not in your last search results)   Show last search results      Search page      Enter new bug
Bug#: 158540
Alias:
Product:
Component:
Status: RESOLVED
Resolution: FIXED
Assigned To: Roy Marples (RETIRED) <uberlord@gentoo.org>
Hardware:
OS:
Version:
Priority:
Severity:
Reporter: Nick Fortune <qb4w0p7r02@sneakemail.com>
Add CC:
CC:
URL:
Summary:
Status Whiteboard:
Keywords:

Filename Description Type Creator Created Size Actions
Create a New Attachment (proposed patch, testcase, etc.) View All

Bug 158540 depends on: Show dependency tree
Bug 158540 blocks:
Votes: 0    Show votes for this bug    Vote for this bug

Additional Comments: (this is where you put emerge --info)


Not eligible to see or edit group visibility for this bug.






View Bug Activity   |   Format For Printing   |   XML   |   Clone This Bug


Description:   Opened: 2006-12-19 05:56 0000
The script shebang is 

#!/bin/bash

and should be  

#!/bin/sh

Otherwise, if bash isn't installed (as is generally the case on embedded
builds) dhclient fails with "file not found"

Not a biggie, but I thought you might like it logged.

------- Comment #1 From Jakub Moc (RETIRED) 2006-12-19 07:03:42 0000 -------
Reopen with exact ebuild name and version; assuming that everyone uses some
weirdo busybox stuff plain doesn't work... No idea what's this about.

------- Comment #2 From Nick Fortune 2006-12-19 08:41:23 0000 -------
sorry. package is net-misc/dhcp-3.0.5

file is /sbin/dhclient-script

> assuming that everyone uses some weirdo busybox stuff plain doesn't work...

Charmed, I'm sure.

The script starts with "#!/bin/bash" which will break on any system that
doesn't have bash installed. On the other hand "#!/bin/sh" should work for
anything that's Bourne shell based.

------- Comment #3 From Roy Marples (RETIRED) 2006-12-19 09:05:33 0000 -------
(In reply to comment #0)
> Otherwise, if bash isn't installed (as is generally the case on embedded
> builds) dhclient fails with "file not found"

That's a fair point, but on on embedded systems then udhcpc or dhcpcd would be
used as ISC'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 -> udhcpd
-rwxr-xr-x 1 root root  27672 2006-07-25 21:49 /sbin/udhcpd

------- Comment #4 From Roy Marples (RETIRED) 2006-12-19 09:07:56 0000 -------
(In reply to comment #2)
> The script starts with "#!/bin/bash" which will break on any system that
> doesn't have bash installed. On the other hand "#!/bin/sh" should work for
> anything that'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't use
any of that, so I'll update it in one of the ~ARCH versions.

------- Comment #5 From Roy Marples (RETIRED) 2006-12-20 04:36:17 0000 -------
Fixed in dhcp-3.0.5 and 3.1.0_alpha2

Bug List: (This bug is not in your last search results)   Show last search results      Search page      Enter new bug