There is no set time for how long a workout should take.
Depending on what you are training for, how many muscles you are training, how many sets and reps you are doing and how long your rest periods are, are just some of the variables which will determine your total training time.
MUSCLE GAIN routines where you are focusing on one particular muscle, will generally take anywhere between 45 minutes - 2 hours.
A STRENGTH routine on the other hand, may take longer because you will need to rest longer in between your sets.
The important thing is don't worry about how long your workout takes, worry about how you are spending your time working out.