Re: Implementing tables with fewer source files
"Joshua Tolley" <[email protected]>
| Newsgroups | gmane.network.net-snmp.user |
|---|---|
| Message-ID | <[email protected]> |
On Tue, Sep 2, 2008 at 5:39 PM, Wes Hardaker <[email protected]> wrote: >>>>>> On Fri, 29 Aug 2008 13:47:25 -0600, eggyknap <[email protected]> said: > > e> I'm writing an agent, and found that mib2c using the mib for dummies > e> config makes about 12 source files for each table I implement. I > e> modify a few lines of the autogenerated code, and add it to my > e> makefile. I'd really like to make my agent somewhat smaller (i.e. less > e> code) -- can I do that? I realize it might not be particularly simple, > e> and I can live with having to do some reading, but I'd like pointers. > e> Thanks in advance. > > You might check out some of the other output styles of mib2c. The > iterator mechanisms, for instance, probably produce the smallest amount > of code. The MFD stuff produces a lot of extra comments and > compartmentalized functions for you to fill in, which makes the code > "look" larger. I'll do that. Looking smaller is certainly something, and certainly a simple count of source files isn't a great way of figuring code size. Admittedly, though, I'd hoped for code that *really was* smaller. It seems that despite the fact that each table is structured uniquely, each of the tables should share almost all the code. I guess that's probably possible, if I wanted to rewrite net-snmp with that as my highest priority :) - Josh ------------------------------------------------------------------------- This SF.Net email is sponsored by the Moblin Your Move Developer's challenge Build the coolest Linux based applications with Moblin SDK & win great prizes Grand prize is a trip for two to an Open Source event anywhere in the world http://moblin-contest.org/redirect.php?banner_id=100&url=/ _______________________________________________ Net-snmp-users mailing list [email protected] Please see the following page to unsubscribe or change other options: https://lists.sourceforge.net/lists/listinfo/net-snmp-users