[CMake] cmake config.h
luxInteg
lux-integ at btconnect.com
Sun Nov 28 09:04:50 EST 2010
On Saturday 27 November 2010 14:58:15 Michael Jackson wrote:
> # In this file we are doing all of our 'configure' checks. Things like
> checking # for headers, functions, libraries, types and size of types.
> INCLUDE (${CMAKE_ROOT}/Modules/CheckIncludeFile.cmake)
.. > # To check for an include file you do this:
> CHECK_INCLUDE_FILE("stdint.h" HAVE_STDINT_H)
this I find straightforward
On Saturday 27 November 2010 14:58:15 Michael Jackson wrote:
> # In this file we are doing all of our 'configure' checks. Things like
> checking # for headers, functions, libraries, types and size of types.
> INCLUDE (${CMAKE_ROOT}/Modules/CheckFunctionExists.cmake)
I presume can be used aas for example:-
CHECK_FUNCTION_EXISTS(pow HAVE_POW)
CHECK_FUNCTION_EXISTS(realloc HAVE_HAVE_REALLOC) etc etc
On Saturday 27 November 2010 14:58:15 Michael Jackson wrote:
> # To check the size of a primitive type:
> CHECK_TYPE_SIZE("int" SIZEOF_INT)
QUESTION:
the ones that frequently come into what I do are long, zint, dzint (complex)
So would these translate to
CHECK_TYPE_SIZE("long" SIZEOF_LONG) etc etc ?
On Saturday 27 November 2010 14:58:15 Michael Jackson wrote:
> # In this file we are doing all of our 'configure' checks. Things like
> checking # for headers, functions, libraries, types and size of types.
> INCLUDE (${CMAKE_ROOT}/Modules/CheckCXXSourceCompiles.cmake)
> INCLUDE (${CMAKE_ROOT}/Modules/TestBigEndian.cmake)
> INCLUDE (${CMAKE_ROOT}/Modules/CheckSymbolExists.cmake)
headers, datatypes, functions seem straight forward, I currently have a
config.h.in refering to 'package' (I assume something to do with pkgconfig
) for which I have not a clue how to translate using the tools above:-
The said problematic config.h.in file has lines like these:-
-----------------------------
/* Name of package */
#undef PACKAGE
/* Define to the address where bug reports for this package should be sent. */
#undef PACKAGE_BUGREPORT
/* Define to the full name of this package. */
#undef PACKAGE_NAME
/* Define to the full name and version of this package. */
#undef PACKAGE_STRING
/* Define to the one symbol short name of this package. */
#undef PACKAGE_TARNAME
/* Define to the version of this package. */
#undef PACKAGE_VERSION
/* Version number of package */
#undef VERSION
/* Define to empty if `const' does not conform to ANSI C. */
#undef const
/* Define to rpl_malloc if the replacement function should be used. */
#undef malloc
/* Define to rpl_realloc if the replacement function should be used. */
#undef realloc
-----------------------
thanks again for your suggestion and advice on the above would be
apprecuated
More information about the CMake
mailing list