Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

psutil won't compile on SunOS 5.10 #421

Closed
giampaolo opened this issue May 23, 2014 · 10 comments
Closed

psutil won't compile on SunOS 5.10 #421

giampaolo opened this issue May 23, 2014 · 10 comments

Comments

@giampaolo
Copy link
Owner

From g.rodola on August 25, 2013 17:09:12

See: https://groups.google.com/forum/#!topic/psutil/6soK0mK27LM

Original issue: http://code.google.com/p/psutil/issues/detail?id=421

@giampaolo giampaolo self-assigned this May 23, 2014
@giampaolo
Copy link
Owner Author

From [email protected] on September 08, 2013 20:09:31

I was able to work around this by hacking up mib2.h... copying it to psutil dir 
and wacking out all the #ifdefs requiring NEW_MIB_COMPLIANT and including the 
local copy of mib2.h in _psutil_sunos.c. Its an ugly brutal hack, but I 
couldn't find a location to put the #define for NEW_MIB_COMPLIANT that would 
let it build cleanly. patch for mib2.h is below

I also had problems with pycc throwing in -KPIC but i bet that's just an 
opencsw gcc/binutils thing. 

The biggest remaining solaris issue is the fact that the initialization routine 
sets BOOT_TIME using psutil itself to get the start time of proc 0. Which is 
all well and good unless you happen to be trying to run this inside a zone 
which doesn't have a process 0 it can read in /proc :)

Attachment: psutil-mib2h-hack.diff

@giampaolo
Copy link
Owner Author

From [email protected] on October 29, 2013 04:18:31

I've just come across the same issues.  Adding '#define NEW_MIB_COMPLIANT' to 
'_psutil_sunos.c' before including '<inet/tcp.h>' does the trick.  

"NEW_MIB_COMPLIANT is a define used in Solaris 10U4+ to enable additional MIB 
information".

Not exactly sure if there any side effects in adding the additional MIB info so 
will look into it a bit more.

Am also experiencing the BOOT_TIME issue, so will try to have a look at that 
too if I get time :)

Attachment: _psutil_sunos_new_mib_compliant.patch

@giampaolo
Copy link
Owner Author

From g.rodola on October 29, 2013 04:30:15

Unfortunately I don't have a SunOS 5.10 to test against therefore the only way 
we can push this forward is if somebody provides a patch which fixes all the 
compilation issues.

Labels: -Priority-Medium Priority-High

@giampaolo
Copy link
Owner Author

From g.rodola on December 02, 2013 11:38:48

Note: BOOT_TIME related compilation issues were fixed as of issue 425 .

@giampaolo
Copy link
Owner Author

From [email protected] on March 11, 2014 15:18:00

The fix in comment #2 gets 2.0.0 compiling and working fine for me on SunOS 5.10

@giampaolo
Copy link
Owner Author

From g.rodola on March 11, 2014 16:08:01

Please try revision 0b6fb805070e .

@giampaolo
Copy link
Owner Author

From g.rodola on March 11, 2014 17:30:16

Please after you do also try:

$ make build
$ make test

@giampaolo
Copy link
Owner Author

From [email protected] on March 11, 2014 17:34:31

That changelog affects OS X. This issue is for SunOS/Solaris 5.10

@giampaolo
Copy link
Owner Author

From g.rodola on March 11, 2014 17:41:17

Sorry, I'm tired. Please try revision a8461d58f055 .

@giampaolo
Copy link
Owner Author

From g.rodola on April 08, 2014 15:13:50

Status: Fixed
Labels: Milestone-2.1.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant