0

I recently discovered the Tiny C Compiler. For the project that I'm currently working on, performance is not a real issue, but file size is, making TCC ideal. I'm using Autotools as a build manager, and I figured that using TCC would be as simple as ./configure CC=tcc.

However, this returns checking whether the C compiler works... no. In config.log, it says configure: exit 77.

Despite all of this, setting CC=clang works fine. Is there any way to get Autotools to use TCC?

Colin Atkinson
  • 986
  • 1
  • 9
  • 18
  • automake has only recently been addding support (partial) for tcc. Check if you have tools that have this support. See https://lists.gnu.org/archive/html/autotools-announce/2012-12/msg00001.html – mikijov May 04 '13 at 23:37
  • My version of Autotools seems to support it. However, the issue appears to have been with my CFLAGS. – Colin Atkinson May 05 '13 at 20:55

2 Answers2

1

The issue appears to have been the fault of my CFLAGS. While TCC was normally able to compile programs with them, Autotools seems to have thought otherwise. Setting CFLAGS="" resolved the issue.

For future reference, my CFLAGS are -march=native -mtune=native -O2 -pipe -fstack-protector --param=ssp-buffer-size=4.

Colin Atkinson
  • 986
  • 1
  • 9
  • 18
0

iirc tcc does not produce tiny executables - it is tcc itself that is tiny. Perhaps you're looking for gcc -Os?

fadedbee
  • 42,671
  • 44
  • 178
  • 308