Fix compilation error on FreeBSD
Fix compilation error on FreeBSD

Error log -
  ```
  undefined reference to `WIFEXITED'
  undefined reference to `WEXITSTATUS'
  ```

Apparently the header file <sys/wait.h> has to be included in FreeBSD
unlike on Linux (Ubuntu 16.10) since it is included by <stdlib.h>.

shivrai/smoketestsuite,shivrai/smoketestsuite,shivansh/smoketestsuite,shivansh/smoketestsuite,shivrai/smoketestsuite,shivansh/smoketestsuite