https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=156901

[email protected] changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |[email protected]

--- Comment #11 from [email protected] ---
Works when specifying the compiler through the environment. In a sample
project, both of these build lines work:

    CC=cc cmake .. && make VERBOSE=1
    CC="/usr/bin/env THIS=THAT /usr/bin/cc" cmake .. && make VERBOSE=1

The CMake output for the latter is a little weird,

    -- Check for working C compiler: /usr/bin/env -- works

but not wrong. The OP notes this, as well. Current CMake even tells you, if you
try to use the command-line-definition approach, what is wrong:

cmake .. "-DCMAKE_C_COMPILER=/usr/bin/env THIS=THAT /usr/bin/cc"
-- The C compiler identification is unknown
CMake Error at CMakeLists.txt:2 (project):
  The CMAKE_C_COMPILER:

    /usr/bin/env THIS=THAT /usr/bin/cc

  is not a full path to an existing compiler tool.

  Tell CMake where to find the compiler by setting either the environment
  variable "CC" or the CMake cache entry CMAKE_C_COMPILER to the full path to
  the compiler, or to the compiler name if it is in the PATH.

This should be, as tcberner@ points out, picked up upstream, or filed under
"Don't Do That Then".

-- 
You are receiving this mail because:
You are the assignee for the bug.

Reply via email to