[CMake] [Insight-developers] 64 bit build detection

Hendrik Sattler post at hendrik-sattler.de
Thu Jun 18 03:25:54 EDT 2009


Zitat von Michael Wild <themiwi at gmail.com>:
> Above code for sure is far from ideal or perfect. But sometimes one
> inherits a code which relies on such details, so here is one relatively
> simple way to deal with it.

Agreed. But preparing old code for current reuse sometimes involves  
updating it to current standards. And when having 64bit issues, this  
is the only sane way.

> And I somehow doubt that there are many
> codes running both on x86/ppc and iPhone...

I don't, at least libraries are most likely to do so.

> Besides, uint32_t and
> related are not present on Windows, so using them is going to break the
> code there.

They are for MSVC > 6, MS compilers for embedded systems and gcc. No  
real problem, there: http://code.google.com/p/msinttypes/

In openobex' CMake build, I put them under include/msvc and use that  
if 'MSVC' is true. You can also do that with other things like  
unistd.h under MSVC.

HS




More information about the CMake mailing list