From: Stefan R. <Ste...@CT...> - 2003-03-25 20:07:21
|
What about procfs? $ uname -srpi SunOS 5.9 sparc SUNW,UltraSPARC-IIi-cEngine $ grep '#error' /usr/include/sys/* | grep Cannot /usr/include/sys/old_procfs.h:#error "Cannot use procfs in the large = file compilation environment" /usr/include/sys/procfs.h:#error "Cannot use procfs in the large = file compilation environment" /usr/include/sys/swap.h:#error "Cannot use swapctl in the large files compilation environment" Stefan P.S.: I'm not a 32/64 wizard > -----Urspr=FCngliche Nachricht----- > Von: Bruce Shaw [mailto:Bru...@go...] > Gesendet: Dienstag, 25. M=E4rz 2003 00:27 > An: Net-Snmp-Coders (E-mail) > Betreff: Solaris Large File Compilation Environment and Perl >=20 > I believe I've found a better solution to our problems with net-snmp = and > Sun's version of Perl hating each other. >=20 > The problem is, in a nutshell, the use of swap.h inside > agent/mibgroup/host/hr_storage.c requiring the "large file = compilation > environment". >=20 > If you look in http://docs.sun.com/db/doc/806-0634/6j9vo5alv?a=3Dview = which > is part of the Solaris 64-bit Developers guide > (http://docs.sun.com/doc/806-0477?q=3Dlarge+file+environment) >=20 > It says "Applications may combine objects produced in the large file > compilation environment with objects produced in the transitional > compilation environment, but must be careful with respect to > interoperability between those objects. Applications should not = declare > global variables of types whose sizes change between compilation > environments." >=20 > The problem specifically in hr_storage.c is >=20 > #if defined(solaris2) > #if HAVE_SYS_SWAP_H > #include <sys/swap.h> > #endif > #endif >=20 > ... >=20 > #ifdef solaris2 > void > sol_get_swapinfo(int *totalP, int *usedP) > { > struct anoninfo ainfo; >=20 > if (swapctl(SC_AINFO, &ainfo) < 0) { > *totalP =3D *usedP =3D 0; > return; > } >=20 > *totalP =3D ainfo.ani_max; > *usedP =3D ainfo.ani_resv; > } > #endif /* solaris2 */ >=20 > If we were to put this into a separate module and compile it WITHOUT > largefile support (which generates the OFFSET_64 problem which is = causing > all the fuss), and pass two simple integers instead of the anoninfo = data > structure it should be able to be included into the larger net-snmp = which > WOULD compile with the largefile (and OFFSET_64) support and play = nice > with > Perl. >=20 > How to specifically do it, especially explaining all this to = ./configure > is > waaaaayyy over my head. >=20 > This communication is intended for the use of the recipient to which = it is > addressed, and may contain confidential, personal and or privileged > information. Please contact us immediately if you are not the = intended > recipient of this communication, and do not copy, distribute, or take > action > relying on it. Any communication received in error, or subsequent = reply, > should be deleted or destroyed. >=20 >=20 >=20 > ------------------------------------------------------- > This SF.net email is sponsored by: > The Definitive IT and Networking Event. Be There! > NetWorld+Interop Las Vegas 2003 -- Register today! > http://ads.sourceforge.net/cgi-bin/redirect.pl?keyn0001en > _______________________________________________ > Net-snmp-coders mailing list > Net...@li... > https://lists.sourceforge.net/lists/listinfo/net-snmp-coders |