Escape classpath separators.

Fixes #1328.
This commit is contained in:
Phil Hagelberg 2013-11-13 09:40:17 -08:00
parent 9718597bd4
commit 23b3477298

View file

@ -329,9 +329,12 @@
project options))))
(defn- normalize-path [root path]
(let [f (io/file path)] ; http://tinyurl.com/ab5vtqf
(.getAbsolutePath (if (or (.isAbsolute f) (.startsWith (.getPath f) "\\"))
f (io/file root path)))))
(let [f (io/file path) ; http://tinyurl.com/ab5vtqf
abs (.getAbsolutePath (if (or (.isAbsolute f)
(.startsWith (.getPath f) "\\"))
f (io/file root path)))
sep (System/getProperty "path.separator")]
(str/replace abs sep (str "\\" sep))))
(defn ext-dependency?
"Should the given dependency be loaded in the extensions classloader?"