equal
deleted
inserted
replaced
2 # NOTE, a generator may set CMAKE_Pascal_COMPILER before |
2 # NOTE, a generator may set CMAKE_Pascal_COMPILER before |
3 # loading this file to force a compiler. |
3 # loading this file to force a compiler. |
4 # use environment variable Pascal first if defined by user, next use |
4 # use environment variable Pascal first if defined by user, next use |
5 # the cmake variable CMAKE_GENERATOR_PASCAL which can be defined by a generator |
5 # the cmake variable CMAKE_GENERATOR_PASCAL which can be defined by a generator |
6 # as a default compiler |
6 # as a default compiler |
|
7 |
|
8 # NOTE: on Darwin cmake >= 2.8.11 until cmake <= 2.8.12.1 will add an incompatible |
|
9 # -F flag to <FLAGS> so you won't be able to use those versions with this script |
7 |
10 |
8 if(NOT CMAKE_Pascal_COMPILER) |
11 if(NOT CMAKE_Pascal_COMPILER) |
9 # prefer the environment variable FPC |
12 # prefer the environment variable FPC |
10 if($ENV{FPC} MATCHES ".+") |
13 if($ENV{FPC} MATCHES ".+") |
11 get_filename_component(CMAKE_Pascal_COMPILER_INIT $ENV{FPC} PROGRAM PROGRAM_ARGS CMAKE_Pascal_FLAGS_ENV_INIT) |
14 get_filename_component(CMAKE_Pascal_COMPILER_INIT $ENV{FPC} PROGRAM PROGRAM_ARGS CMAKE_Pascal_FLAGS_ENV_INIT) |