From: Richard Kreckel Date: Thu, 22 Mar 2001 20:09:25 +0000 (+0000) Subject: * configure.in, cint/run_exams.cpp, cint/ginaccint.cpp: adjusted the X-Git-Tag: release_0-8-0~10 X-Git-Url: https://www.ginac.de/ginac.git//ginac.git?p=ginac.git;a=commitdiff_plain;h=029a7f37abdeffb71ce07f33603e004558ed0f3c;hp=c9282804ff4127fc84bb01b2b8707fbb6724b003 * configure.in, cint/run_exams.cpp, cint/ginaccint.cpp: adjusted the --with-cint logic so ginaccint may run without a preset $CINTSYSDIR (in case of a clean system-wide installation as opposed to the tool- centric installation). cint/Makefile.makecint generation does not yet work in this case, makecint needs a tiny upstream bugfix. --- diff --git a/cint/ginaccint.cpp b/cint/ginaccint.cpp index 515835c1..cd875e90 100644 --- a/cint/ginaccint.cpp +++ b/cint/ginaccint.cpp @@ -31,8 +31,11 @@ int main(int argc, char * *argv) else setenv("LD_LIBRARY_PATH", (std::string(LD_LIBRARY_PATH)+':'+libdir).c_str(), 1); - // hard-wire CINTSYSDIR, inherited from configure, if it is not set - setenv("CINTSYSDIR", CINTSYSDIR.c_str(), 0); + // hard-wire CINTSYSDIR, inherited from configure, but only if it has + // been set therein (to allow for system-wide installations of cint) + // and without overriding it if the user has specified it. + if (CINTSYSDIR != "@CINTSYSDIR@") + setenv("CINTSYSDIR", CINTSYSDIR.c_str(), 0); // execute the real thing int error = execve(binprog.c_str(), argv, environ); diff --git a/cint/run_exams.cpp b/cint/run_exams.cpp index a23a312f..add73bc9 100644 --- a/cint/run_exams.cpp +++ b/cint/run_exams.cpp @@ -24,8 +24,10 @@ int main(int argc, char * *argv) else setenv("LD_LIBRARY_PATH", (std::string(LD_LIBRARY_PATH)+':'+"../ginac/.libs").c_str(), 1); - // 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); // execute the real thing int error = execve(binprog.c_str(), argv, environ);