Chet, MDF is about the "saggiest" material, followed by plywood, that you could use for shelves. Making adjustible shelves is a lot worse than making fixed shelves that can be made more self-supporting.
If you are going to be using materials like these, the only way to stand a chance of success is to run 1x2 pine or similar or larger or stronger wood under at least the front edge and preferably the front and back edge. Solid wood has quite a bit of strength when, for instance, a 1x2 is standing on the 1" side. It will bow many times easier if it's lying on the 2" side.
Laminate coverings will help somewhat in keeping MDF boards flat over a span but are not an ultimate answer. Pantry shelves can accumulate a lot of weight quickly with bags of sugar and flour and canned goods. I would look at 3/4" plywood with 1x2 pine or other solid wood on edge at the front and back face of the plywood. You would want to glue and screw these together and there are several ways to accomplish this successfully.