That question was not closed. It was deleted by the asker. The asker of a question can delete it if it has no answer, or a single answer with no upvote — the idea being that the answer might be something like “there was a typo at line 3”, in which case deleting the question which would not have helped anyone is the best scenario.
At the time of deletion, it had a single close vote, out of 5 required to close. The question was actually on-topic, since it was about compiling software that the asker didn't write. This site is for users and administrators of unix systems, and compiling a program is an administrator task. If the question had been about writing a program and compiling it (for example, if it had actually been about
strdup — but it isn't), it would have been a developer task, and off-topic.
In this case, I think the question is worthwhile and shouldn't be deleted. The asker may have deleted because they believed the (incorrect) comment on the question stating that it's off-topic. But your answer is wrong — the code is being compiled by a C++ compiler, but judging by the error message it's actually C code, or C++ that requires a particularly C-friendly C++ compiler (it might be achievable with the right
g++ options, I don't know).