Introduce new Delphi compatible switch $IMPORTEDDATA/$G which allows to control locally whether variable locations are loaded indirectly or directly.

globtype.pas:
  + tlocalswitch: add new value cs_imported_data
switches.pas:
  * set G of the Turbo Pascal switch table to cs_imported_data
scandir.pas:
  + new directive dir_importeddata which is equivalent to switch G
  * InitScannerDirectives: register dir_importeddata
globals.pas:
  * default_settings: enable cs_imported_data by default (Delphi compatible)

git-svn-id: http://svn.freepascal.org/svn/fpc/branches/svenbarth@28641 3ad0048d-3df7-0310-abae-a5850022a9f2
Generate indirect symbols for global variables and load them indirectly when necessary.

ptconst.pas, read_typed_const:
  * generate an indirect symbol for the const data using the indirect_suffix constant
ngenutil.pas, tnodeutils.insertbssdata:
  * generate an indirect symbol for the uninitialized data using the indirect_suffix constant
ncgld.pas, tcgloadnode.pass_generate_code:
  * load static variables indirectly if the following conditions are true:
      - the target supports packages (otherwise this is a waste of cycles)
      - the variable is not external
      - IMPORTEDDATA is active
      - the variable is loaded from a different unit

git-svn-id: http://svn.freepascal.org/svn/fpc/branches/svenbarth@28642 3ad0048d-3df7-0310-abae-a5850022a9f2