Thousands of mourners in the US city of Charleston are hoping that out of tragedy can come healing and a better racial understanding.