Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
gaoqiong
MIGraphX
Commits
97ea1a39
Commit
97ea1a39
authored
Jun 08, 2018
by
Paul
Browse files
Run in gdb
parent
fd92f1ab
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
13 deletions
+1
-13
test/CMakeLists.txt
test/CMakeLists.txt
+1
-13
No files found.
test/CMakeLists.txt
View file @
97ea1a39
...
...
@@ -26,19 +26,7 @@ function(add_test_command NAME EXE)
add_test
(
NAME
${
NAME
}
COMMAND
${
WINE_CMD
}
cmd /c
"
${
CMAKE_CURRENT_BINARY_DIR
}
/test_
${
NAME
}
.cmd"
$<TARGET_FILE:
${
EXE
}
>
)
else
()
if
(
RTG_TEST_GDB
)
file
(
GENERATE OUTPUT
"
${
CMAKE_CURRENT_BINARY_DIR
}
/test_
${
NAME
}
.cmake"
CONTENT
"
execute_process(COMMAND $<TARGET_FILE:
${
EXE
}
>
${
ARGN
}
RESULT_VARIABLE RESULT)
if(NOT RESULT EQUAL 0)
if(EXISTS core)
execute_process(COMMAND gdb $<TARGET_FILE:
${
EXE
}
> core -batch -ex bt)
else()
message(
\"
No core dump
\"
)
endif()
message(FATAL_ERROR
\"
Test failed
\"
)
endif()
"
)
add_test
(
NAME
${
NAME
}
COMMAND
${
CMAKE_COMMAND
}
-P
"
${
CMAKE_CURRENT_BINARY_DIR
}
/test_
${
NAME
}
.cmake"
)
add_test
(
NAME
${
NAME
}
COMMAND gdb --batch --return-child-result -ex r -ex bt --args $<TARGET_FILE:
${
EXE
}
>
${
ARGN
}
)
else
()
add_test
(
NAME
${
NAME
}
COMMAND
${
EXE
}
${
ARGN
}
)
endif
()
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a 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