Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
A
autoicon
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
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
w2w
autoicon
Commits
673d5171
Commit
673d5171
authored
1 year ago
by
Oriol Tintó
Browse files
Options
Downloads
Patches
Plain Diff
Add libxml2 dependency to dwd-icon-tools.
parent
dbcbd9d1
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Pipeline
#18938
failed
1 year ago
Stage: everything
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
spack_repo/packages/dwd-icon-tools/package.py
+23
-22
23 additions, 22 deletions
spack_repo/packages/dwd-icon-tools/package.py
with
23 additions
and
22 deletions
spack_repo/packages/dwd-icon-tools/package.py
+
23
−
22
View file @
673d5171
...
...
@@ -46,27 +46,28 @@ class DwdIconTools(Package):
depends_on
(
"
netcdf-c
"
)
depends_on
(
"
eccodes
"
)
def
patch
(
self
):
"""
Because of the lack of access rights to the original submodule repositories,
we patch the gitmodules file to point to a different mirror.
"""
git_submodules_file
=
Path
().
cwd
()
/
"
.gitmodules
"
git_mirror
=
"
git@gitlab.lrz.de:dkrz-mirror
"
git_modules_patch
=
f
"""
[submodule
"
externals/libcdi
"
]
path = externals/libcdi
url =
{
git_mirror
}
/libcdi.git
"""
# Replace the content of the original file with the patch
with
git_submodules_file
.
open
(
"
w
"
)
as
out_f
:
out_f
.
write
(
git_modules_patch
)
# Run git submodule update
git
=
which
(
"
git
"
)
git
(
"
submodule
"
,
"
update
"
,
"
--init
"
,
"
--recursive
"
)
depends_on
(
"
libxml2
"
)
#
# def patch(self):
# """
# Because of the lack of access rights to the original submodule repositories,
# we patch the gitmodules file to point to a different mirror.
# """
# git_submodules_file = Path().cwd() / ".gitmodules"
# git_mirror = "git@gitlab.lrz.de:dkrz-mirror"
# git_modules_patch = f"""
# [submodule "externals/libcdi"]
# path = externals/libcdi
# url = {git_mirror}/libcdi.git
# """
#
# # Replace the content of the original file with the patch
# with git_submodules_file.open("w") as out_f:
# out_f.write(git_modules_patch)
#
# # Run git submodule update
# git = which("git")
# git("submodule", "update", "--init", "--recursive")
def
setup_build_environment
(
self
,
env
):
...
...
@@ -78,7 +79,7 @@ class DwdIconTools(Package):
# "F77": spec["mpi"].mpif77,
"
CXXFLAGS
"
:
"
-O2 -g -fopenmp -Wunused -DNOMPI
"
,
"
FCFLAGS
"
:
"
-I/usr/include --std=f2008 -O2 -g -cpp -fopenmp -fbounds-check -Wunused -DNOMPI
"
,
"
LIBS
"
:
"
-leccodes -lgfortran -lhdf5 -lxml2
"
,
"
LIBS
"
:
f
"
-L
{
spec
[
'
libxml2
'
].
prefix
.
lib
}
-leccodes -lgfortran -lhdf5 -lxml2
"
,
}
for
variable
,
value
in
env_variables_to_set
.
items
():
env
.
set
(
variable
,
value
)
...
...
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