Some relaxation results for functionals depending on constrained strain and chemical composition