Re: [CMake] Bad flags being passed to NAG Fortran compiler

2013-02-18 Thread Neil Carlson
Thanks Petr, the ID variable was exactly what I needed. On Mon, Feb 18, 2013 at 1:24 AM, Alan W. Irwin wrote: > I would also try setting > > set(CMAKE_Fortran_COMPILE_**OPTIONS_PIC "-PIC") > > in Modules/Compiler/NAG-Fortran.**cmake as well to see if that > completely satisfies your needs. > I s

Re: [CMake] comparing strings

2013-02-18 Thread Shaun Williams
Thanks, I will be using this method: if (myvar MATCHES "^somestring$") endif() Do NOT use "${myvar}" because that forces CMake to treat the value of myvar as a variable name if it exists. That will give you accidentally indirection that may point to the value of another string. On Fri, Feb 15,

[CMake] Remove _MBCS

2013-02-18 Thread YanmingZou
Hi, I am developing an application on windows with VS2012 and CMake (2.8.10.2). I want to use unicode in my program, so I add UNICODE and _UNICODE with ADD_DEFINITIONS. However, there is always a _MBCS marco in the generated project file. The project can be compiled, but I am not happy with that

Re: [CMake] Bad flags being passed to NAG Fortran compiler

2013-02-18 Thread Alan W. Irwin
Hi Neil: I have no experience with the NAG Fortran compiler, but just to get the discussion rolling, I think I can guess at the answer to your principal question below. On 2013-02-17 17:13-0700 Neil Carlson wrote: When building a shared library using the NAG Fortran compiler, cmake is invoking

Re: [CMake] Bad flags being passed to NAG Fortran compiler

2013-02-18 Thread Petr Kmoch
Hi Neil. I can only answer your question 3: there are variables like CMAKE_Fortran_COMPILER and CMAKE_Fortran_COMPILER_ID which you could use for this purpose. They're documented as CMAKE__COMPILER etc. under "Variables for Languages". Petr On Mon, Feb 18, 2013 at 1:13 AM, Neil Carlson wrote: >