[Backend] Make cx_Oracle compilation optional in cx_Oracle 5.2.1
@@ -154,7 +154,7 @@ else:
instantClientRPMLib = None
# try to determine the Oracle home
-userOracleHome = os.environ.get("ORACLE_HOME")
+userOracleHome = os.environ.get("ORACLE_HOME", os.environ.get("ORACLE_INSTANTCLIENT_HOME"))
if userOracleHome is not None:
if not CheckOracleHome(userOracleHome):
messageFormat = "Oracle home (%s) does not refer to an " \
@@ -167,8 +167,8 @@ else:
if oracleHome is None and sys.platform.startswith("linux"):
instantClientRPMLib = FindInstantClientRPMLib()
if oracleHome is None:
- raise DistutilsSetupError("cannot locate an Oracle software " \
- "installation")
+ print >>sys.stderr, "cannot locate an Oracle software installation. skipping"
+ sys.exit(0)
# define some variables
if sys.platform == "win32":
