Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
TASTE
dmt
Commits
64972430
Commit
64972430
authored
Oct 06, 2020
by
Thanassis Tsiodras
Committed by
Thanassis Tsiodras
Nov 17, 2020
Browse files
Ask ASN1SCC for 'all boards' support in a consistent manner that preserves legacy builds.
parent
208912f3
Changes
3
Hide whitespace changes
Inline
Side-by-side
dmt/A_mappers/ada_A_mapper.py
View file @
64972430
...
...
@@ -50,7 +50,7 @@ def OnStartup(unused_modelingLanguage: str, asnFiles: List[str], outputDir: str,
extraFlags
=
os
.
getenv
(
"ASN1SCC_FLAGS"
)
or
""
os
.
system
(
(
"mono "
if
sys
.
platform
.
startswith
(
'linux'
)
else
""
)
+
"
\"
{}
\"
-typePrefix asn1Scc -equal
--target allboards
-Ada {} -o
\"
"
.
format
(
asn1SccPath
,
extraFlags
)
+
"
\"
{}
\"
-typePrefix asn1Scc -equal -Ada {} -o
\"
"
.
format
(
asn1SccPath
,
extraFlags
)
+
outputDir
+
"
\"
\"
"
+
"
\"
\"
"
.
join
(
asnFiles
)
+
"
\"
"
)
# os.system("rm -f \"" + outputDir + "\"/*.adb")
...
...
dmt/aadl2glueC.py
View file @
64972430
...
...
@@ -244,7 +244,7 @@ types). This used to cover Dumpable C/Ada Types and OG headers.'''
if
asnFile
is
not
None
:
if
not
asn1SccPath
:
panic
(
"ASN1SCC seems not installed on your system (asn1.exe not found in PATH).
\n
"
)
# pragma: no cover
os
.
system
(
'mono "{}" -typePrefix asn1Scc {}
--target allboards
-Ada -equal -o "{}" "{}"'
os
.
system
(
'mono "{}" -typePrefix asn1Scc {} -Ada -equal -o "{}" "{}"'
.
format
(
asn1SccPath
,
extraFlags
,
outputDir
,
'" "'
.
join
([
asnFile
])))
...
...
@@ -501,6 +501,13 @@ def main() -> None:
import
pdb
# pragma: no cover pylint: disable=wrong-import-position,wrong-import-order
pdb
.
set_trace
()
# pragma: no cover
use_ASN1SCC_allboards_support
=
"-allboards"
in
sys
.
argv
if
use_ASN1SCC_allboards_support
:
sys
.
argv
.
remove
(
"-allboards"
)
# pragma: no cover
extraFlags
=
os
.
getenv
(
"ASN1SCC_FLAGS"
)
or
""
extraFlags
+=
" --target allboards "
os
.
putenv
(
"ASN1SCC_FLAGS"
,
extraFlags
)
if
"-profile"
in
sys
.
argv
:
sys
.
argv
.
remove
(
"-profile"
)
import
cProfile
...
...
dmt/asn2dataModel.py
View file @
64972430
...
...
@@ -86,6 +86,14 @@ def main() -> None:
import
pdb
# pragma: no cover pylint: disable=wrong-import-position,wrong-import-order
pdb
.
set_trace
()
# pragma: no cover
use_ASN1SCC_allboards_support
=
"-allboards"
in
sys
.
argv
if
use_ASN1SCC_allboards_support
:
sys
.
argv
.
remove
(
"-allboards"
)
# pragma: no cover
extraFlags
=
os
.
getenv
(
"ASN1SCC_FLAGS"
)
or
""
extraFlags
+=
" --target allboards "
os
.
putenv
(
"ASN1SCC_FLAGS"
,
extraFlags
)
if
"-v"
in
sys
.
argv
:
import
pkg_resources
# pragma: no cover
version
=
pkg_resources
.
require
(
"dmt"
)[
0
].
version
# pragma: no cover
...
...
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