NP-hardness of shop-scheduling problems with three jobs