유닉스 에러 socket: Address family not supported by protocol

qhdasltjr의 이미지

#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include
#include

int main(int argc, char **argv)
{
int sock;
if((sock = socket(PF_PACKET, SOCK_RAW, htons(ETH_P_ALL))) perror("socket");
return 1;
}

}

컴파일까지는 되는데 실행파일을 실행하면 socket: Address family not supported by protocol 라고 에러가 뜹니다. 뭐가 문제인지 도저히 모르겠어요.