SCM Repository
[diderot] Diff of /branches/vis12/src/compiler/nrrd/run-dnorm_sml.in
Diff of /branches/vis12/src/compiler/nrrd/run-dnorm_sml.in
Parent Directory
|
Revision Log
|
Patch
22 |
"@DIDEROT_ROOT@/bin", "@prefix@/bin" |
"@DIDEROT_ROOT@/bin", "@prefix@/bin" |
23 |
] |
] |
24 |
|
|
25 |
(* FIXME: with SML/NJ 110.73, we'll be able to use PathUtil.findExe *) |
fun findExe () = (case PathUtil.findExe paths "dnorm" |
|
fun findExe () = let |
|
|
fun isExe p = OS.FileSys.access(p, [OS.FileSys.A_EXEC]) |
|
|
in |
|
|
case PathUtil.existsFile isExe paths "dnorm" |
|
26 |
of SOME cmd => cmd |
of SOME cmd => cmd |
27 |
| NONE => raise Fail "unable to find dnorm executable" |
| NONE => raise Fail "unable to find dnorm executable" |
28 |
(* end case *) |
(* end case *)) |
|
end |
|
29 |
|
|
30 |
fun run srcFile = if OS.FileSys.access(srcFile, [OS.FileSys.A_READ]) |
fun run srcFile = if OS.FileSys.access(srcFile, [OS.FileSys.A_READ]) |
31 |
then let |
then let |
56 |
else raise Fail "error running dnorm" |
else raise Fail "error running dnorm" |
57 |
end |
end |
58 |
else raise Fail(concat["image file \"", srcFile, "\" not found"]) |
else raise Fail(concat["image file \"", srcFile, "\" not found"]) |
59 |
|
|
60 |
end |
end |
|
Legend:
Removed from v.1782 |
|
changed lines |
|
Added in v.1783 |
|
|