diff options
author | Tristan Gingold | 2015-05-11 21:18:05 +0200 |
---|---|---|
committer | Tristan Gingold | 2015-05-11 21:18:05 +0200 |
commit | c9940be923f60e0fe8348aea212f02cebb6ddb81 (patch) | |
tree | 4520a7913d146affc1269f056f953e3e6c11ce59 /src/ghdldrv | |
parent | 262976db6c8f846125dbaf2dca75eaeb32866b00 (diff) | |
download | ghdl-c9940be923f60e0fe8348aea212f02cebb6ddb81.tar.gz ghdl-c9940be923f60e0fe8348aea212f02cebb6ddb81.tar.bz2 ghdl-c9940be923f60e0fe8348aea212f02cebb6ddb81.zip |
ghdldrv: support absolute path with --elab-run.
Implement ticket 51.
Diffstat (limited to 'src/ghdldrv')
-rw-r--r-- | src/ghdldrv/ghdldrv.adb | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/src/ghdldrv/ghdldrv.adb b/src/ghdldrv/ghdldrv.adb index a9470b7..f7860b9 100644 --- a/src/ghdldrv/ghdldrv.adb +++ b/src/ghdldrv/ghdldrv.adb @@ -1003,7 +1003,7 @@ package body Ghdldrv is Success : Boolean; Run_Arg : Natural; begin - Set_Elab_Units ("-elab-run", Args, Run_Arg); + Set_Elab_Units ("--elab-run", Args, Run_Arg); Setup_Compiler (False); Bind; @@ -1012,8 +1012,12 @@ package body Ghdldrv is else Link (Add_Std => True, Disp_Only => False); Delete_File (Filelist_Name.all, Success); - My_Spawn ('.' & Directory_Separator & Output_File.all, - Args (Run_Arg .. Args'Last)); + if Is_Absolute_Path (Output_File.all) then + My_Spawn (Output_File.all, Args (Run_Arg .. Args'Last)); + else + My_Spawn ('.' & Directory_Separator & Output_File.all, + Args (Run_Arg .. Args'Last)); + end if; end if; end Perform_Action; |