This is the mail archive of the
cygwin
mailing list for the Cygwin project.
RE: Cmake on cygwin64 fails with error "C compiler "/usr/bin/cc" is not able to compile a simple test program"
- From: Frank Brill <f dot brill at samsung dot com>
- To: "cygwin at cygwin dot com" <cygwin at cygwin dot com>
- Date: Tue, 21 Jun 2016 22:19:42 +0000
- Subject: RE: Cmake on cygwin64 fails with error "C compiler "/usr/bin/cc" is not able to compile a simple test program"
- Authentication-results: sourceware.org; auth=none
- References: <ee151bc17b85475c885fb8dd1bfef9da at sraex01sc dot sisa dot samsung dot com> <12e058e5-9492-095c-15e3-7c0d07765cf3 at t-online dot de>
Tony Kelman writes:
> I'm at a conference this week so really busy, but it sounds like I may
> need to update cmake to the latest version (which is overdue anyway)
> if something in the latest gcc is unhappy. Can you provide full
> reproduction steps, a source repo or tarball to download? Also looking
> into (and posting) the full content of the cmake error/output log
> files might provide more information about what the problem is
I made the world's smallest example, taken from the CMake tutorial.
There's a CMakeLists.txt that contains this:
cmake_minimum_required (VERSION 2.6)
project (Tutorial)
add_executable(Tutorial tutorial.cxx)
and a tutorial.cxx that contains this:
// A simple program that computes the square root of a number
#include <stdio.h>
#include <stdlib.h>
#include <math.h>
int main (int argc, char *argv[])
{
if (argc < 2)
{
fprintf(stdout,"Usage: %s number\n",argv[0]);
return 1;
}
double inputValue = atof(argv[1]);
double outputValue = sqrt(inputValue);
fprintf(stdout,"The square root of %g is %g\n",
inputValue, outputValue);
return 0;
}
Just create the two files above and do:
$ cmake .
$ make
$ ./Tutorial 2
On 32-bit Cygwin, it all works nicely as expected. But on my fresh 64-bit
installation, I get the " not able to compile a simple test program" message.
I think Hans-Bernhard's theory that there's some other app interfering is
probably correct, and it probably has something to do with my company's
security software.
I will post more information in subsequent posts that hopefully stay under
the "spam score threshold".
--
Problem reports: http://cygwin.com/problems.html
FAQ: http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple