[Haskell-cafe] Access to Oracle database from Haskell
alistair at abayley.org
Wed Jun 25 06:07:49 EDT 2008
> I'll have to change the way that Setup.hs tries to find $ORACLE_HOME.
> Using getEnv would be a much better idea. I don't recall why I didn't
> use it before; perhaps it's not always set on Windows installations.
Try this version of configOracle in Setup.hs:
configOracle verbose buildtools = do
if not (sqlplusProgram `isElem` buildtools)
then return Nothing
path <- getEnv "ORACLE_HOME"
info verbose ("Using Oracle: " ++ path)
makeConfig path libDir "oci/include"
where libDir = if isWindows then "bin" else "lib"
You'll also need to add this import:
import System.Environment (getEnv)
I always used to get the "Using..." messages, but now it seems I need to say:
$ setup configure -v -foracle
More information about the Haskell-Cafe