I have only recently managed to compile a piece of open source software that has been published a few years ago and not been maintained since then. A few adjustments to the source code have been necessary to enable compilation and I had to piece them together from several SO questions.

Now that it is finally working I would like to document my workflow by posting a self-answered question so that other people will find all the required steps in one place and not have to go through all the trouble I have just been through.

I have seen Is Stack Overflow a central store for tutorials? but am still not sure whether this sort of tutorial would be welcome here. Is it maybe too localized because it only deals with one software instead of addressing the compilation problems in a more general fashion? Or is it even too broad because all of these steps deserve their own question?

The proposed question wording is attached below. Please let me know what you think before I post this to the main site. I'd hate to post a detailed explanation just to see it closed or removed because it doesn't fit here.

I am trying to compile the Contraction Hierarchies Implementation by KIT.

This software has been published in 2008 and obviously not been maintained since then. Since a few things have changed in the mean time (with new C++ standards and compiler versions) the code does not compile off the shelf anymore.

What steps do I need to take to make this compile?

Thank you for your input, question and answer is now at How do I compile Contraction Hierarchies by KIT?.


While Undo is correct that your question should be a question, your question still seems a bit fabricated. The best questions on Stack Overflow are those about a real, actual problem you're facing. Those questions explain exactly what is wrong, what you tried, and what error messages you're getting.

In its current form, your question is extremely vague. Instead, think about what problems you faced when you tried to compile the project. Where did you get stuck? What error messages did you get? What did you try? Those are the components that make a great question.

Then, once you have your question in mind, post a great answer. Don't just post a tutorial; instead, post an actual answer to the problem, one that addresses the exact point in the process where you got stuck. At the end, it's of course okay to say something like "See this great tutorial on how to compile X", but your answer shouldn't be a book.

The best way to ask and answer your own question is to pretend like you're two people. Pretend like you're an asker with a problem, then pretend like you're another person who has the answer. Rememeber, self-answering is hard. If you do it wrong, please don't be upset if the community closes your post. It's the risk you take in trudging down Encyclopedia Stack Exchange; however, if you take your time and put effort into this, the rewards can be great. Good luck with your post! :)

  • Well, the problem with only explaining the first point where I was stuck is that this is already explained on SO, just not so easy to find right away. Actually, all of the points where I was stuck are explained in one form or the other on SO but trying to figure out the problem and then finding the right question took me quite a while. This is why I wanted to create an answer guiding through the entire process. Unfortunately, there is no external site offering a tutorial on compiling this software which is why I wanted to post it here. – Chris Jul 16 '13 at 2:26
  • Also including all error messages in the question is nearly impossible as that would really create a fabricated question: compiler and linker fail with different error messages throughout the process, you will not encounter all of them on the first try but only after fixing a few problems. – Chris Jul 16 '13 at 2:29
  • 4
    @Chris, I'd say theres nothing wrong with "I followed the official (but outdated) instructions to install X [ + details] but I recieved the error message [first set of error messages], how do I solve this and sucessfully install X" Then your answer can go through the whole process. Most people experiencing the problem will experience the first error message – Richard Tingle Jul 16 '13 at 6:56
  • @Chris - Your question shouldn't be a one stop shop for every single error message you faced. Instead, start with the most challenging error message and post a question based on that. Think about the last time you used Stack Overflow to solve a problem you faced, a complicated multi-step problem. You most likely found the answers in a string of SO posts. When posts are self-contained, they're more helpful than if all the info is dumped in one place. That's what makes us better than the forums. Hope this helps. – jmort253 Jul 16 '13 at 19:38
  • But what @RichardTingle says is a good way to stretch this a bit without being too broad. :) – jmort253 Jul 16 '13 at 19:39
  • @jmort253 I am thinking back to the time I used several SO questions to compile the software I am describing and it took me a day. Having the entire process in one place should enable people to do it in 30 minutes. There are already self-contained SO posts for the specific subproblems which I linked from my answer. – Chris Jul 16 '13 at 22:19

Remember, we're not just looking for good answers, but good questions!

The question that you've proposed, by itself, would be closed as "unclear what you're asking" since it doesn't actually reference the problem(s) you had compiling the software.

To improve it, the question should also contain all of the compilation errors which you had to work around.


Yes, you should be okay doing that, just make sure the question is a question! (It is in your example.)

Also, if you aren't concerned about the rep earned from it, mark the community wiki box so that users with less than 2k reputation can easily edit it, just like Wikipedia.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .