[cs631apue] Confusing with header files

kwang9 kwang9 at stevens.edu
Mon Sep 23 23:47:36 EDT 2013


Dear all,

I have these files,

common.h:
#include <sys/types.h>
#include <sys/stat.h>
#include <unistd.h>
...

print.h:
#include "common.h"
...

print.c:
...
...S_IFMT...
...

It compiles fine on my Mac, while ERROR! on linux-lab:
error: ‘S_IFMT’ undeclared (first use in this function)

Could anyone tell my why please...

Sincerely,
Kai




More information about the cs631apue mailing list