Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
TASTE
Ocarina
Commits
96289202
Commit
96289202
authored
Mar 02, 2020
by
Jerome Hugues
Browse files
* For AADLv2 runtime files (e.g. drivers), one cannot force relative
path shortcut For openaadl/ocarina#248
parent
3b85ace5
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/backends/ocarina-backends-build_utils.adb
View file @
96289202
...
...
@@ -74,9 +74,11 @@ package body Ocarina.Backends.Build_Utils is
-- Split the path made of Filename and Directory into Basename and
-- Dirname (with regular shell interpretations)
--
-- * If Relative_Path is true, we disregard Directory and assume
-- the base directory to be "../.." relative to the generated code
-- directory.
-- * If Relative_Path is true, and if Directory is not Ocarina
-- install directory (case of runtime library elements), then we
-- disregard Directory and assume the base directory to be "../.."
-- relative to the generated code directory.
--
-- * If Relative_Path is false, the full directory path is
-- resolved and is absolute to the user environment.
...
...
@@ -158,8 +160,20 @@ package body Ocarina.Backends.Build_Utils is
Dirname
:
out
Name_Id
;
Relative_Path
:
Boolean
:=
False
)
is
Temp_Dirname
:
Name_Id
:=
No_Name
;
AADL_Library_File
:
Boolean
:=
False
;
begin
if
Relative_Path
then
Temp_Dirname
:=
Get_String_Name
(
Normalize_Pathname
(
Get_Name_String
(
Directory
))
&
"/"
);
if
Temp_Dirname
=
Default_Library_Path
then
AADL_Library_File
:=
True
;
end
if
;
end
if
;
if
Relative_Path
and
then
not
AADL_Library_File
then
Set_Str_To_Name_Buffer
(
"../.."
);
elsif
Directory
=
No_Name
then
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new 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