[CMake] howto retrigger check_function_exists
J Decker
d3ck0r at gmail.com
Thu Aug 18 15:24:25 EDT 2016
I don't understand how this works....
info_size[1] will return 'N'
how will it know it has to pass like 14 arguments to get the right
character? And even then the character '4' is not the value 4.
- this is the code generated for check_type_size
#include <sys/types.h>
#include <stdint.h>
#include <stddef.h>
#include "time.h"
#undef KEY
#if defined(__i386)
# define KEY '_','_','i','3','8','6'
#elif defined(__x86_64)
# define KEY '_','_','x','8','6','_','6','4'
#elif defined(__ppc__)
# define KEY '_','_','p','p','c','_','_'
#elif defined(__ppc64__)
# define KEY '_','_','p','p','c','6','4','_','_'
#endif
#define SIZE (sizeof(time_t))
char info_size[] = {'I', 'N', 'F', 'O', ':', 's','i','z','e','[',
('0' + ((SIZE / 10000)%10)),
('0' + ((SIZE / 1000)%10)),
('0' + ((SIZE / 100)%10)),
('0' + ((SIZE / 10)%10)),
('0' + (SIZE % 10)),
']',
#ifdef KEY
' ','k','e','y','[', KEY, ']',
#endif
'\0'};
#ifdef __CLASSIC_C__
int main(argc, argv) int argc; char *argv[];
#else
int main(int argc, char *argv[])
#endif
{
int require = 0;
require += info_size[argc];
(void)argv;
return require;
}
On Thu, Aug 18, 2016 at 11:50 AM, J Decker <d3ck0r at gmail.com> wrote:
> I was trying to add some libraries for CMAKE_REQUIRED_LIBRARIES to be able
> to find more symbols, but changing that didn't cause the
> check_function-0exists to re-run; is there a shorter way to get it to
> re-run without deleting CMakeCache.txt?
> I'm not abject to manually editing files; I had tried to remove just the
> cached variable reference, but that didn't help.
>
> Same for check_type_size() I guess
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/cmake/attachments/20160818/41ff2d03/attachment-0001.html>
More information about the CMake
mailing list