Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
Lustrec - public version
Manage
Activity
Members
Labels
Plan
Issues
0
Issue boards
Milestones
Iterations
Wiki
Requirements
Code
Merge requests
0
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package Registry
Container Registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
LustreC
Lustrec - public version
Commits
ecba3795
Commit
ecba3795
authored
8 years ago
by
Frédéric Boniol
Browse files
Options
Downloads
Patches
Plain Diff
add lusi option
parent
30f766ab
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
share/FindLustre.cmake
+18
-1
18 additions, 1 deletion
share/FindLustre.cmake
with
18 additions
and
1 deletion
share/FindLustre.cmake
+
18
−
1
View file @
ecba3795
...
@@ -17,6 +17,7 @@
...
@@ -17,6 +17,7 @@
# LUS_FILES <Lustre files>
# LUS_FILES <Lustre files>
# [USER_C_FILES <C files>]
# [USER_C_FILES <C files>]
# [VERBOSE <level>]
# [VERBOSE <level>]
# [LUSI]
# LIBNAME <libraryName>)
# LIBNAME <libraryName>)
#
#
# When used the Lustre_Compile macro define the variable
# When used the Lustre_Compile macro define the variable
...
@@ -72,11 +73,15 @@ find_path(LUSTRE_INCLUDE_DIR
...
@@ -72,11 +73,15 @@ find_path(LUSTRE_INCLUDE_DIR
# Macros used to compile a lustre library
# Macros used to compile a lustre library
include
(
CMakeParseArguments
)
include
(
CMakeParseArguments
)
function
(
Lustre_Compile
)
function
(
Lustre_Compile
)
set
(
options
""
)
set
(
options
LUSI
)
set
(
oneValueArgs NODE LIBNAME VERBOSE
)
set
(
oneValueArgs NODE LIBNAME VERBOSE
)
set
(
multiValueArgs LUS_FILES USER_C_FILES
)
set
(
multiValueArgs LUS_FILES USER_C_FILES
)
cmake_parse_arguments
(
LUS
"
${
options
}
"
"
${
oneValueArgs
}
"
"
${
multiValueArgs
}
"
${
ARGN
}
)
cmake_parse_arguments
(
LUS
"
${
options
}
"
"
${
oneValueArgs
}
"
"
${
multiValueArgs
}
"
${
ARGN
}
)
if
(
LUS_LUSI
)
set
(
LUSTRE_LUSI_OPT
"-lusi"
)
endif
()
if
(
NOT LUS_LIBNAME
)
if
(
NOT LUS_LIBNAME
)
message
(
FATAL_ERROR
"You should specify LIBNAME for each Lustre_Compile call."
)
message
(
FATAL_ERROR
"You should specify LIBNAME for each Lustre_Compile call."
)
endif
()
endif
()
...
@@ -110,6 +115,18 @@ function(Lustre_Compile)
...
@@ -110,6 +115,18 @@ function(Lustre_Compile)
endif
()
endif
()
list
(
APPEND GLOBAL_LUSTRE_GENERATED_C_FILES
${
LUSTRE_GENERATED_FILES
}
)
list
(
APPEND GLOBAL_LUSTRE_GENERATED_C_FILES
${
LUSTRE_GENERATED_FILES
}
)
set
(
LUSTRE_GENERATED_FILES
${
LUSTRE_GENERATED_FILES
}
${
LUSTRE_OUTPUT_DIR
}
/
${
L
}
.lusic
)
set
(
LUSTRE_GENERATED_FILES
${
LUSTRE_GENERATED_FILES
}
${
LUSTRE_OUTPUT_DIR
}
/
${
L
}
.lusic
)
if
(
LUS_LUSI
)
add_custom_command
(
OUTPUT
${
CMAKE_CURRENT_SOURCE_DIR
}
/
${
LFILE
}
i
#OUTPUT ${LUSTRE_OUTPUT_DIR}/${L}.lusi
COMMAND
${
LUSTRE_COMPILER
}
${
LUSTRE_LUSI_OPT
}
${
LFILE
}
#COMMAND ${CMAKE_COMMAND} -E rename ${L}.lusi ${LUSTRE_OUTPUT_DIR}/${L}.lusi
DEPENDS
${
CMAKE_CURRENT_SOURCE_DIR
}
/
${
LFILE
}
WORKING_DIRECTORY
${
CMAKE_CURRENT_SOURCE_DIR
}
COMMENT
"Compile Lustre source(s):
${
LFILE
}
with option -lusi."
)
message
(
STATUS
"lustrec will produce lusi file:
${
LFILE
}
i"
)
endif
()
add_custom_command
(
add_custom_command
(
OUTPUT
${
LUSTRE_GENERATED_FILES
}
OUTPUT
${
LUSTRE_GENERATED_FILES
}
COMMAND
${
LUSTRE_COMPILER
}
${
LUSTRE_VERBOSE_OPT
}
${
LUSTRE_NODE_OPT
}
-d
${
LUSTRE_OUTPUT_DIR
}
${
LFILE
}
COMMAND
${
LUSTRE_COMPILER
}
${
LUSTRE_VERBOSE_OPT
}
${
LUSTRE_NODE_OPT
}
-d
${
LUSTRE_OUTPUT_DIR
}
${
LFILE
}
...
...
This diff is collapsed.
Click to expand it.
Preview
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!
Save comment
Cancel
Please
register
or
sign in
to comment