Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
D
dune-common
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
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
Timo Koch
dune-common
Commits
7f43465d
Commit
7f43465d
authored
10 years ago
by
Dominic Kempf
Browse files
Options
Downloads
Patches
Plain Diff
[CMake] Do copies as a fall-back if symlinks are not available on the platform
There is still a warning issued in that case.
parent
b6987367
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
cmake/modules/DuneMacros.cmake
+13
-11
13 additions, 11 deletions
cmake/modules/DuneMacros.cmake
with
13 additions
and
11 deletions
cmake/modules/DuneMacros.cmake
+
13
−
11
View file @
7f43465d
...
...
@@ -1228,16 +1228,18 @@ endmacro(dune_symlink_to_source_tree)
# corresponding build directory. Use for ini files, grid files etc. A warning
# is issued on Windows systems.
macro
(
dune_symlink_to_source_files files
)
# check for Windwos to issue a warning
if
(
${
CMAKE_SYSTEM_NAME
}
STREQUAL
"Windows"
)
if
(
NOT DEFINED DUNE_WINDOWS_SYMLINK_WARNING
)
message
(
WARNING
"Your module wanted to create symlinks, but you cannot do that on your platform."
)
set
(
DUNE_WINDOWS_SYMLINK_WARNING
)
endif
()
else
()
# create symlinks for all given files
foreach
(
f
${
files
}
)
# create symlinks for all given files
foreach
(
f
${
files
}
)
# check for Windows to issue a warning
if
(
${
CMAKE_SYSTEM_NAME
}
STREQUAL
"Windows"
)
if
(
NOT DEFINED DUNE_WINDOWS_SYMLINK_WARNING
)
message
(
WARNING
"Your module wanted to create symlinks, but you cannot do that on your platform."
)
set
(
DUNE_WINDOWS_SYMLINK_WARNING
)
endif
()
dune_add_copy_command
(
${
f
}
)
else
()
# create symlink
execute_process
(
COMMAND
${
CMAKE_COMMAND
}
"-E"
"create_symlink"
"
${
CMAKE_CURRENT_SOURCE_DIR
}
/
${
f
}
"
"
${
CMAKE_CURRENT_BINARY_DIR
}
/
${
f
}
"
)
endf
oreach
()
end
i
f
()
end
i
f
()
endf
oreach
()
endmacro
(
dune_symlink_to_source_files files
)
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