-
Notifications
You must be signed in to change notification settings - Fork 4
/
build-qwt.cmake
30 lines (26 loc) · 745 Bytes
/
build-qwt.cmake
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
29
30
set(CTEST_PROJECT_NAME "qwt")
set(CTEST_BUILD_NAME "$ENV{SGEN}-qwt")
set(CTEST_SITE "$ENV{COMPUTERNAME}")
# rewrite qwtconfig.pri QWT_INSTALL_PREFIX
FILE(RENAME
${CTEST_SCRIPT_DIRECTORY}/lib/src/qwt-${VER}/qwtconfig.pri
${CTEST_SCRIPT_DIRECTORY}/lib/src/qwt-${VER}/qwtconfig.pri.orig
)
FILE(STRINGS
${CTEST_SCRIPT_DIRECTORY}/lib/src/qwt-${VER}/qwtconfig.pri.orig
lines
)
foreach(line IN LISTS lines)
if (line)
STRING(REGEX REPLACE
"/usr/local/qwt-\\$\\$QWT_VERSION"
"${CTEST_SCRIPT_DIRECTORY}/lib/install/qwt-${VER}"
new_line ${line})
else()
set(new_line ${line})
endif()
file(APPEND
${CTEST_SCRIPT_DIRECTORY}/lib/src/qwt-${VER}/qwtconfig.pri
"${new_line}\n"
)
endforeach()