Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
H
HDL
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Requirements
Jira
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
RTSD
HDL
Commits
5bb1bed5
Commit
5bb1bed5
authored
5 years ago
by
Pieter Donker
Browse files
Options
Downloads
Patches
Plain Diff
changes in init files
parent
b8cb8ce9
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
init_hdl.sh
+21
-8
21 additions, 8 deletions
init_hdl.sh
with
21 additions
and
8 deletions
init_hdl.sh
+
21
−
8
View file @
5bb1bed5
...
@@ -34,29 +34,42 @@ if [[ "$_" == "${0}" ]]; then
...
@@ -34,29 +34,42 @@ if [[ "$_" == "${0}" ]]; then
exit
exit
fi
fi
#
if
[
-z
"
${
ALTERA_DIR
}
"
]
;
then
echo
"== environ variable 'ALTERA_DIR' not set. =="
echo
"should be in your .bashrc file."
echo
"if it is your .bashrc file but not active run bash in your terminal"
exit
fi
# Figure out where this script is located and set environment variables accordingly
# Figure out where this script is located and set environment variables accordingly
export
RADIOHDL_WORK
=
"
$(
cd
"
$(
dirname
"
${
BASH_SOURCE
[0]
}
"
)
"
&&
pwd
)
"
export
RADIOHDL_WORK
=
"
$(
cd
"
$(
dirname
"
${
BASH_SOURCE
[0]
}
"
)
"
&&
pwd
)
"
echo
"HDL environment will be setup for"
$RADIOHDL_WORK
# setup paths to build and config dir if not already defined by the user.
# setup paths to build and config dir if not already defined by the user.
export
ARGS_WORK
=
${
ARGS_WORK
:-${
RADIOHDL_WORK
}}
export
HDL_BUILD_DIR
=
${
HDL_BUILD_DIR
:-${
RADIOHDL_WORK
}
/build
}
export
HDL_BUILD_DIR
=
${
HDL_BUILD_DIR
:-${
RADIOHDL_WORK
}
/build
}
echo
"HDL environment will be setup for"
$RADIOHDL_WORK
# modelsim uses this sim dir for testing
# modelsim uses this sim dir for testing
export
HDL_IOFILE_SIM_DIR
=
${
HDL_IOFILE_SIM_DIR
:-${
HDL_BUILD_DIR
}
/sim
}
export
HDL_IOFILE_SIM_DIR
=
${
HDL_IOFILE_SIM_DIR
:-${
HDL_BUILD_DIR
}
/sim
}
if
!
[[
-e
HDL_IOFILE_SIM_DIR
]]
;
then
if
[[
!
-d
"
${
HDL_IOFILE_SIM_DIR
}
"
]]
;
then
echo
"make sim dir"
echo
"make sim dir"
mkdir
${
HDL_BUILD_DIR
}
/sim
mkdir
"
${
HDL_IOFILE_SIM_DIR
}
"
fi
# if sim dir not empty, remove all files and dirs
if
[
!
-z
"
$(
ls
-A
${
HDL_IOFILE_SIM_DIR
}
)
"
]
;
then
echo
"clear sim dir"
rm
-r
${
HDL_IOFILE_SIM_DIR
}
/
*
fi
fi
rm
-r
${
HDL_BUILD_DIR
}
/sim/
*
# copy git user_componets.ipx into Altera dir's
# copy git user_componets.ipx into Altera dir's
for
altera_dir
in
${
ALTERA_DIR
}
/
*
;
do
for
altera_dir
in
${
ALTERA_DIR
}
/
*
;
do
if
[[
-d
${
altera_dir
}
]]
&&
[[
!
-h
${
altera_dir
}
]]
;
then
if
[[
-d
"
${
altera_dir
}
"
]]
&&
[[
!
-h
"
${
altera_dir
}
"
]]
;
then
echo
"copy git hdl_user_components.ipx to
${
altera_dir
}
/ip/altera/user_components.ipx"
echo
"copy git hdl_user_components.ipx to
${
altera_dir
}
/ip/altera/user_components.ipx"
cp
${
RADIOHDL_WORK
}
/hdl_user_components.ipx
$altera_dir
/ip/altera/user_components.ipx
cp
${
RADIOHDL_WORK
}
/hdl_user_components.ipx
$altera_dir
/ip/altera/user_components.ipx
fi
fi
done
done
if
[
-z
"
${
RADIOHDL_GEAR
}
"
]
;
then
# source also radiohdl and args tools
.
../radiohdl/init_radiohdl.sh
.
../radiohdl/init_radiohdl.sh
fi
.
../args/init_args.sh
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
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!
Save comment
Cancel
Please
register
or
sign in
to comment