Remove cached light variables to reduce work when parsing DLs.

Also removes some duplication between GL and the inactive D3D code.
Buildfix non-windows platforms
Don't initialize lighting and lights unless they are enabled
Merge remote-tracking branch 'upstream/no-light-cache'
Fix typo breaking older savestates.
Move the light params to separate funcs.
Fix uniform dirtying on colortest mask.
Separate out the fog color/coef executes.