Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
H
Hdlmake
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
15
Issues
15
List
Board
Labels
Milestones
Merge Requests
4
Merge Requests
4
Wiki
Wiki
image/svg+xml
Discourse
Discourse
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Projects
Hdlmake
Commits
c82de3ff
Commit
c82de3ff
authored
Aug 16, 2013
by
Paweł Szostek
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
use EnvChecker for modelsim.ini path
parent
e0d8f4dd
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
5 additions
and
11 deletions
+5
-11
manifest_parser.py
hdlmake/manifest_parser.py
+2
-1
modelsim.py
hdlmake/tools/modelsim.py
+2
-9
configparser.py
hdlmake/util/configparser.py
+1
-1
No files found.
hdlmake/manifest_parser.py
View file @
c82de3ff
...
...
@@ -62,6 +62,7 @@ class ManifestParser(ConfigParser):
self
.
add_option
(
'syn_pre_cmd'
,
default
=
None
,
help
=
"Command to be executed before synthesis"
,
type
=
''
)
self
.
add_option
(
'syn_post_cmd'
,
default
=
None
,
help
=
"Command to be executed after synthesis"
,
type
=
''
)
self
.
add_delimiter
()
self
.
add_option
(
'top_module'
,
default
=
None
,
help
=
"Top level entity for synthesis and simulation"
,
type
=
''
)
self
.
add_delimiter
()
...
...
@@ -117,7 +118,7 @@ class ManifestParser(ConfigParser):
return
self
.
add_config_file
(
manifest
.
path
)
def
print_help
(
self
):
ConfigParser
.
help
()
self
.
help
()
def
search_for_package
(
self
):
"""
...
...
hdlmake/tools/modelsim.py
View file @
c82de3ff
...
...
@@ -25,8 +25,8 @@
from
__future__
import
print_function
import
xml.dom.minidom
import
xml.parsers.expat
import
os
import
re
import
os
XmlImpl
=
xml
.
dom
.
minidom
.
getDOMImplementation
()
...
...
@@ -37,11 +37,10 @@ def detect_modelsim_version(path):
pass
class
ModelsiminiReader
(
object
):
def
__init__
(
self
,
path
=
None
):
if
path
is
None
:
path
=
self
.
modelsim_ini_dir
()
+
"/modelsim.ini"
path
=
os
.
path
.
join
(
global_mod
.
env
[
"modelsim_path"
],
"/modelsim.ini"
)
self
.
path
=
path
def
get_libraries
(
self
):
...
...
@@ -75,9 +74,3 @@ class ModelsiminiReader(object):
lib
=
line
[
0
]
.
strip
()
libs
.
append
(
lib
.
lower
())
return
libs
@
staticmethod
def
modelsim_ini_dir
():
vsim_path
=
os
.
popen
(
"which vsim"
)
.
read
()
.
strip
()
bin_path
=
os
.
path
.
dirname
(
vsim_path
)
return
os
.
path
.
abspath
(
bin_path
+
"/../"
)
hdlmake/util/configparser.py
View file @
c82de3ff
...
...
@@ -176,7 +176,7 @@ class ConfigParser(object):
raise
RuntimeError
(
"No such option as "
+
str
(
name
))
def
help
(
self
):
print
(
"Variables
available in a manifest
:"
)
print
(
"Variables
with special meaning for Hdlmake
:"
)
for
opt
in
self
.
options
:
if
opt
is
None
:
print
(
""
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment