summaryrefslogtreecommitdiffstats
path: root/Tests/RunCMake/CMP0139/CMP0139-NEW.cmake
blob: 81446962584988d112679ae2e1b2f69df3845ba1 (plain)
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
cmake_policy(SET CMP0139 NEW)


set(path "a///b/c")
if (NOT path PATH_EQUAL "a/b/c")
  message(SEND_ERROR "if(PATH_EQUAL): '${path}' not equal to 'a/b/c'")
endif()
set(path2 "a/b/c")
if (NOT path PATH_EQUAL path2)
  message(SEND_ERROR "if(PATH_EQUAL): '${path}' not equal to '${path2}'")
endif()

set (path "a/b/d/../c")
if (path PATH_EQUAL "a/b/c")
  message(SEND_ERROR "if(PATH_EQUAL): '${path}' equal to 'a/b/c'")
endif()
set(path2 "a/b/c")
if ("a/b/d/../c" PATH_EQUAL path2)
  message(SEND_ERROR "if(PATH_EQUAL): 'a/b/d/../c' equal to '${path2}'")
endif()

cmake_path(NORMAL_PATH path)
if (NOT path PATH_EQUAL "a/b/c")
  message(SEND_ERROR "if(PATH_EQUAL): '${path}' not equal to 'a/b/c'")
endif()