VirtualBox

Changeset 2591 in kBuild for trunk/src/kmk/make.h


Ignore:
Timestamp:
Jun 17, 2012 8:45:31 PM (13 years ago)
Author:
bird
Message:

kmk: Merged in changes from GNU make 3.82. Previous GNU make base version was gnumake-2008-10-28-CVS.

Location:
trunk/src/kmk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/kmk

    • Property svn:ignore
      •  

        old new  
        1313stamp-*
        1414makebook*
         15
        1516.*gdbinit
         17.gdb_history
         18
        1619*.dep
        1720*.dvi
         
        3134*.pg
        3235*.pgs
         36
        3337README
        3438README.DOS
        3539README.W32
         40README.OS2
        3641aclocal.m4
        3742autom4te.cache
         
        5257config.h.W32
        5358config.h-vms
         59
        5460loadavg
        5561loadavg.c
        5662make
         63
        5764.deps
        5865.dep_segment
         66ID
         67TAGS
         68
        5969_*
        6070sun4
         
        7282sol2
        7383i486-linux
         84
        7485customs
         86
        7587install-sh
        7688mkinstalldirs
         89
         90.directive.asc
  • trunk/src/kmk/make.h

    r2548 r2591  
    11/* Miscellaneous global declarations and portability cruft for GNU Make.
    22Copyright (C) 1988, 1989, 1990, 1991, 1992, 1993, 1994, 1995, 1996, 1997,
    3 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007 Free Software
    4 Foundation, Inc.
     31998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008, 2009,
     42010 Free Software Foundation, Inc.
    55This file is part of GNU Make.
    66
     
    2424#define HAVE_CONFIG_H 1
    2525
     26/* Specify we want GNU source code.  This must be defined before any
     27   system headers are included.  */
     28
     29#define _GNU_SOURCE 1
     30
    2631/* AIX requires this to be the first thing in the file.  */
    27 #ifndef __GNUC__
    28 # if HAVE_ALLOCA_H
    29 #  include <alloca.h>
    30 # else
    31 #  ifdef _AIX
     32#if HAVE_ALLOCA_H
     33# include <alloca.h>
     34#else
     35# ifdef _AIX
    3236 #pragma alloca
    33 #  else
     37# else
     38#  if !defined(__GNUC__) && !defined(WINDOWS32)
    3439#   ifndef alloca /* predefined by HP cc +Olibcalls */
    3540char *alloca ();
     
    3742#  endif
    3843# endif
    39 #elif defined(__sun__) && defined (HAVE_ALLOCA_H) /* bird: kill warnings. */
    40 # include <alloca.h>
    41 #endif
    42 
    43 
    44 /* Specify we want GNU source code.  This must be defined before any
    45    system headers are included.  */
    46 
    47 #define _GNU_SOURCE 1
     44#endif
    4845
    4946
     
    240237#endif
    241238
     239/* bird - start */
     240#define COMMA ,
     241#ifdef CONFIG_WITH_VALUE_LENGTH
     242# define IF_WITH_VALUE_LENGTH(a_Expr)           a_Expr
     243# define IF_WITH_VALUE_LENGTH_PARAM(a_Expr)     , a_Expr
     244#else
     245# define IF_WITH_VALUE_LENGTH(a_Expr)
     246# define IF_WITH_VALUE_LENGTH_PARAM(a_Expr)
     247#endif
     248
     249#ifdef CONFIG_WITH_ALLOC_CACHES
     250# define IF_WITH_ALLOC_CACHES(a_Expr)           a_Expr
     251# define IF_WITH_ALLOC_CACHES_PARAM(a_Expr)     , a_Expr
     252#else
     253# define IF_WITH_ALLOC_CACHES(a_Expr)
     254# define IF_WITH_ALLOC_CACHES_PARAM(a_Expr)
     255#endif
     256
     257#ifdef CONFIG_WITH_COMMANDS_FUNC
     258# define IF_WITH_COMMANDS_FUNC(a_Expr)          a_Expr
     259# define IF_WITH_COMMANDS_FUNC_PARAM(a_Expr)    , a_Expr
     260#else
     261# define IF_WITH_COMMANDS_FUNC(a_Expr)
     262# define IF_WITH_COMMANDS_FUNC_PARAM(a_Expr)
     263#endif
     264
     265/* bird - end */
     266
    242267
    243268#ifndef CHAR_BIT
     
    363388#define ISDIGIT(c) ((unsigned) (c) - '0' <= 9)
    364389
    365 #ifndef iAPX286
    366 # define streq(a, b) \
     390/* Test if two strings are equal. Is this worthwhile?  Should be profiled.  */
     391#define streq(a, b) \
    367392   ((a) == (b) || \
    368393    (*(a) == *(b) && (*(a) == '\0' || !strcmp ((a) + 1, (b) + 1))))
    369 # ifdef HAVE_CASE_INSENSITIVE_FS
    370 #  define strieq(a, b) \
     394
     395/* Test if two strings are equal, but match case-insensitively on systems
     396   which have case-insensitive filesystems.  Should only be used for
     397   filenames!  */
     398#ifdef HAVE_CASE_INSENSITIVE_FS
     399# define patheq(a, b) \
    371400    ((a) == (b) \
    372401     || (tolower((unsigned char)*(a)) == tolower((unsigned char)*(b)) \
    373402         && (*(a) == '\0' || !strcasecmp ((a) + 1, (b) + 1))))
    374 # else
    375 #  define strieq(a, b) streq(a, b)
    376 # endif
    377 #else
    378 /* Buggy compiler can't handle this.  */
    379 # define streq(a, b) (strcmp ((a), (b)) == 0)
    380 # define strieq(a, b) (strcmp ((a), (b)) == 0)
    381 #endif
     403#else
     404# define patheq(a, b) streq(a, b)
     405#endif
     406
    382407#define strneq(a, b, l) (strncmp ((a), (b), (l)) == 0)
    383408
     
    425450
    426451void sync_Path_environment (void);
    427 int w32_kill (int pid, int sig);
     452int w32_kill (pid_t pid, int sig);
    428453char *end_of_token_w32 (const char *s, char stopchar);
    429454int find_and_set_default_shell (const char *token);
     
    435460extern int unixy_shell;
    436461#endif  /* WINDOWS32 */
     462
     463#if defined(HAVE_SYS_RESOURCE_H) && defined(HAVE_GETRLIMIT) && defined(HAVE_SETRLIMIT)
     464# define SET_STACK_SIZE
     465#endif
     466#ifdef SET_STACK_SIZE
     467# include <sys/resource.h>
     468struct rlimit stack_limit;
     469#endif
    437470
    438471struct floc
     
    475508
    476509#if HAVE_ANSI_COMPILER && USE_VARIADIC && HAVE_STDARG_H
     510const char *concat (unsigned int, ...);
    477511void message (int prefix, const char *fmt, ...)
    478512              __attribute__ ((__format__ (__printf__, 2, 3)));
     
    482516                   __attribute__ ((noreturn, __format__ (__printf__, 2, 3)));
    483517#else
     518const char *concat ();
    484519void message ();
    485520void error ();
     
    491526void pfatal_with_name (const char *) __attribute__ ((noreturn));
    492527void perror_with_name (const char *, const char *);
    493 char *savestring (const char *, unsigned int);
    494 char *concat (const char *, const char *, const char *);
    495528void *xmalloc (unsigned int);
     529void *xcalloc (unsigned int);
    496530void *xrealloc (void *, unsigned int);
    497531char *xstrdup (const char *);
     532char *xstrndup (const char *, unsigned int);
    498533#ifdef CONFIG_WITH_PRINT_STATS_SWITCH
    499534void print_heap_stats (void);
     
    553588void build_vpath_lists (void);
    554589void construct_vpath_list (char *pattern, char *dirpath);
    555 const char *vpath_search (const char *file, FILE_TIMESTAMP *mtime_ptr);
     590const char *vpath_search (const char *file, FILE_TIMESTAMP *mtime_ptr,
     591                          unsigned int* vpath_index, unsigned int* path_index);
    556592int gpath_search (const char *file, unsigned int len);
    557593
     
    696732#endif
    697733
     734#if !HAVE_STRNCASECMP
     735# if HAVE_STRNICMP
     736#  define strncasecmp strnicmp
     737# elif HAVE_STRNCMPI
     738#  define strncasecmp strncmpi
     739# else
     740/* Create our own, in misc.c */
     741int strncasecmp (const char *s1, const char *s2, int n);
     742# endif
     743#endif
     744
    698745extern const struct floc *reading_file;
    699746extern const struct floc **expanding_var;
     
    709756extern int warn_undefined_variables_flag, posix_pedantic, not_parallel;
    710757extern int second_expansion, clock_skew_detected, rebuilding_makefiles;
     758extern int one_shell;
     759
    711760#ifdef CONFIG_WITH_2ND_TARGET_EXPANSION
    712761extern int second_target_expansion;
Note: See TracChangeset for help on using the changeset viewer.

© 2025 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette