Unified · Split
| @@ -18,6 +18,8 @@ · 17 unmodified lines | ||
| 18 | 18 | * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. |
| 19 | 19 | */ |
| 20 | 20 | #define _GNU_SOURCE |
| 21 | +#include "config.h" | |
| 22 | + | |
| 21 | 23 | #include <stdlib.h> |
| 22 | 24 | #include <stdio.h> |
| 23 | 25 | #include <stdarg.h> |
| @@ -71,10 +73,6 @@ · 47 unmodified lines | ||
| 71 | 73 | /* define it to include assembler support */ |
| 72 | 74 | #define CONFIG_TCC_ASM |
| 73 | 75 | |
| 74 | −#ifndef CONFIG_TCC_PREFIX | |
| 75 | −#define CONFIG_TCC_PREFIX "/usr/local" | |
| 76 | −#endif | |
| 77 | − | |
| 78 | 76 | /* path to find crt1.o, crti.o and crtn.o. Only needed when generating |
| 79 | 77 | executables or dlls */ |
| 80 | 78 | #define CONFIG_TCC_CRT_PREFIX "/usr/lib" |
| @@ -332,7 +330,9 @@ static int do_debug = 0; · 251 unmodified lines | ||
| 332 | 330 | static int do_bounds_check = 0; |
| 333 | 331 | |
| 334 | 332 | /* display benchmark infos */ |
| 333 | +#if !defined(LIBTCC) | |
| 335 | 334 | static int do_bench = 0; |
| 335 | +#endif | |
| 336 | 336 | static int total_lines; |
| 337 | 337 | static int total_bytes; |
| 338 | 338 | |
| @@ -350,7 +350,7 @@ static const char **rt_bound_error_msg; · 11 unmodified lines | ||
| 350 | 350 | static struct TCCState *tcc_state; |
| 351 | 351 | |
| 352 | 352 | /* give the path of the tcc libraries */ |
| 353 | −static const char *tcc_lib_path = CONFIG_TCC_PREFIX "/lib/tcc"; | |
| 353 | +static const char *tcc_lib_path = CONFIG_TCC_LIBDIR "/tcc"; | |
| 354 | 354 | |
| 355 | 355 | struct TCCState { |
| 356 | 356 | int output_type; |
| @@ -9379,7 +9379,7 @@ static int64_t getclock_us(void) · 9022 unmodified lines | ||
| 9379 | 9379 | |
| 9380 | 9380 | void help(void) |
| 9381 | 9381 | { |
| 9382 | − printf("tcc version 0.9.16 - Tiny C Compiler - Copyright (C) 2001, 2002 Fabrice Bellard\n" | |
| 9382 | + printf("tcc version " TCC_VERSION " - Tiny C Compiler - Copyright (C) 2001, 2002 Fabrice Bellard\n" | |
| 9383 | 9383 | "usage: tcc [-c] [-o outfile] [-Bdir] [-bench] [-Idir] [-Dsym[=val]] [-Usym]\n" |
| 9384 | 9384 | " [-g] [-b] [-bt N] [-Ldir] [-llib] [-shared] [-static]\n" |
| 9385 | 9385 | " [--] infile1 [infile2... --] [infile_args...]\n" |