How can I parse the string by commas? I know I should really be using strtok in a loop, but I'm trying to parse in the most simplest way possible before attempting to do anything more complex since I'm a beginner programmer.

2) using an index counter in a while loop, go through each array char, until you find the next comma

3) When you find the comma, or the end of the line, put the char's that are not already processed, into their final data structure.

This is simple *IF* you work it out by hand (paper and pencil), until you have a clear vision of this process. Then you'll use two index counters (or pointers), start will be the slower one, that marks the spot in the array where the next word should start, and end will be the "faster" leading edge marker, to mark the end of the next word.

The big mistake is to sit down at the computer, and start banging out code, and thinking about C string functions, etc. Then you simply can't see the forest for the trees.

If you get stuck with the algorithm, post back.

Note: I'd prefer, while you're working on the basic algo, that you didn't malloc /calloc the array - use a static one for now. Also, you don't need to cast a C malloc/calloc call. And, you do need to include stdlib.h (and a cast will hide that error).

The issue isn't with strtok(), altho' there's a better way to go about it, but with the storage allocation; cause of the segv at runtime.

Code:

line = (char *)malloc(sizeof(char) *N); /* line points to an array that can hold only 10 characters */
...
fgets(line, linemax, inp); /* tries to read 255 chars from inp into the array pointed to be line?? */

Your segfault won't go away until you fix your storage allocations.
Why not go for static allocation instead of dynamic as you are a beginner.
Once the code is working you can switch to dynamic allocation.