Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

sys/sysinfo.h: No such file or directory --> MACOSX 10.6.4

994 views
Skip to first unread message

Maura Jauhola

unread,
Aug 13, 2010, 5:28:53 AM8/13/10
to
I need a real help to compile a small program which compiles fine with
g++ in Linux machines. However I need to compile-it in my machine with
g++. I have this problem and I dont know how to solve it:
sys/sysinfo.h: No such file or directory

could someone please help me?

Thanks!

Jens Thoms Toerring

unread,
Aug 13, 2010, 7:49:45 AM8/13/10
to
Maura Jauhola <maura....@gmail.com> wrote:
> I need a real help to compile a small program which compiles fine with
> g++ in Linux machines. However I need to compile-it in my machine with
> g++. I have this problem and I dont know how to solve it:
> sys/sysinfo.h: No such file or directory

As far as I know this is a Linux specific header file (it, e.g.
has the declaration for the sysinfo(2) function that relies on
a Linux specific kernel call). Thus it rather likely isn't
directly available on other platforms. Since you don't give
any information about the program you try to compile it's hard
to say what needs to be done (if there's something that can be
done at all). If the program doesn't actually require the stuff
from <sys/sysinfo.h> then you could try to remove the include
of it and throw out the parts in the code where the compiler is
complaining about the use of undeclared functions and/or the
linker about undefined symbols. On the other hand, if the pro-
grams purpose is mostly to e.g. display data obtained from a
call of sysinfo(2) then you might be out of luck unless there's
some replacement - I have been reading that at least some of
the information can be obtained via the sysctl(3) function on
Mac OS X but since I have no experience with that platform I
can't say for sure.
Regards, Jens
--
\ Jens Thoms Toerring ___ j...@toerring.de
\__________________________ http://toerring.de

0 new messages