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
d365ae88
Commit
d365ae88
authored
Jul 31, 2013
by
Pawel Szostek
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
add stub for check-manifest command
parent
6cca8428
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
25 additions
and
0 deletions
+25
-0
__main__.py
src/__main__.py
+4
-0
__init__.py
src/action/__init__.py
+2
-0
check_manifest.py
src/action/check_manifest.py
+19
-0
No files found.
src/__main__.py
View file @
d365ae88
...
...
@@ -29,6 +29,8 @@ def main():
subparsers
=
parser
.
add_subparsers
(
title
=
"commands"
,
dest
=
"command"
)
check_env
=
subparsers
.
add_parser
(
"check-env"
,
help
=
"check environment for HDLMAKE-related settings"
)
check_manifest
=
subparsers
.
add_parser
(
"check-manifest"
,
help
=
"check manifest for formal correctness"
)
check_manifest
.
add_argument
(
"--top"
,
help
=
"indicate path to the top manifest"
,
default
=
None
)
manifest_help
=
subparsers
.
add_parser
(
"manifest-help"
,
help
=
"print manifest file variables description"
)
make_sim
=
subparsers
.
add_parser
(
"make-sim"
,
help
=
"generate a simulation Makefile"
)
make_sim
.
add_argument
(
"--append"
,
help
=
"append generated makefile to the existing one"
,
default
=
False
,
action
=
"store_true"
)
...
...
@@ -85,6 +87,8 @@ def main():
if
options
.
command
==
"check-env"
:
env
.
check_env
(
verbose
=
True
)
quit
()
if
options
.
command
==
"check-manifest"
:
env
.
check_manifest
(
modules_pool
.
get_top_module
()
.
manifest
,
verbose
=
True
)
modules_pool
.
process_top_module_manifest
()
...
...
src/action/__init__.py
View file @
d365ae88
#!/usr/bin/env python
from
check_manifest
import
CheckManifest
from
clean
import
CleanModules
from
default
import
Default
from
fetch
import
FetchModules
...
...
@@ -12,3 +13,4 @@ from merge_cores import MergeCores
from
quartus_project
import
GenerateQuartusProject
from
remote_synthesis
import
GenerateRemoteSynthesisMakefile
from
simulation
import
GenerateSimulationMakefile
src/action/check_manifest.py
0 → 100644
View file @
d365ae88
from
action
import
Action
from
manifest_parser
import
ManifestParser
class
CheckManifest
(
Action
):
def
_check_options
(
self
):
if
not
self
.
options
.
top
:
logging
.
info
(
"--top is not specified. Current manifest will be treated as the top manifest"
)
def
run
(
self
):
###
### THIS IS JUST A STUB
###
manifest_parser
=
ManifestParser
()
manifest_parser
.
add_arbitrary_code
(
"__manifest=
\"
"
+
self
.
path
+
"
\"
"
)
manifest_parser
.
add_arbitrary_code
(
global_mod
.
options
.
arbitrary_code
)
opt_map
=
manifest_parser
.
parse
()
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