1. をしないとunistd.hを二重にインクルードしたってエラーが多分止まります。 3. でHAVE_GETOPTを定義するとsrc/driver.hにunistd.hがインクルードされて >>677 >hufo_smoke.cpp: In function `void hack_handle_opts(int, char **)': >hufo_smoke.cpp:176: implicit declaration of function `int getopt(...)' >hufo_smoke.cpp:190: `optarg' undeclared (first use this function) > というエラーは出なくなるはずです。