Here's a valid command line from my Debian running PC:
/usr/bin/dot -Tpng /home/fz/programming/Lisp/graphviz/todot-output.dot -o /home/fz/programming/Lisp/graphviz/todot-output.png
The above command takes a valid .dot file and produces a valid .png
file.
I'm trying to do it inside SBCL:
(run-program
"/usr/bin/dot"
'("-Tpng /home/fz/programming/Lisp/graphviz/todot-output.dot" "-o" "/home/fz/programming/Lisp/graphviz/todot-output.png"))
But I could not produce any file. Seems like the above run-program
has no file writing effect. How can I make SBCL
invoke the same command? What am I doing wrong? Is it about
passing parameters?
Any clues?
Thanks in advance.
--
Emre Sevinc
eMBA Software Developer Actively engaged in:
http:www.bilgi.edu.tr http://ileriseviye.org
http://www.bilgi.edu.tr http://fazlamesai.net
Cognitive Science Student http://cazci.com
http://www.cogsci.boun.edu.tr
On Thu, 07 Jul 2005 03:00:47 +0300, Emre Sevinc wrote:
>
> Here's a valid command line from my Debian running PC:
>
> /usr/bin/dot -Tpng /home/fz/programming/Lisp/graphviz/todot-output.dot -o /home/fz/programming/Lisp/graphviz/todot-output.png
>
> The above command takes a valid .dot file and produces a valid .png
> file.
>
> I'm trying to do it inside SBCL:
>
> (run-program
> "/usr/bin/dot"
> '("-Tpng /home/fz/programming/Lisp/graphviz/todot-output.dot" "-o" "/home/fz/programming/Lisp/graphviz/todot-output.png"))
Shouldn't this be:
(run-program
"/usr/bin/dot"
'("-Tpng" "/home/fz/programming/Lisp/graphviz/todot-output.dot"
"-o" "/hofz/programming/Lisp/graphviz/todot-output.png"))
Note the missing separation of the format switch and the input file name
in your example.
HTH Ralf Mattes
> But I could not produce any file. Seems like the above run-program has
> no file writing effect. How can I make SBCL invoke the same command?
> What am I doing wrong? Is it about passing parameters?
>
> Any clues?
>
> Thanks in advance.
"R. Mattes" <ยทยท@mh-freiburg.de> writes:
> On Thu, 07 Jul 2005 03:00:47 +0300, Emre Sevinc wrote:
>
>>
>> Here's a valid command line from my Debian running PC:
>>
>> /usr/bin/dot -Tpng /home/fz/programming/Lisp/graphviz/todot-output.dot -o /home/fz/programming/Lisp/graphviz/todot-output.png
>>
>> The above command takes a valid .dot file and produces a valid .png
>> file.
>>
>> I'm trying to do it inside SBCL:
>>
>> (run-program
>> "/usr/bin/dot"
>> '("-Tpng /home/fz/programming/Lisp/graphviz/todot-output.dot" "-o" "/home/fz/programming/Lisp/graphviz/todot-output.png"))
>
> Shouldn't this be:
> (run-program
> "/usr/bin/dot"
> '("-Tpng" "/home/fz/programming/Lisp/graphviz/todot-output.dot"
> "-o" "/hofz/programming/Lisp/graphviz/todot-output.png"))
>
> Note the missing separation of the format switch and the input file name
> in your example.
Thank you very much. After correcting my mistake I have also
added the required stuff to grab the output (even though this
one doesn't have much to output):
(with-output-to-string
(stream)
(run-program
"/usr/bin/dot"
'("-Tpng" "todot-output.dot" "-o" "todot-output.png")
:output stream))
"Given enough eyeballs, all bugs are shallow."
--
Emre Sevinc
eMBA Software Developer Actively engaged in:
http:www.bilgi.edu.tr http://ileriseviye.org
http://www.bilgi.edu.tr http://fazlamesai.net
Cognitive Science Student http://cazci.com
http://www.cogsci.boun.edu.tr