|
3 | 3 | # See the FindMathematica manual for usage hints. |
4 | 4 | # |
5 | 5 | #============================================================================= |
6 | | -# Copyright 2010-2024 Sascha Kratky |
| 6 | +# Copyright 2010-2025 Sascha Kratky |
7 | 7 | # |
8 | 8 | # Permission is hereby granted, free of charge, to any person) |
9 | 9 | # obtaining a copy of this software and associated documentation) |
|
28 | 28 | #============================================================================= |
29 | 29 |
|
30 | 30 | # we need the CMakeParseArguments module |
31 | | -# call cmake_minimum_required, but prevent modification of the CMake policy stack |
32 | | -cmake_policy(PUSH) |
33 | | -cmake_minimum_required(VERSION 3.5.0) |
34 | | -cmake_policy(POP) |
| 31 | +cmake_minimum_required(VERSION 3.10..3.31) |
35 | 32 |
|
36 | 33 | set (Mathematica_CMAKE_MODULE_DIR "${CMAKE_CURRENT_LIST_DIR}") |
37 | | -set (Mathematica_CMAKE_MODULE_VERSION "4.0.0") |
38 | | - |
39 | | -# activate select policies |
40 | | -if (POLICY CMP0025) |
41 | | - # Compiler id for Apple Clang is now AppleClang |
42 | | - cmake_policy(SET CMP0025 NEW) |
43 | | -endif() |
44 | | - |
45 | | -if (POLICY CMP0026) |
46 | | - # disallow use of the LOCATION target property |
47 | | - if (CYGWIN OR MSYS) |
48 | | - # Cygwin and MSYS do not produce workable Mathematica paths using |
49 | | - # the $<TARGET_FILE:...> notation |
50 | | - cmake_policy(SET CMP0026 OLD) |
51 | | - else() |
52 | | - cmake_policy(SET CMP0026 NEW) |
53 | | - endif() |
54 | | -endif() |
55 | | - |
56 | | -if (POLICY CMP0038) |
57 | | - # targets may not link directly to themselves |
58 | | - cmake_policy(SET CMP0038 NEW) |
59 | | -endif() |
60 | | - |
61 | | -if (POLICY CMP0039) |
62 | | - # utility targets may not have link dependencies |
63 | | - cmake_policy(SET CMP0039 NEW) |
64 | | -endif() |
65 | | - |
66 | | -if (POLICY CMP0040) |
67 | | - # target in the TARGET signature of add_custom_command() must exist |
68 | | - cmake_policy(SET CMP0040 NEW) |
69 | | -endif() |
70 | | - |
71 | | -if (POLICY CMP0045) |
72 | | - # error on non-existent target in get_target_property |
73 | | - cmake_policy(SET CMP0045 NEW) |
74 | | -endif() |
75 | | - |
76 | | -if (POLICY CMP0046) |
77 | | - # error on non-existent dependency in add_dependencies |
78 | | - cmake_policy(SET CMP0046 NEW) |
79 | | -endif() |
80 | | - |
81 | | -if (POLICY CMP0049) |
82 | | - # do not expand variables in target source entries |
83 | | - cmake_policy(SET CMP0049 NEW) |
84 | | -endif() |
85 | | - |
86 | | -if (POLICY CMP0050) |
87 | | - # disallow add_custom_command SOURCE signatures |
88 | | - cmake_policy(SET CMP0050 NEW) |
89 | | -endif() |
90 | | - |
91 | | -if (POLICY CMP0051) |
92 | | - # include TARGET_OBJECTS expressions in a target's SOURCES property |
93 | | - cmake_policy(SET CMP0051 NEW) |
94 | | -endif() |
95 | | - |
96 | | -if (POLICY CMP0053) |
97 | | - # simplify variable reference and escape sequence evaluation |
98 | | - cmake_policy(SET CMP0053 NEW) |
99 | | -endif() |
100 | | - |
101 | | -if (POLICY CMP0054) |
102 | | - # only interpret if() arguments as variables or keywords when unquoted |
103 | | - cmake_policy(SET CMP0054 NEW) |
104 | | -endif() |
| 34 | +set (Mathematica_CMAKE_MODULE_VERSION "4.1.0") |
105 | 35 |
|
106 | 36 | include(TestBigEndian) |
107 | 37 | include(CMakeParseArguments) |
|
0 commit comments