forked from stepcode/stepcode
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathinverse_qualifiers.cmake
More file actions
29 lines (22 loc) · 957 Bytes
/
inverse_qualifiers.cmake
File metadata and controls
29 lines (22 loc) · 957 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
cmake_minimum_required( VERSION 3.12 )
# executable is ${EXPPP}, input file is ${INFILE}
set( ofile "inverse_qual_out.exp" )
execute_process( COMMAND ${EXPPP} -o ${ofile} ${INFILE}
RESULT_VARIABLE CMD_RESULT )
if( NOT ${CMD_RESULT} EQUAL 0 )
message(FATAL_ERROR "Error running ${EXPPP} on ${INFILE}")
endif( NOT ${CMD_RESULT} EQUAL 0 )
# file( READ ${INFILE} pretty_in LIMIT 1024 )
file( READ ${ofile} pretty_out LIMIT 1024 )
# SELF\product_occurrence.occurrence_contexts : SET [1 : ?] OF assembly_component_relationship FOR related_view;
# one backslash balloons into 4 x(
string( REGEX MATCH " *SELF *\\\\ *product_occurrence *\\. *occurrence_contexts *: *SET *\\[ *1 *:" match_result ${pretty_out} )
if( match_result STREQUAL "" )
message( FATAL_ERROR "Pretty printer output does not match input." )
endif( match_result STREQUAL "" )
# Local Variables:
# tab-width: 8
# mode: cmake
# indent-tabs-mode: t
# End:
# ex: shiftwidth=2 tabstop=8