A static global oversized array is normally the simplest solution.

Only when that array would be hundreds of megabytes, it makes sense to use pointers and malloc for not wasting memory.