- // hard-wire CINTSYSDIR, inherited from configure
- setenv("CINTSYSDIR", CINTSYSDIR.c_str(), 1);
+ // hard-wire CINTSYSDIR, inherited from configure, but only if it has
+ // been set therein (to allow for system-wide installations of cint).
+ if (CINTSYSDIR != "@CINTSYSDIR@")
+ setenv("CINTSYSDIR", CINTSYSDIR.c_str(), 1);