dhclient binary size

Bancroft, Matt matt.bancroft at unify.com
Fri Sep 30 10:23:18 UTC 2016


Thanks for the suggestion. Your changes reduce the binary size by 100Kb. However, the binary went from ~500Kb to 2Mb when updating from 4.1-ESV-Rx to 4.3.4, so the 100Kb is not really a significant reduction.
I am compiling for arm if that makes any difference. And the main reason for the upgrade is to support all the new dhcpv6 options, particularly the –D option introduce in 4.2.
The client is being used in an embedded environment so binary size is an important issue.

Can you suggest any other way to reduce the binary size?

Kind Regards,
Matt Bancroft

From: dhcp-users [mailto:dhcp-users-bounces at lists.isc.org] On Behalf Of Thomas Markwalder
Sent: 28 September 2016 15:55
To: dhcp-users at lists.isc.org
Subject: Re: dhclient binary size

On 9/28/16 10:23 AM, Bancroft, Matt wrote:

Between 4.1-ESV-R12b1 and 4.3.4 the binary size of the dhclient significantly increased.

I‘ve had a search back through posts and cannot see any discussion about why this is; presumably the DDNS changes?

Is there any way to compile a minimum feature version to maintain a small binary size for the client?

Kind Regards,
Matt Bancroft

Hello Matt:

If you do not need the client to support DNS updates, you can compile it out.  To do so you need to:

1. Undefine NSUPDATE (comment it out) in includes/site.
2. dhclient_ddns_cb_free(), needs to be wrapped with NSUPDATE conditional compilation.


I  have attached a diff, containing these changes.  The resulting client is notably smaller.   Please note that, these changes have
not been tested and are use-at-your-own-risk.


Thomas Markwalder
ISC Software Engineering


dhcp-users mailing list

dhcp-users at lists.isc.org<mailto:dhcp-users at lists.isc.org>


-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.isc.org/pipermail/dhcp-users/attachments/20160930/0edaa9c1/attachment.html>

More information about the dhcp-users mailing list