[CMake] CMake Visual Studio 64bit flag?

2010-10-08 Thread Peter Clemenko
Hello, I'm trying to work on creating a precompiled binary package for a
project I'm working on, and I was wondering if there was any way to
configure CMake to select a folder based on whether or not the 64bit version
of Visual studio was selected for the library path. The library path would
be something similar to:

lib
|-vs8
|--x86
|--x64
|-vs9
|--x86
|--x64
|-vs10
|--x86
|--x64

Is there any flag I can use in my Find.cmake files in order select the
library path based on if 64 bit or 32 bit is selected?

Thanks,
Peter
___
Powered by www.kitware.com

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Follow this link to subscribe/unsubscribe:
http://www.cmake.org/mailman/listinfo/cmake

Re: [CMake] CMake Visual Studio 64bit flag?

2010-10-08 Thread Michael Jackson

maybe SIZE_OF_VOID_POINTER of whatever that variable is in CMake?
___
Mike Jackson  www.bluequartz.net
Principal Software Engineer   mike.jack...@bluequartz.net
BlueQuartz Software   Dayton, Ohio



On Oct 8, 2010, at 11:35 AM, Peter Clemenko wrote:

Hello, I'm trying to work on creating a precompiled binary package  
for a project I'm working on, and I was wondering if there was any  
way to configure CMake to select a folder based on whether or not  
the 64bit version of Visual studio was selected for the library  
path. The library path would be something similar to:


lib
|-vs8
|--x86
|--x64
|-vs9
|--x86
|--x64
|-vs10
|--x86
|--x64

Is there any flag I can use in my Find.cmake files in order select  
the library path based on if 64 bit or 32 bit is selected?


Thanks,
Peter
___
Powered by www.kitware.com

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Follow this link to subscribe/unsubscribe:
http://www.cmake.org/mailman/listinfo/cmake


___
Powered by www.kitware.com

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Follow this link to subscribe/unsubscribe:
http://www.cmake.org/mailman/listinfo/cmake


Re: [CMake] CMake Visual Studio 64bit flag?

2010-10-08 Thread Mateusz Loskot

On 08/10/10 16:42, Michael Jackson wrote:

maybe SIZE_OF_VOID_POINTER of whatever that variable is in CMake?


In SOCI library, I use something like this:

if(UNIX AND CMAKE_SIZEOF_VOID_P EQUAL 4)
  set(SOCI_LIBDIR lib64)
else()
  set(SOCI_LIBDIR lib)
endif()

Best regards,
--
Mateusz Loskot, http://mateusz.loskot.net
Charter Member of OSGeo, http://osgeo.org
Member of ACCU, http://accu.org
___
Powered by www.kitware.com

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Follow this link to subscribe/unsubscribe:
http://www.cmake.org/mailman/listinfo/cmake


Re: [CMake] CMake Visual Studio 64bit flag?

2010-10-08 Thread David Cole
Either you've got that reversed, or 4 should be 8... right?

lib64 should be for an 8-byte void* ...


On Fri, Oct 8, 2010 at 11:48 AM, Mateusz Loskot mate...@loskot.net wrote:

 On 08/10/10 16:42, Michael Jackson wrote:

 maybe SIZE_OF_VOID_POINTER of whatever that variable is in CMake?


 In SOCI library, I use something like this:

 if(UNIX AND CMAKE_SIZEOF_VOID_P EQUAL 4)
  set(SOCI_LIBDIR lib64)
 else()
  set(SOCI_LIBDIR lib)
 endif()

 Best regards,
 --
 Mateusz Loskot, http://mateusz.loskot.net
 Charter Member of OSGeo, http://osgeo.org
 Member of ACCU, http://accu.org

 ___
 Powered by www.kitware.com

 Visit other Kitware open-source projects at
 http://www.kitware.com/opensource/opensource.html

 Please keep messages on-topic and check the CMake FAQ at:
 http://www.cmake.org/Wiki/CMake_FAQ

 Follow this link to subscribe/unsubscribe:
 http://www.cmake.org/mailman/listinfo/cmake

___
Powered by www.kitware.com

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Follow this link to subscribe/unsubscribe:
http://www.cmake.org/mailman/listinfo/cmake

Re: [CMake] CMake Visual Studio 64bit flag?

2010-10-08 Thread Mateusz Loskot

Yes, you are right.
My mistake.

Thanks!
Mat


On 08/10/10 16:51, David Cole wrote:

Either you've got that reversed, or 4 should be 8... right?

lib64 should be for an 8-byte void* ...


On Fri, Oct 8, 2010 at 11:48 AM, Mateusz Loskot mate...@loskot.net
mailto:mate...@loskot.net wrote:

On 08/10/10 16:42, Michael Jackson wrote:

maybe SIZE_OF_VOID_POINTER of whatever that variable is in CMake?


In SOCI library, I use something like this:

if(UNIX AND CMAKE_SIZEOF_VOID_P EQUAL 4)
  set(SOCI_LIBDIR lib64)
else()
  set(SOCI_LIBDIR lib)
endif()

Best regards,
--
Mateusz Loskot, http://mateusz.loskot.net
Charter Member of OSGeo, http://osgeo.org
Member of ACCU, http://accu.org

___
Powered by www.kitware.com http://www.kitware.com

Visit other Kitware open-source projects at
http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the CMake FAQ at:
http://www.cmake.org/Wiki/CMake_FAQ

Follow this link to subscribe/unsubscribe:
http://www.cmake.org/mailman/listinfo/cmake





--
Mateusz Loskot, http://mateusz.loskot.net
Charter Member of OSGeo, http://osgeo.org
Member of ACCU, http://accu.org
___
Powered by www.kitware.com

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Follow this link to subscribe/unsubscribe:
http://www.cmake.org/mailman/listinfo/cmake


Re: [CMake] CMake Visual Studio 64bit flag?

2010-10-08 Thread aaron.meadows
Is this not sufficient: (from Variables That Describe the System)

 

CMAKE_CL_64: Using the 64 bit compiler from Microsoft

 

Set to true when using the 64 bit cl compiler from Microsoft.

 

This is what I'm intending on using, so if this won't work, I'll need to
know...

 

Aaron C. Meadows 



From: cmake-boun...@cmake.org [mailto:cmake-boun...@cmake.org] On Behalf
Of Peter Clemenko
Sent: Friday, October 08, 2010 10:35 AM
To: cmake@cmake.org
Subject: [CMake] CMake Visual Studio 64bit flag?

 

Hello, I'm trying to work on creating a precompiled binary package for a
project I'm working on, and I was wondering if there was any way to
configure CMake to select a folder based on whether or not the 64bit
version of Visual studio was selected for the library path. The library
path would be something similar to:

 

lib

|-vs8

|--x86

|--x64

|-vs9

|--x86

|--x64

|-vs10

|--x86

|--x64

 

Is there any flag I can use in my Find.cmake files in order select the
library path based on if 64 bit or 32 bit is selected?

 

Thanks,

Peter



This email was sent to you by Thomson Reuters, the global news and information 
company.
Any views expressed in this message are those of the individual sender, except 
where the sender specifically states them to be the views of Thomson Reuters.

___
Powered by www.kitware.com

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Follow this link to subscribe/unsubscribe:
http://www.cmake.org/mailman/listinfo/cmake

Re: [CMake] CMake Visual Studio 64bit flag?

2010-10-08 Thread Rolf Eike Beer
Am Friday 08 October 2010 schrieb aaron.mead...@thomsonreuters.com:
 Is this not sufficient: (from Variables That Describe the System)
 
 CMAKE_CL_64: Using the 64 bit compiler from Microsoft
 
 Set to true when using the 64 bit cl compiler from Microsoft.
 
 This is what I'm intending on using, so if this won't work, I'll need to
 know...

IIRC that doesn't work if you use the Studio generator (i.e. not Makefiles). So 
this needs to be something like if (CMAKE_CL_64 or CMAKE_GENERATOR MATCHES 
Win64)

Eike


signature.asc
Description: This is a digitally signed message part.
___
Powered by www.kitware.com

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Follow this link to subscribe/unsubscribe:
http://www.cmake.org/mailman/listinfo/cmake

Re: [CMake] CMake Visual Studio 64bit flag?

2010-10-08 Thread aaron.meadows
Seems to work correctly from my tests:

 

CMakeLists.txt:

cmake_minimum_required (VERSION 2.8)

 

project(test CXX)

message( STATUS CMAKE_GENERATOR: ${CMAKE_GENERATOR})

message( STATUS CMAKE_CL_64: ${CMAKE_CL_64})

 

 

 

c:\dev2\Builds\test\x64cmake -G Visual Studio 8 2005 ../.

-- Check for working CXX compiler using: Visual Studio 8 2005

-- Check for working CXX compiler using: Visual Studio 8 2005 -- works

-- Detecting CXX compiler ABI info

-- Detecting CXX compiler ABI info - done

-- CMAKE_GENERATOR: Visual Studio 8 2005

-- CMAKE_CL_64: 0

-- Configuring done

-- Generating done

-- Build files have been written to: C:/dev2/Builds/test/x64

 

 

c:\dev2\Builds\test\x86cmake -G Visual Studio 8 2005 Win64 ../.

-- Check for working CXX compiler using: Visual Studio 8 2005 Win64

-- Check for working CXX compiler using: Visual Studio 8 2005 Win64 --
works

-- Detecting CXX compiler ABI info

-- Detecting CXX compiler ABI info - done

-- CMAKE_GENERATOR: Visual Studio 8 2005 Win64

-- CMAKE_CL_64: 1

-- Configuring done

-- Generating done

-- Build files have been written to: C:/dev2/Builds/test/x86

 

 

 

 

Aaron C. Meadows 

 

-Original Message-
From: cmake-boun...@cmake.org [mailto:cmake-boun...@cmake.org] On Behalf
Of Rolf Eike Beer
Sent: Friday, October 08, 2010 11:33 AM
To: cmake@cmake.org
Subject: Re: [CMake] CMake Visual Studio 64bit flag?

 

Am Friday 08 October 2010 schrieb aaron.mead...@thomsonreuters.com:

 Is this not sufficient: (from Variables That Describe the System)

 

 CMAKE_CL_64: Using the 64 bit compiler from Microsoft

 

 Set to true when using the 64 bit cl compiler from Microsoft.

 

 This is what I'm intending on using, so if this won't work, I'll need
to

 know...

 

IIRC that doesn't work if you use the Studio generator (i.e. not
Makefiles). So 

this needs to be something like if (CMAKE_CL_64 or CMAKE_GENERATOR
MATCHES 

Win64)

 

Eike



This email was sent to you by Thomson Reuters, the global news and information 
company.
Any views expressed in this message are those of the individual sender, except 
where the sender specifically states them to be the views of Thomson Reuters.

___
Powered by www.kitware.com

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Follow this link to subscribe/unsubscribe:
http://www.cmake.org/mailman/listinfo/cmake

Re: [CMake] CMake Visual Studio 64bit flag?

2010-10-08 Thread John Drescher
On Fri, Oct 8, 2010 at 12:50 PM,  aaron.mead...@thomsonreuters.com wrote:
 Seems to work correctly from my tests:



 CMakeLists.txt:

 cmake_minimum_required (VERSION 2.8)



 project(test CXX)

 message( STATUS CMAKE_GENERATOR: ${CMAKE_GENERATOR})

 message( STATUS CMAKE_CL_64: ${CMAKE_CL_64})







 c:\dev2\Builds\test\x64cmake -G Visual Studio 8 2005 ../.

 -- Check for working CXX compiler using: Visual Studio 8 2005

 -- Check for working CXX compiler using: Visual Studio 8 2005 -- works

 -- Detecting CXX compiler ABI info

 -- Detecting CXX compiler ABI info - done

 -- CMAKE_GENERATOR: Visual Studio 8 2005

 -- CMAKE_CL_64: 0

 -- Configuring done

 -- Generating done

 -- Build files have been written to: C:/dev2/Builds/test/x64





 c:\dev2\Builds\test\x86cmake -G Visual Studio 8 2005 Win64 ../.

 -- Check for working CXX compiler using: Visual Studio 8 2005 Win64

 -- Check for working CXX compiler using: Visual Studio 8 2005 Win64 -- works

 -- Detecting CXX compiler ABI info

 -- Detecting CXX compiler ABI info - done

 -- CMAKE_GENERATOR: Visual Studio 8 2005 Win64

 -- CMAKE_CL_64: 1

 -- Configuring done

 -- Generating done

 -- Build files have been written to: C:/dev2/Builds/test/x86



I believe you got your folder names backwards.
John
___
Powered by www.kitware.com

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Follow this link to subscribe/unsubscribe:
http://www.cmake.org/mailman/listinfo/cmake


Re: [CMake] CMake Visual Studio 64bit flag?

2010-10-08 Thread aaron.meadows
Thanks for pointing that out.. not that it effects the example in the
slightest... they could have been Bozo and Crusty and still prove it
works.  =D

Aaron C. Meadows 

-Original Message-
From: John Drescher [mailto:dresche...@gmail.com] 
Sent: Friday, October 08, 2010 11:52 AM
To: Meadows, Aaron C.
Cc: e...@sf-mail.de; cmake@cmake.org
Subject: Re: [CMake] CMake Visual Studio 64bit flag?

On Fri, Oct 8, 2010 at 12:50 PM,  aaron.mead...@thomsonreuters.com
wrote:
 Seems to work correctly from my tests:



 CMakeLists.txt:

 cmake_minimum_required (VERSION 2.8)



 project(test CXX)

 message( STATUS CMAKE_GENERATOR: ${CMAKE_GENERATOR})

 message( STATUS CMAKE_CL_64: ${CMAKE_CL_64})







 c:\dev2\Builds\test\x64cmake -G Visual Studio 8 2005 ../.

 -- Check for working CXX compiler using: Visual Studio 8 2005

 -- Check for working CXX compiler using: Visual Studio 8 2005 -- works

 -- Detecting CXX compiler ABI info

 -- Detecting CXX compiler ABI info - done

 -- CMAKE_GENERATOR: Visual Studio 8 2005

 -- CMAKE_CL_64: 0

 -- Configuring done

 -- Generating done

 -- Build files have been written to: C:/dev2/Builds/test/x64





 c:\dev2\Builds\test\x86cmake -G Visual Studio 8 2005 Win64 ../.

 -- Check for working CXX compiler using: Visual Studio 8 2005 Win64

 -- Check for working CXX compiler using: Visual Studio 8 2005 Win64 --
works

 -- Detecting CXX compiler ABI info

 -- Detecting CXX compiler ABI info - done

 -- CMAKE_GENERATOR: Visual Studio 8 2005 Win64

 -- CMAKE_CL_64: 1

 -- Configuring done

 -- Generating done

 -- Build files have been written to: C:/dev2/Builds/test/x86



I believe you got your folder names backwards.
John


This email was sent to you by Thomson Reuters, the global news and information 
company.
Any views expressed in this message are those of the individual sender, except 
where the sender specifically states them to be the views of Thomson Reuters.


___
Powered by www.kitware.com

Visit other Kitware open-source projects at 
http://www.kitware.com/opensource/opensource.html

Please keep messages on-topic and check the CMake FAQ at: 
http://www.cmake.org/Wiki/CMake_FAQ

Follow this link to subscribe/unsubscribe:
http://www.cmake.org/mailman/listinfo/cmake