Run vsim from dmenu — it only works when directly invoked in the terminal
4
votes
1
answer
2083
views
- Works:
vsim
, sh -c vsim
- Doesn't work: echo "vsim" | sh
, echo "vsim" | xargs -I {} sh -c "{}"
I want to run ModelSim (vsim
) with dmenu
, which is triggered using xbindkeys
.
---
### Details
vsim
is a executable for ModelSim, installed in /opt/altera/modelsim_ase/bin
.
When I run it directly, it runs. But when I run it with xargs
(eg. from dmenu), it does not work at all - the script itself launches, but probably in the wrong directory or something, I'm really clueless what's wrong.
My path (I added newlines for clarity):
[ondra@x201 ~]$ echo $PATH
/usr/local/sbin:
/usr/local/bin:
/usr/bin:
/usr/lib/jvm/default/bin:
/usr/bin/site_perl:
/usr/bin/vendor_perl:
/usr/bin/core_perl:
/opt/altera/quartus/bin:
/opt/altera/modelsim_ase/bin:
/home/ondra/bin:
/home/ondra/.gem/ruby/2.1.0/bin:
/opt/altera/University_Program/Monitor_Program/bin/bin
Where is vsim
?
[ondra@x201 ~]$ which vsim
/opt/altera/modelsim_ase/bin/vsim
Run it with xargs
:
[ondra@x201 ~]$ echo "vsim" | xargs -I {} sh -c '{} &'
[ondra@x201 ~]$ Reading /opt/altera/modelsim_ase/tcl/vsim/pref.tcl
# 10.1d
#
#
^C
Run it directly:
[ondra@x201 ~]$ vsim
Reading /opt/altera/modelsim_ase/tcl/vsim/pref.tcl
# --- and modelsim starts fine now ---
Any ideas welcome.
Asked by MightyPork
(1242 rep)
Nov 18, 2014, 10:12 AM
Last activity: Jun 20, 2025, 11:04 PM
Last activity: Jun 20, 2025, 11:04 PM