leveldb, lua, and snappy should respect optmization setting

This change aids in debugging by ensuring that the optimization is carried through to some dependencies.